libgpac
Documentation of the core library of GPAC
base_scenegraph.c File Reference
#include <gpac/internal/scenegraph_dev.h>
#include <gpac/scenegraph_svg.h>
#include <gpac/nodes_mpeg4.h>
#include <gpac/nodes_x3d.h>
#include <gpac/events.h>
#include <gpac/nodes_svg.h>
#include <gpac/xml.h>
+ Include dependency graph for base_scenegraph.c:

Functions

static void ReplaceDEFNode (GF_Node *FromNode, GF_Node *node, GF_Node *newNode, Bool updateOrderedGroup)
 
static void ReplaceIRINode (GF_Node *FromNode, GF_Node *oldNode, GF_Node *newNode)
 
static void node_modif_stub (GF_SceneGraph *sg, GF_Node *node, GF_FieldInfo *info, GF_Node *script)
 
GF_EXPORT GF_SceneGraph * gf_sg_new ()
 
GF_EXPORT GF_SceneGraph * gf_sg_new_subscene (GF_SceneGraph *scene)
 
GF_EXPORT void gf_sg_set_node_callback (GF_SceneGraph *sg, gf_sg_node_init_callback NodeCallback)
 
GF_EXPORT void gf_sg_set_scene_time_callback (GF_SceneGraph *sg, Double(*GetSceneTime)(void *user_priv))
 
GF_EXPORT Double gf_node_get_scene_time (GF_Node *node)
 
GF_EXPORT void gf_sg_del (GF_SceneGraph *sg)
 
GFINLINE GF_NodeSG_SearchForNode (GF_SceneGraph *sg, GF_Node *node)
 
static GFINLINE u32 get_num_id_nodes (GF_SceneGraph *sg)
 
GF_EXPORT void gf_sg_reset (GF_SceneGraph *sg)
 
GFINLINE GF_NodeSG_SearchForDuplicateNodeID (GF_SceneGraph *sg, u32 nodeID, GF_Node *toExclude)
 
GF_EXPORT void gf_sg_set_private (GF_SceneGraph *sg, void *ptr)
 
GF_EXPORT void * gf_sg_get_private (GF_SceneGraph *sg)
 
GF_EXPORT void gf_sg_set_scene_size_info (GF_SceneGraph *sg, u32 width, u32 height, Bool usePixelMetrics)
 
GF_EXPORT Bool gf_sg_use_pixel_metrics (GF_SceneGraph *sg)
 
GF_EXPORT Bool gf_sg_get_scene_size_info (GF_SceneGraph *sg, u32 *width, u32 *height)
 
GF_EXPORT GF_Nodegf_sg_get_root_node (GF_SceneGraph *sg)
 
GF_EXPORT void gf_sg_set_root_node (GF_SceneGraph *sg, GF_Node *node)
 
void remove_node_id (GF_SceneGraph *sg, GF_Node *node)
 
GF_Err gf_node_try_destroy (GF_SceneGraph *sg, GF_Node *pNode, GF_Node *parentNode)
 
GF_EXPORT GF_Err gf_node_unregister (GF_Node *pNode, GF_Node *parentNode)
 
GF_EXPORT GF_Err gf_node_register (GF_Node *node, GF_Node *parentNode)
 
static void Replace_IRI (GF_SceneGraph *sg, GF_Node *old_node, GF_Node *newNode)
 
GF_EXPORT GF_Err gf_node_replace (GF_Node *node, GF_Node *new_node, Bool updateOrderedGroup)
 
static GFINLINE void insert_node_def (GF_SceneGraph *sg, GF_Node *def, u32 ID, const char *name)
 
GF_EXPORT GF_Err gf_node_set_id (GF_Node *p, u32 ID, const char *name)
 
GF_EXPORT GF_Err gf_node_remove_id (GF_Node *p)
 
GF_EXPORT void gf_node_traverse (GF_Node *node, void *renderStack)
 
GF_EXPORT void gf_node_allow_cyclic_traverse (GF_Node *node)
 
GF_EXPORT Bool gf_node_set_cyclic_traverse_flag (GF_Node *node, Bool on)
 
GF_EXPORT void gf_node_traverse_children (GF_Node *node, void *renderStack)
 
GF_EXPORT GF_SceneGraph * gf_node_get_graph (GF_Node *node)
 
GF_EXPORT GF_Nodegf_sg_find_node (GF_SceneGraph *sg, u32 nodeID)
 
GF_EXPORT GF_Nodegf_sg_find_node_by_name (GF_SceneGraph *sg, char *name)
 
GF_EXPORT u32 gf_sg_get_next_available_node_id (GF_SceneGraph *sg)
 
GF_EXPORT u32 gf_sg_get_max_node_id (GF_SceneGraph *sg)
 
void gf_node_setup (GF_Node *p, u32 tag)
 
GF_Nodegf_sg_new_base_node ()
 
GF_EXPORT u32 gf_node_get_tag (GF_Node *p)
 
