Top |
FluStreamType
flu_stream_type_get (FluStream *thiz
);
Gets the type of a FluStream
FluStream *
flu_stream_ref (FluStream *thiz
);
Increase the reference count of an FluStream
void flu_stream_unref (FluStream *thiz
);
Decrease the reference count of an FluStream
gboolean flu_stream_is_active (FluStream *thiz
);
Checks if an FluStream is active
gboolean flu_stream_is_ignored (FluStream *thiz
);
Checks if an FluStream is ignored
gboolean flu_stream_is_pending (FluStream *thiz
);
Checks if an FluStream is pending for activation
gboolean flu_stream_info_get (FluStream *thiz
,const FluStreamInfo **info
);
Gets the information of an FluStream
thiz |
The stream to get the information from |
|
info |
The pointer to store the stream information.
Returned structure lifetime is the same as the associated FluStream
instance. If you need to keep FluStreamInfo data beyond the lifetime
of the FluStream instance, you can use |
[out][transfer none] |
FluSource *
flu_stream_get_source (FluStream *thiz
);
get the source the stream belongs to
void flu_stream_expose (FluStream *thiz
);
Tell an FluStream to expose the last frame This will redraw the last frame on the destination texture
void flu_stream_mouse_event_send (FluStream *thiz
,const
,gchar *event,
gint button,
gdouble x);
gdouble y
Send a mouse event to a FluStream. These events are typically retrieved from the user Interface layer (e.g. GTK) and sent to the stream for processing (e.g., by the DVD virtual machine inside Fluendo SDK).
thiz |
The FluStream to send the mouse event to |
|
event |
The type of mouse event, as a text string. Recognised values are "mouse-button-press", "mouse-button-release" and "mouse-move". |
|
button |
The pressed button |
|
x |
The X coordinate of the mouse event |
|
y |
The Y coordinate of the mouse event |
void flu_stream_key_event_send (FluStream *thiz
,const
,gchar *eventconst
);gchar *key
Send a key event to a FluStream. These events are typically retrieved from the user Interface layer (e.g. GTK) and sent to the stream for processing (e.g., by the DVD virtual machine inside Fluendo SDK).
thiz |
The FluStream to send the key event to |
|
event |
The type of the key event, as a text string. Recognised values are "key-press" and "key-release". |
|
key |
The key to send |
void flu_stream_navigation_cmd_send (FluStream *thiz
,FluStreamNavigationCommand command
);
Send a navigation command to a FluStream. These events are typically generated through a User Interface menu, remote or special key and sent to the stream for processing (e.g., by the DVD virtual machine inside Fluendo SDK).
void flu_stream_texture_set (FluStream *thiz
,,
guintptr handle);
gboolean handle_aspect_ratio
Sets the video texture on a FluStream. The texture pointer is system dependent. For X11 you need to pass a XDrawable, for android a ANativeWindow, for Windows a HWND and for Quartz an NSView.
thiz |
The FluStream of type FLU_STREAM_TYPE_VIDEO to set the texture on |
|
handle |
The texture to set |
|
handle_aspect_ratio |
indicates that the video rendering element should handle the black borders to maintain video's original aspect ratio. |
guintptr flu_stream_texture_get (FluStream *thiz
);
Gets the video texture from a FluStream
void flu_stream_volume_set (FluStream *thiz
,);
gfloat volume
Sets the volume of a FluStream
thiz |
The FluStream of type FLU_STREAM_TYPE_AUDIO to set the volume on |
|
volume |
The volume to set, in the range of 0 to 1 |
void flu_stream_volume_get (FluStream *thiz
,);
gfloat *volume
Gets the volume of a FluStream
thiz |
The FluStream of type FLU_STREAM_TYPE_AUDIO to get the volume from |
|
volume |
The volume to get, in the range of 0 to 1. |
[out] |
void flu_stream_time_offset_set (FluStream *thiz
,);
gint64 offset
Sets the time offset of a FluStream. Setting a time offset on a stream will make the playback of the stream be shifted by the time specified. This is useful, for example, to synchronize the playback in case the streams are badly muxed, or to synchronize the subtitles.
void flu_stream_time_offset_get (FluStream *thiz
,);
gint64 *offset
Gets the time offset of a FluStream.
Initially the offset will be set to zero. In case
flu_stream_time_offset_set()
is used to set another value, this function
will return such value.
gboolean flu_stream_position_get (FluStream *thiz
,);
gint64 *position
Gets the current position of this stream. Player position describes an overall clock position, and not the current sample that is being rendered for a particular stream. In some cases it might be required by the application developer to know what is the current position of a specific stream to easily return to that position. (For exemple a subtitle buffer or sparse video stream)
gboolean flu_stream_roi_set (FluStream *thiz
,,
gint x,
gint y,
gint w);
gint h
Set the ROI (Region of Interest) on a stream note: The stream must be of type FLU_STREAM_TYPE_VIDEO
thiz |
The FluStream to set the ROI |
|
x |
The x coordinate of the ROI rectangle |
|
y |
The y coordinate of the ROI rectangle |
|
w |
The width of the ROI rectangle |
|
h |
The height of the ROI rectangle |
gboolean flu_stream_roi_get (FluStream *thiz
,,
gint *x,
gint *y,
gint *w);
gint *h
Get the ROI (Region of Interest) of a stream note: The stream must be of type FLU_STREAM_TYPE_VIDEO
gboolean flu_stream_render_rectangle_set (FluStream *thiz
,,
gint x,
gint y,
gint width);
gint height
Set the render rectangle on a stream. A render rectangle specifies the area of the texture the stream must draw into note: The stream must be of type FLU_STREAM_TYPE_VIDEO
thiz |
The FluStream to set the render rectangle |
|
x |
The x coordinate of the render rectangle |
|
y |
The y coordinate of the render rectangle |
|
width |
The width of the render rectangle |
|
height |
The height of the render rectangle |
gboolean flu_stream_render_rectangle_get (FluStream *thiz
,,
gint *x,
gint *y,
gint *width);
gint *height
Get the render rectangle on a stream. A render rectangle specifies the area of the texture the stream must draw into note: The stream must be of type FLU_STREAM_TYPE_VIDEO
gboolean flu_stream_text_pango_get (FluStream *thiz
,,
gchar **content);
gsize *len
Get the current pango content from a FluStream note: The stream must be active and of type FLU_STREAM_TYPE_TEXT
gboolean flu_stream_text_plain_get (FluStream *thiz
,,
gchar **content);
gsize *len
Get the current plain text from a FluStream note: The stream must be active and of type FLU_STREAM_TYPE_TEXT
gboolean flu_stream_data_xml_get (FluStream *thiz
,,
gchar **content);
gsize *len
Get the current xml text from a FluStream note: The stream must be active and of type FLU_STREAM_TYPE_DATA
thiz |
The FluStream to get the xml text content from |
|
content |
The pointer to store the text xml content on |
|
len |
The length of the |
gboolean flu_stream_frame_ycbcr_get (FluStream *thiz
,FluStreamVideoYcbcrFormat format
,,
gint width,
gint height,
guint8 **planes);
guint32 *pitches
Get the current YCbCr frame pixels from a FluStream note: The stream must be active and of type FLU_STREAM_TYPE_VIDEO
thiz |
The FluStream to get the YCbCr pixels from |
|
format |
The FluStreamVideoYcbcrFormat format to use |
|
width |
The desired width of the frame (-1 to use the native width) |
|
height |
The desired height of the frame (-1 to use the native height) |
|
planes |
The planes pointer to store the pixels. The number of planes depend on the format used |
|
pitches |
The pitch for each plane. The number of pitches depend on the format used. |
gboolean flu_stream_frame_ycbcr_push (FluStream *thiz
,FluStreamVideoYcbcrFormat format
,,
gint width,
gint height,
guint8 **planes);
guint32 *pitches
gboolean flu_stream_frame_rgb_get (FluStream *thiz
,FluStreamVideoRgbFormat format
,,
gint width,
gint height,
gpointer data);
guint32 pitch
Get the current RGB frame pixels from a FluStream note: The stream must be active and of type FLU_STREAM_TYPE_VIDEO
thiz |
The FluStream to get the RGB pixels from |
|
format |
The FluStreamVideoRgbFormat format to use |
|
width |
The desired width of the frame (-1 to use the native width) |
|
height |
The desired height of the frame (-1 to use the native height) |
|
data |
The pointer where data is to be stored |
|
pitch |
The pitch of the frame (distance in bytes from the beginning of a row to the beginning of the next) |
gboolean flu_stream_frame_rgb_push (FluStream *thiz
,FluStreamVideoRgbFormat format
,,
gint width,
gint height,
guint8 *data);
guint32 pitch
gboolean flu_stream_frame_encoded_get (FluStream *thiz
,FluStreamVideoFrameFormat format
,,
gint width,
gint height,
guint8 **data);
guint *size
Get the current frame out of a FluStream, encoded in the format specified by FluStreamVideoFrameFormat format. Note: Stream must be active and have FLU_STREAM_TYPE_VIDEO or FLU_STREAM_TYPE_TEXT type.
thiz |
The FluStream to get the frame pixels from |
|
format |
The FluStreamVideoFrameFormat format to use |
|
width |
The desired width of the frame (-1 to use the native width) |
|
height |
The desired height of the frame (-1 to use the native height) |
|
data |
Address of a pointer where data are going to
be copied. On succes, data pointer will be filled out with the address of
a binary data block representing the encoded content of the frame. In this
case, data content must be freed using |
[out][type gpointer] |
size |
size in bytes of the buffer returned by data parameter. |
[out] |
gboolean flu_stream_frame_save (FluStream *thiz
,FluStreamVideoFrameFormat format
,,
gint width,
gint heightconst
);gchar *location
Save the current frame into an image file Note: Stream must be active and have FLU_STREAM_TYPE_VIDEO or FLU_STREAM_TYPE_TEXT type.
thiz |
The FluStream to save to a file |
|
format |
The FluStreamVideoFrameFormat format to use |
|
width |
The desired width of the frame (-1 to use the native width) |
|
height |
The desired height of the frame (-1 to use the native height) |
|
location |
The file path to save the file (not a URI) |
void flu_stream_user_data_add (FluStream *thiz
,const
,gchar *key,
gpointer user_data);
GDestroyNotify destroy
Add user provided data into a stream
void flu_stream_user_data_remove (FluStream *thiz
,const
);gchar *key
Remove user provided data from a stream
gpointer flu_stream_user_data_get (FluStream *thiz
,const
);gchar *key
Get the user provided data from a stream
gboolean flu_stream_last_sample_copy (FluStream *thiz
,FluStream *out_stream
);
Gets the last sample from a stream and forwards it the output stream.
note: The output stream must be a FluStream requested, for example from a FluRecorder. Both streams must be of the same type, as you can't copy an audio sample to a stream of type FLU_STREAM_TYPE_VIDEO
Enum values used to describe different types of YCbCr formats
Bit-field structure to inform what changed in a stream
the stream was added |
||
the stream was removed |
||
the stream was activated or deactivated |
||
FluStreamInfo changed |
Enum values used to describe different user commands that can be sent to an FluStream through the navigation interface. These are typically used for DVD menu navigation, for example.