libgpac
Documentation of the core library of GPAC
compositor.h File Reference

GPAC A/V/2D/3D compositor/rendering. More...

#include <gpac/scenegraph.h>
#include <gpac/events.h>
#include <gpac/color.h>
+ Include dependency graph for compositor.h:
+ This graph shows which files directly or indirectly include this file:

Enumerations

enum  GF_CompositorGrabMode { GF_SC_GRAB_DEPTH_NONE = 0 , GF_SC_GRAB_DEPTH_ONLY = 1 , GF_SC_GRAB_DEPTH_RGBD = 2 , GF_SC_GRAB_DEPTH_RGBDS = 3 }
 
enum  { GF_ASPECT_RATIO_KEEP = 0 , GF_ASPECT_RATIO_16_9 , GF_ASPECT_RATIO_4_3 , GF_ASPECT_RATIO_FILL_SCREEN }
 
enum  { GF_ANTIALIAS_NONE = 0 , GF_ANTIALIAS_TEXT , GF_ANTIALIAS_FULL }
 
enum  { GF_STATE_PLAYING = 0 , GF_STATE_PAUSED , GF_STATE_STEP_PAUSE , GF_STATE_PLAY_LIVE = 10 }
 
enum  { GF_INTERACT_NORMAL = 1 , GF_INTERACT_INPUT_SENSOR = 2 , GF_INTERACT_NAVIGATION = 4 }
 
enum  { GF_BOUNDS_NONE = 0 , GF_BOUNDS_BOX , GF_BOUNDS_AABB }
 
enum  { GF_WIREFRAME_NONE = 0 , GF_WIREFRAME_ONLY , GF_WIREFRAME_SOLID }
 
enum  { GF_NAVIGATE_TYPE_NONE , GF_NAVIGATE_TYPE_2D , GF_NAVIGATE_TYPE_3D }
 
enum  {
  GF_NAVIGATE_NONE = 0 , GF_NAVIGATE_WALK , GF_NAVIGATE_FLY , GF_NAVIGATE_PAN ,
  GF_NAVIGATE_GAME , GF_NAVIGATE_SLIDE , GF_NAVIGATE_EXAMINE , GF_NAVIGATE_ORBIT ,
  GF_NAVIGATE_VR
}
 
enum  { GF_COLLISION_NONE , GF_COLLISION_NORMAL , GF_COLLISION_DISPLACEMENT }
 
enum  { GF_TEXTURE_TEXT_DEFAULT = 0 , GF_TEXTURE_TEXT_NEVER , GF_TEXTURE_TEXT_ALWAYS }
 
enum  { GF_NORMALS_NONE = 0 , GF_NORMALS_FACE , GF_NORMALS_VERTEX }
 
enum  { GF_BACK_CULL_OFF = 0 , GF_BACK_CULL_ON , GF_BACK_CULL_ALPHA }
 
enum  { GF_DRAW_MODE_DEFER =0 , GF_DRAW_MODE_IMMEDIATE , GF_DRAW_MODE_DEFER_DEBUG }
 
enum  GF_CompositorOption {
  GF_OPT_ANTIALIAS =0 , GF_OPT_HIGHSPEED , GF_OPT_FULLSCREEN , GF_OPT_ORIGINAL_VIEW ,
  GF_OPT_OVERRIDE_SIZE , GF_OPT_AUDIO_VOLUME , GF_OPT_AUDIO_PAN , GF_OPT_AUDIO_MUTE ,
  GF_OPT_HAS_JAVASCRIPT , GF_OPT_CAN_SELECT_STREAMS , GF_OPT_INTERACTION_LEVEL , GF_OPT_VISIBLE ,
  GF_OPT_FREEZE_DISPLAY , GF_OPT_IS_FINISHED , GF_OPT_IS_OVER , GF_OPT_ASPECT_RATIO ,
  GF_OPT_REFRESH , GF_OPT_STRESS_MODE , GF_OPT_DRAW_BOUNDS , GF_OPT_TEXTURE_TEXT ,
  GF_OPT_RELOAD_CONFIG , GF_OPT_NAVIGATION_TYPE , GF_OPT_NAVIGATION , GF_OPT_PLAY_STATE ,
  GF_OPT_MAIN_ADDON , GF_OPT_VIDEO_BENCH , GF_OPT_USE_OPENGL , GF_OPT_DRAW_MODE ,
  GF_OPT_SCALABLE_ZOOM , GF_OPT_YUV_HARDWARE , GF_OPT_YUV_FORMAT , GF_OPT_VIDEO_CACHE_SIZE ,
  GF_OPT_HTTP_MAX_RATE , GF_OPT_FORCE_AUDIO_CONFIG , GF_OPT_RASTER_OUTLINES , GF_OPT_EMULATE_POW2 ,
  GF_OPT_POLYGON_ANTIALIAS , GF_OPT_WIREFRAME , GF_OPT_NORMALS , GF_OPT_BACK_CULL ,
  GF_OPT_NO_RECT_TEXTURE , GF_OPT_HEADLIGHT , GF_OPT_COLLISION , GF_OPT_GRAVITY ,
  GF_OPT_NUM_STEREO_VIEWS , GF_OPT_MULTIVIEW_MODE , GF_OPT_ORIENTATION_SENSORS_ACTIVE
}
 

Functions

