![]() |
![]() |
![]() |
OGMRip Reference Manual | ![]() |
---|---|---|---|---|
#include <ogmrip-plugin.h> OGMRipPluginVideoCodec; OGMRipPluginAudioCodec; OGMRipPluginSubpCodec; OGMRipPluginContainer; void (*OGMRipPluginFunc) (GType type, const gchar *name, const gchar *description, gpointer data); gint (*OGMRipPluginCmpFunc) (GType type, const gchar *name, const gchar *description, gconstpointer data); void ogmrip_plugin_init (void); void ogmrip_plugin_uninit (void); gint ogmrip_plugin_get_n_containers (void); void ogmrip_plugin_foreach_container (OGMRipPluginFunc func, gpointer data); GType ogmrip_plugin_find_container (OGMRipPluginCmpFunc func, gconstpointer data); GType ogmrip_plugin_get_nth_container (guint n); gchar* ogmrip_plugin_get_container_name (GType container); gint ogmrip_plugin_get_container_index (GType container); gboolean ogmrip_plugin_get_container_bframes (GType container); gint ogmrip_plugin_get_container_max_audio (GType container); gint ogmrip_plugin_get_container_max_subp (GType container); gint ogmrip_plugin_get_n_video_codecs (void); void ogmrip_plugin_foreach_video_codec (OGMRipPluginFunc func, gpointer data); GType ogmrip_plugin_find_video_codec (OGMRipPluginCmpFunc func, gconstpointer data); GType ogmrip_plugin_get_nth_video_codec (guint n); gchar* ogmrip_plugin_get_video_codec_name (GType codec); gint ogmrip_plugin_get_video_codec_index (GType codec); gint ogmrip_plugin_get_video_codec_format (GType codec); gint ogmrip_plugin_get_video_codec_passes (GType codec); gint ogmrip_plugin_get_video_codec_threads (GType codec); gint ogmrip_plugin_get_n_audio_codecs (void); void ogmrip_plugin_foreach_audio_codec (OGMRipPluginFunc func, gpointer data); GType ogmrip_plugin_find_audio_codec (OGMRipPluginCmpFunc func, gconstpointer data); GType ogmrip_plugin_get_nth_audio_codec (guint n); gchar* ogmrip_plugin_get_audio_codec_name (GType codec); gint ogmrip_plugin_get_audio_codec_index (GType codec); gint ogmrip_plugin_get_audio_codec_format (GType codec); gint ogmrip_plugin_get_n_subp_codecs (void); void ogmrip_plugin_foreach_subp_codec (OGMRipPluginFunc func, gpointer data); GType ogmrip_plugin_find_subp_codec (OGMRipPluginCmpFunc func, gconstpointer data); GType ogmrip_plugin_get_nth_subp_codec (guint n); gchar* ogmrip_plugin_get_subp_codec_name (GType codec); gint ogmrip_plugin_get_subp_codec_index (GType codec); gint ogmrip_plugin_get_subp_codec_format (GType codec); gboolean ogmrip_plugin_get_subp_codec_text (GType codec); gboolean ogmrip_plugin_can_contain_video (GType container, GType codec); gboolean ogmrip_plugin_can_contain_audio (GType container, GType codec); gboolean ogmrip_plugin_can_contain_subp (GType container, GType codec); gboolean ogmrip_plugin_can_contain_format (GType container, OGMRipFormatType format); gboolean ogmrip_plugin_can_contain_n_audio (GType container, guint ncodec); gboolean ogmrip_plugin_can_contain_n_subp (GType container, guint ncodec);
typedef struct { GModule *module; GType type; gchar *name; gchar *description; OGMRipFormatType format; gint passes; gint threads; } OGMRipPluginVideoCodec;
A structure describing a video codec plugin
GModule *module ; |
For internal use only |
GType type ; |
The type of the codec |
gchar *name ; |
The name of the codec |
gchar *description ; |
The description of the codec |
OGMRipFormatType format ; |
The codec output format |
gint passes ; |
The number of passes supported by the codec |
gint threads ; |
The number of threads supported by the codec |
typedef struct { GModule *module; GType type; gchar *name; gchar *description; OGMRipFormatType format; } OGMRipPluginAudioCodec;
A structure describing an audio codec plugin
GModule *module ; |
For internal use only |
GType type ; |
The type of the codec |
gchar *name ; |
The name of the codec |
gchar *description ; |
The description of the codec |
OGMRipFormatType format ; |
The codec output format |
typedef struct { GModule *module; GType type; gchar *name; gchar *description; OGMRipFormatType format; gboolean text; } OGMRipPluginSubpCodec;
A structure describing a subtitle codec plugin
typedef struct { GModule *module; GType type; gchar *name; gchar *description; gboolean bframes; gint max_audio; gint max_subp; gint *formats; } OGMRipPluginContainer;
A structure describing a container plugin
GModule *module ; |
For internal use only |
GType type ; |
The type of the container |
gchar *name ; |
The name of the container |
gchar *description ; |
The description of the container |
gboolean bframes ; |
Whether the container supports B-frames |
gint max_audio ; |
The maximum number of audio streams that can be embedded in the container |
gint max_subp ; |
The maximum number of subtitle streams that can be embedded in the container |
gint *formats ; |
A NULL terminated array of OGMRipFormatType supported by the container |
void (*OGMRipPluginFunc) (GType type, const gchar *name, const gchar *description, gpointer data);
Specifies the type of functions passed to ogmrip_plugin_foreach_container()
,
ogmrip_plugin_foreach_video_codec()
, ogmrip_plugin_foreach_audio_codec()
,
and ogmrip_plugin_foreach_subp_codec()
.
type : |
The type of the plugin |
name : |
The name of the plugin |
description : |
The description of the plugin |
data : |
The user data |
gint (*OGMRipPluginCmpFunc) (GType type, const gchar *name, const gchar *description, gconstpointer data);
Specifieѕ the type of functions passed to ogmrip_plugin_find_container()
,
ogmrip_plugin_find_video_codec()
, ogmrip_plugin_find_audio_codec()
, and
ogmrip_plugin_find_subp_codec()
.
type : |
The type of the plugin |
name : |
The name of the plugin |
description : |
The description of the plugin |
data : |
The user data |
Returns : | 0 when the expected plugin is found |
gint ogmrip_plugin_get_n_containers (void);
Gets the number of container plugins.
Returns : | the number of container plugins |
void ogmrip_plugin_foreach_container (OGMRipPluginFunc func, gpointer data);
Calls a function for each container plugin.
func : |
The function to call with each container plugin's data |
data : |
User data to pass to the function |
GType ogmrip_plugin_find_container (OGMRipPluginCmpFunc func, gconstpointer data);
Finds a container using the supplied function.
func : |
The function to call for each container plugin. It should return 0 when the desired container is found |
data : |
User data passed to the function |
Returns : | The type of the container, or G_TYPE_NONE
|
GType ogmrip_plugin_get_nth_container (guint n);
Gets the container at the given position.
n : |
The index of the container |
Returns : | The type of the container, or G_TYPE_NONE
|
gchar* ogmrip_plugin_get_container_name (GType container);
Gets the name of the given container.
container : |
A container type |
Returns : | The name of the container, or NULL |
gint ogmrip_plugin_get_container_index (GType container);
Gets the position of the given container.
container : |
A container type |
Returns : | The index of the container, or -1 |
gboolean ogmrip_plugin_get_container_bframes (GType container);
Gets whether the given container supports B-frames
container : |
A container type |
Returns : | TRUE if the container supports B-frames
|
gint ogmrip_plugin_get_container_max_audio (GType container);
Returns the number of audio streams the given container can contain.
container : |
A container type |
Returns : | the number of audio streams, or -1 |
gint ogmrip_plugin_get_container_max_subp (GType container);
Returns the number of subtitle streams the given container can contain.
container : |
A container type |
Returns : | the number of subtitle streams, or -1 |
gint ogmrip_plugin_get_n_video_codecs (void);
Gets the number of video codec plugins.
Returns : | the number of video codec plugins |
void ogmrip_plugin_foreach_video_codec (OGMRipPluginFunc func, gpointer data);
Calls a function for each video codec plugin.
func : |
The function to call with each video codec plugin's data |
data : |
User data to pass to the function |
GType ogmrip_plugin_find_video_codec (OGMRipPluginCmpFunc func, gconstpointer data);
Finds a video codec using the supplied function.
func : |
The function to call for each video codec plugin. It should return 0 when the desired video codec is found |
data : |
User data passed to the function |
Returns : | The type of the video codec, or G_TYPE_NONE
|
GType ogmrip_plugin_get_nth_video_codec (guint n);
Gets the video codec at the given position.
n : |
The index of the video codec |
Returns : | The type of the video codec, or G_TYPE_NONE
|
gchar* ogmrip_plugin_get_video_codec_name (GType codec);
Gets the name of the given video codec.
codec : |
A video codec type |
Returns : | The name of the video codec, or NULL |
gint ogmrip_plugin_get_video_codec_index (GType codec);
Gets the position of the given video codec.
codec : |
A video codec type |
Returns : | The index of the video codec, or -1 |
gint ogmrip_plugin_get_video_codec_format (GType codec);
Gets the format of the given video codec.
codec : |
A video codec type |
Returns : | The format of the video codec, or NULL |
gint ogmrip_plugin_get_video_codec_passes (GType codec);
Gets the maximum number of passes the given video codec supports.
codec : |
A video codec type |
Returns : | The maximum number of passes, or -1 |
gint ogmrip_plugin_get_video_codec_threads (GType codec);
Gets the maximum number of threads the given video codec supports.
codec : |
A video codec type |
Returns : | The maximum number of threads, or -1 |
gint ogmrip_plugin_get_n_audio_codecs (void);
Gets the number of audio codec plugins.
Returns : | the number of audio codec plugins |
void ogmrip_plugin_foreach_audio_codec (OGMRipPluginFunc func, gpointer data);
Calls a function for each plugin.
func : |
The function to call with each plugin's data |
data : |
User data to pass to the function |
GType ogmrip_plugin_find_audio_codec (OGMRipPluginCmpFunc func, gconstpointer data);
Finds a audio codec using the supplied function.
func : |
The function to call for each audio codec plugin. It should return 0 when the desired audio codec is found |
data : |
User data passed to the function |
Returns : | The type of the audio codec, or G_TYPE_NONE
|
GType ogmrip_plugin_get_nth_audio_codec (guint n);
Gets the audio codec at the given position.
n : |
The index of the audio codec |
Returns : | The type of the audio codec, or G_TYPE_NONE
|
gchar* ogmrip_plugin_get_audio_codec_name (GType codec);
Gets the name of the given audio codec.
codec : |
An audio codec type |
Returns : | The name of the audio codec, or NULL |
gint ogmrip_plugin_get_audio_codec_index (GType codec);
Gets the position of the given audio codec.
codec : |
An audio codec type |
Returns : | The index of the audio codec, or -1 |
gint ogmrip_plugin_get_audio_codec_format (GType codec);
Gets the format of the given audio codec.
codec : |
A audio codec type |
Returns : | The format of the audio codec, or NULL |
gint ogmrip_plugin_get_n_subp_codecs (void);
Gets the number of subtitle codec plugins.
Returns : | the number of subtitle codec plugins |
void ogmrip_plugin_foreach_subp_codec (OGMRipPluginFunc func, gpointer data);
Calls a function for each plugin.
func : |
The function to call with each plugin's data |
data : |
User data to pass to the function |
GType ogmrip_plugin_find_subp_codec (OGMRipPluginCmpFunc func, gconstpointer data);
Finds a subtitle codec using the supplied function.
func : |
The function to call for each subtitle codec plugin. It should return 0 when the desired subtitle codec is found |
data : |
User data passed to the function |
Returns : | The type of the subtitle codec, or G_TYPE_NONE
|
GType ogmrip_plugin_get_nth_subp_codec (guint n);
Gets the subtitle codec at the given position.
n : |
The index of the subtitle codec |
Returns : | The type of the subtitle codec, or G_TYPE_NONE
|
gchar* ogmrip_plugin_get_subp_codec_name (GType codec);
Gets the name of the given subtitle codec.
codec : |
A subtitle codec type |
Returns : | The name of the subtitle codec, or NULL |
gint ogmrip_plugin_get_subp_codec_index (GType codec);
Gets the position of the given subtitle codec.
codec : |
A subtitle codec type |
Returns : | The index of the subtitle codec, or -1 |
gint ogmrip_plugin_get_subp_codec_format (GType codec);
Gets the format of the given subtitle codec.
codec : |
A subtitle codec type |
Returns : | The format of the subtitle codec, or NULL |
gboolean ogmrip_plugin_get_subp_codec_text (GType codec);
Gets whether the given codec outputs text subtitles.
codec : |
A subtitle codec type |
Returns : | TRUE if the codec output text subtitles
|
gboolean ogmrip_plugin_can_contain_video (GType container, GType codec);
Returns whether container
supports the given video codec.
container : |
A container type |
codec : |
A video codec type |
Returns : | TRUE if container supports type
|
gboolean ogmrip_plugin_can_contain_audio (GType container, GType codec);
Returns whether container
supports the given audio codec.
container : |
A container type |
codec : |
An audio codec type |
Returns : | TRUE if container supports type
|
gboolean ogmrip_plugin_can_contain_subp (GType container, GType codec);
Returns whether container
supports the given subtitle codec.
container : |
A container type |
codec : |
A subtitle codec type |
Returns : | TRUE if container supports type
|
gboolean ogmrip_plugin_can_contain_format (GType container, OGMRipFormatType format);
Returns whether container
supports the given format.
container : |
A container type |
format : |
An OGMRipFormatType |
Returns : | TRUE if container supports format
|
gboolean ogmrip_plugin_can_contain_n_audio (GType container, guint ncodec);
Returns whether container
can contain ncodec
audio streams.
container : |
A container type |
ncodec : |
The number of audio codecs |
Returns : | TRUE if container can contain ncodec audio streams
|
gboolean ogmrip_plugin_can_contain_n_subp (GType container, guint ncodec);
Returns whether container
can contain ncodec
subtitle streams.
container : |
A container type |
ncodec : |
The number of subtitle codecs |
Returns : | TRUE if container can contain ncodec subtitle streams
|