GF_EXPORT u32 gf_node_get_id (GF_Node *p)
 
GF_EXPORT const char * gf_node_get_name (GF_Node *p)
 
GF_EXPORT const char * gf_node_get_name_and_id (GF_Node *p, u32 *id)
 
GF_EXPORT void * gf_node_get_private (GF_Node *p)
 
GF_EXPORT void gf_node_set_private (GF_Node *p, void *pr)
 
GF_EXPORT GF_Err gf_node_set_callback_function (GF_Node *p, void(*TraverseNode)(GF_Node *node, void *render_stack, Bool is_destroy))
 
void gf_sg_parent_setup (GF_Node *node)
 
GF_EXPORT void gf_node_unregister_children (GF_Node *container, GF_ChildNodeItem *child)
 
GF_EXPORT GF_Err gf_node_list_insert_child (GF_ChildNodeItem **list, GF_Node *n, u32 pos)
 
GF_EXPORT GF_Nodegf_node_list_get_child (GF_ChildNodeItem *list, s32 pos)
 
GF_EXPORT s32 gf_node_list_find_child (GF_ChildNodeItem *list, GF_Node *n)
 
GF_EXPORT GF_Err gf_node_list_add_child (GF_ChildNodeItem **list, GF_Node *n)
 
GF_EXPORT GF_Err gf_node_list_add_child_last (GF_ChildNodeItem **list, GF_Node *n, GF_ChildNodeItem **last_child)
 
GF_EXPORT Bool gf_node_list_del_child (GF_ChildNodeItem **list, GF_Node *n)
 
GF_EXPORT GF_Nodegf_node_list_del_child_idx (GF_ChildNodeItem **list, u32 pos)
 
GF_EXPORT u32 gf_node_list_get_count (GF_ChildNodeItem *list)
 
void gf_sg_parent_reset (GF_Node *node)
 
void gf_node_free (GF_Node *node)
 
GF_EXPORT u32 gf_node_get_parent_count (GF_Node *node)
 
GF_EXPORT GF_Nodegf_node_get_parent (GF_Node *node, u32 idx)
 
static void dirty_children (GF_Node *node)
 
static void dirty_parents (GF_Node *node)
 
GF_EXPORT void gf_node_dirty_parent_graph (GF_Node *node)
 
GF_EXPORT void gf_node_dirty_set (GF_Node *node, u32 flags, Bool and_dirty_parents)
 
GF_EXPORT void gf_node_dirty_parents (GF_Node *node)
 
GF_EXPORT void gf_node_dirty_clear (GF_Node *node, u32 flag_to_remove)
 
GF_EXPORT u32 gf_node_dirty_get (GF_Node *node)
 
GF_EXPORT void gf_node_dirty_reset (GF_Node *node, Bool reset_children)
 
GF_EXPORT void gf_node_init (GF_Node *node)
 
void gf_node_changed_internal (GF_Node *node, GF_FieldInfo *field, Bool notify_scripts)
 
GF_EXPORT void gf_node_changed (GF_Node *node, GF_FieldInfo *field)
 
void gf_node_del (GF_Node *node)
 
GF_EXPORT u32 gf_node_get_field_count (GF_Node *node)
 
GF_EXPORT const char * gf_node_get_class_name (GF_Node *node)
 
GF_EXPORT GF_Nodegf_node_new (GF_SceneGraph *inScene, u32 tag)
 
GF_EXPORT GF_Err gf_node_get_field (GF_Node *node, u32 FieldIndex, GF_FieldInfo *info)
 
u32 gf_node_get_num_instances (GF_Node *node)
 
static GF_Err gf_node_get_field_by_name_enum (GF_Node *node, char *name, GF_FieldInfo *field)
 
GF_EXPORT GF_Err gf_node_get_field_by_name (GF_Node *node, char *name, GF_FieldInfo *field)
 
const char * gf_node_get_log_name (GF_Node *anim)
 
static GF_Err gf_node_deactivate_ex (GF_Node *node)
 
GF_Err gf_node_deactivate (GF_Node *node)
 
static u32 gf_node_activate_ex (GF_Node *node)
 
GF_Err gf_node_activate (GF_Node *node)
 
GF_EXPORT GF_Nodegf_node_clone (GF_SceneGraph *inScene, GF_Node *orig, GF_Node *cloned_parent, char *id, Bool deep)
 
GF_NamespaceType gf_xml_get_namespace_id (char *name)
 
GF_EXPORT GF_Err gf_sg_add_namespace (GF_SceneGraph *sg, char *name, char *qname)
 
GF_Err gf_sg_remove_namespace (GF_SceneGraph *sg, char *ns_name, char *q_name)
 
GF_NamespaceType gf_sg_get_namespace_code (GF_SceneGraph *sg, char *qname)
 
GF_NamespaceType gf_sg_get_namespace_code_from_name (GF_SceneGraph *sg, char *name)
 
