Custom source

Custom source — Custom source interface

Functions

Description

Custom source interface.

This interface allows to create a source supplied by the application with data using the FluPlayerEventSourceNeedData.

The application must register to FLU_PLAYER_EVENT_NEED_DATA_SOURCE to feed the custom source.

The application must also register to FLU_PLAYER_EVENT_SEEK_SOURCE to let the custom source provides a given position in the stream.

Functions

flu_source_custom_new ()

FluSource *
flu_source_custom_new (const char *source_name,
                       FluFormat format,
                       gint64 length,
                       gboolean is_seekable);

Creates a new custom based source

Parameters

source_name

Name of the new source or NULL to automatically create a new unique name.

 

format

Format from FluFormat used by the source.

 

length

The length of the data stream in bytes or in ns depending on FluFormat. Use FLU_SIZE_UNKNOWN if unknown.

 

is_seekable

Flag indicating if source is seekable or not.

 

Returns

A new instance of a FluSource


flu_source_custom_eos_send ()

gboolean
flu_source_custom_eos_send (FluSource *src);

Sends the EOS to the FluSource

Parameters

src

The FluSource to send an EOS

 

Returns

TRUE if the operation succeed, FALSE otherwise

Types and Values