libgpac
Documentation of the core library of GPAC
load_svg.c File Reference
#include <gpac/internal/compositor_dev.h>
#include <gpac/scene_manager.h>
#include <gpac/constants.h>
#include <zlib.h>
+ Include dependency graph for load_svg.c:

Data Structures

struct  SVGIn
 

Macros

#define SVG_PROGRESSIVE_BUFFER_SIZE   4096
 
#define OFFS(_n)   #_n, offsetof(SVGIn, _n)
 

Functions

GF_Err svgin_deflate (SVGIn *svgin, const char *buffer, u32 buffer_len, Bool is_dims)
 
static GF_Err svgin_configure_pid (GF_Filter *filter, GF_FilterPid *pid, Bool is_remove)
 
static GF_Err svgin_process (GF_Filter *filter)
 
static Bool svgin_process_event (GF_Filter *filter, const GF_FilterEvent *com)
 
const GF_FilterRegister * svgplay_register (GF_FilterSession *session)
 

Variables

static const GF_FilterCapability SVGInCaps []
 
static const GF_FilterArgs SVGInArgs []
 
GF_FilterRegister SVGInRegister
 

Data Structure Documentation

◆ SVGIn

struct SVGIn
+ Collaboration diagram for SVGIn:
Data Fields
u32 sax_dur
GF_FilterPid * in_pid
GF_FilterPid * out_pid
GF_SceneLoader loader
GF_Scene * scene
u32 codecid
const char * file_name
u32 file_size
u16 base_es_id
u32 file_pos
void * src
Bool is_playing
GF_FileIO * fio
Bool load_file
GF_FilterPacket * pck_ref

Macro Definition Documentation

◆ SVG_PROGRESSIVE_BUFFER_SIZE

#define SVG_PROGRESSIVE_BUFFER_SIZE   4096

◆ OFFS

#define OFFS (   _n)    #_n, offsetof(SVGIn, _n)

Function Documentation

◆ svgin_deflate()

GF_Err svgin_deflate ( SVGIn svgin,
const char *  buffer,
u32  buffer_len,
Bool  is_dims 
)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ svgin_configure_pid()

static GF_Err svgin_configure_pid ( GF_Filter *  filter,
GF_FilterPid *  pid,
Bool  is_remove 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ svgin_process()

static GF_Err svgin_process ( GF_Filter *  filter)
static

streaming SVG

streaming SVG + gz

DIMS (dsi = 3GPP DIMS configuration)

+ Here is the call graph for this function:

◆ svgin_process_event()

static Bool svgin_process_event ( GF_Filter *  filter,
const GF_FilterEvent *  com 
)
static
+ Here is the call graph for this function:

◆ svgplay_register()

const GF_FilterRegister* svgplay_register ( GF_FilterSession *  session)

Variable Documentation

◆ SVGInCaps

const GF_FilterCapability SVGInCaps[]
static
Initial value:
=
{
{0},
}
@ GF_CODECID_SVG
Definition: constants.h:512
@ GF_CODECID_SVG_GZ
Definition: constants.h:514
@ GF_CODECID_DIMS
Definition: constants.h:516
@ GF_CODECID_RAW
Definition: constants.h:600
@ GF_STREAM_SCENE
Definition: constants.h:62
@ GF_STREAM_FILE
Definition: constants.h:104
#define CAP_UINT(_f, _a, _b)
Definition: filters.h:2172
#define CAP_STRING(_f, _a, _b)
Definition: filters.h:2194
#define GF_CAPS_INPUT_EXCLUDED
Definition: filters.h:2228
#define CAP_BOOL(_f, _a, _b)
Definition: filters.h:2180
#define GF_CAPS_INPUT
Definition: filters.h:2220
#define GF_CAPS_OUTPUT_STATIC
Definition: filters.h:2238
@ GF_PROP_PID_CODECID
Definition: filters.h:1116
@ GF_PROP_PID_STREAM_TYPE
Definition: filters.h:1112
@ GF_PROP_PID_UNFRAMED
Definition: filters.h:1118
@ GF_PROP_PID_FILE_EXT
Definition: filters.h:1190
@ GF_PROP_PID_MIME
Definition: filters.h:1189
@ GF_TRUE
Definition: setup.h:474

◆ SVGInArgs

const GF_FilterArgs SVGInArgs[]
static
Initial value:
=
{
{ OFFS(sax_dur), "loading duration for SAX parsing, 0 disables SAX parsing", GF_PROP_UINT, "0", NULL, GF_FS_ARG_HINT_ADVANCED},
{0}
}
@ GF_FS_ARG_HINT_ADVANCED
Definition: filters.h:2102
@ GF_PROP_UINT
Definition: filters.h:852
#define OFFS(_n)
Definition: load_svg.c:479

◆ SVGInRegister

GF_FilterRegister SVGInRegister
Initial value:
= {
.name = "svgplay",
GF_FS_SET_HELP("This filter parses SVG files directly into the scene graph of the compositor.\n"
"\n"
"When [-sax_dur=N]() is set, the filter will do a progressive load of the source and cancel current loading when processing time is higher than `N`.\n")
.private_size = sizeof(SVGIn),
.process = svgin_process,
.configure_pid = svgin_configure_pid,
.process_event = svgin_process_event,
.hint_class_type = GF_FS_CLASS_DECODER
}
#define GF_FS_SET_HELP(_help)
Definition: filters.h:2372
#define SETCAPS(__struct)
Definition: filters.h:2364
@ GF_FS_REG_MAIN_THREAD
Definition: filters.h:2387
@ GF_FS_CLASS_DECODER
Definition: filters.h:2465
attribute Array args
Definition: jsf.idl:24
static Bool svgin_process_event(GF_Filter *filter, const GF_FilterEvent *com)
Definition: load_svg.c:407
static const GF_FilterCapability SVGInCaps[]
Definition: load_svg.c:463
static GF_Err svgin_configure_pid(GF_Filter *filter, GF_FilterPid *pid, Bool is_remove)
Definition: load_svg.c:317
static GF_Err svgin_process(GF_Filter *filter)
Definition: load_svg.c:103
static const GF_FilterArgs SVGInArgs[]
Definition: load_svg.c:481
Definition: load_svg.c:36