const char * gf_sg_get_namespace_qname (GF_SceneGraph *sg, GF_NamespaceType xmlns_id)
 
const char * gf_sg_get_namespace (GF_SceneGraph *sg, GF_NamespaceType xmlns_id)
 
GF_EXPORT GF_Err gf_node_replace_child (GF_Node *node, GF_ChildNodeItem **container, s32 pos, GF_Node *newNode)
 
GF_EXPORT Bool gf_node_parent_of (GF_Node *node, GF_Node *target)
 
GF_SceneGraph * gf_sg_get_parent (GF_SceneGraph *scene)
 
static GF_Err gf_sg_load_dom_node (GF_SceneGraph *document, GF_XMLNode *n, GF_DOMFullNode *par)
 
GF_Err gf_sg_init_from_xml_node (GF_SceneGraph *document, GF_DOMXMLNODE root_node)
 
void gf_sg_set_destroy_cookie (GF_SceneGraph *sg, Bool *cookie)
 

Variables

static char log_node_name [2+16+1]
 

Function Documentation

◆ ReplaceDEFNode()

static void ReplaceDEFNode ( GF_Node FromNode,
GF_Node node,
GF_Node newNode,
Bool  updateOrderedGroup 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ReplaceIRINode()

static void ReplaceIRINode ( GF_Node FromNode,
GF_Node oldNode,
GF_Node newNode 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ node_modif_stub()

static void node_modif_stub ( GF_SceneGraph *  sg,
GF_Node node,
GF_FieldInfo info,
GF_Node script 
)
static
+ Here is the caller graph for this function:

◆ SG_SearchForNode()

GFINLINE GF_Node* SG_SearchForNode ( GF_SceneGraph *  sg,
GF_Node node 
)
+ Here is the caller graph for this function:

◆ get_num_id_nodes()

static GFINLINE u32 get_num_id_nodes ( GF_SceneGraph *  sg)
static
+ Here is the caller graph for this function:

◆ SG_SearchForDuplicateNodeID()

GFINLINE GF_Node* SG_SearchForDuplicateNodeID ( GF_SceneGraph *  sg,
u32  nodeID,
GF_Node toExclude 
)

◆ remove_node_id()

void remove_node_id ( GF_SceneGraph *  sg,
GF_Node node 
)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_try_destroy()

GF_Err gf_node_try_destroy ( GF_SceneGraph *  sg,
GF_Node pNode,
GF_Node parentNode 
)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Replace_IRI()

static void Replace_IRI ( GF_SceneGraph *  sg,
GF_Node old_node,
GF_Node newNode 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ insert_node_def()

static GFINLINE void insert_node_def ( GF_SceneGraph *  sg,
GF_Node def,
u32  ID,
const char *  name 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_setup()

void gf_node_setup ( GF_Node p,
u32  tag 
)

◆ gf_sg_new_base_node()

GF_Node* gf_sg_new_base_node ( )
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_set_callback_function()

GF_EXPORT GF_Err gf_node_set_callback_function ( GF_Node p,
void(*)(GF_Node *node, void *render_stack, Bool is_destroy)  TraverseNode 
)

◆ gf_sg_parent_setup()

void gf_sg_parent_setup ( GF_Node node)
+ Here is the caller graph for this function:

◆ gf_sg_parent_reset()

void gf_sg_parent_reset ( GF_Node node)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_free()

void gf_node_free ( GF_Node node)
+ Here is the call graph for this function:

◆ dirty_children()

static void dirty_children ( GF_Node node)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ dirty_parents()

static void dirty_parents ( GF_Node node)
static
+ Here is the caller graph for this function:

◆ gf_node_dirty_parent_graph()

GF_EXPORT void gf_node_dirty_parent_graph ( GF_Node node)
+ Here is the caller graph for this function:

◆ gf_node_changed_internal()

void gf_node_changed_internal ( GF_Node node,
GF_FieldInfo field,
Bool  notify_scripts 
)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_del()

void gf_node_del ( GF_Node node)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_get_field_by_name_enum()

static GF_Err gf_node_get_field_by_name_enum ( GF_Node node,
char *  name,
GF_FieldInfo field 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_deactivate_ex()

static GF_Err gf_node_deactivate_ex ( GF_Node node)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_deactivate()

GF_Err gf_node_deactivate ( GF_Node node)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_activate_ex()

static u32 gf_node_activate_ex ( GF_Node node)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_node_activate()

GF_Err gf_node_activate ( GF_Node node)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_sg_load_dom_node()

static GF_Err gf_sg_load_dom_node ( GF_SceneGraph *  document,
GF_XMLNode n,
GF_DOMFullNode par 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gf_sg_set_destroy_cookie()

void gf_sg_set_destroy_cookie ( GF_SceneGraph *  sg,
Bool cookie 
)
+ Here is the caller graph for this function:

Variable Documentation

◆ log_node_name

char log_node_name[2+16+1]
static