libgpac
Documentation of the core library of GPAC
out_pipe.c File Reference
#include <gpac/filters.h>
#include <gpac/constants.h>
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
+ Include dependency graph for out_pipe.c:

Data Structures

struct  GF_PipeOutCtx
 

Macros

#define PIPE_FLUSH_MARKER   "GPACPIF"
 
#define OFFS(_n)   #_n, offsetof(GF_PipeOutCtx, _n)
 

Functions

const char * gf_errno_str (int errnoval)
 error code description More...
 
static GF_Err pipeout_open_close (GF_PipeOutCtx *ctx, const char *filename, const char *ext, u32 file_idx, Bool explicit_overwrite)
 
static GF_Err pipeout_setup_file (GF_PipeOutCtx *ctx, Bool explicit_overwrite)
 
static GF_Err pipeout_configure_pid (GF_Filter *filter, GF_FilterPid *pid, Bool is_remove)
 
static GF_Err pipeout_initialize (GF_Filter *filter)
 
static void pipeout_finalize (GF_Filter *filter)
 
static void pout_write_marker (GF_PipeOutCtx *ctx)
 
static GF_Err pipeout_process (GF_Filter *filter)
 
static GF_FilterProbeScore pipeout_probe_url (const char *url, const char *mime)
 
const GF_FilterRegister * pout_register (GF_FilterSession *session)
 

Variables

static const GF_FilterArgs PipeOutArgs []
 
static const GF_FilterCapability PipeOutCaps []
 
GF_FilterRegister PipeOutRegister
 

Data Structure Documentation

◆ GF_PipeOutCtx

struct GF_PipeOutCtx
+ Collaboration diagram for GF_PipeOutCtx:
Data Fields
Double start
Double speed
char * dst
char * mime
char * ext
Bool dynext
Bool mkp
Bool ka
Bool marker
Bool force_close
u32 block_size
GF_FilterPid * pid
int fd
GF_FilterCapability in_caps[2]
char szExt[10]
char * szFileName
Bool owns_pipe

Macro Definition Documentation

◆ PIPE_FLUSH_MARKER

#define PIPE_FLUSH_MARKER   "GPACPIF"

◆ OFFS

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

Function Documentation

◆ pipeout_open_close()

static GF_Err pipeout_open_close ( GF_PipeOutCtx ctx,
const char *  filename,
const char *  ext,
u32  file_idx,
Bool  explicit_overwrite 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ pipeout_setup_file()

static GF_Err pipeout_setup_file ( GF_PipeOutCtx ctx,
Bool  explicit_overwrite 
)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ pipeout_configure_pid()

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

◆ pipeout_initialize()

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

◆ pipeout_finalize()

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

◆ pout_write_marker()

static void pout_write_marker ( GF_PipeOutCtx ctx)
static
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ pipeout_process()

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

◆ pipeout_probe_url()

static GF_FilterProbeScore pipeout_probe_url ( const char *  url,
const char *  mime 
)
static

◆ pout_register()

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

Variable Documentation

◆ PipeOutArgs

const GF_FilterArgs PipeOutArgs[]
static
Initial value:
=
{
{ OFFS(dst), "name of destination pipe", GF_PROP_NAME, NULL, NULL, 0},
{ OFFS(ext), "indicate file extension of pipe data", GF_PROP_STRING, NULL, NULL, 0},
{ OFFS(mime), "indicate mime type of pipe data", GF_PROP_STRING, NULL, NULL, 0},
{ OFFS(dynext), "indicate the file extension is set by filter chain, not dst", GF_PROP_BOOL, "false", NULL, GF_FS_ARG_HINT_ADVANCED},
{ OFFS(start), "set playback start offset. A negative value means percent of media duration with -1 equal to duration", GF_PROP_DOUBLE, "0.0", NULL, 0},
{ OFFS(speed), "set playback speed. If negative and start is 0, start is set to -1", GF_PROP_DOUBLE, "1.0", NULL, 0},
{ OFFS(mkp), "create pipe if not found", GF_PROP_BOOL, "false", NULL, 0 },
{ OFFS(block_size), "buffer size used to write to pipe, Windows only", GF_PROP_UINT, "5000", NULL, GF_FS_ARG_HINT_ADVANCED },
{ OFFS(ka), "keep pipe alive when broken pipe is detected", GF_PROP_BOOL, "false", NULL, GF_FS_ARG_HINT_ADVANCED},
{ OFFS(marker), "inject marker upon pipeline flush events", GF_PROP_BOOL, "false", NULL, GF_FS_ARG_HINT_ADVANCED},
{0}
}
@ GF_FS_ARG_HINT_ADVANCED
Definition: filters.h:2102
@ GF_PROP_BOOL
Definition: filters.h:858
@ GF_PROP_STRING
Definition: filters.h:876
@ GF_PROP_DOUBLE
Definition: filters.h:866
@ GF_PROP_NAME
Definition: filters.h:884
@ GF_PROP_UINT
Definition: filters.h:852
#define OFFS(_n)
Definition: out_pipe.c:516

◆ PipeOutCaps

const GF_FilterCapability PipeOutCaps[]
static
Initial value:
=
{
}
@ 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
Definition: filters.h:2220
@ GF_PROP_PID_STREAM_TYPE
Definition: filters.h:1112
@ GF_PROP_PID_FILE_EXT
Definition: filters.h:1190
@ GF_PROP_PID_MIME
Definition: filters.h:1189

◆ PipeOutRegister

GF_FilterRegister PipeOutRegister