GF_Err gf_sc_load (GF_Compositor *compositor)
 
void gf_sc_unload (GF_Compositor *compositor)
 
void gf_sc_set_fps (GF_Compositor *compositor, GF_Fraction fps)
 
GF_Err gf_sc_set_scene (GF_Compositor *compositor, GF_SceneGraph *scene_graph)
 
Bool gf_sc_draw_frame (GF_Compositor *compositor, Bool no_video_flush, s32 *ms_till_next)
 
void gf_sc_invalidate (GF_Compositor *compositor, GF_Node *node)
 
void gf_sc_invalidate_next_frame (GF_Compositor *compositor)
 
Bool gf_sc_frame_was_produced (GF_Compositor *compositor)
 
u32 gf_sc_get_clock (GF_Compositor *compositor)
 
void gf_sc_node_destroy (GF_Compositor *compositor, GF_Node *node, GF_SceneGraph *sg)
 
void gf_sc_lock (GF_Compositor *compositor, Bool do_lock)
 
Bool gf_sc_user_event (GF_Compositor *compositor, GF_Event *event)
 
void gf_sc_disconnect (GF_Compositor *compositor)
 
void gf_sc_connect_from_time (GF_Compositor *compositor, const char *URL, u64 startTime, u32 pause_at_first_frame, Bool secondary_scene, const char *parent_path)
 
void gf_sc_map_point (GF_Compositor *compositor, s32 X, s32 Y, Fixed *bifsX, Fixed *bifsY)
 
Double gf_sc_get_fps (GF_Compositor *compositor, Bool absoluteFPS)
 
Bool gf_sc_has_text_selection (GF_Compositor *compositor)
 
const char * gf_sc_get_selected_text (GF_Compositor *compositor)
 
GF_Err gf_sc_paste_text (GF_Compositor *compositor, const char *text)
 
GF_Err gf_sc_add_object (GF_Compositor *compositor, const char *url, Bool auto_play)
 
GF_Err gf_sc_get_screen_buffer (GF_Compositor *compositor, GF_VideoSurface *framebuffer, GF_CompositorGrabMode depth_grab_mode)
 
GF_Err gf_sc_get_offscreen_buffer (GF_Compositor *compositor, GF_VideoSurface *framebuffer, u32 view_idx, GF_CompositorGrabMode depth_grab_mode)
 
GF_Err gf_sc_release_screen_buffer (GF_Compositor *compositor, GF_VideoSurface *framebuffer)
 
void gf_sc_reset_graphics (GF_Compositor *compositor)
 
GF_Err gf_sc_get_viewpoint (GF_Compositor *compositor, u32 viewpoint_idx, const char **out_name, Bool *is_bound)
 
GF_Err gf_sc_set_viewpoint (GF_Compositor *compositor, u32 viewpoint_idx, const char *viewpoint_name)
 
void gf_sc_traverse_subscene (GF_Compositor *compositor, GF_Node *inline_parent, GF_SceneGraph *subscene, void *rs)
 
GF_Err gf_sc_set_size (GF_Compositor *compositor, u32 new_width, u32 new_height)
 
void gf_sc_register_extra_graph (GF_Compositor *compositor, GF_SceneGraph *extra_scene, Bool do_remove)
 
GF_Compositor * gf_sc_get_compositor (GF_Node *node)
 
Bool gf_sc_script_action (GF_Compositor *compositor, GF_JSAPIActionType type, GF_Node *node, GF_JSAPIParam *param)
 
Bool gf_sc_uri_is_hardcoded_proto (GF_Compositor *compositor, const char *uri)
 
void gf_sc_reload_config (GF_Compositor *compositor)
 
u32 gf_sc_get_time_in_ms (GF_Compositor *compositor)
 
void gf_sc_switch_quality (GF_Compositor *compositor, Bool up)
 
void gf_sc_toggle_addons (GF_Compositor *compositor, Bool show_addons)
 
GF_Err gf_sc_set_speed (GF_Compositor *compositor, Fixed speed)
 
Bool gf_sc_is_supported_url (GF_Compositor *compositor, const char *URL, Bool use_parent_url)
 
void gf_sc_navigate_to (GF_Compositor *compositor, const char *toURL)
 
u32 gf_sc_play_from_time (GF_Compositor *compositor, u64 from_time, u32 pause_at_first_frame)
 
GF_Err gf_sc_dump_scene (GF_Compositor *compositor, char *rad_name, char **filename, Bool xml_dump, Bool skip_proto)
 
GF_Err gf_sc_scene_update (GF_Compositor *compositor, char *type, char *com)
 
void gf_sc_select_service (GF_Compositor *compositor, u32 service_id)
 
const char * gf_sc_get_url (GF_Compositor *compositor)
 
const void * gf_sc_get_main_pid (GF_Compositor *compositor)
 
const char * gf_sc_get_world_info (GF_Compositor *compositor, GF_List *descriptions)
 
u32 gf_sc_get_current_service_id (GF_Compositor *compositor)
 
Double gf_sc_get_simulation_frame_rate (GF_Compositor *compositor, u32 *nb_frames_drawn)
 
GF_Err gf_sc_set_option (GF_Compositor *compositor, GF_CompositorOption type, u32 value)
 
u32 gf_sc_get_option (GF_Compositor *compositor, GF_CompositorOption type)
 

Detailed Description

>