mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-26 17:18:15 +00:00
*.h: Revert indenting
Original commit message from CVS: * *.h: Revert indenting
This commit is contained in:
parent
84244843c6
commit
72ec4a2aa3
49 changed files with 1286 additions and 1176 deletions
|
@ -1,3 +1,7 @@
|
|||
2004-03-15 Johan Dahlin <johan@gnome.org>
|
||||
|
||||
* *.h: Revert indenting
|
||||
|
||||
2004-03-15 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* configure.ac:
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/bytestream/bytestream.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_A52DEC \
|
||||
(gst_a52dec_get_type())
|
||||
#define GST_A52DEC(obj) \
|
||||
|
@ -35,37 +36,38 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_A52DEC))
|
||||
#define GST_IS_A52DEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_A52DEC))
|
||||
|
||||
typedef struct _GstA52Dec GstA52Dec;
|
||||
typedef struct _GstA52DecClass GstA52DecClass;
|
||||
|
||||
struct _GstA52Dec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstA52Dec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
int bit_rate;
|
||||
int sample_rate;
|
||||
int stream_channels;
|
||||
int request_channels;
|
||||
int using_channels;
|
||||
GstPad *sinkpad,
|
||||
*srcpad;
|
||||
int bit_rate;
|
||||
int sample_rate;
|
||||
int stream_channels;
|
||||
int request_channels;
|
||||
int using_channels;
|
||||
|
||||
sample_t level;
|
||||
sample_t bias;
|
||||
gboolean dynamic_range_compression;
|
||||
sample_t *samples;
|
||||
a52_state_t *state;
|
||||
sample_t level;
|
||||
sample_t bias;
|
||||
gboolean dynamic_range_compression;
|
||||
sample_t *samples;
|
||||
a52_state_t *state;
|
||||
|
||||
GstByteStream *bs;
|
||||
|
||||
GstClockTime last_ts;
|
||||
GstClockTime current_ts;
|
||||
GstClockTime last_ts;
|
||||
GstClockTime current_ts;
|
||||
};
|
||||
|
||||
struct _GstA52DecClass
|
||||
{
|
||||
struct _GstA52DecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_A52DEC_H__ */
|
||||
|
|
|
@ -25,7 +25,9 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
|
||||
G_BEGIN_DECLS GstElementDetails dvdreadsrc_details;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
GstElementDetails dvdreadsrc_details;
|
||||
|
||||
|
||||
#define GST_TYPE_DVDREADSRC \
|
||||
|
@ -40,29 +42,27 @@ G_BEGIN_DECLS GstElementDetails dvdreadsrc_details;
|
|||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_DVDREADSRC))
|
||||
|
||||
/* NOTE: per-element flags start with 16 for now */
|
||||
typedef enum
|
||||
{
|
||||
DVDREADSRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
DVDREADSRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
DVDREADSRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
DVDREADSRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST+2,
|
||||
} DVDReadSrcFlags;
|
||||
|
||||
typedef struct _DVDReadSrc DVDReadSrc;
|
||||
typedef struct _DVDReadSrcPrivate DVDReadSrcPrivate;
|
||||
typedef struct _DVDReadSrcClass DVDReadSrcClass;
|
||||
|
||||
struct _DVDReadSrc
|
||||
{
|
||||
struct _DVDReadSrc {
|
||||
GstElement element;
|
||||
DVDReadSrcPrivate *priv;
|
||||
};
|
||||
|
||||
struct _DVDReadSrcClass
|
||||
{
|
||||
struct _DVDReadSrcClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType dvdreadsrc_get_type (void);
|
||||
GType dvdreadsrc_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __DVDREADSRC_H__ */
|
||||
|
|
|
@ -25,9 +25,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#include <lame/lame.h>
|
||||
|
||||
|
@ -42,76 +41,73 @@ extern "C"
|
|||
#define GST_IS_LAME_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_LAME))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_LAME_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
GST_LAME_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_LAME_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstLameFlags;
|
||||
GST_LAME_FLAG_LAST = GST_ELEMENT_FLAG_LAST+2,
|
||||
} GstLameFlags;
|
||||
|
||||
typedef struct _GstLame GstLame;
|
||||
typedef struct _GstLameClass GstLameClass;
|
||||
typedef struct _GstLame GstLame;
|
||||
typedef struct _GstLameClass GstLameClass;
|
||||
|
||||
struct _GstLame
|
||||
{
|
||||
GstElement element;
|
||||
/* pads */
|
||||
GstPad *srcpad, *sinkpad;
|
||||
struct _GstLame {
|
||||
GstElement element;
|
||||
/* pads */
|
||||
GstPad *srcpad, *sinkpad;
|
||||
|
||||
gint samplerate;
|
||||
gint num_channels;
|
||||
gboolean initialized;
|
||||
gint samplerate;
|
||||
gint num_channels;
|
||||
gboolean initialized;
|
||||
|
||||
gint bitrate;
|
||||
gfloat compression_ratio;
|
||||
gint quality;
|
||||
gint mode;
|
||||
gboolean force_ms;
|
||||
gboolean free_format;
|
||||
gboolean copyright;
|
||||
gboolean original;
|
||||
gboolean error_protection;
|
||||
gint padding_type;
|
||||
gboolean extension;
|
||||
gboolean strict_iso;
|
||||
gboolean disable_reservoir;
|
||||
gboolean vbr;
|
||||
gint vbr_mean_bitrate;
|
||||
gint vbr_min_bitrate;
|
||||
gint vbr_max_bitrate;
|
||||
gint vbr_hard_min;
|
||||
gint lowpass_freq;
|
||||
gint lowpass_width;
|
||||
gint highpass_freq;
|
||||
gint highpass_width;
|
||||
gboolean ath_only;
|
||||
gboolean ath_short;
|
||||
gboolean no_ath;
|
||||
gint ath_type;
|
||||
gint ath_lower;
|
||||
gint cwlimit;
|
||||
gboolean allow_diff_short;
|
||||
gboolean no_short_blocks;
|
||||
gboolean emphasis;
|
||||
gint bitrate;
|
||||
gfloat compression_ratio;
|
||||
gint quality;
|
||||
gint mode;
|
||||
gboolean force_ms;
|
||||
gboolean free_format;
|
||||
gboolean copyright;
|
||||
gboolean original;
|
||||
gboolean error_protection;
|
||||
gint padding_type;
|
||||
gboolean extension;
|
||||
gboolean strict_iso;
|
||||
gboolean disable_reservoir;
|
||||
gboolean vbr;
|
||||
gint vbr_mean_bitrate;
|
||||
gint vbr_min_bitrate;
|
||||
gint vbr_max_bitrate;
|
||||
gint vbr_hard_min;
|
||||
gint lowpass_freq;
|
||||
gint lowpass_width;
|
||||
gint highpass_freq;
|
||||
gint highpass_width;
|
||||
gboolean ath_only;
|
||||
gboolean ath_short;
|
||||
gboolean no_ath;
|
||||
gint ath_type;
|
||||
gint ath_lower;
|
||||
gint cwlimit;
|
||||
gboolean allow_diff_short;
|
||||
gboolean no_short_blocks;
|
||||
gboolean emphasis;
|
||||
|
||||
lame_global_flags *lgf;
|
||||
lame_global_flags *lgf;
|
||||
|
||||
GstTagList *tags;
|
||||
GstTagList *tags;
|
||||
|
||||
/* time tracker */
|
||||
guint64 last_ts, last_offs, last_duration;
|
||||
};
|
||||
/* time tracker */
|
||||
guint64 last_ts, last_offs, last_duration;
|
||||
};
|
||||
|
||||
struct _GstLameClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstLameClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_lame_get_type (void);
|
||||
GType gst_lame_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_LAME_H__ */
|
||||
#endif /* __GST_LAME_H__ */
|
||||
|
|
|
@ -26,13 +26,17 @@
|
|||
#include <mad.h>
|
||||
#include <id3tag.h>
|
||||
|
||||
G_BEGIN_DECLS GType gst_mad_get_type (void);
|
||||
GType gst_id3_parse_get_type (void);
|
||||
GType gst_id3_tag_get_type (void);
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
GstTagList *gst_mad_id3_to_tag_list (const struct id3_tag *tag);
|
||||
struct id3_tag *gst_mad_tag_list_to_id3_tag (GstTagList * list);
|
||||
GType gst_mad_get_type (void);
|
||||
GType gst_id3_parse_get_type (void);
|
||||
GType gst_id3_tag_get_type (void);
|
||||
|
||||
GstTagList* gst_mad_id3_to_tag_list (const struct id3_tag * tag);
|
||||
struct id3_tag * gst_mad_tag_list_to_id3_tag (GstTagList * list);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MAD_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <mpeg2.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_MPEG2DEC \
|
||||
(gst_mpeg2dec_get_type())
|
||||
#define GST_MPEG2DEC(obj) \
|
||||
|
@ -36,8 +37,10 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_MPEG2DEC))
|
||||
#define GST_IS_MPEG2DEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MPEG2DEC))
|
||||
|
||||
#define MPEGTIME_TO_GSTTIME(time) (((time) * (GST_MSECOND/10)) / 9LL)
|
||||
#define GSTTIME_TO_MPEGTIME(time) (((time) * 9LL) / (GST_MSECOND/10))
|
||||
|
||||
typedef struct _GstMpeg2dec GstMpeg2dec;
|
||||
typedef struct _GstMpeg2decClass GstMpeg2decClass;
|
||||
|
||||
|
@ -48,53 +51,54 @@ typedef enum
|
|||
MPEG2DEC_FORMAT_YV12,
|
||||
} Mpeg2decFormat;
|
||||
|
||||
typedef enum
|
||||
typedef enum
|
||||
{
|
||||
MPEG2DEC_DISC_NONE = 0,
|
||||
MPEG2DEC_DISC_NONE = 0,
|
||||
MPEG2DEC_DISC_NEW_PICTURE,
|
||||
MPEG2DEC_DISC_NEW_KEYFRAME,
|
||||
} DiscontState;
|
||||
|
||||
struct _GstMpeg2dec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMpeg2dec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad, *userdatapad;
|
||||
GstPad *sinkpad,
|
||||
*srcpad,
|
||||
*userdatapad;
|
||||
|
||||
mpeg2dec_t *decoder;
|
||||
gboolean closed;
|
||||
gboolean have_fbuf;
|
||||
mpeg2dec_t *decoder;
|
||||
gboolean closed;
|
||||
gboolean have_fbuf;
|
||||
|
||||
/* the timestamp of the next frame */
|
||||
DiscontState discont_state;
|
||||
gint64 next_time;
|
||||
gint64 segment_start;
|
||||
gint64 segment_end;
|
||||
DiscontState discont_state;
|
||||
gint64 next_time;
|
||||
gint64 segment_start;
|
||||
gint64 segment_end;
|
||||
|
||||
/* video state */
|
||||
Mpeg2decFormat format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint pixel_width;
|
||||
gint pixel_height;
|
||||
gint frame_rate_code;
|
||||
gint64 total_frames;
|
||||
gint64 frame_period;
|
||||
gboolean need_sequence;
|
||||
gint width;
|
||||
gint height;
|
||||
gint pixel_width;
|
||||
gint pixel_height;
|
||||
gint frame_rate_code;
|
||||
gint64 total_frames;
|
||||
gint64 frame_period;
|
||||
gboolean need_sequence;
|
||||
|
||||
GstEvent *pending_event;
|
||||
GstEvent *pending_event;
|
||||
|
||||
GstIndex *index;
|
||||
gint index_id;
|
||||
GstIndex *index;
|
||||
gint index_id;
|
||||
};
|
||||
|
||||
struct _GstMpeg2decClass
|
||||
{
|
||||
struct _GstMpeg2decClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mpeg2dec_get_type (void);
|
||||
GType gst_mpeg2dec_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MPEG2DEC_H__ */
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_SIDDEC \
|
||||
(gst_siddec_get_type())
|
||||
#define GST_SIDDEC(obj) \
|
||||
|
@ -38,37 +39,38 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SIDDEC))
|
||||
#define GST_IS_SIDDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SIDDEC))
|
||||
|
||||
typedef struct _GstSidDec GstSidDec;
|
||||
typedef struct _GstSidDecClass GstSidDecClass;
|
||||
|
||||
struct _GstSidDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSidDec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,
|
||||
*srcpad;
|
||||
|
||||
gint state;
|
||||
guchar *tune_buffer;
|
||||
gint tune_len;
|
||||
gint tune_number;
|
||||
guint64 total_bytes;
|
||||
gint state;
|
||||
guchar *tune_buffer;
|
||||
gint tune_len;
|
||||
gint tune_number;
|
||||
guint64 total_bytes;
|
||||
|
||||
emuEngine *engine;
|
||||
sidTune *tune;
|
||||
emuConfig *config;
|
||||
emuEngine *engine;
|
||||
sidTune *tune;
|
||||
emuConfig *config;
|
||||
|
||||
gulong blocksize;
|
||||
gulong blocksize;
|
||||
|
||||
GstCaps *metadata;
|
||||
GstCaps *metadata;
|
||||
};
|
||||
|
||||
struct _GstSidDecClass
|
||||
{
|
||||
struct _GstSidDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_siddec_get_type (void);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SIDDEC_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#define __GST_AUDIO_AUDIO_H__
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* For people that are looking at this source: the purpose of these defines is
|
||||
* to make GstCaps a bit easier, in that you don't have to know all of the
|
||||
* properties that need to be defined. you can just use these macros. currently
|
||||
|
@ -49,7 +50,9 @@ G_BEGIN_DECLS
|
|||
*
|
||||
* Andy Wingo, 18 August 2001
|
||||
* Thomas, 6 September 2002 */
|
||||
|
||||
#define GST_AUDIO_DEF_RATE 44100
|
||||
|
||||
#define GST_AUDIO_INT_PAD_TEMPLATE_CAPS \
|
||||
"audio/x-raw-int, " \
|
||||
"rate = (int) [ 1, MAX ], " \
|
||||
|
@ -57,7 +60,9 @@ G_BEGIN_DECLS
|
|||
"endianness = (int) { LITTLE_ENDIAN, BIG_ENDIAN }, " \
|
||||
"width = (int) { 8, 16, 32 }, " \
|
||||
"depth = (int) [ 1, 32 ], " \
|
||||
"signed = (boolean) { true, false }"
|
||||
"signed = (boolean) { true, false }"
|
||||
|
||||
|
||||
/* "standard" int audio is native order, 16 bit stereo. */
|
||||
#define GST_AUDIO_INT_STANDARD_PAD_TEMPLATE_CAPS \
|
||||
"audio/x-raw-int, " \
|
||||
|
@ -66,7 +71,8 @@ G_BEGIN_DECLS
|
|||
"endianness = (int) BYTE_ORDER, " \
|
||||
"width = (int) 16, " \
|
||||
"depth = (int) 16, " \
|
||||
"signed = (boolean) true"
|
||||
"signed = (boolean) true"
|
||||
|
||||
#define GST_AUDIO_FLOAT_PAD_TEMPLATE_CAPS \
|
||||
"audio/x-raw-float, " \
|
||||
"rate = (int) [ 1, MAX ], " \
|
||||
|
@ -74,6 +80,7 @@ G_BEGIN_DECLS
|
|||
"endianness = (int) { LITTLE_ENDIAN , BIG_ENDIAN }, " \
|
||||
"width = (int) { 32, 64 }, " \
|
||||
"buffer-frames = (int) [ 1, MAX]"
|
||||
|
||||
/* "standard" float audio is native order, 32 bit mono. */
|
||||
#define GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS \
|
||||
"audio/x-raw-float, " \
|
||||
|
@ -81,42 +88,43 @@ G_BEGIN_DECLS
|
|||
"channels = (int) 1, " \
|
||||
"endianness = (int) BYTE_ORDER, " \
|
||||
"buffer-frames = (int) [ 1, MAX]"
|
||||
|
||||
/*
|
||||
* this library defines and implements some helper functions for audio
|
||||
* handling
|
||||
*/
|
||||
|
||||
/* get byte size of audio frame (based on caps of pad */
|
||||
int gst_audio_frame_byte_size (GstPad * pad);
|
||||
int gst_audio_frame_byte_size (GstPad* pad);
|
||||
|
||||
/* get length in frames of buffer */
|
||||
long gst_audio_frame_length (GstPad * pad, GstBuffer * buf);
|
||||
long gst_audio_frame_length (GstPad* pad, GstBuffer* buf);
|
||||
|
||||
/* get frame rate based on caps */
|
||||
long gst_audio_frame_rate (GstPad * pad);
|
||||
long gst_audio_frame_rate (GstPad *pad);
|
||||
|
||||
/* calculate length in seconds of audio buffer buf based on caps of pad */
|
||||
double gst_audio_length (GstPad * pad, GstBuffer * buf);
|
||||
double gst_audio_length (GstPad* pad, GstBuffer* buf);
|
||||
|
||||
/* calculate highest possible sample value based on capabilities of pad */
|
||||
long gst_audio_highest_sample_value (GstPad * pad);
|
||||
long gst_audio_highest_sample_value (GstPad* pad);
|
||||
|
||||
/* check if the buffer size is a whole multiple of the frame size */
|
||||
gboolean gst_audio_is_buffer_framed (GstPad * pad, GstBuffer * buf);
|
||||
gboolean gst_audio_is_buffer_framed (GstPad* pad, GstBuffer* buf);
|
||||
|
||||
/* functions useful for _getcaps functions */
|
||||
typedef enum
|
||||
{
|
||||
GST_AUDIO_FIELD_RATE = (1 << 0),
|
||||
GST_AUDIO_FIELD_CHANNELS = (1 << 1),
|
||||
GST_AUDIO_FIELD_ENDIANNESS = (1 << 2),
|
||||
GST_AUDIO_FIELD_WIDTH = (1 << 3),
|
||||
GST_AUDIO_FIELD_DEPTH = (1 << 4),
|
||||
GST_AUDIO_FIELD_SIGNED = (1 << 5),
|
||||
typedef enum {
|
||||
GST_AUDIO_FIELD_RATE = (1 << 0),
|
||||
GST_AUDIO_FIELD_CHANNELS = (1 << 1),
|
||||
GST_AUDIO_FIELD_ENDIANNESS = (1 << 2),
|
||||
GST_AUDIO_FIELD_WIDTH = (1 << 3),
|
||||
GST_AUDIO_FIELD_DEPTH = (1 << 4),
|
||||
GST_AUDIO_FIELD_SIGNED = (1 << 5),
|
||||
GST_AUDIO_FIELD_BUFFER_FRAMES = (1 << 6)
|
||||
} GstAudioFieldFlag;
|
||||
|
||||
void gst_audio_structure_set_int (GstStructure * structure,
|
||||
GstAudioFieldFlag flag);
|
||||
void gst_audio_structure_set_int (GstStructure *structure, GstAudioFieldFlag flag);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_AUDIO_AUDIO_H__ */
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/gstsystemclock.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_AUDIO_CLOCK \
|
||||
(gst_audio_clock_get_type())
|
||||
#define GST_AUDIO_CLOCK(obj) \
|
||||
|
@ -37,15 +38,14 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_CLOCK))
|
||||
#define GST_IS_AUDIO_CLOCK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_CLOCK))
|
||||
|
||||
typedef struct _GstAudioClock GstAudioClock;
|
||||
typedef struct _GstAudioClockClass GstAudioClockClass;
|
||||
|
||||
typedef GstClockTime (*GstAudioClockGetTimeFunc) (GstClock * clock,
|
||||
gpointer user_data);
|
||||
typedef GstClockTime (*GstAudioClockGetTimeFunc) (GstClock *clock, gpointer user_data);
|
||||
|
||||
|
||||
struct _GstAudioClock
|
||||
{
|
||||
struct _GstAudioClock {
|
||||
GstSystemClock clock;
|
||||
|
||||
GstClockTime prev1, prev2;
|
||||
|
@ -63,19 +63,19 @@ struct _GstAudioClock
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstAudioClockClass
|
||||
{
|
||||
struct _GstAudioClockClass {
|
||||
GstSystemClockClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
GType gst_audio_clock_get_type (void);
|
||||
GstClock *gst_audio_clock_new (gchar * name, GstAudioClockGetTimeFunc func,
|
||||
gpointer user_data);
|
||||
void gst_audio_clock_set_active (GstAudioClock * aclock, gboolean active);
|
||||
GType gst_audio_clock_get_type (void);
|
||||
GstClock* gst_audio_clock_new (gchar *name, GstAudioClockGetTimeFunc func,
|
||||
gpointer user_data);
|
||||
void gst_audio_clock_set_active (GstAudioClock *aclock, gboolean active);
|
||||
|
||||
void gst_audio_clock_update_time (GstAudioClock * aclock, GstClockTime time);
|
||||
void gst_audio_clock_update_time (GstAudioClock *aclock, GstClockTime time);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_AUDIO_CLOCK_H__ */
|
||||
|
|
|
@ -25,15 +25,17 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstAudiofilter GstAudiofilter;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstAudiofilter GstAudiofilter;
|
||||
typedef struct _GstAudiofilterClass GstAudiofilterClass;
|
||||
|
||||
typedef void (*GstAudiofilterFilterFunc) (GstAudiofilter * filter,
|
||||
GstBuffer * outbuf, GstBuffer * inbuf);
|
||||
typedef void (*GstAudiofilterInplaceFilterFunc) (GstAudiofilter * filter,
|
||||
GstBuffer * buffer);
|
||||
typedef void (*GstAudiofilterFilterFunc)(GstAudiofilter *filter,
|
||||
GstBuffer *outbuf, GstBuffer *inbuf);
|
||||
typedef void (*GstAudiofilterInplaceFilterFunc)(GstAudiofilter *filter,
|
||||
GstBuffer *buffer);
|
||||
|
||||
typedef void (*GstAudiofilterSetupFunc) (GstAudiofilter * filter);
|
||||
typedef void (*GstAudiofilterSetupFunc) (GstAudiofilter *filter);
|
||||
|
||||
|
||||
#define GST_TYPE_AUDIOFILTER \
|
||||
|
@ -47,11 +49,10 @@ typedef void (*GstAudiofilterSetupFunc) (GstAudiofilter * filter);
|
|||
#define GST_IS_AUDIOFILTER_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIOFILTER))
|
||||
|
||||
struct _GstAudiofilter
|
||||
{
|
||||
struct _GstAudiofilter {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
/* audio state */
|
||||
gboolean inited;
|
||||
|
@ -67,8 +68,7 @@ struct _GstAudiofilter
|
|||
int bytes_per_sample;
|
||||
};
|
||||
|
||||
struct _GstAudiofilterClass
|
||||
{
|
||||
struct _GstAudiofilterClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
GstCaps *caps;
|
||||
|
@ -77,10 +77,11 @@ struct _GstAudiofilterClass
|
|||
GstAudiofilterFilterFunc filter;
|
||||
};
|
||||
|
||||
GType gst_audiofilter_get_type (void);
|
||||
GType gst_audiofilter_get_type(void);
|
||||
|
||||
void gst_audiofilter_class_add_pad_templates (GstAudiofilterClass *
|
||||
audiofilterclass, const GstCaps * caps);
|
||||
void gst_audiofilter_class_add_pad_templates (GstAudiofilterClass *audiofilterclass, const GstCaps *caps);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_AUDIOFILTER_H__ */
|
||||
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/colorbalance/colorbalance-enumtypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_COLOR_BALANCE \
|
||||
(gst_color_balance_get_type ())
|
||||
#define GST_COLOR_BALANCE(obj) \
|
||||
|
@ -41,48 +42,55 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_COLOR_BALANCE))
|
||||
#define GST_COLOR_BALANCE_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_COLOR_BALANCE, GstColorBalanceClass))
|
||||
|
||||
#define GST_COLOR_BALANCE_TYPE(klass) (klass->balance_type)
|
||||
typedef struct _GstColorBalance GstColorBalance;
|
||||
|
||||
typedef struct _GstColorBalance GstColorBalance;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_COLOR_BALANCE_HARDWARE,
|
||||
GST_COLOR_BALANCE_SOFTWARE
|
||||
} GstColorBalanceType;
|
||||
|
||||
typedef struct _GstColorBalanceClass
|
||||
{
|
||||
typedef struct _GstColorBalanceClass {
|
||||
GTypeInterface klass;
|
||||
|
||||
GstColorBalanceType balance_type;
|
||||
|
||||
|
||||
/* virtual functions */
|
||||
const GList *(*list_channels) (GstColorBalance * balance);
|
||||
const GList * (* list_channels) (GstColorBalance *balance);
|
||||
|
||||
void (*set_value) (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel, gint value);
|
||||
gint (*get_value) (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel);
|
||||
void (* set_value) (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel,
|
||||
gint value);
|
||||
gint (* get_value) (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel);
|
||||
|
||||
/* signals */
|
||||
void (*value_changed) (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel, gint value);
|
||||
void (* value_changed) (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel,
|
||||
gint value);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstColorBalanceClass;
|
||||
|
||||
GType gst_color_balance_get_type (void);
|
||||
GType gst_color_balance_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
const GList *gst_color_balance_list_channels (GstColorBalance * balance);
|
||||
void gst_color_balance_set_value (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel, gint value);
|
||||
gint gst_color_balance_get_value (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel);
|
||||
const GList *
|
||||
gst_color_balance_list_channels (GstColorBalance *balance);
|
||||
void gst_color_balance_set_value (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel,
|
||||
gint value);
|
||||
gint gst_color_balance_get_value (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel);
|
||||
|
||||
/* trigger signal */
|
||||
void gst_color_balance_value_changed (GstColorBalance * balance,
|
||||
GstColorBalanceChannel * channel, gint value);
|
||||
void gst_color_balance_value_changed (GstColorBalance *balance,
|
||||
GstColorBalanceChannel *channel,
|
||||
gint value);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_COLOR_BALANCE_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_COLOR_BALANCE_CHANNEL \
|
||||
(gst_color_balance_channel_get_type ())
|
||||
#define GST_COLOR_BALANCE_CHANNEL(obj) \
|
||||
|
@ -37,25 +38,27 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_COLOR_BALANCE_CHANNEL))
|
||||
#define GST_IS_COLOR_BALANCE_CHANNEL_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_COLOR_BALANCE_CHANNEL))
|
||||
typedef struct _GstColorBalanceChannel
|
||||
{
|
||||
|
||||
typedef struct _GstColorBalanceChannel {
|
||||
GObject parent;
|
||||
|
||||
gchar *label;
|
||||
gint min_value, max_value;
|
||||
gchar *label;
|
||||
gint min_value,
|
||||
max_value;
|
||||
} GstColorBalanceChannel;
|
||||
|
||||
typedef struct _GstColorBalanceChannelClass
|
||||
{
|
||||
typedef struct _GstColorBalanceChannelClass {
|
||||
GObjectClass parent;
|
||||
|
||||
/* signals */
|
||||
void (*value_changed) (GstColorBalanceChannel * channel, gint value);
|
||||
void (* value_changed) (GstColorBalanceChannel *channel,
|
||||
gint value);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstColorBalanceChannelClass;
|
||||
|
||||
GType gst_color_balance_channel_get_type (void);
|
||||
GType gst_color_balance_channel_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_COLOR_BALANCE_CHANNEL_H__ */
|
||||
|
|
|
@ -29,46 +29,53 @@
|
|||
#include <glib/gtypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#if (HAVE_LRINT && HAVE_LRINTF)
|
||||
/* These defines enable functionality introduced with the 1999 ISO C
|
||||
** standard. They must be defined before the inclusion of math.h to
|
||||
** engage them. If optimisation is enabled, these functions will be
|
||||
** inlined. With optimisation switched off, you have to link in the
|
||||
** maths library using -lm.
|
||||
*/
|
||||
#define _ISOC9X_SOURCE 1
|
||||
#define _ISOC99_SOURCE 1
|
||||
#define __USE_ISOC9X 1
|
||||
#define __USE_ISOC99 1
|
||||
#include <math.h>
|
||||
#define gst_cast_float(x) ((gint)lrintf(x))
|
||||
#define gst_cast_double(x) ((gint)lrint(x))
|
||||
|
||||
/* These defines enable functionality introduced with the 1999 ISO C
|
||||
** standard. They must be defined before the inclusion of math.h to
|
||||
** engage them. If optimisation is enabled, these functions will be
|
||||
** inlined. With optimisation switched off, you have to link in the
|
||||
** maths library using -lm.
|
||||
*/
|
||||
|
||||
#define _ISOC9X_SOURCE 1
|
||||
#define _ISOC99_SOURCE 1
|
||||
|
||||
#define __USE_ISOC9X 1
|
||||
#define __USE_ISOC99 1
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#define gst_cast_float(x) ((gint)lrintf(x))
|
||||
#define gst_cast_double(x) ((gint)lrint(x))
|
||||
|
||||
#else
|
||||
/* use a standard c cast, but do rounding correctly */
|
||||
#define gst_cast_float(x) ((gint)floor((x)+0.5))
|
||||
#define gst_cast_double(x) ((gint)floor((x)+0.5))
|
||||
/* use a standard c cast, but do rounding correctly */
|
||||
#define gst_cast_float(x) ((gint)floor((x)+0.5))
|
||||
#define gst_cast_double(x) ((gint)floor((x)+0.5))
|
||||
|
||||
#endif
|
||||
|
||||
inline static gfloat
|
||||
GFLOAT_SWAP_LE_BE (gfloat in)
|
||||
GFLOAT_SWAP_LE_BE(gfloat in)
|
||||
{
|
||||
gint32 swap;
|
||||
gfloat out;
|
||||
|
||||
memcpy (&swap, &in, 4);
|
||||
memcpy(&swap, &in, 4);
|
||||
swap = GUINT32_SWAP_LE_BE_CONSTANT (swap);
|
||||
memcpy (&out, &swap, 4);
|
||||
memcpy(&out, &swap, 4);
|
||||
return out;
|
||||
}
|
||||
|
||||
inline static gdouble
|
||||
GDOUBLE_SWAP_LE_BE (gdouble in)
|
||||
GDOUBLE_SWAP_LE_BE(gdouble in)
|
||||
{
|
||||
gint64 swap;
|
||||
gdouble out;
|
||||
|
||||
memcpy (&swap, &in, 8);
|
||||
memcpy(&swap, &in, 8);
|
||||
swap = GUINT64_SWAP_LE_BE_CONSTANT (swap);
|
||||
memcpy (&out, &swap, 8);
|
||||
memcpy(&out, &swap, 8);
|
||||
return out;
|
||||
}
|
||||
|
||||
|
@ -94,4 +101,6 @@ GDOUBLE_SWAP_LE_BE (gdouble in)
|
|||
#define GDOUBLE_FROM_BE(val) (GDOUBLE_TO_BE (val))
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __FLOATCAST_H__ */
|
||||
|
||||
|
|
|
@ -27,16 +27,17 @@
|
|||
#include <gst/gst.h>
|
||||
#include <gconf/gconf-client.h>
|
||||
|
||||
gchar *gst_gconf_get_string (const gchar * key);
|
||||
void gst_gconf_set_string (const gchar * key, const gchar * value);
|
||||
gchar * gst_gconf_get_string (const gchar *key);
|
||||
void gst_gconf_set_string (const gchar *key,
|
||||
const gchar *value);
|
||||
|
||||
GstElement *gst_gconf_render_bin_from_key (const gchar * key);
|
||||
GstElement *gst_gconf_render_bin_from_description (const gchar * description);
|
||||
GstElement * gst_gconf_render_bin_from_key (const gchar *key);
|
||||
GstElement * gst_gconf_render_bin_from_description (const gchar *description);
|
||||
|
||||
GstElement *gst_gconf_get_default_video_sink (void);
|
||||
GstElement *gst_gconf_get_default_audio_sink (void);
|
||||
GstElement *gst_gconf_get_default_video_src (void);
|
||||
GstElement *gst_gconf_get_default_audio_src (void);
|
||||
GstElement *gst_gconf_get_default_visualization_element (void);
|
||||
GstElement * gst_gconf_get_default_video_sink (void);
|
||||
GstElement * gst_gconf_get_default_audio_sink (void);
|
||||
GstElement * gst_gconf_get_default_video_src (void);
|
||||
GstElement * gst_gconf_get_default_audio_src (void);
|
||||
GstElement * gst_gconf_get_default_visualization_element (void);
|
||||
|
||||
#endif /* GST_GCONF_H */
|
||||
|
|
|
@ -22,8 +22,8 @@
|
|||
#ifndef __GST_I18N_PLUGIN_H__
|
||||
#define __GST_I18N_PLUGIN_H__
|
||||
|
||||
#include <locale.h> /* some people need it and some people don't */
|
||||
#include "gettext.h" /* included with gettext distribution and copied */
|
||||
#include <locale.h> /* some people need it and some people don't */
|
||||
#include "gettext.h" /* included with gettext distribution and copied */
|
||||
|
||||
#ifndef GETTEXT_PACKAGE
|
||||
#error You must define GETTEXT_PACKAGE before including this header.
|
||||
|
|
|
@ -16,7 +16,7 @@ typedef DCTELEM DCTBLOCK[DCTSIZE2];
|
|||
|
||||
typedef long INT32; /* must be at least 32 bits */
|
||||
|
||||
extern void gst_idct_int_idct ();
|
||||
extern void gst_idct_int_idct();
|
||||
|
||||
extern void gst_idct_init_fast_int_idct (void);
|
||||
extern void gst_idct_fast_int_idct (short *block);
|
||||
|
@ -27,5 +27,6 @@ extern void gst_idct_mmx32_idct (short *block);
|
|||
extern void gst_idct_sse_idct (short *block);
|
||||
#endif /* HAVE_LIBMMX */
|
||||
|
||||
extern void gst_idct_init_float_idct (void);
|
||||
extern void gst_idct_init_float_idct(void);
|
||||
extern void gst_idct_float_idct (short *block);
|
||||
|
||||
|
|
|
@ -23,24 +23,22 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_IDCT_DEFAULT,
|
||||
GST_IDCT_INT,
|
||||
GST_IDCT_FAST_INT,
|
||||
GST_IDCT_FLOAT,
|
||||
GST_IDCT_MMX,
|
||||
typedef enum {
|
||||
GST_IDCT_DEFAULT,
|
||||
GST_IDCT_INT,
|
||||
GST_IDCT_FAST_INT,
|
||||
GST_IDCT_FLOAT,
|
||||
GST_IDCT_MMX,
|
||||
GST_IDCT_MMX32,
|
||||
GST_IDCT_SSE,
|
||||
} GstIDCTMethod;
|
||||
|
||||
typedef struct _GstIDCT GstIDCT;
|
||||
typedef void (*GstIDCTFunction) (gshort * block);
|
||||
typedef void (*GstIDCTFunction) (gshort *block);
|
||||
|
||||
#define GST_IDCT_TRANSPOSE(idct) ((idct)->need_transpose)
|
||||
|
||||
struct _GstIDCT
|
||||
{
|
||||
struct _GstIDCT {
|
||||
/* private */
|
||||
GstIDCTFunction convert;
|
||||
GstIDCTFunction convert_sparse;
|
||||
|
@ -48,10 +46,9 @@ struct _GstIDCT
|
|||
};
|
||||
|
||||
|
||||
GstIDCT *gst_idct_new (GstIDCTMethod method);
|
||||
|
||||
GstIDCT *gst_idct_new(GstIDCTMethod method);
|
||||
#define gst_idct_convert(idct, blocks) (idct)->convert((blocks))
|
||||
#define gst_idct_convert_sparse(idct, blocks) (idct)->convert_sparse((blocks))
|
||||
void gst_idct_destroy (GstIDCT * idct);
|
||||
void gst_idct_destroy(GstIDCT *idct);
|
||||
|
||||
#endif /* __GST_IDCT_H__ */
|
||||
|
|
|
@ -72,65 +72,69 @@ struct GstMediaInfoPriv
|
|||
gint metadata_iters;
|
||||
GstTagList *streaminfo;
|
||||
|
||||
GstElement *pipeline; /* will be != NULL during collection */
|
||||
gchar *pipeline_desc; /* will be != NULL during collection */
|
||||
GstElement *fakesink; /* so we can get caps from the
|
||||
decoder sink pad */
|
||||
gchar *source_name; /* type of element used as source */
|
||||
GstElement *pipeline; /* will be != NULL during collection */
|
||||
gchar *pipeline_desc; /* will be != NULL during collection */
|
||||
GstElement *fakesink; /* so we can get caps from the
|
||||
decoder sink pad */
|
||||
gchar *source_name; /* type of element used as source */
|
||||
GstElement *source;
|
||||
GstPad *source_pad; /* pad for querying encoded caps */
|
||||
GstPad *source_pad; /* pad for querying encoded caps */
|
||||
GstElement *decoder;
|
||||
GstPad *decoder_pad; /* pad for querying decoded caps */
|
||||
GstElement *decontainer; /* element to typefind in containers */
|
||||
GstPad *decoder_pad; /* pad for querying decoded caps */
|
||||
GstElement *decontainer; /* element to typefind in containers */
|
||||
|
||||
GstMediaInfoState state; /* current state of state machine */
|
||||
gchar *location; /* location set on the info object */
|
||||
guint16 flags; /* flags supplied for detection */
|
||||
GstMediaInfoTrack *current_track; /* track pointer under inspection */
|
||||
glong current_track_num; /* current track under inspection */
|
||||
GstMediaInfoState state; /* current state of state machine */
|
||||
gchar *location; /* location set on the info object */
|
||||
guint16 flags; /* flags supplied for detection */
|
||||
GstMediaInfoTrack *current_track; /* track pointer under inspection */
|
||||
glong current_track_num; /* current track under inspection */
|
||||
|
||||
GstMediaInfoStream *stream; /* total stream properties */
|
||||
char *cache; /* location of cache */
|
||||
GstMediaInfoStream *stream; /* total stream properties */
|
||||
char *cache; /* location of cache */
|
||||
|
||||
GError *error; /* error for creation problems */
|
||||
GError *error; /* error for creation problems */
|
||||
};
|
||||
|
||||
/* declarations */
|
||||
GstMediaInfoStream *gmi_stream_new (void);
|
||||
void gmi_stream_free (GstMediaInfoStream * stream);
|
||||
GstMediaInfoStream *
|
||||
gmi_stream_new (void);
|
||||
void gmi_stream_free (GstMediaInfoStream *stream);
|
||||
|
||||
GstMediaInfoTrack *gmi_track_new (void);
|
||||
GstMediaInfoTrack *
|
||||
gmi_track_new (void);
|
||||
|
||||
void gmip_reset (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_init (GstMediaInfoPriv * priv, GError ** error);
|
||||
void gmip_reset (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_init (GstMediaInfoPriv *priv, GError **error);
|
||||
|
||||
void gmi_clear_decoder (GstMediaInfo * info);
|
||||
void gmi_clear_decoder (GstMediaInfo *info);
|
||||
|
||||
gboolean gmi_seek_to_track (GstMediaInfo * info, long track);
|
||||
gboolean gmi_seek_to_track (GstMediaInfo *info,
|
||||
long track);
|
||||
|
||||
gboolean gmi_set_mime (GstMediaInfo * info, const char *mime);
|
||||
gboolean gmi_set_mime (GstMediaInfo *info,
|
||||
const char *mime);
|
||||
|
||||
void deep_notify_callback (GObject * object,
|
||||
GstObject * origin, GParamSpec * pspec, GstMediaInfoPriv * priv);
|
||||
void found_tag_callback (GObject * pipeline, GstElement * source,
|
||||
GstTagList * tags, GstMediaInfoPriv * priv);
|
||||
void error_callback (GObject * element, GstElement * source, GError * error,
|
||||
gchar * debug, GstMediaInfoPriv * priv);
|
||||
void deep_notify_callback (GObject *object,
|
||||
GstObject *origin,
|
||||
GParamSpec *pspec,
|
||||
GstMediaInfoPriv *priv);
|
||||
void found_tag_callback (GObject *pipeline, GstElement *source, GstTagList *tags, GstMediaInfoPriv *priv);
|
||||
void error_callback (GObject *element, GstElement *source, GError *error, gchar *debug, GstMediaInfoPriv *priv);
|
||||
|
||||
gboolean gmip_find_type_pre (GstMediaInfoPriv * priv, GError ** error);
|
||||
gboolean gmip_find_type_post (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_type (GstMediaInfoPriv * priv, GError ** error);
|
||||
gboolean gmip_find_stream_pre (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_stream_post (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_stream (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_metadata_pre (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_metadata_post (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_metadata (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_streaminfo_pre (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_streaminfo_post (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_streaminfo (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_format_pre (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_format_post (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_track_format (GstMediaInfoPriv * priv);
|
||||
gboolean gmip_find_type_pre (GstMediaInfoPriv *priv, GError **error);
|
||||
gboolean gmip_find_type_post (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_type (GstMediaInfoPriv *priv, GError **error);
|
||||
gboolean gmip_find_stream_pre (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_stream_post (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_stream (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_metadata_pre (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_metadata_post (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_metadata (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_streaminfo_pre (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_streaminfo_post (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_streaminfo (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_format_pre (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_format_post (GstMediaInfoPriv *priv);
|
||||
gboolean gmip_find_track_format (GstMediaInfoPriv *priv);
|
||||
|
||||
#endif /* __GST_MEDIA_INFO_PRIV_H__ */
|
||||
|
|
|
@ -23,9 +23,11 @@
|
|||
|
||||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct GstMediaInfoPriv GstMediaInfoPriv;
|
||||
typedef struct _GstMediaInfo GstMediaInfo;
|
||||
typedef struct _GstMediaInfoClass GstMediaInfoClass;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct GstMediaInfoPriv GstMediaInfoPriv;
|
||||
typedef struct _GstMediaInfo GstMediaInfo;
|
||||
typedef struct _GstMediaInfoClass GstMediaInfoClass;
|
||||
|
||||
struct _GstMediaInfo
|
||||
{
|
||||
|
@ -41,9 +43,8 @@ struct _GstMediaInfoClass
|
|||
GObjectClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*media_info_signal) (GstMediaInfo * gst_media_info);
|
||||
void (*error_signal) (GstMediaInfo * gst_media_info, GError * error,
|
||||
const gchar * debug);
|
||||
void (*media_info_signal) (GstMediaInfo *gst_media_info);
|
||||
void (*error_signal) (GstMediaInfo *gst_media_info, GError *error, const gchar *debug);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
@ -99,25 +100,34 @@ typedef struct
|
|||
#define GST_MEDIA_INFO_FORMAT 1 << 5
|
||||
#define GST_MEDIA_INFO_ALL ((1 << 6) - 1)
|
||||
|
||||
GQuark gst_media_info_error_quark (void);
|
||||
GQuark gst_media_info_error_quark (void);
|
||||
|
||||
void gst_media_info_init (void);
|
||||
GType gst_media_info_get_type (void);
|
||||
void gst_media_info_init (void);
|
||||
GType gst_media_info_get_type (void);
|
||||
|
||||
GstMediaInfo *gst_media_info_new (GError ** error);
|
||||
|
||||
gboolean gst_media_info_set_source (GstMediaInfo * info,
|
||||
const char *source, GError ** error);
|
||||
void gst_media_info_read_with_idler (GstMediaInfo * media_info,
|
||||
const char *location, guint16 GST_MEDIA_INFO_FLAGS, GError ** error);
|
||||
gboolean gst_media_info_read_idler (GstMediaInfo * media_info,
|
||||
GstMediaInfoStream ** streamp, GError ** error);
|
||||
GstMediaInfoStream *gst_media_info_read (GstMediaInfo * media_info,
|
||||
const char *location, guint16 GST_MEDIA_INFO_FLAGS, GError ** error);
|
||||
gboolean gst_media_info_read_many (GstMediaInfo * media_info,
|
||||
GList * locations, guint16 GST_MEDIA_INFO_FLAGS, GError ** error);
|
||||
GstCaps *gst_media_info_get_next (GstMediaInfo * media_info, GError ** error);
|
||||
GstMediaInfo * gst_media_info_new (GError **error);
|
||||
|
||||
gboolean gst_media_info_set_source (GstMediaInfo *info,
|
||||
const char *source,
|
||||
GError **error);
|
||||
void gst_media_info_read_with_idler (GstMediaInfo *media_info,
|
||||
const char *location,
|
||||
guint16 GST_MEDIA_INFO_FLAGS,
|
||||
GError **error);
|
||||
gboolean gst_media_info_read_idler (GstMediaInfo *media_info,
|
||||
GstMediaInfoStream **streamp,
|
||||
GError **error);
|
||||
GstMediaInfoStream *
|
||||
gst_media_info_read (GstMediaInfo *media_info,
|
||||
const char *location,
|
||||
guint16 GST_MEDIA_INFO_FLAGS,
|
||||
GError **error);
|
||||
gboolean gst_media_info_read_many (GstMediaInfo *media_info,
|
||||
GList *locations,
|
||||
guint16 GST_MEDIA_INFO_FLAGS,
|
||||
GError **error);
|
||||
GstCaps * gst_media_info_get_next (GstMediaInfo *media_info,
|
||||
GError **error);
|
||||
/*
|
||||
* FIXME: reset ?
|
||||
gboolean gst_media_info_write (GstMediaInfo *media_info,
|
||||
|
@ -126,4 +136,5 @@ gboolean gst_media_info_write (GstMediaInfo *media_info,
|
|||
*/
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MEDIA_INFO_H__ */
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/mixer/mixer-enumtypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_MIXER \
|
||||
(gst_mixer_get_type ())
|
||||
#define GST_MIXER(obj) \
|
||||
|
@ -39,7 +40,9 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_MIXER))
|
||||
#define GST_MIXER_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_MIXER, GstMixerClass))
|
||||
|
||||
#define GST_MIXER_TYPE(klass) (klass->mixer_type)
|
||||
|
||||
typedef struct _GstMixer GstMixer;
|
||||
|
||||
typedef enum
|
||||
|
@ -48,52 +51,70 @@ typedef enum
|
|||
GST_MIXER_SOFTWARE
|
||||
} GstMixerType;
|
||||
|
||||
typedef struct _GstMixerClass
|
||||
{
|
||||
typedef struct _GstMixerClass {
|
||||
GTypeInterface klass;
|
||||
|
||||
GstMixerType mixer_type;
|
||||
|
||||
|
||||
/* virtual functions */
|
||||
const GList *(*list_tracks) (GstMixer * mixer);
|
||||
const GList * (* list_tracks) (GstMixer *mixer);
|
||||
|
||||
void (*set_volume) (GstMixer * mixer, GstMixerTrack * track, gint * volumes);
|
||||
void (*get_volume) (GstMixer * mixer, GstMixerTrack * track, gint * volumes);
|
||||
void (* set_volume) (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gint *volumes);
|
||||
void (* get_volume) (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gint *volumes);
|
||||
|
||||
void (*set_mute) (GstMixer * mixer, GstMixerTrack * track, gboolean mute);
|
||||
void (*set_record) (GstMixer * mixer, GstMixerTrack * track, gboolean record);
|
||||
void (* set_mute) (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean mute);
|
||||
void (* set_record) (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean record);
|
||||
|
||||
/* signals */
|
||||
void (*mute_toggled) (GstMixer * mixer,
|
||||
GstMixerTrack * channel, gboolean mute);
|
||||
void (*record_toggled) (GstMixer * mixer,
|
||||
GstMixerTrack * channel, gboolean record);
|
||||
void (*volume_changed) (GstMixer * mixer,
|
||||
GstMixerTrack * channel, gint * volumes);
|
||||
void (* mute_toggled) (GstMixer *mixer,
|
||||
GstMixerTrack *channel,
|
||||
gboolean mute);
|
||||
void (* record_toggled) (GstMixer *mixer,
|
||||
GstMixerTrack *channel,
|
||||
gboolean record);
|
||||
void (* volume_changed) (GstMixer *mixer,
|
||||
GstMixerTrack *channel,
|
||||
gint *volumes);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstMixerClass;
|
||||
|
||||
GType gst_mixer_get_type (void);
|
||||
GType gst_mixer_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
const GList *gst_mixer_list_tracks (GstMixer * mixer);
|
||||
void gst_mixer_set_volume (GstMixer * mixer,
|
||||
GstMixerTrack * track, gint * volumes);
|
||||
void gst_mixer_get_volume (GstMixer * mixer,
|
||||
GstMixerTrack * track, gint * volumes);
|
||||
void gst_mixer_set_mute (GstMixer * mixer,
|
||||
GstMixerTrack * track, gboolean mute);
|
||||
void gst_mixer_set_record (GstMixer * mixer,
|
||||
GstMixerTrack * track, gboolean record);
|
||||
const GList * gst_mixer_list_tracks (GstMixer *mixer);
|
||||
void gst_mixer_set_volume (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gint *volumes);
|
||||
void gst_mixer_get_volume (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gint *volumes);
|
||||
void gst_mixer_set_mute (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean mute);
|
||||
void gst_mixer_set_record (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean record);
|
||||
|
||||
/* trigger signals */
|
||||
void gst_mixer_mute_toggled (GstMixer * mixer,
|
||||
GstMixerTrack * track, gboolean mute);
|
||||
void gst_mixer_record_toggled (GstMixer * mixer,
|
||||
GstMixerTrack * track, gboolean record);
|
||||
void gst_mixer_volume_changed (GstMixer * mixer,
|
||||
GstMixerTrack * track, gint * volumes);
|
||||
void gst_mixer_mute_toggled (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean mute);
|
||||
void gst_mixer_record_toggled (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gboolean record);
|
||||
void gst_mixer_volume_changed (GstMixer *mixer,
|
||||
GstMixerTrack *track,
|
||||
gint *volumes);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MIXER_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_MIXER_TRACK \
|
||||
(gst_mixer_track_get_type ())
|
||||
#define GST_MIXER_TRACK(obj) \
|
||||
|
@ -37,6 +38,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_MIXER_TRACK))
|
||||
#define GST_IS_MIXER_TRACK_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_MIXER_TRACK))
|
||||
|
||||
/*
|
||||
* Naming:
|
||||
*
|
||||
|
@ -52,41 +54,45 @@ G_BEGIN_DECLS
|
|||
* mixer, which means that setting this track will change
|
||||
* the hearable volume on any output.
|
||||
*/
|
||||
typedef enum
|
||||
{
|
||||
GST_MIXER_TRACK_INPUT = (1 << 0),
|
||||
GST_MIXER_TRACK_OUTPUT = (1 << 1),
|
||||
GST_MIXER_TRACK_MUTE = (1 << 2),
|
||||
GST_MIXER_TRACK_RECORD = (1 << 3),
|
||||
GST_MIXER_TRACK_MASTER = (1 << 4),
|
||||
GST_MIXER_TRACK_SOFTWARE = (1 << 5)
|
||||
|
||||
typedef enum {
|
||||
GST_MIXER_TRACK_INPUT = (1<<0),
|
||||
GST_MIXER_TRACK_OUTPUT = (1<<1),
|
||||
GST_MIXER_TRACK_MUTE = (1<<2),
|
||||
GST_MIXER_TRACK_RECORD = (1<<3),
|
||||
GST_MIXER_TRACK_MASTER = (1<<4),
|
||||
GST_MIXER_TRACK_SOFTWARE = (1<<5)
|
||||
} GstMixerTrackFlags;
|
||||
|
||||
#define GST_MIXER_TRACK_HAS_FLAG(channel, flag) \
|
||||
((channel)->flags & flag)
|
||||
|
||||
typedef struct _GstMixerTrack
|
||||
{
|
||||
GObject parent;
|
||||
typedef struct _GstMixerTrack {
|
||||
GObject parent;
|
||||
|
||||
gchar *label;
|
||||
gchar *label;
|
||||
GstMixerTrackFlags flags;
|
||||
gint num_channels, min_volume, max_volume;
|
||||
gint num_channels,
|
||||
min_volume,
|
||||
max_volume;
|
||||
} GstMixerTrack;
|
||||
|
||||
typedef struct _GstMixerTrackClass
|
||||
{
|
||||
typedef struct _GstMixerTrackClass {
|
||||
GObjectClass parent;
|
||||
|
||||
/* signals */
|
||||
void (*mute_toggled) (GstMixerTrack * channel, gboolean mute);
|
||||
void (*record_toggled) (GstMixerTrack * channel, gboolean record);
|
||||
void (*volume_changed) (GstMixerTrack * channel, gint * volumes);
|
||||
void (* mute_toggled) (GstMixerTrack *channel,
|
||||
gboolean mute);
|
||||
void (* record_toggled) (GstMixerTrack *channel,
|
||||
gboolean record);
|
||||
void (* volume_changed) (GstMixerTrack *channel,
|
||||
gint *volumes);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstMixerTrackClass;
|
||||
|
||||
GType gst_mixer_track_get_type (void);
|
||||
GType gst_mixer_track_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MIXER_TRACK_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_NAVIGATION \
|
||||
(gst_navigation_get_type ())
|
||||
#define GST_NAVIGATION(obj) \
|
||||
|
@ -34,28 +35,28 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_NAVIGATION))
|
||||
#define GST_NAVIGATION_GET_IFACE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_NAVIGATION, GstNavigationInterface))
|
||||
|
||||
typedef struct _GstNavigation GstNavigation;
|
||||
|
||||
typedef struct _GstNavigationInterface
|
||||
{
|
||||
typedef struct _GstNavigationInterface {
|
||||
GTypeInterface g_iface;
|
||||
|
||||
/* virtual functions */
|
||||
void (*send_event) (GstNavigation * navigation, GstStructure * structure);
|
||||
|
||||
void (*send_event) (GstNavigation *navigation, GstStructure *structure);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstNavigationInterface;
|
||||
|
||||
GType gst_navigation_get_type (void);
|
||||
GType gst_navigation_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
void gst_navigation_send_event (GstNavigation * navigation,
|
||||
GstStructure * structure);
|
||||
void gst_navigation_send_event (GstNavigation *navigation, GstStructure *structure);
|
||||
|
||||
void gst_navigation_send_key_event (GstNavigation * navigation,
|
||||
const char *event, const char *key);
|
||||
void gst_navigation_send_mouse_event (GstNavigation * navigation,
|
||||
const char *event, int button, double x, double y);
|
||||
void gst_navigation_send_key_event (GstNavigation *navigation,
|
||||
const char *event, const char *key);
|
||||
void gst_navigation_send_mouse_event (GstNavigation *navigation,
|
||||
const char *event, int button, double x, double y);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_NAVIGATION_H__ */
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __GST_PLAY_H__
|
||||
#define __GST_PLAY_H__
|
||||
|
||||
|
@ -46,43 +46,51 @@ typedef enum
|
|||
typedef struct _GstPlay GstPlay;
|
||||
typedef struct _GstPlayClass GstPlayClass;
|
||||
typedef struct _GstPlayPrivate GstPlayPrivate;
|
||||
|
||||
|
||||
struct _GstPlay
|
||||
{
|
||||
GstPipeline pipeline;
|
||||
|
||||
|
||||
GstPlayPrivate *priv;
|
||||
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
|
||||
struct _GstPlayClass
|
||||
{
|
||||
GstPipelineClass parent_class;
|
||||
|
||||
void (*time_tick) (GstPlay * play, gint64 time_nanos);
|
||||
void (*stream_length) (GstPlay * play, gint64 length_nanos);
|
||||
void (*have_video_size) (GstPlay * play, gint width, gint height);
|
||||
|
||||
|
||||
void (*time_tick) (GstPlay *play, gint64 time_nanos);
|
||||
void (*stream_length) (GstPlay *play, gint64 length_nanos);
|
||||
void (*have_video_size) (GstPlay *play, gint width, gint height);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
GType gst_play_get_type (void);
|
||||
GstPlay *gst_play_new (GError ** error);
|
||||
GType gst_play_get_type (void);
|
||||
GstPlay * gst_play_new (GError **error);
|
||||
|
||||
gboolean gst_play_set_data_src (GstPlay * play, GstElement * data_src);
|
||||
gboolean gst_play_set_video_sink (GstPlay * play, GstElement * video_sink);
|
||||
gboolean gst_play_set_audio_sink (GstPlay * play, GstElement * audio_sink);
|
||||
gboolean gst_play_set_data_src (GstPlay *play,
|
||||
GstElement *data_src);
|
||||
gboolean gst_play_set_video_sink (GstPlay *play,
|
||||
GstElement *video_sink);
|
||||
gboolean gst_play_set_audio_sink (GstPlay *play,
|
||||
GstElement *audio_sink);
|
||||
|
||||
gboolean gst_play_set_visualization (GstPlay * play, GstElement * element);
|
||||
gboolean gst_play_connect_visualization (GstPlay * play, gboolean connect);
|
||||
gboolean gst_play_set_visualization (GstPlay *play,
|
||||
GstElement *element);
|
||||
gboolean gst_play_connect_visualization (GstPlay *play,
|
||||
gboolean connect);
|
||||
|
||||
gboolean gst_play_set_location (GstPlay * play, const char *location);
|
||||
char *gst_play_get_location (GstPlay * play);
|
||||
gboolean gst_play_set_location (GstPlay *play,
|
||||
const char *location);
|
||||
char * gst_play_get_location (GstPlay *play);
|
||||
|
||||
gboolean gst_play_seek_to_time (GstPlay * play, gint64 time_nanos);
|
||||
gboolean gst_play_seek_to_time (GstPlay *play,
|
||||
gint64 time_nanos);
|
||||
|
||||
GstElement *gst_play_get_sink_element (GstPlay * play,
|
||||
GstElement * element, GstPlaySinkType sink_type);
|
||||
GstElement * gst_play_get_sink_element (GstPlay *play,
|
||||
GstElement *element,
|
||||
GstPlaySinkType sink_type);
|
||||
|
||||
#endif /* __GST_PLAY_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_PROPERTY_PROBE \
|
||||
(gst_property_probe_get_type ())
|
||||
#define GST_PROPERTY_PROBE(obj) \
|
||||
|
@ -33,59 +34,64 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_PROPERTY_PROBE))
|
||||
#define GST_PROPERTY_PROBE_GET_IFACE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_PROPERTY_PROBE, GstPropertyProbeInterface))
|
||||
typedef struct _GstPropertyProbe GstPropertyProbe; /* dummy typedef */
|
||||
|
||||
typedef struct _GstPropertyProbeInterface
|
||||
{
|
||||
typedef struct _GstPropertyProbe GstPropertyProbe; /* dummy typedef */
|
||||
|
||||
typedef struct _GstPropertyProbeInterface {
|
||||
GTypeInterface klass;
|
||||
|
||||
/* signals */
|
||||
void (*probe_needed) (GstPropertyProbe * probe, const GParamSpec * pspec);
|
||||
void (*probe_needed) (GstPropertyProbe *probe,
|
||||
const GParamSpec *pspec);
|
||||
|
||||
/* virtual functions */
|
||||
const GList *(*get_properties) (GstPropertyProbe * probe);
|
||||
gboolean (*needs_probe) (GstPropertyProbe * probe,
|
||||
guint prop_id, const GParamSpec * pspec);
|
||||
void (*probe_property) (GstPropertyProbe * probe,
|
||||
guint prop_id, const GParamSpec * pspec);
|
||||
GValueArray *(*get_values) (GstPropertyProbe * probe,
|
||||
guint prop_id, const GParamSpec * pspec);
|
||||
const GList * (*get_properties) (GstPropertyProbe *probe);
|
||||
gboolean (*needs_probe) (GstPropertyProbe *probe,
|
||||
guint prop_id,
|
||||
const GParamSpec *pspec);
|
||||
void (*probe_property) (GstPropertyProbe *probe,
|
||||
guint prop_id,
|
||||
const GParamSpec *pspec);
|
||||
GValueArray * (*get_values) (GstPropertyProbe *probe,
|
||||
guint prop_id,
|
||||
const GParamSpec *pspec);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstPropertyProbeInterface;
|
||||
|
||||
GType gst_property_probe_get_type (void);
|
||||
GType gst_property_probe_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
|
||||
/* returns list of GParamSpecs */
|
||||
const GList *gst_property_probe_get_properties (GstPropertyProbe * probe);
|
||||
const GParamSpec *gst_property_probe_get_property (GstPropertyProbe * probe,
|
||||
const gchar * name);
|
||||
const GList * gst_property_probe_get_properties (GstPropertyProbe *probe);
|
||||
const GParamSpec *gst_property_probe_get_property (GstPropertyProbe *probe,
|
||||
const gchar *name);
|
||||
|
||||
/* probe one property */
|
||||
void gst_property_probe_probe_property (GstPropertyProbe * probe,
|
||||
const GParamSpec * pspec);
|
||||
void gst_property_probe_probe_property_name (GstPropertyProbe * probe,
|
||||
const gchar * name);
|
||||
void gst_property_probe_probe_property (GstPropertyProbe *probe,
|
||||
const GParamSpec *pspec);
|
||||
void gst_property_probe_probe_property_name (GstPropertyProbe *probe,
|
||||
const gchar *name);
|
||||
|
||||
/* do we need a probe? */
|
||||
gboolean gst_property_probe_needs_probe (GstPropertyProbe * probe,
|
||||
const GParamSpec * pspec);
|
||||
gboolean gst_property_probe_needs_probe_name (GstPropertyProbe * probe,
|
||||
const gchar * name);
|
||||
gboolean gst_property_probe_needs_probe (GstPropertyProbe *probe,
|
||||
const GParamSpec *pspec);
|
||||
gboolean gst_property_probe_needs_probe_name (GstPropertyProbe *probe,
|
||||
const gchar *name);
|
||||
|
||||
/* returns list of GValues */
|
||||
GValueArray *gst_property_probe_get_values (GstPropertyProbe * probe,
|
||||
const GParamSpec * pspec);
|
||||
GValueArray *gst_property_probe_get_values_name (GstPropertyProbe * probe,
|
||||
const gchar * name);
|
||||
GValueArray * gst_property_probe_get_values (GstPropertyProbe *probe,
|
||||
const GParamSpec *pspec);
|
||||
GValueArray * gst_property_probe_get_values_name (GstPropertyProbe *probe,
|
||||
const gchar *name);
|
||||
|
||||
/* sugar */
|
||||
GValueArray *gst_property_probe_probe_and_get_values (GstPropertyProbe * probe,
|
||||
const GParamSpec * pspec);
|
||||
GValueArray *gst_property_probe_probe_and_get_values_name (GstPropertyProbe *
|
||||
probe, const gchar * name);
|
||||
GValueArray * gst_property_probe_probe_and_get_values (GstPropertyProbe *probe,
|
||||
const GParamSpec *pspec);
|
||||
GValueArray * gst_property_probe_probe_and_get_values_name (GstPropertyProbe *probe,
|
||||
const gchar *name);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PROPERTY_PROBE_H__ */
|
||||
|
|
|
@ -23,71 +23,68 @@
|
|||
|
||||
#include "resample.h"
|
||||
|
||||
void gst_resample_nearest_s16 (gst_resample_t * r);
|
||||
void gst_resample_bilinear_s16 (gst_resample_t * r);
|
||||
void gst_resample_sinc_s16 (gst_resample_t * r);
|
||||
void gst_resample_sinc_slow_s16 (gst_resample_t * r);
|
||||
void gst_resample_sinc_ft_s16 (gst_resample_t * r);
|
||||
void gst_resample_nearest_s16(gst_resample_t *r);
|
||||
void gst_resample_bilinear_s16(gst_resample_t *r);
|
||||
void gst_resample_sinc_s16(gst_resample_t *r);
|
||||
void gst_resample_sinc_slow_s16(gst_resample_t *r);
|
||||
void gst_resample_sinc_ft_s16(gst_resample_t * r);
|
||||
|
||||
void gst_resample_nearest_float (gst_resample_t * r);
|
||||
void gst_resample_bilinear_float (gst_resample_t * r);
|
||||
void gst_resample_sinc_float (gst_resample_t * r);
|
||||
void gst_resample_sinc_slow_float (gst_resample_t * r);
|
||||
void gst_resample_sinc_ft_float (gst_resample_t * r);
|
||||
void gst_resample_nearest_float(gst_resample_t *r);
|
||||
void gst_resample_bilinear_float(gst_resample_t *r);
|
||||
void gst_resample_sinc_float(gst_resample_t *r);
|
||||
void gst_resample_sinc_slow_float(gst_resample_t *r);
|
||||
void gst_resample_sinc_ft_float(gst_resample_t * r);
|
||||
|
||||
|
||||
typedef struct functable_s functable_t;
|
||||
struct functable_s
|
||||
{
|
||||
double start;
|
||||
double offset;
|
||||
int len;
|
||||
struct functable_s {
|
||||
double start;
|
||||
double offset;
|
||||
int len;
|
||||
|
||||
double invoffset;
|
||||
double invoffset;
|
||||
|
||||
double scale;
|
||||
double scale2;
|
||||
double scale;
|
||||
double scale2;
|
||||
|
||||
double (*func_x) (void *, double x);
|
||||
double (*func_dx) (void *, double x);
|
||||
double (*func_x)(void *,double x);
|
||||
double (*func_dx)(void *,double x);
|
||||
|
||||
double (*func2_x) (void *, double x);
|
||||
double (*func2_dx) (void *, double x);
|
||||
double (*func2_x)(void *,double x);
|
||||
double (*func2_dx)(void *,double x);
|
||||
|
||||
double *fx;
|
||||
double *fdx;
|
||||
double *fx;
|
||||
double *fdx;
|
||||
|
||||
void *priv;
|
||||
void *priv;
|
||||
};
|
||||
|
||||
void functable_init (functable_t * t);
|
||||
double functable_eval (functable_t * t, double x);
|
||||
void functable_init(functable_t *t);
|
||||
double functable_eval(functable_t *t,double x);
|
||||
|
||||
double functable_fir (functable_t * t, double x0, int n, double *data, int len);
|
||||
void functable_fir2 (functable_t * t, double *r0, double *r1, double x0,
|
||||
int n, double *data, int len);
|
||||
double functable_fir(functable_t *t,double x0,int n,double *data,int len);
|
||||
void functable_fir2(functable_t *t,double *r0, double *r1, double x0,
|
||||
int n,double *data,int len);
|
||||
|
||||
double functable_sinc (void *p, double x);
|
||||
double functable_dsinc (void *p, double x);
|
||||
double functable_window_std (void *p, double x);
|
||||
double functable_window_dstd (void *p, double x);
|
||||
double functable_window_boxcar (void *p, double x);
|
||||
double functable_window_dboxcar (void *p, double x);
|
||||
double functable_sinc(void *p, double x);
|
||||
double functable_dsinc(void *p, double x);
|
||||
double functable_window_std(void *p, double x);
|
||||
double functable_window_dstd(void *p, double x);
|
||||
double functable_window_boxcar(void *p, double x);
|
||||
double functable_window_dboxcar(void *p, double x);
|
||||
|
||||
/* math lib stuff */
|
||||
|
||||
void conv_double_short_table (double *dest, short *src, int n);
|
||||
void conv_double_short_unroll (double *dest, short *src, int n);
|
||||
void conv_double_short_ref (double *dest, short *src, int n);
|
||||
|
||||
void conv_double_short_table(double *dest, short *src, int n);
|
||||
void conv_double_short_unroll(double *dest, short *src, int n);
|
||||
void conv_double_short_ref(double *dest, short *src, int n);
|
||||
#ifdef HAVE_CPU_PPC
|
||||
void conv_double_short_altivec (double *dest, short *src, int n);
|
||||
void conv_double_short_altivec(double *dest, short *src, int n);
|
||||
#endif
|
||||
|
||||
void conv_short_double_ref (short *dest, double *src, int n);
|
||||
|
||||
void conv_short_double_ref(short *dest, double *src, int n);
|
||||
#ifdef HAVE_CPU_PPC
|
||||
void conv_short_double_ppcasm (short *dest, double *src, int n);
|
||||
void conv_short_double_ppcasm(short *dest, double *src, int n);
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_CPU_PPC
|
||||
|
@ -101,12 +98,12 @@ void conv_short_double_ppcasm (short *dest, double *src, int n);
|
|||
#define conv_double_float conv_double_float_ref
|
||||
#define conv_float_double conv_float_double_ref
|
||||
|
||||
void conv_double_short_dstr (double *dest, short *src, int n, int dstr);
|
||||
void conv_short_double_sstr (short *dest, double *src, int n, int dstr);
|
||||
void conv_double_short_dstr(double *dest, short *src, int n, int dstr);
|
||||
void conv_short_double_sstr(short *dest, double *src, int n, int dstr);
|
||||
|
||||
void conv_double_float_ref (double *dest, float *src, int n);
|
||||
void conv_float_double_ref (float *dest, double *src, int n);
|
||||
void conv_double_float_dstr (double *dest, float *src, int n, int dstr);
|
||||
void conv_float_double_sstr (float *dest, double *src, int n, int sstr);
|
||||
void conv_double_float_ref(double *dest, float *src, int n);
|
||||
void conv_float_double_ref(float *dest, double *src, int n);
|
||||
void conv_double_float_dstr(double *dest, float *src, int n, int dstr);
|
||||
void conv_float_double_sstr(float *dest, double *src, int n, int sstr);
|
||||
|
||||
#endif /* __PRIVATE_H__ */
|
||||
|
|
|
@ -21,78 +21,76 @@
|
|||
#ifndef __GST_RESAMPLE_H__
|
||||
#define __GST_RESAMPLE_H__
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_RESAMPLE_NEAREST = 0,
|
||||
GST_RESAMPLE_BILINEAR,
|
||||
GST_RESAMPLE_SINC_SLOW,
|
||||
GST_RESAMPLE_SINC,
|
||||
typedef enum {
|
||||
GST_RESAMPLE_NEAREST = 0,
|
||||
GST_RESAMPLE_BILINEAR,
|
||||
GST_RESAMPLE_SINC_SLOW,
|
||||
GST_RESAMPLE_SINC,
|
||||
} gst_resample_method;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_RESAMPLE_S16 = 0,
|
||||
GST_RESAMPLE_FLOAT
|
||||
typedef enum {
|
||||
GST_RESAMPLE_S16 = 0,
|
||||
GST_RESAMPLE_FLOAT
|
||||
} gst_resample_format;
|
||||
|
||||
typedef struct gst_resample_s gst_resample_t;
|
||||
|
||||
struct gst_resample_s
|
||||
{
|
||||
/* parameters */
|
||||
struct gst_resample_s {
|
||||
/* parameters */
|
||||
|
||||
gst_resample_method method;
|
||||
int channels;
|
||||
int verbose;
|
||||
gst_resample_format format;
|
||||
gst_resample_method method;
|
||||
int channels;
|
||||
int verbose;
|
||||
gst_resample_format format;
|
||||
|
||||
int filter_length;
|
||||
int filter_length;
|
||||
|
||||
double i_rate;
|
||||
double o_rate;
|
||||
double i_rate;
|
||||
double o_rate;
|
||||
|
||||
void *priv;
|
||||
void *priv;
|
||||
|
||||
void *(*get_buffer) (void *priv, unsigned int size);
|
||||
void *(*get_buffer)(void *priv, unsigned int size);
|
||||
|
||||
/* internal parameters */
|
||||
/* internal parameters */
|
||||
|
||||
double halftaps;
|
||||
double halftaps;
|
||||
|
||||
/* filter state */
|
||||
/* filter state */
|
||||
|
||||
void *buffer;
|
||||
int buffer_len;
|
||||
void *buffer;
|
||||
int buffer_len;
|
||||
|
||||
double i_start;
|
||||
double o_start;
|
||||
double i_start;
|
||||
double o_start;
|
||||
|
||||
double i_start_buf;
|
||||
double i_end_buf;
|
||||
double i_start_buf;
|
||||
double i_end_buf;
|
||||
|
||||
double i_inc;
|
||||
double o_inc;
|
||||
double i_inc;
|
||||
double o_inc;
|
||||
|
||||
double i_end;
|
||||
double o_end;
|
||||
double i_end;
|
||||
double o_end;
|
||||
|
||||
int i_samples;
|
||||
int o_samples;
|
||||
int i_samples;
|
||||
int o_samples;
|
||||
|
||||
void *i_buf, *o_buf;
|
||||
void *i_buf, *o_buf;
|
||||
|
||||
double acc[10];
|
||||
double acc[10];
|
||||
|
||||
/* methods */
|
||||
void (*scale) (gst_resample_t * r);
|
||||
/* methods */
|
||||
void (*scale)(gst_resample_t *r);
|
||||
|
||||
double ack;
|
||||
double ack;
|
||||
};
|
||||
|
||||
void gst_resample_init (gst_resample_t * r);
|
||||
void gst_resample_init(gst_resample_t *r);
|
||||
|
||||
void gst_resample_reinit (gst_resample_t * r);
|
||||
void gst_resample_reinit(gst_resample_t *r);
|
||||
|
||||
void gst_resample_scale (gst_resample_t * r, void *i_buf, unsigned int size);
|
||||
void gst_resample_scale(gst_resample_t *r, void *i_buf, unsigned int size);
|
||||
|
||||
#endif /* __GST_RESAMPLE_H__ */
|
||||
|
||||
|
|
|
@ -66,29 +66,29 @@
|
|||
#define GST_RIFF_FCCH_MSVC GST_MAKE_FOURCC ('M','S','V','C')
|
||||
|
||||
/* INFO types - see http://www.saettler.com/RIFFMCI/riffmci.html */
|
||||
#define GST_RIFF_INFO_IARL GST_MAKE_FOURCC ('I','A','R','L') /* location */
|
||||
#define GST_RIFF_INFO_IART GST_MAKE_FOURCC ('I','A','R','T') /* artist */
|
||||
#define GST_RIFF_INFO_ICMS GST_MAKE_FOURCC ('I','C','M','S') /* commissioned */
|
||||
#define GST_RIFF_INFO_ICMT GST_MAKE_FOURCC ('I','C','M','T') /* comment */
|
||||
#define GST_RIFF_INFO_ICOP GST_MAKE_FOURCC ('I','C','O','P') /* copyright */
|
||||
#define GST_RIFF_INFO_ICRD GST_MAKE_FOURCC ('I','C','R','D') /* creation date */
|
||||
#define GST_RIFF_INFO_ICRP GST_MAKE_FOURCC ('I','C','R','P') /* cropped */
|
||||
#define GST_RIFF_INFO_IDIM GST_MAKE_FOURCC ('I','D','I','M') /* dimensions */
|
||||
#define GST_RIFF_INFO_IDPI GST_MAKE_FOURCC ('I','D','P','I') /* dots-per-inch */
|
||||
#define GST_RIFF_INFO_IENG GST_MAKE_FOURCC ('I','E','N','G') /* engineer(s) */
|
||||
#define GST_RIFF_INFO_IGNR GST_MAKE_FOURCC ('I','G','N','R') /* genre */
|
||||
#define GST_RIFF_INFO_IKEY GST_MAKE_FOURCC ('I','K','E','Y') /* keywords */
|
||||
#define GST_RIFF_INFO_ILGT GST_MAKE_FOURCC ('I','L','G','T') /* lightness */
|
||||
#define GST_RIFF_INFO_IMED GST_MAKE_FOURCC ('I','M','E','D') /* medium */
|
||||
#define GST_RIFF_INFO_INAM GST_MAKE_FOURCC ('I','N','A','M') /* name */
|
||||
#define GST_RIFF_INFO_IPLT GST_MAKE_FOURCC ('I','P','L','T') /* palette setting */
|
||||
#define GST_RIFF_INFO_IPRD GST_MAKE_FOURCC ('I','P','R','D') /* product */
|
||||
#define GST_RIFF_INFO_ISBJ GST_MAKE_FOURCC ('I','S','B','J') /* subject */
|
||||
#define GST_RIFF_INFO_ISFT GST_MAKE_FOURCC ('I','S','F','T') /* software */
|
||||
#define GST_RIFF_INFO_ISHP GST_MAKE_FOURCC ('I','S','H','P') /* sharpness */
|
||||
#define GST_RIFF_INFO_ISRC GST_MAKE_FOURCC ('I','S','R','C') /* source */
|
||||
#define GST_RIFF_INFO_ISRF GST_MAKE_FOURCC ('I','S','R','F') /* source form */
|
||||
#define GST_RIFF_INFO_ITCH GST_MAKE_FOURCC ('I','T','C','H') /* technician(s) */
|
||||
#define GST_RIFF_INFO_IARL GST_MAKE_FOURCC ('I','A','R','L') /* location */
|
||||
#define GST_RIFF_INFO_IART GST_MAKE_FOURCC ('I','A','R','T') /* artist */
|
||||
#define GST_RIFF_INFO_ICMS GST_MAKE_FOURCC ('I','C','M','S') /* commissioned */
|
||||
#define GST_RIFF_INFO_ICMT GST_MAKE_FOURCC ('I','C','M','T') /* comment */
|
||||
#define GST_RIFF_INFO_ICOP GST_MAKE_FOURCC ('I','C','O','P') /* copyright */
|
||||
#define GST_RIFF_INFO_ICRD GST_MAKE_FOURCC ('I','C','R','D') /* creation date */
|
||||
#define GST_RIFF_INFO_ICRP GST_MAKE_FOURCC ('I','C','R','P') /* cropped */
|
||||
#define GST_RIFF_INFO_IDIM GST_MAKE_FOURCC ('I','D','I','M') /* dimensions */
|
||||
#define GST_RIFF_INFO_IDPI GST_MAKE_FOURCC ('I','D','P','I') /* dots-per-inch */
|
||||
#define GST_RIFF_INFO_IENG GST_MAKE_FOURCC ('I','E','N','G') /* engineer(s) */
|
||||
#define GST_RIFF_INFO_IGNR GST_MAKE_FOURCC ('I','G','N','R') /* genre */
|
||||
#define GST_RIFF_INFO_IKEY GST_MAKE_FOURCC ('I','K','E','Y') /* keywords */
|
||||
#define GST_RIFF_INFO_ILGT GST_MAKE_FOURCC ('I','L','G','T') /* lightness */
|
||||
#define GST_RIFF_INFO_IMED GST_MAKE_FOURCC ('I','M','E','D') /* medium */
|
||||
#define GST_RIFF_INFO_INAM GST_MAKE_FOURCC ('I','N','A','M') /* name */
|
||||
#define GST_RIFF_INFO_IPLT GST_MAKE_FOURCC ('I','P','L','T') /* palette setting */
|
||||
#define GST_RIFF_INFO_IPRD GST_MAKE_FOURCC ('I','P','R','D') /* product */
|
||||
#define GST_RIFF_INFO_ISBJ GST_MAKE_FOURCC ('I','S','B','J') /* subject */
|
||||
#define GST_RIFF_INFO_ISFT GST_MAKE_FOURCC ('I','S','F','T') /* software */
|
||||
#define GST_RIFF_INFO_ISHP GST_MAKE_FOURCC ('I','S','H','P') /* sharpness */
|
||||
#define GST_RIFF_INFO_ISRC GST_MAKE_FOURCC ('I','S','R','C') /* source */
|
||||
#define GST_RIFF_INFO_ISRF GST_MAKE_FOURCC ('I','S','R','F') /* source form */
|
||||
#define GST_RIFF_INFO_ITCH GST_MAKE_FOURCC ('I','T','C','H') /* technician(s) */
|
||||
|
||||
/*********Chunk Names***************/
|
||||
#define GST_RIFF_FF00 GST_MAKE_FOURCC (0xFF,0xFF,0x00,0x00)
|
||||
|
@ -167,7 +167,7 @@
|
|||
#define GST_RIFF_v422 GST_MAKE_FOURCC ('v', '4', '2', '2')
|
||||
#define GST_RIFF_V422 GST_MAKE_FOURCC ('V', '4', '2', '2')
|
||||
#define GST_RIFF_mvi1 GST_MAKE_FOURCC ('m', 'v', 'i', '1')
|
||||
#define GST_RIFF_MPIX GST_MAKE_FOURCC (0x04,0x00, 'i', '1') /* MotionPixels munged their id */
|
||||
#define GST_RIFF_MPIX GST_MAKE_FOURCC (0x04,0x00, 'i', '1') /* MotionPixels munged their id */
|
||||
#define GST_RIFF_AURA GST_MAKE_FOURCC ('A', 'U', 'R', 'A')
|
||||
#define GST_RIFF_DMB1 GST_MAKE_FOURCC ('D', 'M', 'B', '1')
|
||||
#define GST_RIFF_dmb1 GST_MAKE_FOURCC ('d', 'm', 'b', '1')
|
||||
|
@ -203,7 +203,7 @@
|
|||
|
||||
#define GST_RIFF_rpza GST_MAKE_FOURCC ('r', 'p', 'z', 'a')
|
||||
/* And this here's the mistakes that need to be supported */
|
||||
#define GST_RIFF_azpr GST_MAKE_FOURCC ('a', 'z', 'p', 'r') /* recognize Apple's rpza mangled? */
|
||||
#define GST_RIFF_azpr GST_MAKE_FOURCC ('a', 'z', 'p', 'r') /* recognize Apple's rpza mangled? */
|
||||
|
||||
/*********** FND in MJPG **********/
|
||||
#define GST_RIFF_ISFT GST_MAKE_FOURCC ('I', 'S', 'F', 'T')
|
||||
|
@ -216,28 +216,26 @@
|
|||
#define GST_RIFF_rec GST_MAKE_FOURCC ('r', 'e', 'c', ' ')
|
||||
|
||||
/* common data structures */
|
||||
typedef struct _gst_riff_strh
|
||||
{
|
||||
guint32 type; /* stream type */
|
||||
guint32 fcc_handler; /* fcc_handler */
|
||||
typedef struct _gst_riff_strh {
|
||||
guint32 type; /* stream type */
|
||||
guint32 fcc_handler; /* fcc_handler */
|
||||
guint32 flags;
|
||||
/* flags values */
|
||||
#define GST_RIFF_STRH_DISABLED 0x000000001
|
||||
#define GST_RIFF_STRH_VIDEOPALCHANGES 0x000010000
|
||||
guint32 priority;
|
||||
guint32 init_frames; /* initial frames (???) */
|
||||
guint32 init_frames; /* initial frames (???) */
|
||||
guint32 scale;
|
||||
guint32 rate;
|
||||
guint32 start;
|
||||
guint32 length;
|
||||
guint32 bufsize; /* suggested buffer size */
|
||||
guint32 bufsize; /* suggested buffer size */
|
||||
guint32 quality;
|
||||
guint32 samplesize;
|
||||
/* XXX 16 bytes ? */
|
||||
} gst_riff_strh;
|
||||
|
||||
typedef struct _gst_riff_strf_vids
|
||||
{ /* == BitMapInfoHeader */
|
||||
typedef struct _gst_riff_strf_vids { /* == BitMapInfoHeader */
|
||||
guint32 size;
|
||||
guint32 width;
|
||||
guint32 height;
|
||||
|
@ -247,14 +245,13 @@ typedef struct _gst_riff_strf_vids
|
|||
guint32 image_size;
|
||||
guint32 xpels_meter;
|
||||
guint32 ypels_meter;
|
||||
guint32 num_colors; /* used colors */
|
||||
guint32 imp_colors; /* important colors */
|
||||
guint32 num_colors; /* used colors */
|
||||
guint32 imp_colors; /* important colors */
|
||||
/* may be more for some codecs */
|
||||
} gst_riff_strf_vids;
|
||||
|
||||
|
||||
typedef struct _gst_riff_strf_auds
|
||||
{ /* == WaveHeader (?) */
|
||||
typedef struct _gst_riff_strf_auds { /* == WaveHeader (?) */
|
||||
guint16 format;
|
||||
/**** from public Microsoft RIFF docs ******/
|
||||
#define GST_RIFF_WAVE_FORMAT_UNKNOWN (0x0000)
|
||||
|
@ -293,8 +290,7 @@ typedef struct _gst_riff_strf_auds
|
|||
guint16 size;
|
||||
} gst_riff_strf_auds;
|
||||
|
||||
typedef struct _gst_riff_strf_iavs
|
||||
{
|
||||
typedef struct _gst_riff_strf_iavs {
|
||||
guint32 DVAAuxSrc;
|
||||
guint32 DVAAuxCtl;
|
||||
guint32 DVAAuxSrc1;
|
||||
|
@ -305,8 +301,7 @@ typedef struct _gst_riff_strf_iavs
|
|||
guint32 DVReserved2;
|
||||
} gst_riff_strf_iavs;
|
||||
|
||||
typedef struct _gst_riff_index_entry
|
||||
{
|
||||
typedef struct _gst_riff_index_entry {
|
||||
guint32 id;
|
||||
guint32 flags;
|
||||
#define GST_RIFF_IF_LIST (0x00000001L)
|
||||
|
@ -317,8 +312,7 @@ typedef struct _gst_riff_index_entry
|
|||
guint32 size;
|
||||
} gst_riff_index_entry;
|
||||
|
||||
typedef struct _gst_riff_dmlh
|
||||
{
|
||||
typedef struct _gst_riff_dmlh {
|
||||
guint32 totalframes;
|
||||
} gst_riff_dmlh;
|
||||
|
||||
|
|
|
@ -27,15 +27,23 @@
|
|||
#include "riff-ids.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/*
|
||||
* Create one caps. strh/strf can be NULL (for non-fixed caps).
|
||||
*/
|
||||
GstCaps * gst_riff_create_video_caps (guint32 codec_fcc,
|
||||
gst_riff_strh * strh, gst_riff_strf_vids * strf, char **codec_name);
|
||||
GstCaps *gst_riff_create_audio_caps (guint16 codec_id,
|
||||
gst_riff_strh * strh, gst_riff_strf_auds * strf, char **codec_name);
|
||||
GstCaps *gst_riff_create_iavs_caps (guint32 codec_fcc,
|
||||
gst_riff_strh * strh, gst_riff_strf_iavs * strf, char **codec_name);
|
||||
|
||||
GstCaps *gst_riff_create_video_caps (guint32 codec_fcc,
|
||||
gst_riff_strh *strh,
|
||||
gst_riff_strf_vids *strf,
|
||||
char **codec_name);
|
||||
GstCaps *gst_riff_create_audio_caps (guint16 codec_id,
|
||||
gst_riff_strh *strh,
|
||||
gst_riff_strf_auds *strf,
|
||||
char **codec_name);
|
||||
GstCaps *gst_riff_create_iavs_caps (guint32 codec_fcc,
|
||||
gst_riff_strh *strh,
|
||||
gst_riff_strf_iavs *strf,
|
||||
char **codec_name);
|
||||
|
||||
/*
|
||||
* Create template caps (includes all known types).
|
||||
|
@ -43,7 +51,8 @@ GstCaps *gst_riff_create_iavs_caps (guint32 codec_fcc,
|
|||
|
||||
GstCaps *gst_riff_create_video_template_caps (void);
|
||||
GstCaps *gst_riff_create_audio_template_caps (void);
|
||||
GstCaps *gst_riff_create_iavs_template_caps (void);
|
||||
GstCaps *gst_riff_create_iavs_template_caps (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_RIFF_READ_H__ */
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/bytestream/bytestream.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_RIFF_READ \
|
||||
(gst_riff_read_get_type ())
|
||||
#define GST_RIFF_READ(obj) \
|
||||
|
@ -39,13 +40,13 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_RIFF_READ))
|
||||
#define GST_RIFF_READ_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_RIFF_READ, GstRiffReadClass))
|
||||
typedef struct _GstRiffLevel
|
||||
{
|
||||
guint64 start, length;
|
||||
|
||||
typedef struct _GstRiffLevel {
|
||||
guint64 start,
|
||||
length;
|
||||
} GstRiffLevel;
|
||||
|
||||
typedef struct _GstRiffRead
|
||||
{
|
||||
typedef struct _GstRiffRead {
|
||||
GstElement parent;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -54,35 +55,43 @@ typedef struct _GstRiffRead
|
|||
GList *level;
|
||||
} GstRiffRead;
|
||||
|
||||
typedef struct _GstRiffReadClass
|
||||
{
|
||||
typedef struct _GstRiffReadClass {
|
||||
GstElementClass parent;
|
||||
} GstRiffReadClass;
|
||||
|
||||
GType gst_riff_read_get_type (void);
|
||||
GType gst_riff_read_get_type (void);
|
||||
|
||||
guint32 gst_riff_peek_tag (GstRiffRead * riff, guint * level_up);
|
||||
guint32 gst_riff_peek_list (GstRiffRead * riff);
|
||||
guint32 gst_riff_peek_tag (GstRiffRead *riff,
|
||||
guint *level_up);
|
||||
guint32 gst_riff_peek_list (GstRiffRead *riff);
|
||||
|
||||
GstEvent *gst_riff_read_seek (GstRiffRead * riff, guint64 offset);
|
||||
gboolean gst_riff_read_skip (GstRiffRead * riff);
|
||||
gboolean gst_riff_read_data (GstRiffRead * riff,
|
||||
guint32 * tag, GstBuffer ** buf);
|
||||
gboolean gst_riff_read_ascii (GstRiffRead * riff, guint32 * tag, gchar ** str);
|
||||
gboolean gst_riff_read_list (GstRiffRead * riff, guint32 * tag);
|
||||
gboolean gst_riff_read_header (GstRiffRead * read, guint32 * doctype);
|
||||
GstEvent *gst_riff_read_seek (GstRiffRead *riff,
|
||||
guint64 offset);
|
||||
gboolean gst_riff_read_skip (GstRiffRead *riff);
|
||||
gboolean gst_riff_read_data (GstRiffRead *riff,
|
||||
guint32 *tag,
|
||||
GstBuffer **buf);
|
||||
gboolean gst_riff_read_ascii (GstRiffRead *riff,
|
||||
guint32 *tag,
|
||||
gchar **str);
|
||||
gboolean gst_riff_read_list (GstRiffRead *riff,
|
||||
guint32 *tag);
|
||||
gboolean gst_riff_read_header (GstRiffRead *read,
|
||||
guint32 *doctype);
|
||||
|
||||
/*
|
||||
* Utility functions (including byteswapping).
|
||||
*/
|
||||
gboolean gst_riff_read_strh (GstRiffRead * riff, gst_riff_strh ** header);
|
||||
gboolean gst_riff_read_strf_vids (GstRiffRead * riff,
|
||||
gst_riff_strf_vids ** header);
|
||||
gboolean gst_riff_read_strf_auds (GstRiffRead * riff,
|
||||
gst_riff_strf_auds ** header);
|
||||
gboolean gst_riff_read_strf_iavs (GstRiffRead * riff,
|
||||
gst_riff_strf_iavs ** header);
|
||||
gboolean gst_riff_read_info (GstRiffRead * riff);
|
||||
gboolean gst_riff_read_strh (GstRiffRead *riff,
|
||||
gst_riff_strh **header);
|
||||
gboolean gst_riff_read_strf_vids (GstRiffRead *riff,
|
||||
gst_riff_strf_vids **header);
|
||||
gboolean gst_riff_read_strf_auds (GstRiffRead *riff,
|
||||
gst_riff_strf_auds **header);
|
||||
gboolean gst_riff_read_strf_iavs (GstRiffRead *riff,
|
||||
gst_riff_strf_iavs **header);
|
||||
gboolean gst_riff_read_info (GstRiffRead *riff);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_RIFF_READ_H__ */
|
||||
|
|
|
@ -24,30 +24,39 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
/* functions for vorbis comment manipulation */
|
||||
G_CONST_RETURN gchar * gst_tag_from_vorbis_tag (const gchar * vorbis_tag);
|
||||
G_CONST_RETURN gchar *gst_tag_to_vorbis_tag (const gchar * gst_tag);
|
||||
void gst_vorbis_tag_add (GstTagList * list,
|
||||
const gchar * tag, const gchar * value);
|
||||
|
||||
GList *gst_tag_to_vorbis_comments (const GstTagList * list, const gchar * tag);
|
||||
|
||||
/* functions for vorbis comment manipulation */
|
||||
|
||||
G_CONST_RETURN gchar * gst_tag_from_vorbis_tag (const gchar * vorbis_tag);
|
||||
G_CONST_RETURN gchar * gst_tag_to_vorbis_tag (const gchar * gst_tag);
|
||||
void gst_vorbis_tag_add (GstTagList * list,
|
||||
const gchar * tag,
|
||||
const gchar * value);
|
||||
|
||||
GList * gst_tag_to_vorbis_comments (const GstTagList * list,
|
||||
const gchar * tag);
|
||||
|
||||
/* functions to convert GstBuffers with vorbiscomment contents to GstTagLists and back */
|
||||
GstTagList *gst_tag_list_from_vorbiscomment_buffer (const GstBuffer * buffer,
|
||||
const guint8 * id_data, const guint id_data_length, gchar ** vendor_string);
|
||||
GstBuffer *gst_tag_list_to_vorbiscomment_buffer (const GstTagList * list,
|
||||
const guint8 * id_data,
|
||||
const guint id_data_length, const gchar * vendor_string);
|
||||
GstTagList * gst_tag_list_from_vorbiscomment_buffer (const GstBuffer * buffer,
|
||||
const guint8 * id_data,
|
||||
const guint id_data_length,
|
||||
gchar ** vendor_string);
|
||||
GstBuffer * gst_tag_list_to_vorbiscomment_buffer (const GstTagList * list,
|
||||
const guint8 * id_data,
|
||||
const guint id_data_length,
|
||||
const gchar * vendor_string);
|
||||
|
||||
/* functions for ID3 tag manipulation */
|
||||
|
||||
guint gst_tag_id3_genre_count (void);
|
||||
G_CONST_RETURN gchar *gst_tag_id3_genre_get (const guint id);
|
||||
GstTagList *gst_tag_list_new_from_id3v1 (const guint8 * data);
|
||||
guint gst_tag_id3_genre_count (void);
|
||||
G_CONST_RETURN gchar * gst_tag_id3_genre_get (const guint id);
|
||||
GstTagList * gst_tag_list_new_from_id3v1 (const guint8 * data);
|
||||
|
||||
G_CONST_RETURN gchar *gst_tag_from_id3_tag (const gchar * vorbis_tag);
|
||||
G_CONST_RETURN gchar *gst_tag_to_id3_tag (const gchar * gst_tag);
|
||||
G_CONST_RETURN gchar * gst_tag_from_id3_tag (const gchar * vorbis_tag);
|
||||
G_CONST_RETURN gchar * gst_tag_to_id3_tag (const gchar * gst_tag);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TAG_TAG_H__ */
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include <gst/tuner/tuner-enumtypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TUNER \
|
||||
(gst_tuner_get_type ())
|
||||
#define GST_TUNER(obj) \
|
||||
|
@ -40,65 +41,87 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TUNER))
|
||||
#define GST_TUNER_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_TUNER, GstTunerClass))
|
||||
|
||||
typedef struct _GstTuner GstTuner;
|
||||
|
||||
typedef struct _GstTunerClass
|
||||
{
|
||||
typedef struct _GstTunerClass {
|
||||
GTypeInterface klass;
|
||||
|
||||
/* virtual functions */
|
||||
const GList *(*list_channels) (GstTuner * tuner);
|
||||
void (*set_channel) (GstTuner * tuner, GstTunerChannel * channel);
|
||||
GstTunerChannel *(*get_channel) (GstTuner * tuner);
|
||||
const GList * (* list_channels) (GstTuner *tuner);
|
||||
void (* set_channel) (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
GstTunerChannel *
|
||||
(* get_channel) (GstTuner *tuner);
|
||||
|
||||
const GList *(*list_norms) (GstTuner * tuner);
|
||||
void (*set_norm) (GstTuner * tuner, GstTunerNorm * norm);
|
||||
GstTunerNorm *(*get_norm) (GstTuner * tuner);
|
||||
const GList * (* list_norms) (GstTuner *tuner);
|
||||
void (* set_norm) (GstTuner *tuner,
|
||||
GstTunerNorm *norm);
|
||||
GstTunerNorm *(* get_norm) (GstTuner *tuner);
|
||||
|
||||
void (*set_frequency) (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gulong frequency);
|
||||
gulong (*get_frequency) (GstTuner * tuner, GstTunerChannel * channel);
|
||||
gint (*signal_strength) (GstTuner * tuner, GstTunerChannel * channel);
|
||||
void (* set_frequency) (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gulong frequency);
|
||||
gulong (* get_frequency) (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
gint (* signal_strength) (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
|
||||
/* signals */
|
||||
void (*channel_changed) (GstTuner * tuner, GstTunerChannel * channel);
|
||||
void (*norm_changed) (GstTuner * tuner, GstTunerNorm * norm);
|
||||
void (*frequency_changed) (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gulong frequency);
|
||||
void (*signal_changed) (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gint signal);
|
||||
void (*channel_changed) (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
void (*norm_changed) (GstTuner *tuner,
|
||||
GstTunerNorm *norm);
|
||||
void (*frequency_changed) (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gulong frequency);
|
||||
void (*signal_changed) (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gint signal);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstTunerClass;
|
||||
|
||||
GType gst_tuner_get_type (void);
|
||||
GType gst_tuner_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
const GList *gst_tuner_list_channels (GstTuner * tuner);
|
||||
void gst_tuner_set_channel (GstTuner * tuner, GstTunerChannel * channel);
|
||||
GstTunerChannel *gst_tuner_get_channel (GstTuner * tuner);
|
||||
const GList * gst_tuner_list_channels (GstTuner *tuner);
|
||||
void gst_tuner_set_channel (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
GstTunerChannel *
|
||||
gst_tuner_get_channel (GstTuner *tuner);
|
||||
|
||||
const GList *gst_tuner_list_norms (GstTuner * tuner);
|
||||
void gst_tuner_set_norm (GstTuner * tuner, GstTunerNorm * channel);
|
||||
GstTunerNorm *gst_tuner_get_norm (GstTuner * tuner);
|
||||
const GList * gst_tuner_list_norms (GstTuner *tuner);
|
||||
void gst_tuner_set_norm (GstTuner *tuner,
|
||||
GstTunerNorm *channel);
|
||||
GstTunerNorm * gst_tuner_get_norm (GstTuner *tuner);
|
||||
|
||||
void gst_tuner_set_frequency (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gulong frequency);
|
||||
gulong gst_tuner_get_frequency (GstTuner * tuner, GstTunerChannel * channel);
|
||||
gint gst_tuner_signal_strength (GstTuner * tuner, GstTunerChannel * channel);
|
||||
void gst_tuner_set_frequency (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gulong frequency);
|
||||
gulong gst_tuner_get_frequency (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
gint gst_tuner_signal_strength (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
|
||||
/* helper functions */
|
||||
GstTunerNorm *gst_tuner_find_norm_by_name (GstTuner * tuner, gchar * norm);
|
||||
GstTunerChannel *gst_tuner_find_channel_by_name (GstTuner * tuner,
|
||||
gchar * channel);
|
||||
GstTunerNorm * gst_tuner_find_norm_by_name (GstTuner *tuner,
|
||||
gchar *norm);
|
||||
GstTunerChannel *gst_tuner_find_channel_by_name (GstTuner *tuner,
|
||||
gchar *channel);
|
||||
|
||||
/* trigger signals */
|
||||
void gst_tuner_channel_changed (GstTuner * tuner, GstTunerChannel * channel);
|
||||
void gst_tuner_norm_changed (GstTuner * tuner, GstTunerNorm * norm);
|
||||
void gst_tuner_frequency_changed (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gulong frequency);
|
||||
void gst_tuner_signal_changed (GstTuner * tuner,
|
||||
GstTunerChannel * channel, gint signal);
|
||||
void gst_tuner_channel_changed (GstTuner *tuner,
|
||||
GstTunerChannel *channel);
|
||||
void gst_tuner_norm_changed (GstTuner *tuner,
|
||||
GstTunerNorm *norm);
|
||||
void gst_tuner_frequency_changed (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gulong frequency);
|
||||
void gst_tuner_signal_changed (GstTuner *tuner,
|
||||
GstTunerChannel *channel,
|
||||
gint signal);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TUNER_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TUNER_CHANNEL \
|
||||
(gst_tuner_channel_get_type ())
|
||||
#define GST_TUNER_CHANNEL(obj) \
|
||||
|
@ -37,39 +38,42 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TUNER_CHANNEL))
|
||||
#define GST_IS_TUNER_CHANNEL_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TUNER_CHANNEL))
|
||||
typedef enum
|
||||
{
|
||||
GST_TUNER_CHANNEL_INPUT = (1 << 0),
|
||||
GST_TUNER_CHANNEL_OUTPUT = (1 << 1),
|
||||
GST_TUNER_CHANNEL_FREQUENCY = (1 << 2),
|
||||
GST_TUNER_CHANNEL_AUDIO = (1 << 3),
|
||||
|
||||
typedef enum {
|
||||
GST_TUNER_CHANNEL_INPUT = (1<<0),
|
||||
GST_TUNER_CHANNEL_OUTPUT = (1<<1),
|
||||
GST_TUNER_CHANNEL_FREQUENCY = (1<<2),
|
||||
GST_TUNER_CHANNEL_AUDIO = (1<<3),
|
||||
} GstTunerChannelFlags;
|
||||
|
||||
#define GST_TUNER_CHANNEL_HAS_FLAG(channel, flag) \
|
||||
((channel)->flags & flag)
|
||||
|
||||
typedef struct _GstTunerChannel
|
||||
{
|
||||
GObject parent;
|
||||
typedef struct _GstTunerChannel {
|
||||
GObject parent;
|
||||
|
||||
gchar *label;
|
||||
gchar *label;
|
||||
GstTunerChannelFlags flags;
|
||||
gulong min_frequency, max_frequency;
|
||||
gint min_signal, max_signal;
|
||||
gulong min_frequency,
|
||||
max_frequency;
|
||||
gint min_signal,
|
||||
max_signal;
|
||||
} GstTunerChannel;
|
||||
|
||||
typedef struct _GstTunerChannelClass
|
||||
{
|
||||
typedef struct _GstTunerChannelClass {
|
||||
GObjectClass parent;
|
||||
|
||||
/* signals */
|
||||
void (*frequency_changed) (GstTunerChannel * channel, gulong frequency);
|
||||
void (*signal_changed) (GstTunerChannel * channel, gint signal);
|
||||
void (*frequency_changed) (GstTunerChannel *channel,
|
||||
gulong frequency);
|
||||
void (*signal_changed) (GstTunerChannel *channel,
|
||||
gint signal);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstTunerChannelClass;
|
||||
|
||||
GType gst_tuner_channel_get_type (void);
|
||||
GType gst_tuner_channel_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TUNER_CHANNEL_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TUNER_NORM \
|
||||
(gst_tuner_norm_get_type ())
|
||||
#define GST_TUNER_NORM(obj) \
|
||||
|
@ -35,22 +36,22 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TUNER_NORM))
|
||||
#define GST_IS_TUNER_NORM_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TUNER_NORM))
|
||||
typedef struct _GstTunerNorm
|
||||
{
|
||||
|
||||
typedef struct _GstTunerNorm {
|
||||
GObject parent;
|
||||
|
||||
gchar *label;
|
||||
gfloat fps;
|
||||
gchar *label;
|
||||
gfloat fps;
|
||||
} GstTunerNorm;
|
||||
|
||||
typedef struct _GstTunerNormClass
|
||||
{
|
||||
typedef struct _GstTunerNormClass {
|
||||
GObjectClass parent;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstTunerNormClass;
|
||||
|
||||
GType gst_tuner_norm_get_type (void);
|
||||
GType gst_tuner_norm_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TUNER_NORM_H__ */
|
||||
|
|
|
@ -98,31 +98,31 @@
|
|||
|
||||
#define GST_VIDEO_CAPS_RGBx \
|
||||
__GST_VIDEO_CAPS_MAKE_32 (1, 2, 3)
|
||||
|
||||
|
||||
#define GST_VIDEO_CAPS_xRGB \
|
||||
__GST_VIDEO_CAPS_MAKE_32 (2, 3, 4)
|
||||
|
||||
|
||||
#define GST_VIDEO_CAPS_BGRx \
|
||||
__GST_VIDEO_CAPS_MAKE_32 (3, 2, 1)
|
||||
|
||||
|
||||
#define GST_VIDEO_CAPS_xBGR \
|
||||
__GST_VIDEO_CAPS_MAKE_32 (4, 3, 2)
|
||||
|
||||
/* note: the macro name uses the order on BE systems */
|
||||
#if G_BYTE_ORDER == G_BIG_ENDIAN
|
||||
#define GST_VIDEO_CAPS_xRGB_HOST_ENDIAN \
|
||||
#define GST_VIDEO_CAPS_xRGB_HOST_ENDIAN \
|
||||
GST_VIDEO_CAPS_xRGB
|
||||
#define GST_VIDEO_CAPS_BGRx_HOST_ENDIAN \
|
||||
#define GST_VIDEO_CAPS_BGRx_HOST_ENDIAN \
|
||||
GST_VIDEO_CAPS_BGRx
|
||||
#else
|
||||
#define GST_VIDEO_CAPS_xRGB_HOST_ENDIAN \
|
||||
#define GST_VIDEO_CAPS_xRGB_HOST_ENDIAN \
|
||||
GST_VIDEO_CAPS_BGRx
|
||||
#define GST_VIDEO_CAPS_BGRx_HOST_ENDIAN \
|
||||
#define GST_VIDEO_CAPS_BGRx_HOST_ENDIAN \
|
||||
GST_VIDEO_CAPS_xRGB
|
||||
#endif
|
||||
|
||||
|
||||
/* 15/16 bit */
|
||||
|
||||
|
||||
#define GST_VIDEO_CAPS_RGB_16 \
|
||||
"video/x-raw-rgb, " \
|
||||
"bpp = (int) 16, " \
|
||||
|
@ -155,7 +155,9 @@
|
|||
"framerate = " GST_VIDEO_FPS_RANGE
|
||||
|
||||
/* functions */
|
||||
gdouble gst_video_frame_rate (GstPad * pad);
|
||||
gboolean gst_video_get_size (GstPad * pad, gint * width, gint * height);
|
||||
gdouble gst_video_frame_rate (GstPad *pad);
|
||||
gboolean gst_video_get_size (GstPad *pad,
|
||||
gint *width,
|
||||
gint *height);
|
||||
|
||||
#endif /* __GST_VIDEO_H__ */
|
||||
|
|
|
@ -17,17 +17,16 @@
|
|||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __GST_VIDEOSINK_H__
|
||||
#define __GST_VIDEOSINK_H__
|
||||
|
||||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_VIDEOSINK (gst_videosink_get_type())
|
||||
#define GST_VIDEOSINK(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_VIDEOSINK, GstVideoSink))
|
||||
|
@ -39,39 +38,37 @@ extern "C"
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_VIDEOSINK))
|
||||
#define GST_VIDEOSINK_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_VIDEOSINK, GstVideoSinkClass))
|
||||
|
||||
|
||||
#define GST_VIDEOSINK_PAD(obj) (GST_VIDEOSINK (obj)->sinkpad)
|
||||
#define GST_VIDEOSINK_WIDTH(obj) (GST_VIDEOSINK (obj)->width)
|
||||
#define GST_VIDEOSINK_HEIGHT(obj) (GST_VIDEOSINK (obj)->height)
|
||||
#define GST_VIDEOSINK_CLOCK(obj) (GST_VIDEOSINK (obj)->clock)
|
||||
|
||||
typedef struct _GstVideoSink GstVideoSink;
|
||||
typedef struct _GstVideoSinkClass GstVideoSinkClass;
|
||||
|
||||
typedef struct _GstVideoSink GstVideoSink;
|
||||
typedef struct _GstVideoSinkClass GstVideoSinkClass;
|
||||
struct _GstVideoSink {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
||||
gint width, height;
|
||||
|
||||
GstClock *clock;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstVideoSink
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstVideoSinkClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
||||
gint width, height;
|
||||
|
||||
GstClock *clock;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstVideoSinkClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
GType gst_videosink_get_type (void);
|
||||
GType gst_videosink_get_type (void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_VIDEOSINK_H__ */
|
||||
#endif /* __GST_VIDEOSINK_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_X_OVERLAY \
|
||||
(gst_x_overlay_get_type ())
|
||||
#define GST_X_OVERLAY(obj) \
|
||||
|
@ -39,38 +40,42 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_X_OVERLAY))
|
||||
#define GST_X_OVERLAY_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_X_OVERLAY, GstXOverlayClass))
|
||||
|
||||
typedef struct _GstXOverlay GstXOverlay;
|
||||
|
||||
typedef struct _GstXOverlayClass
|
||||
{
|
||||
typedef struct _GstXOverlayClass {
|
||||
GTypeInterface klass;
|
||||
|
||||
/* virtual functions */
|
||||
void (*set_xwindow_id) (GstXOverlay * overlay, gulong xwindow_id);
|
||||
void (* set_xwindow_id) (GstXOverlay *overlay,
|
||||
gulong xwindow_id);
|
||||
/* optional virtual functions */
|
||||
void (*get_desired_size) (GstXOverlay * overlay,
|
||||
guint * width, guint * height);
|
||||
void (*expose) (GstXOverlay * overlay);
|
||||
|
||||
void (* get_desired_size) (GstXOverlay *overlay,
|
||||
guint *width,
|
||||
guint *height);
|
||||
void (* expose) (GstXOverlay *overlay);
|
||||
|
||||
/* signals */
|
||||
void (*have_xwindow_id) (GstXOverlay * overlay, gulong xwindow_id);
|
||||
void (*desired_size) (GstXOverlay * overlay, guint width, guint height);
|
||||
void (*have_xwindow_id) (GstXOverlay *overlay,
|
||||
gulong xwindow_id);
|
||||
void (* desired_size) (GstXOverlay *overlay,
|
||||
guint width,
|
||||
guint height);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
} GstXOverlayClass;
|
||||
|
||||
GType gst_x_overlay_get_type (void);
|
||||
GType gst_x_overlay_get_type (void);
|
||||
|
||||
/* virtual class function wrappers */
|
||||
void gst_x_overlay_set_xwindow_id (GstXOverlay * overlay, gulong xwindow_id);
|
||||
void gst_x_overlay_get_desired_size (GstXOverlay * overlay, guint * width,
|
||||
guint * height);
|
||||
void gst_x_overlay_expose (GstXOverlay * overlay);
|
||||
void gst_x_overlay_set_xwindow_id (GstXOverlay *overlay, gulong xwindow_id);
|
||||
void gst_x_overlay_get_desired_size (GstXOverlay *overlay, guint *width, guint *height);
|
||||
void gst_x_overlay_expose (GstXOverlay *overlay);
|
||||
|
||||
/* public methods to fire signals */
|
||||
void gst_x_overlay_got_xwindow_id (GstXOverlay * overlay, gulong xwindow_id);
|
||||
void gst_x_overlay_got_desired_size (GstXOverlay * overlay, guint width,
|
||||
guint height);
|
||||
void gst_x_overlay_got_xwindow_id (GstXOverlay *overlay, gulong xwindow_id);
|
||||
void gst_x_overlay_got_desired_size (GstXOverlay *overlay, guint width, guint height);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_X_OVERLAY_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <X11/Xlib.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_X_WINDOW_LISTENER \
|
||||
(gst_x_window_listener_get_type())
|
||||
#define GST_X_WINDOW_LISTENER(obj) \
|
||||
|
@ -38,22 +39,28 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_TYPE_X_WINDOW_LISTENER))
|
||||
#define GST_IS_X_WINDOW_LISTENER_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_X_WINDOW_LISTENER))
|
||||
typedef struct _GstXWindowListener GstXWindowListener;
|
||||
typedef struct _GstXWindowListenerClass GstXWindowListenerClass;
|
||||
typedef struct _GstXWindowClip GstXWindowClip;
|
||||
typedef void (*MapWindowFunc) (gpointer your_data, gboolean visible);
|
||||
typedef void (*SetWindowFunc) (gpointer your_data,
|
||||
gint x, gint y, gint w, gint h, GstXWindowClip * clips, gint num_clips);
|
||||
|
||||
struct _GstXWindowClip
|
||||
{
|
||||
gint32 x_offset, y_offset, width, height;
|
||||
typedef struct _GstXWindowListener GstXWindowListener;
|
||||
typedef struct _GstXWindowListenerClass GstXWindowListenerClass;
|
||||
typedef struct _GstXWindowClip GstXWindowClip;
|
||||
typedef void (* MapWindowFunc) (gpointer your_data,
|
||||
gboolean visible);
|
||||
typedef void (* SetWindowFunc) (gpointer your_data,
|
||||
gint x, gint y,
|
||||
gint w, gint h,
|
||||
GstXWindowClip *clips,
|
||||
gint num_clips);
|
||||
|
||||
struct _GstXWindowClip {
|
||||
gint32 x_offset,
|
||||
y_offset,
|
||||
width,
|
||||
height;
|
||||
gpointer data;
|
||||
};
|
||||
|
||||
struct _GstXWindowListener
|
||||
{
|
||||
GObject parent;
|
||||
struct _GstXWindowListener {
|
||||
GObject parent;
|
||||
|
||||
/* "per-instance virtual functions" */
|
||||
MapWindowFunc map_window_func;
|
||||
|
@ -63,12 +70,12 @@ struct _GstXWindowListener
|
|||
gpointer private_data;
|
||||
|
||||
/* general information of what we're doing */
|
||||
gchar *display_name;
|
||||
XID xwindow_id;
|
||||
gchar *display_name;
|
||||
XID xwindow_id;
|
||||
|
||||
/* one extra... */
|
||||
Display *main_display;
|
||||
GMutex *main_lock;
|
||||
GMutex *main_lock;
|
||||
|
||||
/* oh my g*d, this is going to be so horribly ugly */
|
||||
GThread *thread;
|
||||
|
@ -77,24 +84,33 @@ struct _GstXWindowListener
|
|||
/* the overlay window + own thread */
|
||||
Display *display;
|
||||
Drawable child;
|
||||
gboolean ov_conf, ov_map, ov_visible, ov_refresh, ov_move, ov_wmmap;
|
||||
gint ov_visibility;
|
||||
guint ov_conf_id, ov_refresh_id;
|
||||
gint x, y, w, h;
|
||||
gboolean ov_conf,
|
||||
ov_map,
|
||||
ov_visible,
|
||||
ov_refresh,
|
||||
ov_move,
|
||||
ov_wmmap;
|
||||
gint ov_visibility;
|
||||
guint ov_conf_id,
|
||||
ov_refresh_id;
|
||||
gint x, y, w, h;
|
||||
GstXWindowClip *clips;
|
||||
gint num_clips;
|
||||
gint num_clips;
|
||||
};
|
||||
|
||||
struct _GstXWindowListenerClass
|
||||
{
|
||||
struct _GstXWindowListenerClass {
|
||||
GObjectClass parent;
|
||||
};
|
||||
|
||||
GType gst_x_window_listener_get_type (void);
|
||||
GstXWindowListener *gst_x_window_listener_new (gchar * display,
|
||||
MapWindowFunc map_window_func,
|
||||
SetWindowFunc set_window_func, gpointer private_data);
|
||||
void gst_x_window_listener_set_xid (GstXWindowListener * xwin, XID id);
|
||||
GType gst_x_window_listener_get_type (void);
|
||||
GstXWindowListener *
|
||||
gst_x_window_listener_new (gchar *display,
|
||||
MapWindowFunc map_window_func,
|
||||
SetWindowFunc set_window_func,
|
||||
gpointer private_data);
|
||||
void gst_x_window_listener_set_xid (GstXWindowListener *xwin,
|
||||
XID id);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __X_WINDOW_LISTENER_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_AC3PARSE \
|
||||
|
@ -42,36 +41,34 @@ extern "C"
|
|||
#define GST_IS_AC3PARSE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AC3PARSE)))
|
||||
|
||||
typedef struct _GstAc3Parse GstAc3Parse;
|
||||
typedef struct _GstAc3ParseClass GstAc3ParseClass;
|
||||
typedef struct _GstAc3Parse GstAc3Parse;
|
||||
typedef struct _GstAc3ParseClass GstAc3ParseClass;
|
||||
|
||||
struct _GstAc3Parse
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstAc3Parse {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
guint lastframebytes; /* bytes in previous of last frame so far */
|
||||
guint lastframesize; /* total length of last frame */
|
||||
guint skip; /* number of frames to skip */
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
guint lastframebytes; /* bytes in previous of last frame so far */
|
||||
guint lastframesize; /* total length of last frame */
|
||||
guint skip; /* number of frames to skip */
|
||||
|
||||
/* some stream parameters */
|
||||
gint sample_rate;
|
||||
gint channels;
|
||||
};
|
||||
/* some stream parameters */
|
||||
gint sample_rate;
|
||||
gint channels;
|
||||
};
|
||||
|
||||
struct _GstAc3ParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstAc3ParseClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_ac3parse_get_type (void);
|
||||
GType gst_ac3parse_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __AC3PARSE_H__ */
|
||||
#endif /* __AC3PARSE_H__ */
|
||||
|
|
|
@ -20,24 +20,21 @@
|
|||
#ifndef ASFHEADERS_H
|
||||
#define ASFHEADERS_H
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
guint32 v1;
|
||||
guint32 v2;
|
||||
guint32 v3;
|
||||
guint32 v4;
|
||||
} ASFGuid;
|
||||
|
||||
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
guint8 obj_id;
|
||||
typedef struct {
|
||||
guint8 obj_id;
|
||||
ASFGuid guid;
|
||||
} ASFGuidHash;
|
||||
|
||||
enum
|
||||
{
|
||||
enum {
|
||||
ASF_OBJ_UNDEFINED = 0,
|
||||
ASF_OBJ_STREAM,
|
||||
ASF_OBJ_DATA,
|
||||
|
@ -56,44 +53,40 @@ enum
|
|||
ASF_OBJ_BITRATE_MUTEX,
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
enum {
|
||||
ASF_STREAM_UNDEFINED = 0,
|
||||
ASF_STREAM_VIDEO,
|
||||
ASF_STREAM_AUDIO,
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
enum {
|
||||
ASF_CORRECTION_UNDEFINED = 0,
|
||||
ASF_CORRECTION_ON,
|
||||
ASF_CORRECTION_OFF,
|
||||
};
|
||||
|
||||
static ASFGuidHash asf_correction_guids[] = {
|
||||
{ASF_CORRECTION_ON, {0xBFC3CD50, 0x11CF618F, 0xAA00B28B, 0x20E2B400}},
|
||||
{ ASF_CORRECTION_ON, { 0xBFC3CD50, 0x11CF618F, 0xAA00B28B, 0x20E2B400 }},
|
||||
/* { ASF_CORRECTION_OFF, { 0x20FB5700, 0x11CF5B55, 0x8000FDA8, 0x2B445C5F }},*/
|
||||
{ASF_CORRECTION_OFF, {0x49F1A440, 0x11D04ECE, 0xA000ACA3, 0xF64803C9}},
|
||||
{ASF_CORRECTION_UNDEFINED, {0, 0, 0, 0}},
|
||||
{ ASF_CORRECTION_OFF, { 0x49F1A440, 0x11D04ECE, 0xA000ACA3, 0xF64803C9 }},
|
||||
{ ASF_CORRECTION_UNDEFINED, { 0, 0, 0, 0 }},
|
||||
};
|
||||
|
||||
static ASFGuidHash asf_stream_guids[] = {
|
||||
{ASF_STREAM_VIDEO, {0xBC19EFC0, 0x11CF5B4D, 0x8000FDA8, 0x2B445C5F}},
|
||||
{ASF_STREAM_AUDIO, {0xF8699E40, 0x11CF5B4D, 0x8000FDA8, 0x2B445C5F}},
|
||||
{ASF_STREAM_UNDEFINED, {0, 0, 0, 0}},
|
||||
{ ASF_STREAM_VIDEO, { 0xBC19EFC0, 0x11CF5B4D, 0x8000FDA8, 0x2B445C5F }},
|
||||
{ ASF_STREAM_AUDIO, { 0xF8699E40, 0x11CF5B4D, 0x8000FDA8, 0x2B445C5F }},
|
||||
{ ASF_STREAM_UNDEFINED, { 0, 0, 0, 0 }},
|
||||
};
|
||||
|
||||
struct _asf_obj_header
|
||||
{
|
||||
struct _asf_obj_header {
|
||||
guint32 num_objects;
|
||||
guint8 unknown1;
|
||||
guint8 unknown2;
|
||||
guint8 unknown1;
|
||||
guint8 unknown2;
|
||||
};
|
||||
|
||||
typedef struct _asf_obj_header asf_obj_header;
|
||||
|
||||
struct _asf_obj_comment
|
||||
{
|
||||
struct _asf_obj_comment {
|
||||
guint16 title_length;
|
||||
guint16 author_length;
|
||||
guint16 copyright_length;
|
||||
|
@ -103,8 +96,7 @@ struct _asf_obj_comment
|
|||
|
||||
typedef struct _asf_obj_comment asf_obj_comment;
|
||||
|
||||
struct _asf_obj_file
|
||||
{
|
||||
struct _asf_obj_file {
|
||||
ASFGuid file_id;
|
||||
guint64 file_size;
|
||||
guint64 creation_time;
|
||||
|
@ -120,8 +112,7 @@ struct _asf_obj_file
|
|||
|
||||
typedef struct _asf_obj_file asf_obj_file;
|
||||
|
||||
struct _asf_obj_stream
|
||||
{
|
||||
struct _asf_obj_stream {
|
||||
ASFGuid type;
|
||||
ASFGuid correction;
|
||||
guint64 unknown1;
|
||||
|
@ -133,8 +124,7 @@ struct _asf_obj_stream
|
|||
|
||||
typedef struct _asf_obj_stream asf_obj_stream;
|
||||
|
||||
struct _asf_stream_audio
|
||||
{
|
||||
struct _asf_stream_audio {
|
||||
guint16 codec_tag;
|
||||
guint16 channels;
|
||||
guint32 sample_rate;
|
||||
|
@ -146,29 +136,26 @@ struct _asf_stream_audio
|
|||
|
||||
typedef struct _asf_stream_audio asf_stream_audio;
|
||||
|
||||
struct _asf_stream_correction
|
||||
{
|
||||
guint8 span;
|
||||
struct _asf_stream_correction {
|
||||
guint8 span;
|
||||
guint16 packet_size;
|
||||
guint16 chunk_size;
|
||||
guint16 data_size;
|
||||
guint8 silence_data;
|
||||
guint8 silence_data;
|
||||
};
|
||||
|
||||
typedef struct _asf_stream_correction asf_stream_correction;
|
||||
|
||||
struct _asf_stream_video
|
||||
{
|
||||
struct _asf_stream_video {
|
||||
guint32 width;
|
||||
guint32 height;
|
||||
guint8 unknown;
|
||||
guint8 unknown;
|
||||
guint16 size;
|
||||
};
|
||||
|
||||
typedef struct _asf_stream_video asf_stream_video;
|
||||
|
||||
struct _asf_stream_video_format
|
||||
{
|
||||
struct _asf_stream_video_format {
|
||||
guint32 size;
|
||||
guint32 width;
|
||||
guint32 height;
|
||||
|
@ -184,69 +171,62 @@ struct _asf_stream_video_format
|
|||
|
||||
typedef struct _asf_stream_video_format asf_stream_video_format;
|
||||
|
||||
struct _asf_obj_data
|
||||
{
|
||||
struct _asf_obj_data {
|
||||
ASFGuid file_id;
|
||||
guint64 packets;
|
||||
guint8 unknown1;
|
||||
guint8 unknown1;
|
||||
/* guint8 unknown2; FIXME: this object is supposed to be 26 bytes?! */
|
||||
guint8 correction;
|
||||
guint8 correction;
|
||||
};
|
||||
|
||||
typedef struct _asf_obj_data asf_obj_data;
|
||||
|
||||
struct _asf_obj_data_correction
|
||||
{
|
||||
struct _asf_obj_data_correction {
|
||||
guint8 type;
|
||||
guint8 cycle;
|
||||
};
|
||||
|
||||
typedef struct _asf_obj_data_correction asf_obj_data_correction;
|
||||
|
||||
struct _asf_obj_data_packet
|
||||
{
|
||||
guint8 flags;
|
||||
guint8 property;
|
||||
struct _asf_obj_data_packet {
|
||||
guint8 flags;
|
||||
guint8 property;
|
||||
};
|
||||
|
||||
typedef struct _asf_obj_data_packet asf_obj_data_packet;
|
||||
|
||||
struct _asf_packet_info
|
||||
{
|
||||
guint32 padsize;
|
||||
guint8 replicsizetype;
|
||||
guint8 fragoffsettype;
|
||||
guint8 seqtype;
|
||||
guint8 segsizetype;
|
||||
struct _asf_packet_info {
|
||||
guint32 padsize;
|
||||
guint8 replicsizetype;
|
||||
guint8 fragoffsettype;
|
||||
guint8 seqtype;
|
||||
guint8 segsizetype;
|
||||
gboolean multiple;
|
||||
guint32 size_left;
|
||||
guint32 size_left;
|
||||
};
|
||||
|
||||
typedef struct _asf_packet_info asf_packet_info;
|
||||
|
||||
struct _asf_segment_info
|
||||
{
|
||||
guint8 stream_number;
|
||||
guint32 chunk_size;
|
||||
guint32 frag_offset;
|
||||
guint32 segment_size;
|
||||
guint32 sequence;
|
||||
guint32 frag_timestamp;
|
||||
struct _asf_segment_info {
|
||||
guint8 stream_number;
|
||||
guint32 chunk_size;
|
||||
guint32 frag_offset;
|
||||
guint32 segment_size;
|
||||
guint32 sequence;
|
||||
guint32 frag_timestamp;
|
||||
gboolean compressed;
|
||||
};
|
||||
|
||||
typedef struct _asf_segment_info asf_segment_info;
|
||||
|
||||
struct _asf_replicated_data
|
||||
{
|
||||
struct _asf_replicated_data {
|
||||
guint32 object_size;
|
||||
guint32 frag_timestamp;
|
||||
};
|
||||
|
||||
typedef struct _asf_replicated_data asf_replicated_data;
|
||||
|
||||
struct _asf_bitrate_record
|
||||
{
|
||||
struct _asf_bitrate_record {
|
||||
guint16 stream_id;
|
||||
guint32 bitrate;
|
||||
};
|
||||
|
@ -254,22 +234,22 @@ struct _asf_bitrate_record
|
|||
typedef struct _asf_bitrate_record asf_bitrate_record;
|
||||
|
||||
static ASFGuidHash asf_object_guids[] = {
|
||||
{ASF_OBJ_STREAM, {0xB7DC0791, 0x11CFA9B7, 0xC000E68E, 0x6553200C}},
|
||||
{ASF_OBJ_DATA, {0x75b22636, 0x11cf668e, 0xAA00D9a6, 0x6Cce6200}},
|
||||
{ASF_OBJ_FILE, {0x8CABDCA1, 0x11CFA947, 0xC000E48E, 0x6553200C}},
|
||||
{ASF_OBJ_HEADER, {0x75B22630, 0x11CF668E, 0xAA00D9A6, 0x6CCE6200}},
|
||||
{ASF_OBJ_CONCEAL_NONE, {0x20fb5700, 0x11cf5b55, 0x8000FDa8, 0x2B445C5f}},
|
||||
{ASF_OBJ_COMMENT, {0x75b22633, 0x11cf668e, 0xAA00D9a6, 0x6Cce6200}},
|
||||
{ASF_OBJ_CODEC_COMMENT, {0x86D15240, 0x11D0311D, 0xA000A4A3, 0xF64803C9}},
|
||||
{ASF_OBJ_CODEC_COMMENT1, {0x86d15241, 0x11d0311d, 0xA000A4a3, 0xF64803c9}},
|
||||
{ASF_OBJ_INDEX, {0x33000890, 0x11cfe5b1, 0xA000F489, 0xCB4903c9}},
|
||||
{ASF_OBJ_HEAD1, {0x5fbf03b5, 0x11cfa92e, 0xC000E38e, 0x6553200c}},
|
||||
{ASF_OBJ_HEAD2, {0xabd3d211, 0x11cfa9ba, 0xC000E68e, 0x6553200c}},
|
||||
{ASF_OBJ_PADDING, {0x1806D474, 0x4509CADF, 0xAB9ABAA4, 0xE8AA96CD}},
|
||||
{ASF_OBJ_BITRATE_PROPS, {0x7bf875ce, 0x11d1468d, 0x6000828d, 0xb2a2c997}},
|
||||
{ASF_OBJ_EXT_CONTENT_DESC, {0xd2d0a440, 0x11d2e307, 0xa000f097, 0x50a85ec9}},
|
||||
{ASF_OBJ_BITRATE_MUTEX, {0xd6e229dc, 0x11d135da, 0xa0003490, 0xbe4903c9}},
|
||||
{ASF_OBJ_UNDEFINED, {0, 0, 0, 0}},
|
||||
{ ASF_OBJ_STREAM, { 0xB7DC0791, 0x11CFA9B7, 0xC000E68E, 0x6553200C }},
|
||||
{ ASF_OBJ_DATA, { 0x75b22636, 0x11cf668e, 0xAA00D9a6, 0x6Cce6200 }},
|
||||
{ ASF_OBJ_FILE, { 0x8CABDCA1, 0x11CFA947, 0xC000E48E, 0x6553200C }},
|
||||
{ ASF_OBJ_HEADER, { 0x75B22630, 0x11CF668E, 0xAA00D9A6, 0x6CCE6200 }},
|
||||
{ ASF_OBJ_CONCEAL_NONE, { 0x20fb5700, 0x11cf5b55, 0x8000FDa8, 0x2B445C5f }},
|
||||
{ ASF_OBJ_COMMENT, { 0x75b22633, 0x11cf668e, 0xAA00D9a6, 0x6Cce6200 }},
|
||||
{ ASF_OBJ_CODEC_COMMENT, { 0x86D15240, 0x11D0311D, 0xA000A4A3, 0xF64803C9 }},
|
||||
{ ASF_OBJ_CODEC_COMMENT1, { 0x86d15241, 0x11d0311d, 0xA000A4a3, 0xF64803c9 }},
|
||||
{ ASF_OBJ_INDEX, { 0x33000890, 0x11cfe5b1, 0xA000F489, 0xCB4903c9 }},
|
||||
{ ASF_OBJ_HEAD1, { 0x5fbf03b5, 0x11cfa92e, 0xC000E38e, 0x6553200c }},
|
||||
{ ASF_OBJ_HEAD2, { 0xabd3d211, 0x11cfa9ba, 0xC000E68e, 0x6553200c }},
|
||||
{ ASF_OBJ_PADDING, { 0x1806D474, 0x4509CADF, 0xAB9ABAA4, 0xE8AA96CD }},
|
||||
{ ASF_OBJ_BITRATE_PROPS, { 0x7bf875ce, 0x11d1468d, 0x6000828d, 0xb2a2c997 }},
|
||||
{ ASF_OBJ_EXT_CONTENT_DESC, { 0xd2d0a440, 0x11d2e307, 0xa000f097, 0x50a85ec9 }},
|
||||
{ ASF_OBJ_BITRATE_MUTEX, { 0xd6e229dc, 0x11d135da, 0xa0003490, 0xbe4903c9 }},
|
||||
{ ASF_OBJ_UNDEFINED, { 0, 0, 0, 0 }},
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include "asfheaders.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_ASF_DEMUX \
|
||||
(asf_demux_get_type())
|
||||
#define GST_ASF_DEMUX(obj) \
|
||||
|
@ -36,11 +37,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_ASF_DEMUX))
|
||||
#define GST_IS_ASF_DEMUX_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ASF_DEMUX))
|
||||
|
||||
typedef struct _GstASFDemux GstASFDemux;
|
||||
typedef struct _GstASFDemuxClass GstASFDemuxClass;
|
||||
|
||||
struct _GstASFStreamContext
|
||||
{
|
||||
struct _GstASFStreamContext {
|
||||
GstPad *pad;
|
||||
guint64 pts;
|
||||
};
|
||||
|
@ -48,7 +49,7 @@ struct _GstASFStreamContext
|
|||
|
||||
typedef struct
|
||||
{
|
||||
GstPad *pad;
|
||||
GstPad *pad;
|
||||
guint16 id;
|
||||
guint32 frag_offset;
|
||||
guint32 sequence;
|
||||
|
@ -56,12 +57,11 @@ typedef struct
|
|||
GstBuffer *payload;
|
||||
} asf_stream_context;
|
||||
|
||||
struct _GstASFDemux
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstASFDemux {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
GstPad *sinkpad;
|
||||
|
||||
GstByteStream *bs;
|
||||
|
||||
|
@ -77,7 +77,7 @@ struct _GstASFDemux
|
|||
GstPad *audio_pad[GST_ASF_DEMUX_NUM_AUDIO_PADS];
|
||||
gint64 audio_PTS[GST_ASF_DEMUX_NUM_AUDIO_PADS];
|
||||
|
||||
guint64 last_seek;
|
||||
guint64 last_seek;
|
||||
gboolean restart;
|
||||
|
||||
guint32 bitrate[GST_ASF_DEMUX_NUM_STREAM_IDS];
|
||||
|
@ -96,23 +96,23 @@ struct _GstASFDemux
|
|||
guint64 pts;
|
||||
|
||||
/* Descrambler settings */
|
||||
guint8 span;
|
||||
guint8 span;
|
||||
guint16 ds_packet_size;
|
||||
guint16 ds_chunk_size;
|
||||
guint16 ds_data_size;
|
||||
|
||||
};
|
||||
|
||||
struct _GstASFDemuxClass
|
||||
{
|
||||
struct _GstASFDemuxClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_asf_demux_get_type (void);
|
||||
GType gst_asf_demux_get_type(void);
|
||||
|
||||
gboolean gst_asf_demux_plugin_init (GModule * module, GstPlugin * plugin);
|
||||
gboolean gst_asf_demux_plugin_init (GModule *module, GstPlugin *plugin);
|
||||
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __ASF_DEMUX_H__ */
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include "asfheaders.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_ASFMUX \
|
||||
(gst_asfmux_get_type())
|
||||
|
@ -41,55 +40,50 @@ extern "C"
|
|||
|
||||
#define MAX_ASF_OUTPUTS 16
|
||||
|
||||
typedef struct _GstAsfMuxStream
|
||||
{
|
||||
guint index;
|
||||
typedef struct _GstAsfMuxStream {
|
||||
guint index;
|
||||
|
||||
gint type; /* ASF_STREAM_VIDEO/AUDIO */
|
||||
GstPad *pad;
|
||||
guint64 time;
|
||||
GstBuffer *queue;
|
||||
gboolean connected, eos;
|
||||
guint seqnum;
|
||||
guint bitrate;
|
||||
gint type; /* ASF_STREAM_VIDEO/AUDIO */
|
||||
GstPad *pad;
|
||||
guint64 time;
|
||||
GstBuffer *queue;
|
||||
gboolean connected, eos;
|
||||
guint seqnum;
|
||||
guint bitrate;
|
||||
|
||||
union
|
||||
{
|
||||
asf_stream_audio audio;
|
||||
struct
|
||||
{
|
||||
asf_stream_video stream;
|
||||
asf_stream_video_format format;
|
||||
} video;
|
||||
} header;
|
||||
} GstAsfMuxStream;
|
||||
union {
|
||||
asf_stream_audio audio;
|
||||
struct {
|
||||
asf_stream_video stream;
|
||||
asf_stream_video_format format;
|
||||
} video;
|
||||
} header;
|
||||
} GstAsfMuxStream;
|
||||
|
||||
typedef struct _GstAsfMux
|
||||
{
|
||||
GstElement element;
|
||||
typedef struct _GstAsfMux {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *srcpad;
|
||||
GstAsfMuxStream output[MAX_ASF_OUTPUTS];
|
||||
guint num_outputs, num_video, num_audio;
|
||||
gboolean write_header;
|
||||
/* pads */
|
||||
GstPad *srcpad;
|
||||
GstAsfMuxStream output[MAX_ASF_OUTPUTS];
|
||||
guint num_outputs, num_video, num_audio;
|
||||
gboolean write_header;
|
||||
|
||||
/* packet */
|
||||
GstBuffer *packet;
|
||||
guint num_packets, packet_frames;
|
||||
guint sequence;
|
||||
guint64 data_offset;
|
||||
} GstAsfMux;
|
||||
/* packet */
|
||||
GstBuffer *packet;
|
||||
guint num_packets, packet_frames;
|
||||
guint sequence;
|
||||
guint64 data_offset;
|
||||
} GstAsfMux;
|
||||
|
||||
typedef struct _GstAsfMuxClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
} GstAsfMuxClass;
|
||||
typedef struct _GstAsfMuxClass {
|
||||
GstElementClass parent_class;
|
||||
} GstAsfMuxClass;
|
||||
|
||||
GType gst_asfmux_get_type (void);
|
||||
GType gst_asfmux_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_ASFMUX_H__ */
|
||||
#endif /* __GST_ASFMUX_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MP3PARSE \
|
||||
|
@ -42,33 +41,31 @@ extern "C"
|
|||
#define GST_IS_MP3PARSE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MP3PARSE))
|
||||
|
||||
typedef struct _GstMPEGAudioParse GstMPEGAudioParse;
|
||||
typedef struct _GstMPEGAudioParseClass GstMPEGAudioParseClass;
|
||||
typedef struct _GstMPEGAudioParse GstMPEGAudioParse;
|
||||
typedef struct _GstMPEGAudioParseClass GstMPEGAudioParseClass;
|
||||
|
||||
struct _GstMPEGAudioParse
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMPEGAudioParse {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
guint skip; /* number of frames to skip */
|
||||
guint bit_rate;
|
||||
gint channels, rate, layer;
|
||||
gboolean in_flush;
|
||||
};
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
guint skip; /* number of frames to skip */
|
||||
guint bit_rate;
|
||||
gint channels, rate, layer;
|
||||
gboolean in_flush;
|
||||
};
|
||||
|
||||
struct _GstMPEGAudioParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstMPEGAudioParseClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mp3parse_get_type (void);
|
||||
GType gst_mp3parse_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __MP3PARSE_H__ */
|
||||
#endif /* __MP3PARSE_H__ */
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
#include <gst/gstsystemclock.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MPEG_CLOCK \
|
||||
|
@ -43,33 +42,30 @@ extern "C"
|
|||
#define GST_IS_MPEG_CLOCK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MPEG_CLOCK))
|
||||
|
||||
typedef struct _GstMPEGClock GstMPEGClock;
|
||||
typedef struct _GstMPEGClockClass GstMPEGClockClass;
|
||||
typedef struct _GstMPEGClock GstMPEGClock;
|
||||
typedef struct _GstMPEGClockClass GstMPEGClockClass;
|
||||
|
||||
typedef GstClockTime (*GstMPEGClockGetTimeFunc) (GstClock * clock,
|
||||
gpointer user_data);
|
||||
typedef GstClockTime (*GstMPEGClockGetTimeFunc) (GstClock *clock, gpointer user_data);
|
||||
|
||||
|
||||
struct _GstMPEGClock
|
||||
{
|
||||
GstSystemClock clock;
|
||||
struct _GstMPEGClock {
|
||||
GstSystemClock clock;
|
||||
|
||||
GstMPEGClockGetTimeFunc func;
|
||||
gpointer user_data;
|
||||
};
|
||||
GstMPEGClockGetTimeFunc func;
|
||||
gpointer user_data;
|
||||
};
|
||||
|
||||
struct _GstMPEGClockClass
|
||||
{
|
||||
GstSystemClockClass parent_class;
|
||||
};
|
||||
struct _GstMPEGClockClass {
|
||||
GstSystemClockClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mpeg_clock_get_type (void);
|
||||
GstClock *gst_mpeg_clock_new (gchar * name, GstMPEGClockGetTimeFunc func,
|
||||
gpointer user_data);
|
||||
GType gst_mpeg_clock_get_type (void);
|
||||
GstClock* gst_mpeg_clock_new (gchar *name, GstMPEGClockGetTimeFunc func,
|
||||
gpointer user_data);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_MPEG_CLOCK_H__ */
|
||||
#endif /* __GST_MPEG_CLOCK_H__ */
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MPEG_DEMUX \
|
||||
|
@ -43,39 +42,37 @@ extern "C"
|
|||
#define GST_IS_MPEG_DEMUX_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MPEG_DEMUX))
|
||||
|
||||
typedef struct _GstMPEGDemux GstMPEGDemux;
|
||||
typedef struct _GstMPEGDemuxClass GstMPEGDemuxClass;
|
||||
typedef struct _GstMPEGDemux GstMPEGDemux;
|
||||
typedef struct _GstMPEGDemuxClass GstMPEGDemuxClass;
|
||||
|
||||
typedef struct _GstMPEGStream GstMPEGStream;
|
||||
typedef struct _GstMPEGStream GstMPEGStream;
|
||||
|
||||
struct _GstMPEGStream
|
||||
{
|
||||
gint8 STD_buffer_bound_scale;
|
||||
gint16 STD_buffer_size_bound;
|
||||
GstPad *pad;
|
||||
guint64 pts;
|
||||
gint index_id;
|
||||
gint size_bound;
|
||||
};
|
||||
struct _GstMPEGStream {
|
||||
gint8 STD_buffer_bound_scale;
|
||||
gint16 STD_buffer_size_bound;
|
||||
GstPad *pad;
|
||||
guint64 pts;
|
||||
gint index_id;
|
||||
gint size_bound;
|
||||
};
|
||||
|
||||
struct _GstMPEGDemux
|
||||
{
|
||||
GstMPEGParse parent;
|
||||
struct _GstMPEGDemux {
|
||||
GstMPEGParse parent;
|
||||
|
||||
/* previous partial chunk and bytes remaining in it */
|
||||
gboolean in_flush;
|
||||
/* previous partial chunk and bytes remaining in it */
|
||||
gboolean in_flush;
|
||||
|
||||
/* program stream header values */
|
||||
guint16 header_length;
|
||||
guint32 rate_bound;
|
||||
guint8 audio_bound;
|
||||
gboolean fixed;
|
||||
gboolean constrained;
|
||||
gboolean audio_lock;
|
||||
gboolean video_lock;
|
||||
guint8 video_bound;
|
||||
gboolean packet_rate_restriction;
|
||||
gint64 total_size_bound;
|
||||
/* program stream header values */
|
||||
guint16 header_length;
|
||||
guint32 rate_bound;
|
||||
guint8 audio_bound;
|
||||
gboolean fixed;
|
||||
gboolean constrained;
|
||||
gboolean audio_lock;
|
||||
gboolean video_lock;
|
||||
guint8 video_bound;
|
||||
gboolean packet_rate_restriction;
|
||||
gint64 total_size_bound;
|
||||
|
||||
#define NUM_PRIVATE_1_STREAMS 8
|
||||
#define NUM_PCM_STREAMS 8
|
||||
|
@ -83,34 +80,33 @@ extern "C"
|
|||
#define NUM_VIDEO_STREAMS 16
|
||||
#define NUM_AUDIO_STREAMS 32
|
||||
|
||||
/* stream output */
|
||||
GstMPEGStream *private_1_stream[NUM_PRIVATE_1_STREAMS]; /* up to 8 ac3 audio tracks */
|
||||
GstMPEGStream *pcm_stream[NUM_PCM_STREAMS];
|
||||
GstMPEGStream *subtitle_stream[NUM_SUBTITLE_STREAMS];
|
||||
GstMPEGStream *private_2_stream;
|
||||
GstMPEGStream *video_stream[NUM_VIDEO_STREAMS];
|
||||
GstMPEGStream *audio_stream[NUM_AUDIO_STREAMS];
|
||||
/* stream output */
|
||||
GstMPEGStream *private_1_stream[NUM_PRIVATE_1_STREAMS]; /* up to 8 ac3 audio tracks */
|
||||
GstMPEGStream *pcm_stream[NUM_PCM_STREAMS];
|
||||
GstMPEGStream *subtitle_stream[NUM_SUBTITLE_STREAMS];
|
||||
GstMPEGStream *private_2_stream;
|
||||
GstMPEGStream *video_stream[NUM_VIDEO_STREAMS];
|
||||
GstMPEGStream *audio_stream[NUM_AUDIO_STREAMS];
|
||||
|
||||
/* The type of linear PCM samples associated to each channel. The
|
||||
values are bit fields with the same format of the sample_info
|
||||
field in the linear PCM header. */
|
||||
guint8 lpcm_sample_info[NUM_PCM_STREAMS];
|
||||
/* The type of linear PCM samples associated to each channel. The
|
||||
values are bit fields with the same format of the sample_info
|
||||
field in the linear PCM header. */
|
||||
guint8 lpcm_sample_info[NUM_PCM_STREAMS];
|
||||
|
||||
GstIndex *index;
|
||||
};
|
||||
GstIndex *index;
|
||||
};
|
||||
|
||||
struct _GstMPEGDemuxClass
|
||||
{
|
||||
GstMPEGParseClass parent_class;
|
||||
};
|
||||
struct _GstMPEGDemuxClass {
|
||||
GstMPEGParseClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mpeg_demux_get_type (void);
|
||||
GType gst_mpeg_demux_get_type(void);
|
||||
|
||||
gboolean gst_mpeg_demux_plugin_init (GstPlugin * plugin);
|
||||
gboolean gst_mpeg_demux_plugin_init (GstPlugin *plugin);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __MPEG_DEMUX_H__ */
|
||||
#endif /* __MPEG_DEMUX_H__ */
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define PICTURE_START_CODE 0x00
|
||||
#define SLICE_MIN_START_CODE 0x01
|
||||
|
@ -45,39 +44,36 @@ extern "C"
|
|||
#define PACK_START_CODE 0xba
|
||||
#define SYS_HEADER_START_CODE 0xbb
|
||||
|
||||
typedef struct _GstMPEGPacketize GstMPEGPacketize;
|
||||
typedef struct _GstMPEGPacketize GstMPEGPacketize;
|
||||
|
||||
#define GST_MPEG_PACKETIZE_ID(pack) ((pack)->id)
|
||||
#define GST_MPEG_PACKETIZE_IS_MPEG2(pack) ((pack)->MPEG2)
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_MPEG_PACKETIZE_SYSTEM,
|
||||
GST_MPEG_PACKETIZE_VIDEO,
|
||||
} GstMPEGPacketizeType;
|
||||
typedef enum {
|
||||
GST_MPEG_PACKETIZE_SYSTEM,
|
||||
GST_MPEG_PACKETIZE_VIDEO,
|
||||
} GstMPEGPacketizeType;
|
||||
|
||||
struct _GstMPEGPacketize
|
||||
{
|
||||
/* current parse state */
|
||||
guchar id;
|
||||
struct _GstMPEGPacketize {
|
||||
/* current parse state */
|
||||
guchar id;
|
||||
|
||||
GstPad *pad;
|
||||
GstByteStream *bs;
|
||||
GstMPEGPacketizeType type;
|
||||
GstPad *pad;
|
||||
GstByteStream *bs;
|
||||
GstMPEGPacketizeType type;
|
||||
|
||||
gboolean MPEG2;
|
||||
gboolean resync;
|
||||
};
|
||||
gboolean MPEG2;
|
||||
gboolean resync;
|
||||
};
|
||||
|
||||
GstMPEGPacketize *gst_mpeg_packetize_new (GstPad * pad,
|
||||
GstMPEGPacketizeType type);
|
||||
void gst_mpeg_packetize_destroy (GstMPEGPacketize * packetize);
|
||||
GstMPEGPacketize* gst_mpeg_packetize_new (GstPad *pad, GstMPEGPacketizeType type);
|
||||
void gst_mpeg_packetize_destroy (GstMPEGPacketize *packetize);
|
||||
|
||||
GstData *gst_mpeg_packetize_read (GstMPEGPacketize * packetize);
|
||||
GstData* gst_mpeg_packetize_read (GstMPEGPacketize *packetize);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __MPEGPACKETIZE_H__ */
|
||||
#endif /* __MPEGPACKETIZE_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include "gstmpegpacketize.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MPEG_PARSE \
|
||||
|
@ -50,70 +49,71 @@ extern "C"
|
|||
#define MPEGTIME_TO_GSTTIME(time) (((time) * (GST_MSECOND/10)) / CLOCK_BASE)
|
||||
#define GSTTIME_TO_MPEGTIME(time) (((time) * CLOCK_BASE) / (GST_MSECOND/10))
|
||||
|
||||
typedef struct _GstMPEGParse GstMPEGParse;
|
||||
typedef struct _GstMPEGParseClass GstMPEGParseClass;
|
||||
typedef struct _GstMPEGParse GstMPEGParse;
|
||||
typedef struct _GstMPEGParseClass GstMPEGParseClass;
|
||||
|
||||
struct _GstMPEGParse
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMPEGParse {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
GstMPEGPacketize *packetize;
|
||||
GstMPEGPacketize *packetize;
|
||||
|
||||
/* pack header values */
|
||||
guint32 mux_rate;
|
||||
guint64 current_scr;
|
||||
guint64 next_scr;
|
||||
guint64 bytes_since_scr;
|
||||
/* pack header values */
|
||||
guint32 mux_rate;
|
||||
guint64 current_scr;
|
||||
guint64 next_scr;
|
||||
guint64 bytes_since_scr;
|
||||
|
||||
gint64 adjust;
|
||||
gint64 adjust;
|
||||
|
||||
gboolean discont_pending;
|
||||
gboolean scr_pending;
|
||||
gint max_discont;
|
||||
gboolean discont_pending;
|
||||
gboolean scr_pending;
|
||||
gint max_discont;
|
||||
|
||||
GstClock *clock;
|
||||
gboolean sync;
|
||||
GstClockID id;
|
||||
GstClock *clock;
|
||||
gboolean sync;
|
||||
GstClockID id;
|
||||
|
||||
GstIndex *index;
|
||||
gint index_id;
|
||||
};
|
||||
GstIndex *index;
|
||||
gint index_id;
|
||||
};
|
||||
|
||||
struct _GstMPEGParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstMPEGParseClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* process packet types */
|
||||
gboolean (*parse_packhead) (GstMPEGParse * parse, GstBuffer * buffer);
|
||||
gboolean (*parse_syshead) (GstMPEGParse * parse, GstBuffer * buffer);
|
||||
gboolean (*parse_packet) (GstMPEGParse * parse, GstBuffer * buffer);
|
||||
gboolean (*parse_pes) (GstMPEGParse * parse, GstBuffer * buffer);
|
||||
/* process packet types */
|
||||
gboolean (*parse_packhead) (GstMPEGParse *parse, GstBuffer *buffer);
|
||||
gboolean (*parse_syshead) (GstMPEGParse *parse, GstBuffer *buffer);
|
||||
gboolean (*parse_packet) (GstMPEGParse *parse, GstBuffer *buffer);
|
||||
gboolean (*parse_pes) (GstMPEGParse *parse, GstBuffer *buffer);
|
||||
|
||||
/* optional method to send out the data */
|
||||
void (*send_data) (GstMPEGParse * parse, GstData * data, GstClockTime time);
|
||||
void (*handle_discont) (GstMPEGParse * parse);
|
||||
};
|
||||
/* optional method to send out the data */
|
||||
void (*send_data) (GstMPEGParse *parse, GstData *data, GstClockTime time);
|
||||
void (*handle_discont) (GstMPEGParse *parse);
|
||||
};
|
||||
|
||||
GType gst_mpeg_parse_get_type (void);
|
||||
GType gst_mpeg_parse_get_type(void);
|
||||
|
||||
gboolean gst_mpeg_parse_plugin_init (GstPlugin * plugin);
|
||||
gboolean gst_mpeg_parse_plugin_init (GstPlugin *plugin);
|
||||
|
||||
const GstFormat *gst_mpeg_parse_get_src_formats (GstPad * pad);
|
||||
const GstFormat*
|
||||
gst_mpeg_parse_get_src_formats (GstPad *pad);
|
||||
|
||||
gboolean gst_mpeg_parse_convert_src (GstPad *pad, GstFormat src_format, gint64 src_value,
|
||||
GstFormat *dest_format, gint64 *dest_value);
|
||||
const GstEventMask*
|
||||
gst_mpeg_parse_get_src_event_masks (GstPad *pad);
|
||||
gboolean gst_mpeg_parse_handle_src_event (GstPad *pad, GstEvent *event);
|
||||
|
||||
gboolean gst_mpeg_parse_convert_src (GstPad * pad, GstFormat src_format,
|
||||
gint64 src_value, GstFormat * dest_format, gint64 * dest_value);
|
||||
const GstEventMask *gst_mpeg_parse_get_src_event_masks (GstPad * pad);
|
||||
gboolean gst_mpeg_parse_handle_src_event (GstPad * pad, GstEvent * event);
|
||||
|
||||
const GstQueryType *gst_mpeg_parse_get_src_query_types (GstPad * pad);
|
||||
gboolean gst_mpeg_parse_handle_src_query (GstPad * pad, GstQueryType type,
|
||||
GstFormat * format, gint64 * value);
|
||||
const GstQueryType*
|
||||
gst_mpeg_parse_get_src_query_types (GstPad *pad);
|
||||
gboolean gst_mpeg_parse_handle_src_query (GstPad *pad, GstQueryType type,
|
||||
GstFormat *format, gint64 *value);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __MPEG_PARSE_H__ */
|
||||
#endif /* __MPEG_PARSE_H__ */
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_RFC2250_ENC \
|
||||
|
@ -46,47 +45,44 @@ extern "C"
|
|||
|
||||
#define GST_RFC2250_ENC_IS_MPEG2(parse) (GST_MPEG_PACKETIZE_IS_MPEG2 (GST_RFC2250_ENC (parse)->packetize))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
ENC_HAVE_SEQ = (1 << 0),
|
||||
ENC_HAVE_GOP = (1 << 1),
|
||||
ENC_HAVE_PIC = (1 << 2),
|
||||
ENC_HAVE_DATA = (1 << 3),
|
||||
} GstEncFlags;
|
||||
typedef enum {
|
||||
ENC_HAVE_SEQ = (1 << 0),
|
||||
ENC_HAVE_GOP = (1 << 1),
|
||||
ENC_HAVE_PIC = (1 << 2),
|
||||
ENC_HAVE_DATA = (1 << 3),
|
||||
} GstEncFlags;
|
||||
|
||||
typedef struct _GstRFC2250Enc GstRFC2250Enc;
|
||||
typedef struct _GstRFC2250EncClass GstRFC2250EncClass;
|
||||
|
||||
typedef struct _GstRFC2250Enc GstRFC2250Enc;
|
||||
typedef struct _GstRFC2250EncClass GstRFC2250EncClass;
|
||||
struct _GstRFC2250Enc {
|
||||
GstElement element;
|
||||
|
||||
struct _GstRFC2250Enc
|
||||
{
|
||||
GstElement element;
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstMPEGPacketize *packetize;
|
||||
|
||||
GstMPEGPacketize *packetize;
|
||||
/* pack header values */
|
||||
guint32 bit_rate;
|
||||
guint64 next_ts;
|
||||
GstBuffer *packet;
|
||||
GstEncFlags flags;
|
||||
gint MTU;
|
||||
gint remaining;
|
||||
};
|
||||
|
||||
/* pack header values */
|
||||
guint32 bit_rate;
|
||||
guint64 next_ts;
|
||||
GstBuffer *packet;
|
||||
GstEncFlags flags;
|
||||
gint MTU;
|
||||
gint remaining;
|
||||
};
|
||||
struct _GstRFC2250EncClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
struct _GstRFC2250EncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
GType gst_rfc2250_enc_get_type(void);
|
||||
|
||||
GType gst_rfc2250_enc_get_type (void);
|
||||
|
||||
gboolean gst_rfc2250_enc_plugin_init (GstPlugin * plugin);
|
||||
gboolean gst_rfc2250_enc_plugin_init (GstPlugin *plugin);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __RFC2250_ENC_H__ */
|
||||
#endif /* __RFC2250_ENC_H__ */
|
||||
|
|
|
@ -25,9 +25,8 @@
|
|||
#include <gst/bytestream/bytestream.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_RMDEMUX \
|
||||
|
@ -43,49 +42,47 @@ extern "C"
|
|||
|
||||
#define GST_RMDEMUX_MAX_STREAMS 8
|
||||
|
||||
typedef struct _GstRMDemux GstRMDemux;
|
||||
typedef struct _GstRMDemuxClass GstRMDemuxClass;
|
||||
typedef struct _GstRMDemuxStream GstRMDemuxStream;
|
||||
typedef struct _GstRMDemux GstRMDemux;
|
||||
typedef struct _GstRMDemuxClass GstRMDemuxClass;
|
||||
typedef struct _GstRMDemuxStream GstRMDemuxStream;
|
||||
|
||||
struct _GstRMDemux
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstRMDemux {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
|
||||
GstRMDemuxStream *streams[GST_RMDEMUX_MAX_STREAMS];
|
||||
int n_streams;
|
||||
int n_video_streams;
|
||||
int n_audio_streams;
|
||||
GstRMDemuxStream *streams[GST_RMDEMUX_MAX_STREAMS];
|
||||
int n_streams;
|
||||
int n_video_streams;
|
||||
int n_audio_streams;
|
||||
|
||||
GstByteStream *bs;
|
||||
GstByteStream *bs;
|
||||
|
||||
GNode *moov_node;
|
||||
GNode *moov_node_compressed;
|
||||
GNode *moov_node;
|
||||
GNode *moov_node_compressed;
|
||||
|
||||
guint32 timescale;
|
||||
guint32 duration;
|
||||
guint32 timescale;
|
||||
guint32 duration;
|
||||
|
||||
int state;
|
||||
int state;
|
||||
|
||||
int offset;
|
||||
int data_offset;
|
||||
int offset;
|
||||
int data_offset;
|
||||
|
||||
int n_chunks;
|
||||
int chunk_index;
|
||||
int n_chunks;
|
||||
int chunk_index;
|
||||
|
||||
guint64 length;
|
||||
guint64 length;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
struct _GstRMDemuxClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstRMDemuxClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_RMDEMUX_H__ */
|
||||
#endif /* __GST_RMDEMUX_H__ */
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
#include <glib.h>
|
||||
|
||||
void synaesthesia_init (guint32 resx, guint32 resy);
|
||||
guint32 *synaesthesia_update (gint16 data[2][512]);
|
||||
guint32 * synaesthesia_update (gint16 data [2][512]);
|
||||
void synaesthesia_close ();
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue