libgpac
Documentation of the core library of GPAC
unit_test_filter.c File Reference
#include <gpac/filters.h>
#include <gpac/list.h>
+ Include dependency graph for unit_test_filter.c:

Data Structures

struct  PIDCtx
 
struct  GF_UnitTestFilter
 

Macros

#define OFFS(_n)   #_n, offsetof(GF_UnitTestFilter, _n)
 
#define UT_CAP_CODE   GF_4CC('c','u','s','t')
 

Enumerations

enum  { UTF_MODE_SOURCE =0 , UTF_MODE_SINK , UTF_MODE_FILTER }
 

Functions

static void test_pck_del (GF_Filter *filter, GF_FilterPid *pid, GF_FilterPacket *pck)
 
void dump_properties (GF_FilterPacket *pck, u32 nb_pck)
 
static void ut_filter_finalize (GF_Filter *filter)
 
static void ut_filter_send_update (GF_Filter *filter, u32 nb_pck)
 
static GF_Err ut_filter_process_filter (GF_Filter *filter)
 
static void ut_source_pck_del (GF_Filter *filter, GF_FilterPid *pid, GF_FilterPacket *pck)
 
static GF_Err ut_source_ifce_get_plane (struct _gf_filter_frame_interface *frame, u32 plane_idx, const u8 **outPlane, u32 *outStride)
 
static GF_Err ut_filter_process_source (GF_Filter *filter)
 
static GF_Err ut_filter_process_sink (GF_Filter *filter)
 
static GF_Err ut_filter_config_input (GF_Filter *filter, GF_FilterPid *pid, Bool is_remove)
 
static GF_Err ut_filter_config_source (GF_Filter *filter)
 
static GF_Err ut_filter_update_arg (GF_Filter *filter, const char *arg_name, const GF_PropertyValue *arg_val)
 
GF_Err utfilter_initialize (GF_Filter *filter)
 
const GF_FilterRegister * ut_filter_register (GF_FilterSession *session)
 
const GF_FilterRegister * ut_source_register (GF_FilterSession *session)
 
const GF_FilterRegister * ut_sink_register (GF_FilterSession *session)
 
const GF_FilterRegister * ut_sink2_register (GF_FilterSession *session)
 

Variables

static const GF_FilterArgs UTFilterArgs []
 
static const GF_FilterCapability UTFilterCaps []
 
static const GF_FilterCapability UTSinkInputs []
 
static const GF_FilterCapability UTSink2Inputs []
 
static const GF_FilterCapability UTSourceOutputs []
 
const GF_FilterRegister UTFilterRegister
 
const GF_FilterRegister UTSinkRegister
 
const GF_FilterRegister UTSink2Register
 
const GF_FilterRegister UTSourceRegister
 

Data Structure Documentation

◆ PIDCtx

struct PIDCtx
+ Collaboration diagram for PIDCtx:
Data Fields
GF_FilterPid * src_pid
GF_FilterPid * dst_pid
GF_SHA1Context * sha_ctx
u32 nb_packets
u32 pck_del
GF_FilterFrameInterface frame_ifce
u8 ifce_data[10]

◆ GF_UnitTestFilter

struct GF_UnitTestFilter
+ Collaboration diagram for GF_UnitTestFilter:
Data Fields
GF_List * pids
u32 mode
u32 max_pck
s32 max_out
const char * pid_att
Bool alloc
u32 nb_pids
u32 fwd
u32 framing
Bool cov
Bool norecfg
const char * update
Bool gsftest
GF_Fraction64 dummy1

Macro Definition Documentation

◆ OFFS

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

◆ UT_CAP_CODE

#define UT_CAP_CODE   GF_4CC('c','u','s','t')

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
UTF_MODE_SOURCE 
UTF_MODE_SINK 
UTF_MODE_FILTER 

Function Documentation

◆ test_pck_del()

static void test_pck_del ( GF_Filter *  filter,
GF_FilterPid *  pid,
GF_FilterPacket *  pck 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ dump_properties()

void dump_properties ( GF_FilterPacket *  pck,
u32  nb_pck 
)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ut_filter_finalize()

static void ut_filter_finalize ( GF_Filter *  filter)
static
+ Here is the call graph for this function:

◆ ut_filter_send_update()

static void ut_filter_send_update ( GF_Filter *  filter,
u32  nb_pck 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ut_filter_process_filter()

static GF_Err ut_filter_process_filter ( GF_Filter *  filter)
static
+ Here is the call graph for this function:

◆ ut_source_pck_del()

static void ut_source_pck_del ( GF_Filter *  filter,
GF_FilterPid *  pid,
GF_FilterPacket *  pck 
)
static
+ Here is the caller graph for this function:

◆ ut_source_ifce_get_plane()

static GF_Err ut_source_ifce_get_plane ( struct _gf_filter_frame_interface *  frame,
u32  plane_idx,
const u8 **  outPlane,
u32 outStride 
)
static
+ Here is the caller graph for this function:

◆ ut_filter_process_source()

static GF_Err ut_filter_process_source ( GF_Filter *  filter)
static
+ Here is the call graph for this function:

◆ ut_filter_process_sink()

static GF_Err ut_filter_process_sink ( GF_Filter *  filter)
static
+ Here is the call graph for this function:

◆ ut_filter_config_input()

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

◆ ut_filter_config_source()

static GF_Err ut_filter_config_source ( GF_Filter *  filter)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ut_filter_update_arg()

static GF_Err ut_filter_update_arg ( GF_Filter *  filter,
const char *  arg_name,
const GF_PropertyValue *  arg_val 
)
static

◆ utfilter_initialize()

GF_Err utfilter_initialize ( GF_Filter *  filter)
+ Here is the call graph for this function:

◆ ut_filter_register()

const GF_FilterRegister* ut_filter_register ( GF_FilterSession *  session)
+ Here is the caller graph for this function:

◆ ut_source_register()

const GF_FilterRegister* ut_source_register ( GF_FilterSession *  session)
+ Here is the caller graph for this function:

◆ ut_sink_register()

const GF_FilterRegister* ut_sink_register ( GF_FilterSession *  session)
+ Here is the caller graph for this function:

◆ ut_sink2_register()

const GF_FilterRegister* ut_sink2_register ( GF_FilterSession *  session)
+ Here is the caller graph for this function:

Variable Documentation

◆ UTFilterArgs

const GF_FilterArgs UTFilterArgs[]
static

◆ UTFilterCaps

const GF_FilterCapability UTFilterCaps[]
static
Initial value:
=
{
}
#define GF_CAPS_OUTPUT
Definition: filters.h:2232
#define CAP_STRING(_f, _a, _b)
Definition: filters.h:2194
#define GF_CAPS_INPUT
Definition: filters.h:2220
#define UT_CAP_CODE
Definition: unit_test_filter.c:889

◆ UTSinkInputs

const GF_FilterCapability UTSinkInputs[]
static
Initial value:
=
{
}

◆ UTSink2Inputs

const GF_FilterCapability UTSink2Inputs[]
static
Initial value:
=
{
}

◆ UTSourceOutputs

const GF_FilterCapability UTSourceOutputs[]
static
Initial value:
=
{
}

◆ UTFilterRegister

const GF_FilterRegister UTFilterRegister
Initial value:
= {
.name = "UTFilter",
.private_size = sizeof(GF_UnitTestFilter),
.args = UTFilterArgs,
.initialize = utfilter_initialize,
.finalize = ut_filter_finalize,
.configure_pid = ut_filter_config_input,
.update_arg = ut_filter_update_arg
}
#define SETCAPS(__struct)
Definition: filters.h:2364
@ GF_FS_REG_EXPLICIT_ONLY
Definition: filters.h:2393
static GF_Err ut_filter_update_arg(GF_Filter *filter, const char *arg_name, const GF_PropertyValue *arg_val)
Definition: unit_test_filter.c:614
static const GF_FilterArgs UTFilterArgs[]
Definition: unit_test_filter.c:856
GF_Err utfilter_initialize(GF_Filter *filter)
Definition: unit_test_filter.c:619
static GF_Err ut_filter_config_input(GF_Filter *filter, GF_FilterPid *pid, Bool is_remove)
Definition: unit_test_filter.c:461
static const GF_FilterCapability UTFilterCaps[]
Definition: unit_test_filter.c:890
static GF_Err ut_filter_process_filter(GF_Filter *filter)
Definition: unit_test_filter.c:154
static void ut_filter_finalize(GF_Filter *filter)
Definition: unit_test_filter.c:94
Definition: unit_test_filter.c:49

◆ UTSinkRegister

const GF_FilterRegister UTSinkRegister
Initial value:
= {
.name = "UTSink",
.private_size = sizeof(GF_UnitTestFilter),
.args = UTFilterArgs,
.initialize = utfilter_initialize,
.finalize = ut_filter_finalize,
.configure_pid = ut_filter_config_input,
.update_arg = ut_filter_update_arg
}
static GF_Err ut_filter_process_sink(GF_Filter *filter)
Definition: unit_test_filter.c:414
static const GF_FilterCapability UTSinkInputs[]
Definition: unit_test_filter.c:898

◆ UTSink2Register

const GF_FilterRegister UTSink2Register
Initial value:
= {
.name = "UTSink2",
.private_size = sizeof(GF_UnitTestFilter),
.args = UTFilterArgs,
.initialize = utfilter_initialize,
.finalize = ut_filter_finalize,
.configure_pid = ut_filter_config_input,
.update_arg = ut_filter_update_arg
}
static const GF_FilterCapability UTSink2Inputs[]
Definition: unit_test_filter.c:903

◆ UTSourceRegister

const GF_FilterRegister UTSourceRegister
Initial value:
= {
.name = "UTSource",
.private_size = sizeof(GF_UnitTestFilter),
.args = UTFilterArgs,
.initialize = utfilter_initialize,
.finalize = ut_filter_finalize,
.update_arg = ut_filter_update_arg,
.hint_class_type = GF_FS_CLASS_TOOL
}
@ GF_FS_CLASS_TOOL
Definition: filters.h:2455
static GF_Err ut_filter_process_source(GF_Filter *filter)
Definition: unit_test_filter.c:270
static const GF_FilterCapability UTSourceOutputs[]
Definition: unit_test_filter.c:908