mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-17 03:35:21 +00:00
*.h: Revert indenting
Original commit message from CVS: * *.h: Revert indenting
This commit is contained in:
parent
1633bd8693
commit
39fd8a2dbd
137 changed files with 4772 additions and 5187 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:
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_ARTS \
|
||||
(gst_arts_get_type())
|
||||
|
@ -43,26 +42,24 @@ extern "C"
|
|||
#define GST_IS_ARTS_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ARTS))
|
||||
|
||||
typedef struct _GstARTS GstARTS;
|
||||
typedef struct _GstARTSClass GstARTSClass;
|
||||
typedef struct _GstARTS GstARTS;
|
||||
typedef struct _GstARTSClass GstARTSClass;
|
||||
|
||||
struct _GstARTS
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstARTS {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
void *wrapper;
|
||||
};
|
||||
GstPad *sinkpad, *srcpad;
|
||||
void *wrapper;
|
||||
};
|
||||
|
||||
struct _GstARTSClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstARTSClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_ARTS_H__ */
|
||||
#endif /* __GST_ARTS_H__ */
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
void *gst_arts_wrapper_new (GstPad * sinkpad, GstPad * sourcepad);
|
||||
void gst_arts_wrapper_free (void *wrapper);
|
||||
void gst_arts_wrapper_do (void *wrapper);
|
||||
void *gst_arts_wrapper_new(GstPad *sinkpad, GstPad *sourcepad);
|
||||
void gst_arts_wrapper_free(void *wrapper);
|
||||
void gst_arts_wrapper_do(void *wrapper);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
|
|
@ -25,9 +25,8 @@
|
|||
#include <artsc.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_ARTSDSINK \
|
||||
|
@ -41,42 +40,39 @@ extern "C"
|
|||
#define GST_IS_ARTSDSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ARTSDSINK))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_ARTSDSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_ARTSDSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstArtsdSinkFlags;
|
||||
typedef enum {
|
||||
GST_ARTSDSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_ARTSDSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST+2,
|
||||
} GstArtsdSinkFlags;
|
||||
|
||||
typedef struct _GstArtsdsink GstArtsdsink;
|
||||
typedef struct _GstArtsdsinkClass GstArtsdsinkClass;
|
||||
typedef struct _GstArtsdsink GstArtsdsink;
|
||||
typedef struct _GstArtsdsinkClass GstArtsdsinkClass;
|
||||
|
||||
struct _GstArtsdsink
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstArtsdsink {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
GstPad *sinkpad;
|
||||
|
||||
gboolean connected;
|
||||
arts_stream_t stream;
|
||||
gboolean mute;
|
||||
gboolean signd;
|
||||
gint depth;
|
||||
gint channels;
|
||||
gint frequency;
|
||||
gchar *connect_name;
|
||||
};
|
||||
gboolean connected;
|
||||
arts_stream_t stream;
|
||||
gboolean mute;
|
||||
gboolean signd;
|
||||
gint depth;
|
||||
gint channels;
|
||||
gint frequency;
|
||||
gchar* connect_name;
|
||||
};
|
||||
|
||||
struct _GstArtsdsinkClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstArtsdsinkClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_artsdsink_get_type (void);
|
||||
GType gst_artsdsink_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_ARTSDSINK_H__ */
|
||||
#endif /* __GST_ARTSDSINK_H__ */
|
||||
|
|
|
@ -27,14 +27,13 @@
|
|||
|
||||
#include <gst/gst.h>
|
||||
#include <gst/bytestream/bytestream.h>
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
#include <af_vfs.h>
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/*GstElementDetails gst_afparse_details;*/
|
||||
|
@ -51,58 +50,55 @@ extern "C"
|
|||
#define GST_IS_AFPARSE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AFPARSE))
|
||||
|
||||
typedef struct _GstAFParse GstAFParse;
|
||||
typedef struct _GstAFParseClass GstAFParseClass;
|
||||
typedef struct _GstAFParse GstAFParse;
|
||||
typedef struct _GstAFParseClass GstAFParseClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_AFPARSE_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
GST_AFPARSE_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_AFPARSE_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFParseFlags;
|
||||
GST_AFPARSE_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFParseFlags;
|
||||
|
||||
struct _GstAFParse
|
||||
{
|
||||
GstElement element;
|
||||
GstPad *srcpad;
|
||||
GstPad *sinkpad;
|
||||
struct _GstAFParse {
|
||||
GstElement element;
|
||||
GstPad *srcpad;
|
||||
GstPad *sinkpad;
|
||||
|
||||
AFvirtualfile *vfile;
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* blocking */
|
||||
gulong curoffset;
|
||||
gulong bytes_per_read;
|
||||
gint frames_per_read;
|
||||
AFvirtualfile *vfile;
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* blocking */
|
||||
gulong curoffset;
|
||||
gulong bytes_per_read;
|
||||
gint frames_per_read;
|
||||
|
||||
gulong seq;
|
||||
gint64 timestamp;
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
gulong seq;
|
||||
gint64 timestamp;
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
|
||||
struct _GstAFParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstAFParseClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*handoff) (GstElement * element, GstPad * pad);
|
||||
};
|
||||
/* signals */
|
||||
void (*handoff) (GstElement *element,GstPad *pad);
|
||||
};
|
||||
|
||||
gboolean gst_afparse_plugin_init (GstPlugin * plugin);
|
||||
gboolean gst_afparse_plugin_init (GstPlugin *plugin);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_AFPARSE_H__ */
|
||||
#endif /* __GST_AFPARSE_H__ */
|
||||
|
|
|
@ -26,13 +26,12 @@
|
|||
|
||||
|
||||
#include <gst/gst.h>
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/*GstElementDetails gst_afsink_details;*/
|
||||
|
@ -49,56 +48,53 @@ extern "C"
|
|||
#define GST_IS_AFSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AFSINK))
|
||||
|
||||
typedef struct _GstAFSink GstAFSink;
|
||||
typedef struct _GstAFSinkClass GstAFSinkClass;
|
||||
typedef struct _GstAFSink GstAFSink;
|
||||
typedef struct _GstAFSinkClass GstAFSinkClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_AFSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
GST_AFSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_AFSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFSinkFlags;
|
||||
GST_AFSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFSinkFlags;
|
||||
|
||||
struct _GstAFSink
|
||||
{
|
||||
GstElement element;
|
||||
GstPad *sinkpad;
|
||||
struct _GstAFSink {
|
||||
GstElement element;
|
||||
GstPad *sinkpad;
|
||||
|
||||
gchar *filename;
|
||||
gchar *filename;
|
||||
/* FILE *file; */
|
||||
|
||||
/* AFfilesetup outfilesetup; */
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
|
||||
struct _GstAFSinkClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstAFSinkClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*handoff) (GstElement * element, GstPad * pad);
|
||||
};
|
||||
/* signals */
|
||||
void (*handoff) (GstElement *element,GstPad *pad);
|
||||
};
|
||||
|
||||
GType gst_afsink_get_type (void);
|
||||
gboolean gst_afsink_plugin_init (GstPlugin * plugin);
|
||||
GType gst_afsink_get_type (void);
|
||||
gboolean gst_afsink_plugin_init (GstPlugin *plugin);
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_AFSINK_H__ */
|
||||
#endif /* __GST_AFSINK_H__ */
|
||||
|
|
|
@ -26,13 +26,12 @@
|
|||
|
||||
|
||||
#include <gst/gst.h>
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
#include <audiofile.h> /* what else are we to do */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/*GstElementDetails gst_afsrc_details;*/
|
||||
|
@ -49,63 +48,60 @@ extern "C"
|
|||
#define GST_IS_AFSRC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AFSRC))
|
||||
|
||||
typedef struct _GstAFSrc GstAFSrc;
|
||||
typedef struct _GstAFSrcClass GstAFSrcClass;
|
||||
typedef struct _GstAFSrc GstAFSrc;
|
||||
typedef struct _GstAFSrcClass GstAFSrcClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_AFSRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
GST_AFSRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_AFSRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFSrcFlags;
|
||||
GST_AFSRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstAFSrcFlags;
|
||||
|
||||
struct _GstAFSrc
|
||||
{
|
||||
GstElement element;
|
||||
GstPad *srcpad;
|
||||
struct _GstAFSrc {
|
||||
GstElement element;
|
||||
GstPad *srcpad;
|
||||
|
||||
gchar *filename;
|
||||
gchar *filename;
|
||||
/* FILE *file; */
|
||||
|
||||
/* AFfilesetup outfilesetup; */
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* blocking */
|
||||
gulong curoffset;
|
||||
gulong bytes_per_read;
|
||||
AFfilehandle file;
|
||||
int format;
|
||||
int channels;
|
||||
int width;
|
||||
unsigned int rate;
|
||||
gboolean is_signed;
|
||||
int type; /* type of output, compare to audiofile.h
|
||||
* RAW, AIFF, AIFFC, NEXTSND, WAVE
|
||||
*/
|
||||
/* blocking */
|
||||
gulong curoffset;
|
||||
gulong bytes_per_read;
|
||||
|
||||
gulong seq;
|
||||
guint64 framestamp;
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
gulong seq;
|
||||
guint64 framestamp;
|
||||
/* FIXME : endianness is a little cryptic at this point */
|
||||
int endianness_data; /* 4321 or 1234 */
|
||||
int endianness_wanted; /* same thing, but what the output format wants */
|
||||
int endianness_output; /* what the output endianness will be */
|
||||
};
|
||||
|
||||
struct _GstAFSrcClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstAFSrcClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*handoff) (GstElement * element, GstPad * pad);
|
||||
};
|
||||
/* signals */
|
||||
void (*handoff) (GstElement *element,GstPad *pad);
|
||||
};
|
||||
|
||||
GType gst_afsrc_get_type (void);
|
||||
gboolean gst_afsrc_plugin_init (GstPlugin * plugin);
|
||||
GType gst_afsrc_get_type (void);
|
||||
gboolean gst_afsrc_plugin_init (GstPlugin *plugin);
|
||||
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_AFSRC_H__ */
|
||||
#endif /* __GST_AFSRC_H__ */
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include <decore.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_DIVXDEC \
|
||||
|
@ -40,36 +39,34 @@ extern "C"
|
|||
#define GST_IS_DIVXDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_DIVXDEC))
|
||||
|
||||
typedef struct _GstDivxDec GstDivxDec;
|
||||
typedef struct _GstDivxDecClass GstDivxDecClass;
|
||||
typedef struct _GstDivxDec GstDivxDec;
|
||||
typedef struct _GstDivxDecClass GstDivxDecClass;
|
||||
|
||||
struct _GstDivxDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstDivxDec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
/* divx handle */
|
||||
void *handle;
|
||||
/* divx handle */
|
||||
void *handle;
|
||||
|
||||
/* video (output) settings */
|
||||
guint32 csp;
|
||||
int bitcnt, bpp;
|
||||
int version;
|
||||
int width, height;
|
||||
gdouble fps;
|
||||
};
|
||||
/* video (output) settings */
|
||||
guint32 csp;
|
||||
int bitcnt, bpp;
|
||||
int version;
|
||||
int width, height;
|
||||
gdouble fps;
|
||||
};
|
||||
|
||||
struct _GstDivxDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstDivxDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_divxdec_get_type (void);
|
||||
GType gst_divxdec_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_DIVXDEC_H__ */
|
||||
#endif /* __GST_DIVXDEC_H__ */
|
||||
|
|
|
@ -23,9 +23,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_DIVXENC \
|
||||
|
@ -39,48 +38,46 @@ extern "C"
|
|||
#define GST_IS_DIVXENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_DIVXENC))
|
||||
|
||||
typedef struct _GstDivxEnc GstDivxEnc;
|
||||
typedef struct _GstDivxEncClass GstDivxEncClass;
|
||||
typedef struct _GstDivxEnc GstDivxEnc;
|
||||
typedef struct _GstDivxEncClass GstDivxEncClass;
|
||||
|
||||
struct _GstDivxEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstDivxEnc {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
/* quality of encoded image */
|
||||
gulong bitrate;
|
||||
/* quality of encoded image */
|
||||
gulong bitrate;
|
||||
|
||||
/* size of the buffers */
|
||||
gulong buffer_size;
|
||||
/* size of the buffers */
|
||||
gulong buffer_size;
|
||||
|
||||
/* max key interval */
|
||||
gint max_key_interval;
|
||||
/* max key interval */
|
||||
gint max_key_interval;
|
||||
|
||||
/* amount of motion estimation to do */
|
||||
gint quality;
|
||||
/* amount of motion estimation to do */
|
||||
gint quality;
|
||||
|
||||
/* divx handle */
|
||||
void *handle;
|
||||
guint32 csp;
|
||||
gint bitcnt;
|
||||
gint width, height;
|
||||
gfloat fps;
|
||||
};
|
||||
/* divx handle */
|
||||
void *handle;
|
||||
guint32 csp;
|
||||
gint bitcnt;
|
||||
gint width, height;
|
||||
gfloat fps;
|
||||
};
|
||||
|
||||
struct _GstDivxEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstDivxEncClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement * element);
|
||||
};
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement *element);
|
||||
};
|
||||
|
||||
GType gst_divxenc_get_type (void);
|
||||
GType gst_divxenc_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_DIVXENC_H__ */
|
||||
#endif /* __GST_DIVXENC_H__ */
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <faac.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_FAAC \
|
||||
(gst_faac_get_type ())
|
||||
#define GST_FAAC(obj) \
|
||||
|
@ -34,17 +35,25 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_FAAC))
|
||||
#define GST_IS_FAAC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_FAAC))
|
||||
typedef struct _GstFaac
|
||||
{
|
||||
|
||||
typedef struct _GstFaac {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *srcpad, *sinkpad;
|
||||
|
||||
/* stream properties */
|
||||
gint samplerate, channels, format, bps, bitrate, profile, shortctl;
|
||||
gboolean tns, midside;
|
||||
gulong bytes, samples;
|
||||
gint samplerate,
|
||||
channels,
|
||||
format,
|
||||
bps,
|
||||
bitrate,
|
||||
profile,
|
||||
shortctl;
|
||||
gboolean tns,
|
||||
midside;
|
||||
gulong bytes,
|
||||
samples;
|
||||
|
||||
/* FAAC object */
|
||||
faacEncHandle handle;
|
||||
|
@ -54,12 +63,12 @@ G_BEGIN_DECLS
|
|||
guint64 cache_time, cache_duration;
|
||||
} GstFaac;
|
||||
|
||||
typedef struct _GstFaacClass
|
||||
{
|
||||
typedef struct _GstFaacClass {
|
||||
GstElementClass parent_class;
|
||||
} GstFaacClass;
|
||||
|
||||
GType gst_faac_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FAAC_H__ */
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <faad.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_FAAD \
|
||||
(gst_faad_get_type ())
|
||||
#define GST_FAAD(obj) \
|
||||
|
@ -34,26 +35,28 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_FAAD))
|
||||
#define GST_IS_FAAD_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_FAAD))
|
||||
typedef struct _GstFaad
|
||||
{
|
||||
|
||||
typedef struct _GstFaad {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *srcpad, *sinkpad;
|
||||
|
||||
/* cache for latest MPEG-frame */
|
||||
gint samplerate, channels, bps;
|
||||
gint samplerate,
|
||||
channels,
|
||||
bps;
|
||||
|
||||
/* FAAD object */
|
||||
faacDecHandle handle;
|
||||
} GstFaad;
|
||||
|
||||
typedef struct _GstFaadClass
|
||||
{
|
||||
typedef struct _GstFaadClass {
|
||||
GstElementClass parent_class;
|
||||
} GstFaadClass;
|
||||
|
||||
GType gst_faad_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FAAD_H__ */
|
||||
|
|
|
@ -31,9 +31,8 @@
|
|||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_GSMDEC \
|
||||
|
@ -47,32 +46,30 @@ extern "C"
|
|||
#define GST_IS_GSMDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_GSMDEC))
|
||||
|
||||
typedef struct _GstGSMDec GstGSMDec;
|
||||
typedef struct _GstGSMDecClass GstGSMDecClass;
|
||||
typedef struct _GstGSMDec GstGSMDec;
|
||||
typedef struct _GstGSMDecClass GstGSMDecClass;
|
||||
|
||||
struct _GstGSMDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstGSMDec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gsm state;
|
||||
gsm_byte buffer[33];
|
||||
gint bufsize;
|
||||
};
|
||||
gsm state;
|
||||
gsm_byte buffer[33];
|
||||
gint bufsize;
|
||||
};
|
||||
|
||||
struct _GstGSMDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstGSMDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_gsmdec_get_type (void);
|
||||
GType gst_gsmdec_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_GSMDEC_H__ */
|
||||
#endif /* __GST_GSMDEC_H__ */
|
||||
|
|
|
@ -31,9 +31,8 @@
|
|||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_GSMENC \
|
||||
|
@ -47,38 +46,36 @@ extern "C"
|
|||
#define GST_IS_GSMENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_GSMENC))
|
||||
|
||||
typedef struct _GstGSMEnc GstGSMEnc;
|
||||
typedef struct _GstGSMEncClass GstGSMEncClass;
|
||||
typedef struct _GstGSMEnc GstGSMEnc;
|
||||
typedef struct _GstGSMEncClass GstGSMEncClass;
|
||||
|
||||
struct _GstGSMEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstGSMEnc {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gsm state;
|
||||
gsm_signal buffer[160];
|
||||
gint bufsize;
|
||||
gsm state;
|
||||
gsm_signal buffer[160];
|
||||
gint bufsize;
|
||||
|
||||
guint64 next_ts;
|
||||
gint rate;
|
||||
};
|
||||
guint64 next_ts;
|
||||
gint rate;
|
||||
};
|
||||
|
||||
struct _GstGSMEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstGSMEncClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement * element);
|
||||
};
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement *element);
|
||||
};
|
||||
|
||||
GType gst_gsmenc_get_type (void);
|
||||
GType gst_gsmenc_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_GSMENC_H__ */
|
||||
#endif /* __GST_GSMENC_H__ */
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
#include <tremor/ivorbiscodec.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_VORBISENC \
|
||||
(vorbisenc_get_type())
|
||||
|
@ -42,61 +41,60 @@ extern "C"
|
|||
#define GST_IS_VORBISENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_VORBISENC))
|
||||
|
||||
typedef struct _VorbisEnc VorbisEnc;
|
||||
typedef struct _VorbisEncClass VorbisEncClass;
|
||||
typedef struct _VorbisEnc VorbisEnc;
|
||||
typedef struct _VorbisEncClass VorbisEncClass;
|
||||
|
||||
struct _VorbisEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _VorbisEnc {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,
|
||||
*srcpad;
|
||||
|
||||
ogg_stream_state os; /* take physical pages, weld into a logical
|
||||
stream of packets */
|
||||
ogg_page og; /* one Ogg bitstream page. Vorbis packets are inside */
|
||||
ogg_packet op; /* one raw packet of data for decode */
|
||||
ogg_stream_state os; /* take physical pages, weld into a logical
|
||||
stream of packets */
|
||||
ogg_page og; /* one Ogg bitstream page. Vorbis packets are inside */
|
||||
ogg_packet op; /* one raw packet of data for decode */
|
||||
|
||||
vorbis_info vi; /* struct that stores all the static vorbis bitstream
|
||||
settings */
|
||||
vorbis_comment vc; /* struct that stores all the user comments */
|
||||
vorbis_info vi; /* struct that stores all the static vorbis bitstream
|
||||
settings */
|
||||
vorbis_comment vc; /* struct that stores all the user comments */
|
||||
|
||||
vorbis_dsp_state vd; /* central working state for the packet->PCM decoder */
|
||||
vorbis_block vb; /* local working space for packet->PCM decode */
|
||||
vorbis_dsp_state vd; /* central working state for the packet->PCM decoder */
|
||||
vorbis_block vb; /* local working space for packet->PCM decode */
|
||||
|
||||
gboolean eos;
|
||||
gboolean eos;
|
||||
|
||||
gboolean managed;
|
||||
gint bitrate;
|
||||
gint min_bitrate;
|
||||
gint max_bitrate;
|
||||
gfloat quality;
|
||||
gboolean quality_set;
|
||||
gint serial;
|
||||
gboolean managed;
|
||||
gint bitrate;
|
||||
gint min_bitrate;
|
||||
gint max_bitrate;
|
||||
gfloat quality;
|
||||
gboolean quality_set;
|
||||
gint serial;
|
||||
|
||||
gint channels;
|
||||
gint frequency;
|
||||
gint channels;
|
||||
gint frequency;
|
||||
|
||||
guint64 samples_in;
|
||||
guint64 bytes_out;
|
||||
guint64 samples_in;
|
||||
guint64 bytes_out;
|
||||
|
||||
GstCaps *metadata;
|
||||
GstCaps *metadata;
|
||||
|
||||
gboolean setup;
|
||||
gboolean flush_header;
|
||||
gchar *last_message;
|
||||
};
|
||||
gboolean setup;
|
||||
gboolean flush_header;
|
||||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _VorbisEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _VorbisEncClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType vorbisenc_get_type (void);
|
||||
GType vorbisenc_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __VORBISENC_H__ */
|
||||
#endif /* __VORBISENC_H__ */
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
#define GST_IS_JACK_BIN_CLASS(klass) G_TYPE_CHECK_CLASS_TYPE(klass, GST_TYPE_JACK_BIN)
|
||||
#define GST_TYPE_JACK_BIN gst_jack_bin_get_type()
|
||||
|
||||
#define GST_JACK_PAD(l) ((GstJackPad*)l->data) /* l is a GList */
|
||||
#define GST_JACK_PAD(l) ((GstJackPad*)l->data) /* l is a GList */
|
||||
|
||||
|
||||
typedef struct _GstJack GstJack;
|
||||
|
@ -64,65 +64,59 @@ typedef GstJack GstJackSrc;
|
|||
typedef GstJackClass GstJackSrcClass;
|
||||
|
||||
|
||||
enum
|
||||
{
|
||||
GST_JACK_OPEN = GST_BIN_FLAG_LAST,
|
||||
GST_JACK_ACTIVE,
|
||||
GST_JACK_FLAG_LAST = GST_BIN_FLAG_LAST + 3,
|
||||
enum {
|
||||
GST_JACK_OPEN = GST_BIN_FLAG_LAST,
|
||||
GST_JACK_ACTIVE,
|
||||
GST_JACK_FLAG_LAST = GST_BIN_FLAG_LAST + 3,
|
||||
};
|
||||
|
||||
|
||||
typedef jack_default_audio_sample_t sample_t;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
GstPad *pad;
|
||||
void *data;
|
||||
const gchar *name;
|
||||
const gchar *peer_name;
|
||||
jack_port_t *port;
|
||||
typedef struct {
|
||||
GstPad *pad;
|
||||
void *data;
|
||||
const gchar *name;
|
||||
const gchar *peer_name;
|
||||
jack_port_t *port;
|
||||
} GstJackPad;
|
||||
|
||||
struct _GstJack
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstJack {
|
||||
GstElement element;
|
||||
|
||||
/* list of GstJackPads */
|
||||
GList *pads;
|
||||
/* list of GstJackPads */
|
||||
GList *pads;
|
||||
|
||||
/* for convenience */
|
||||
GstPadDirection direction;
|
||||
/* for convenience */
|
||||
GstPadDirection direction;
|
||||
|
||||
gchar *port_name_prefix;
|
||||
gchar *port_name_prefix;
|
||||
|
||||
GstJackBin *bin;
|
||||
GstJackBin *bin;
|
||||
};
|
||||
|
||||
struct _GstJackClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstJackClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
struct _GstJackBin
|
||||
{
|
||||
GstBin bin;
|
||||
struct _GstJackBin {
|
||||
GstBin bin;
|
||||
|
||||
jack_client_t *client;
|
||||
gint default_new_port_number;
|
||||
jack_client_t *client;
|
||||
gint default_new_port_number;
|
||||
|
||||
/* lists of GstJackPads */
|
||||
GList *sink_pads;
|
||||
GList *src_pads;
|
||||
/* lists of GstJackPads */
|
||||
GList *sink_pads;
|
||||
GList *src_pads;
|
||||
|
||||
gchar *client_name;
|
||||
gchar *client_name;
|
||||
|
||||
guint rate;
|
||||
jack_nframes_t nframes;
|
||||
guint rate;
|
||||
jack_nframes_t nframes;
|
||||
};
|
||||
|
||||
struct _GstJackBinClass
|
||||
{
|
||||
GstBinClass parent_class;
|
||||
struct _GstJackBinClass {
|
||||
GstBinClass parent_class;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -31,60 +31,62 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
typedef struct _ladspa_control_info
|
||||
{
|
||||
gchar *name;
|
||||
gchar *param_name;
|
||||
gfloat lowerbound, upperbound;
|
||||
gfloat def;
|
||||
gboolean lower, upper, samplerate;
|
||||
gboolean toggled, logarithmic, integer, writable;
|
||||
} ladspa_control_info;
|
||||
typedef struct _ladspa_control_info {
|
||||
gchar *name;
|
||||
gchar *param_name;
|
||||
gfloat lowerbound, upperbound;
|
||||
gfloat def;
|
||||
gboolean lower,upper,samplerate;
|
||||
gboolean toggled, logarithmic, integer, writable;
|
||||
} ladspa_control_info;
|
||||
|
||||
typedef struct _GstLADSPA GstLADSPA;
|
||||
typedef struct _GstLADSPAClass GstLADSPAClass;
|
||||
typedef struct _GstLADSPA GstLADSPA;
|
||||
typedef struct _GstLADSPAClass GstLADSPAClass;
|
||||
|
||||
struct _GstLADSPA
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstLADSPA {
|
||||
GstElement element;
|
||||
|
||||
LADSPA_Descriptor *descriptor;
|
||||
LADSPA_Handle *handle;
|
||||
LADSPA_Descriptor *descriptor;
|
||||
LADSPA_Handle *handle;
|
||||
|
||||
GstDParamManager *dpman;
|
||||
GstDParamManager *dpman;
|
||||
|
||||
gfloat *controls;
|
||||
gfloat *controls;
|
||||
|
||||
GstPad **sinkpads,
|
||||
**srcpads;
|
||||
|
||||
GstPad **sinkpads, **srcpads;
|
||||
gboolean activated;
|
||||
|
||||
gboolean activated;
|
||||
gint samplerate, buffer_frames;
|
||||
gint64 timestamp;
|
||||
gboolean inplace_broken;
|
||||
};
|
||||
|
||||
gint samplerate, buffer_frames;
|
||||
gint64 timestamp;
|
||||
gboolean inplace_broken;
|
||||
};
|
||||
struct _GstLADSPAClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
struct _GstLADSPAClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
LADSPA_Descriptor *descriptor;
|
||||
|
||||
LADSPA_Descriptor *descriptor;
|
||||
gint numports,
|
||||
numsinkpads,
|
||||
numsrcpads,
|
||||
numcontrols;
|
||||
|
||||
gint numports, numsinkpads, numsrcpads, numcontrols;
|
||||
gint *sinkpad_portnums,
|
||||
*srcpad_portnums,
|
||||
*control_portnums;
|
||||
|
||||
gint *sinkpad_portnums, *srcpad_portnums, *control_portnums;
|
||||
|
||||
ladspa_control_info *control_info;
|
||||
};
|
||||
ladspa_control_info *control_info;
|
||||
};
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_LADSPA_H__ */
|
||||
#endif /* __GST_LADSPA_H__ */
|
||||
|
|
|
@ -20,19 +20,20 @@
|
|||
unloadLADSPAPluginLibrary(). Errors are handled by writing a
|
||||
message to stderr and calling exit(1). It is alright (although
|
||||
inefficient) to call this more than once for the same file. */
|
||||
void *loadLADSPAPluginLibrary (const char *pcPluginFilename);
|
||||
void * loadLADSPAPluginLibrary(const char * pcPluginFilename);
|
||||
|
||||
/* This function unloads a LADSPA plugin library. */
|
||||
void unloadLADSPAPluginLibrary (void *pvLADSPAPluginLibrary);
|
||||
void unloadLADSPAPluginLibrary(void * pvLADSPAPluginLibrary);
|
||||
|
||||
/* This function locates a LADSPA plugin within a plugin library
|
||||
loaded with loadLADSPAPluginLibrary(). Errors are handled by
|
||||
writing a message to stderr and calling exit(1). Note that the
|
||||
plugin library filename is only included to help provide
|
||||
informative error messages. */
|
||||
const LADSPA_Descriptor *findLADSPAPluginDescriptor (void
|
||||
*pvLADSPAPluginLibrary, const char *pcPluginLibraryFilename,
|
||||
const char *pcPluginLabel);
|
||||
const LADSPA_Descriptor *
|
||||
findLADSPAPluginDescriptor(void * pvLADSPAPluginLibrary,
|
||||
const char * pcPluginLibraryFilename,
|
||||
const char * pcPluginLabel);
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
|
@ -43,15 +44,16 @@ const LADSPA_Descriptor *findLADSPAPluginDescriptor (void
|
|||
style) and a LADSPA_DescriptorFunction (from which
|
||||
LADSPA_Descriptors can be acquired). */
|
||||
typedef void LADSPAPluginSearchCallbackFunction
|
||||
(const char *pcFullFilename,
|
||||
void *pvPluginHandle, LADSPA_Descriptor_Function fDescriptorFunction);
|
||||
(const char * pcFullFilename,
|
||||
void * pvPluginHandle,
|
||||
LADSPA_Descriptor_Function fDescriptorFunction);
|
||||
|
||||
/* Search through the $(LADSPA_PATH) (or a default path) for any
|
||||
LADSPA plugin libraries. Each plugin library is tested using
|
||||
dlopen() and dlsym(,"ladspa_descriptor"). After loading each
|
||||
library, the callback function is called to process it. This
|
||||
function leaves items passed to the callback function open. */
|
||||
void LADSPAPluginSearch (LADSPAPluginSearchCallbackFunction fCallbackFunction);
|
||||
void LADSPAPluginSearch(LADSPAPluginSearchCallbackFunction fCallbackFunction);
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
|
|
|
@ -25,9 +25,8 @@
|
|||
#include <fame.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_FAMEENC \
|
||||
|
@ -41,50 +40,48 @@ extern "C"
|
|||
#define GST_IS_FAMEENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FAMEENC))
|
||||
|
||||
typedef struct _GstFameEnc GstFameEnc;
|
||||
typedef struct _GstFameEncClass GstFameEncClass;
|
||||
typedef struct _GstFameEnc GstFameEnc;
|
||||
typedef struct _GstFameEncClass GstFameEncClass;
|
||||
|
||||
struct _GstFameEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstFameEnc {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
/* the timestamp of the next frame */
|
||||
guint64 next_time;
|
||||
/* the interval between frames */
|
||||
guint64 time_interval;
|
||||
/* the timestamp of the next frame */
|
||||
guint64 next_time;
|
||||
/* the interval between frames */
|
||||
guint64 time_interval;
|
||||
|
||||
/* video state */
|
||||
gint format;
|
||||
/* the size of the output buffer */
|
||||
gint outsize;
|
||||
/* video state */
|
||||
gint format;
|
||||
/* the size of the output buffer */
|
||||
gint outsize;
|
||||
|
||||
/* encoding pattern string */
|
||||
gchar *pattern;
|
||||
/* encoding pattern string */
|
||||
gchar *pattern;
|
||||
|
||||
/* fameenc stuff */
|
||||
gboolean verbose;
|
||||
fame_context_t *fc;
|
||||
fame_parameters_t fp;
|
||||
fame_yuv_t fy;
|
||||
gulong buffer_size;
|
||||
unsigned char *buffer;
|
||||
gboolean initialized;
|
||||
};
|
||||
/* fameenc stuff */
|
||||
gboolean verbose;
|
||||
fame_context_t *fc;
|
||||
fame_parameters_t fp;
|
||||
fame_yuv_t fy;
|
||||
gulong buffer_size;
|
||||
unsigned char *buffer;
|
||||
gboolean initialized;
|
||||
};
|
||||
|
||||
struct _GstFameEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstFameEncClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_fameenc_get_type (void);
|
||||
GType gst_fameenc_get_type (void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_FAMEENC_H__ */
|
||||
#endif /* __GST_FAMEENC_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <musicbrainz/mb_c.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MUSICBRAINZ \
|
||||
|
@ -43,43 +42,41 @@ extern "C"
|
|||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MUSICBRAINZ))
|
||||
|
||||
|
||||
typedef struct _GstMusicBrainz GstMusicBrainz;
|
||||
typedef struct _GstMusicBrainzClass GstMusicBrainzClass;
|
||||
typedef struct _GstMusicBrainz GstMusicBrainz;
|
||||
typedef struct _GstMusicBrainzClass GstMusicBrainzClass;
|
||||
|
||||
struct _GstMusicBrainz
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMusicBrainz {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
GstPad *srcpad;
|
||||
const GstCaps *caps;
|
||||
GstPad *sinkpad;
|
||||
GstPad *srcpad;
|
||||
const GstCaps *caps;
|
||||
|
||||
trm_t trm;
|
||||
gchar signature[17];
|
||||
gchar ascii_signature[37];
|
||||
trm_t trm;
|
||||
gchar signature[17];
|
||||
gchar ascii_signature[37];
|
||||
|
||||
guint depth;
|
||||
guint rate;
|
||||
guint channels;
|
||||
gboolean linked;
|
||||
gboolean data_available;
|
||||
gboolean signature_available;
|
||||
guint64 total_time;
|
||||
};
|
||||
guint depth;
|
||||
guint rate;
|
||||
guint channels;
|
||||
gboolean linked;
|
||||
gboolean data_available;
|
||||
gboolean signature_available;
|
||||
guint64 total_time;
|
||||
};
|
||||
|
||||
struct _GstMusicBrainzClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstMusicBrainzClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*signature_available) (GstElement * element);
|
||||
};
|
||||
/* signals */
|
||||
void (*signature_available) (GstElement *element);
|
||||
};
|
||||
|
||||
GType gst_musicbrainz_get_type (void);
|
||||
GType gst_musicbrainz_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_MUSICBRAINZE_H__ */
|
||||
#endif /* __GST_MUSICBRAINZE_H__ */
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_NASSINK \
|
||||
|
@ -40,54 +39,51 @@ extern "C"
|
|||
#define GST_IS_NASSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_NASSINK))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_NASSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_NASSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2
|
||||
} GstNasSinkFlags;
|
||||
typedef enum {
|
||||
GST_NASSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_NASSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST+2
|
||||
} GstNasSinkFlags;
|
||||
|
||||
typedef struct _GstNassink GstNassink;
|
||||
typedef struct _GstNassinkClass GstNassinkClass;
|
||||
typedef struct _GstNassink GstNassink;
|
||||
typedef struct _GstNassinkClass GstNassinkClass;
|
||||
|
||||
struct _GstNassink
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstNassink {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
GstPad *sinkpad;
|
||||
|
||||
/* instance properties */
|
||||
/* instance properties */
|
||||
|
||||
gboolean mute;
|
||||
gint depth;
|
||||
gint tracks;
|
||||
gint rate;
|
||||
gchar *host;
|
||||
gboolean mute;
|
||||
gint depth;
|
||||
gint tracks;
|
||||
gint rate;
|
||||
gchar* host;
|
||||
|
||||
/* Server info */
|
||||
/* Server info */
|
||||
|
||||
AuServer *audio;
|
||||
AuFlowID flow;
|
||||
AuDeviceID device;
|
||||
AuServer *audio;
|
||||
AuFlowID flow;
|
||||
AuDeviceID device;
|
||||
|
||||
/* buffer */
|
||||
/* buffer */
|
||||
|
||||
AuUint32 size;
|
||||
AuUint32 pos;
|
||||
AuUint32 size;
|
||||
AuUint32 pos;
|
||||
|
||||
char *buf;
|
||||
};
|
||||
char *buf;
|
||||
};
|
||||
|
||||
struct _GstNassinkClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstNassinkClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_nassink_get_type (void);
|
||||
GType gst_nassink_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_NASSINK_H__ */
|
||||
#endif /* __GST_NASSINK_H__ */
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <SDL.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_SDLVIDEOSINK \
|
||||
(gst_sdlvideosink_get_type())
|
||||
#define GST_SDLVIDEOSINK(obj) \
|
||||
|
@ -35,9 +36,9 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SDLVIDEOSINK))
|
||||
#define GST_IS_SDLVIDEOSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SDLVIDEOSINK))
|
||||
typedef enum
|
||||
{
|
||||
GST_SDLVIDEOSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
typedef enum {
|
||||
GST_SDLVIDEOSINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_SDLVIDEOSINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstSDLVideoSinkFlags;
|
||||
|
@ -45,12 +46,11 @@ G_BEGIN_DECLS
|
|||
typedef struct _GstSDLVideoSink GstSDLVideoSink;
|
||||
typedef struct _GstSDLVideoSinkClass GstSDLVideoSinkClass;
|
||||
|
||||
struct _GstSDLVideoSink
|
||||
{
|
||||
struct _GstSDLVideoSink {
|
||||
GstVideoSink videosink;
|
||||
|
||||
guint32 format;
|
||||
gint width, height; /* the size of the incoming YUV stream */
|
||||
gint width, height; /* the size of the incoming YUV stream */
|
||||
unsigned long xwindow_id;
|
||||
|
||||
gboolean init;
|
||||
|
@ -62,13 +62,13 @@ struct _GstSDLVideoSink
|
|||
GMutex *lock;
|
||||
};
|
||||
|
||||
struct _GstSDLVideoSinkClass
|
||||
{
|
||||
struct _GstSDLVideoSinkClass {
|
||||
GstVideoSinkClass parent_class;
|
||||
|
||||
};
|
||||
|
||||
GType gst_sdlsink_get_type (void);
|
||||
GType gst_sdlsink_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SDLVIDEOSINK_H__ */
|
||||
|
|
|
@ -25,43 +25,40 @@
|
|||
#include <shout/shout.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/* Definition of structure storing data for this element. */
|
||||
typedef struct _GstIcecastSend GstIcecastSend;
|
||||
struct _GstIcecastSend
|
||||
{
|
||||
GstElement element;
|
||||
typedef struct _GstIcecastSend GstIcecastSend;
|
||||
struct _GstIcecastSend {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
shout_conn_t conn;
|
||||
shout_conn_t conn;
|
||||
|
||||
gchar *ip;
|
||||
guint port;
|
||||
gchar *password;
|
||||
gboolean public;
|
||||
gchar *name;
|
||||
gchar *description;
|
||||
gchar *genre;
|
||||
gchar *mount;
|
||||
gchar *dumpfile;
|
||||
gboolean icy;
|
||||
gchar *aim;
|
||||
gchar *icq;
|
||||
gchar *irc;
|
||||
gchar *ip;
|
||||
guint port;
|
||||
gchar *password;
|
||||
gboolean public;
|
||||
gchar *name;
|
||||
gchar *description;
|
||||
gchar *genre;
|
||||
gchar *mount;
|
||||
gchar *dumpfile;
|
||||
gboolean icy;
|
||||
gchar *aim;
|
||||
gchar *icq;
|
||||
gchar *irc;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
/* Standard definition defining a class for this element. */
|
||||
typedef struct _GstIcecastSendClass GstIcecastSendClass;
|
||||
struct _GstIcecastSendClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
typedef struct _GstIcecastSendClass GstIcecastSendClass;
|
||||
struct _GstIcecastSendClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
/* Standard macros for defining types for this element. */
|
||||
#define GST_TYPE_ICECASTSEND \
|
||||
|
@ -76,12 +73,12 @@ extern "C"
|
|||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ICECASTSEND))
|
||||
|
||||
/* Standard function returning type information. */
|
||||
GType gst_icecastsend_get_type (void);
|
||||
GType gst_icecastsend_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_ICECASTSEND_H__ */
|
||||
#endif /* __GST_ICECASTSEND_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <gtk/gtk.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SMOOTHWAVE \
|
||||
|
@ -42,33 +41,31 @@ extern "C"
|
|||
#define GST_IS_SMOOTHWAVE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SMOOTHWAVE))
|
||||
|
||||
typedef struct _GstSmoothWave GstSmoothWave;
|
||||
typedef struct _GstSmoothWaveClass GstSmoothWaveClass;
|
||||
typedef struct _GstSmoothWave GstSmoothWave;
|
||||
typedef struct _GstSmoothWaveClass GstSmoothWaveClass;
|
||||
|
||||
struct _GstSmoothWave
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSmoothWave {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gint width, height;
|
||||
gint width,height;
|
||||
|
||||
GdkRgbCmap *cmap;
|
||||
GtkWidget *image;
|
||||
guchar *imagebuffer;
|
||||
};
|
||||
GdkRgbCmap *cmap;
|
||||
GtkWidget *image;
|
||||
guchar *imagebuffer;
|
||||
};
|
||||
|
||||
struct _GstSmoothWaveClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstSmoothWaveClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_smoothwave_get_type (void);
|
||||
GType gst_smoothwave_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_SMOOTHWAVE_H__ */
|
||||
#endif /* __GST_SMOOTHWAVE_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <png.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SNAPSHOT \
|
||||
|
@ -42,38 +41,36 @@ extern "C"
|
|||
#define GST_IS_SNAPSHOT_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SNAPSHOT))
|
||||
|
||||
typedef struct _GstSnapshot GstSnapshot;
|
||||
typedef struct _GstSnapshotClass GstSnapshotClass;
|
||||
typedef struct _GstSnapshot GstSnapshot;
|
||||
typedef struct _GstSnapshotClass GstSnapshotClass;
|
||||
|
||||
struct _GstSnapshot
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSnapshot {
|
||||
GstElement element;
|
||||
|
||||
guint32 format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint to_bpp;
|
||||
glong frame;
|
||||
glong cur_frame;
|
||||
const gchar *location;
|
||||
gboolean snapshot_asked;
|
||||
guint32 format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint to_bpp;
|
||||
glong frame;
|
||||
glong cur_frame;
|
||||
const gchar *location;
|
||||
gboolean snapshot_asked;
|
||||
|
||||
png_structp png_struct_ptr;
|
||||
png_infop png_info_ptr;
|
||||
png_structp png_struct_ptr;
|
||||
png_infop png_info_ptr;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
};
|
||||
GstPad *sinkpad,*srcpad;
|
||||
};
|
||||
|
||||
struct _GstSnapshotClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstSnapshotClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
void (*snapshot) (GstElement * elem);
|
||||
};
|
||||
void (*snapshot) (GstElement *elem);
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_SNAPSHOT_H__ */
|
||||
#endif /* __GST_SNAPSHOT_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_SF \
|
||||
(gst_sf_get_type())
|
||||
#define GST_SF(obj) \
|
||||
|
@ -37,6 +39,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SF))
|
||||
#define GST_IS_SF_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SF))
|
||||
|
||||
#define GST_TYPE_SFSRC \
|
||||
(gst_sfsrc_get_type())
|
||||
#define GST_SFSRC(obj) \
|
||||
|
@ -47,6 +50,7 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SFSRC))
|
||||
#define GST_IS_SFSRC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SFSRC))
|
||||
|
||||
#define GST_TYPE_SFSINK \
|
||||
(gst_sfsink_get_type())
|
||||
#define GST_SFSINK(obj) \
|
||||
|
@ -57,17 +61,16 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SFSINK))
|
||||
#define GST_IS_SFSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SFSINK))
|
||||
|
||||
typedef struct _GstSF GstSF;
|
||||
typedef struct _GstSFClass GstSFClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_SF_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_SF_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
typedef enum {
|
||||
GST_SF_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
GST_SF_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstSFlags;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
GstPad *pad;
|
||||
gint num;
|
||||
gboolean caps_set;
|
||||
|
@ -75,8 +78,7 @@ typedef struct
|
|||
|
||||
#define GST_SF_CHANNEL(l) ((GstSFChannel*)l->data)
|
||||
|
||||
struct _GstSF
|
||||
{
|
||||
struct _GstSF {
|
||||
GstElement element;
|
||||
GList *channels;
|
||||
|
||||
|
@ -100,15 +102,16 @@ struct _GstSF
|
|||
guint64 time;
|
||||
};
|
||||
|
||||
struct _GstSFClass
|
||||
{
|
||||
struct _GstSFClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_sf_get_type (void);
|
||||
GType gst_sfsrc_get_type (void);
|
||||
GType gst_sfsink_get_type (void);
|
||||
GType gst_sf_get_type (void);
|
||||
GType gst_sfsrc_get_type (void);
|
||||
GType gst_sfsink_get_type (void);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_SFSINK_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <swfdec.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SWFDEC \
|
||||
|
@ -42,49 +41,47 @@ extern "C"
|
|||
#define GST_IS_SWFDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SWFDEC))
|
||||
|
||||
typedef struct _GstSwfdec GstSwfdec;
|
||||
typedef struct _GstSwfdecClass GstSwfdecClass;
|
||||
typedef struct _GstSwfdec GstSwfdec;
|
||||
typedef struct _GstSwfdecClass GstSwfdecClass;
|
||||
|
||||
struct _GstSwfdec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSwfdec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
GstPad *videopad;
|
||||
GstPad *audiopad;
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
GstPad *videopad;
|
||||
GstPad *audiopad;
|
||||
|
||||
SwfdecDecoder *state;
|
||||
gboolean closed;
|
||||
SwfdecDecoder *state;
|
||||
gboolean closed;
|
||||
|
||||
/* the timestamp of the next frame */
|
||||
gboolean first;
|
||||
gboolean have_format;
|
||||
/* the timestamp of the next frame */
|
||||
gboolean first;
|
||||
gboolean have_format;
|
||||
|
||||
double rate;
|
||||
gint64 timestamp;
|
||||
gint64 interval;
|
||||
double frame_rate;
|
||||
double rate;
|
||||
gint64 timestamp;
|
||||
gint64 interval;
|
||||
double frame_rate;
|
||||
|
||||
/* video state */
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint64 total_frames;
|
||||
/* video state */
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint64 total_frames;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
struct _GstSwfdecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstSwfdecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_swfdec_get_type (void);
|
||||
GType gst_swfdec_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_SWFDEC_H__ */
|
||||
#endif /* __GST_SWFDEC_H__ */
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
#define ENTROPY_ENCODER_FLUSH(coder) bitcoder_flush(coder)
|
||||
#define ENTROPY_DECODER_INIT(coder,bitstream,limit) \
|
||||
bitcoder_decoder_init(coder,bitstream,limit)
|
||||
#define ENTROPY_DECODER_DONE(coder) /* nothing to do ... */
|
||||
#define ENTROPY_DECODER_DONE(coder) /* nothing to do ... */
|
||||
#define ENTROPY_CODER_BITSTREAM(coder) (coder)->bitstream
|
||||
|
||||
#define ENTROPY_CODER_SYMBOL(coder) 1
|
||||
|
@ -25,107 +25,106 @@
|
|||
#endif
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int32_t bit_count; /* number of valid bits in byte */
|
||||
uint8_t byte; /* buffer to save bits */
|
||||
uint32_t byte_count; /* number of bytes written */
|
||||
uint8_t *bitstream;
|
||||
uint32_t limit; /* don't write more bytes to bitstream ... */
|
||||
int eos; /* end of stream reached */
|
||||
typedef struct {
|
||||
int32_t bit_count; /* number of valid bits in byte */
|
||||
uint8_t byte; /* buffer to save bits */
|
||||
uint32_t byte_count; /* number of bytes written */
|
||||
uint8_t *bitstream;
|
||||
uint32_t limit; /* don't write more bytes to bitstream ... */
|
||||
int eos; /* end of stream reached */
|
||||
} BitCoderState;
|
||||
|
||||
|
||||
|
||||
static inline void
|
||||
bitcoder_encoder_init (BitCoderState * s, uint32_t limit)
|
||||
static inline
|
||||
void bitcoder_encoder_init (BitCoderState *s, uint32_t limit)
|
||||
{
|
||||
s->bit_count = 0;
|
||||
s->byte = 0;
|
||||
s->byte_count = 0;
|
||||
s->bitstream = (uint8_t *) MALLOC (limit);
|
||||
s->limit = limit;
|
||||
s->eos = 0;
|
||||
s->bit_count = 0;
|
||||
s->byte = 0;
|
||||
s->byte_count = 0;
|
||||
s->bitstream = (uint8_t*) MALLOC (limit);
|
||||
s->limit = limit;
|
||||
s->eos = 0;
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
bitcoder_encoder_done (BitCoderState * s)
|
||||
static inline
|
||||
void bitcoder_encoder_done (BitCoderState *s)
|
||||
{
|
||||
FREE (s->bitstream);
|
||||
FREE (s->bitstream);
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
bitcoder_decoder_init (BitCoderState * s, uint8_t * bitstream, uint32_t limit)
|
||||
static inline
|
||||
void bitcoder_decoder_init (BitCoderState *s, uint8_t *bitstream, uint32_t limit)
|
||||
{
|
||||
s->bit_count = -1;
|
||||
s->byte = 0;
|
||||
s->byte_count = 0;
|
||||
s->bitstream = bitstream;
|
||||
s->limit = limit;
|
||||
s->eos = 0;
|
||||
s->bit_count = -1;
|
||||
s->byte = 0;
|
||||
s->byte_count = 0;
|
||||
s->bitstream = bitstream;
|
||||
s->limit = limit;
|
||||
s->eos = 0;
|
||||
}
|
||||
|
||||
|
||||
static inline uint32_t
|
||||
bitcoder_flush (BitCoderState * s)
|
||||
static inline
|
||||
uint32_t bitcoder_flush (BitCoderState *s)
|
||||
{
|
||||
if (s->bit_count > 0 && s->byte_count < s->limit)
|
||||
s->bitstream[s->byte_count++] = s->byte << (8 - s->bit_count);
|
||||
if (s->bit_count > 0 && s->byte_count < s->limit)
|
||||
s->bitstream [s->byte_count++] = s->byte << (8 - s->bit_count);
|
||||
|
||||
/*printf ("%s: %i bytes written.\n", __FUNCTION__, s->byte_count); */
|
||||
/*printf ("%s: last bit %i\n", __FUNCTION__, s->bit_count); */
|
||||
return s->byte_count;
|
||||
return s->byte_count;
|
||||
}
|
||||
|
||||
|
||||
|
||||
static inline void
|
||||
bitcoder_write_bit (BitCoderState * s, int bit)
|
||||
static inline
|
||||
void bitcoder_write_bit (BitCoderState *s, int bit)
|
||||
{
|
||||
s->byte <<= 1;
|
||||
s->byte |= bit & 1;
|
||||
s->byte <<= 1;
|
||||
s->byte |= bit & 1;
|
||||
|
||||
s->bit_count++;
|
||||
s->bit_count++;
|
||||
|
||||
if (s->bit_count == 8) {
|
||||
if (s->byte_count < s->limit) {
|
||||
s->bitstream[s->byte_count++] = s->byte;
|
||||
s->bit_count = 0;
|
||||
} else {
|
||||
s->eos = 1;
|
||||
}
|
||||
}
|
||||
if (s->bit_count == 8) {
|
||||
if (s->byte_count < s->limit) {
|
||||
s->bitstream [s->byte_count++] = s->byte;
|
||||
s->bit_count = 0;
|
||||
} else {
|
||||
s->eos = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static inline int
|
||||
bitcoder_read_bit (BitCoderState * s)
|
||||
static inline
|
||||
int bitcoder_read_bit (BitCoderState *s)
|
||||
{
|
||||
int ret;
|
||||
int ret;
|
||||
|
||||
if (s->bit_count <= 0) {
|
||||
if (!s->bitstream) {
|
||||
s->eos = 1;
|
||||
return 0;
|
||||
}
|
||||
if (s->bit_count <= 0) {
|
||||
if (!s->bitstream) {
|
||||
s->eos = 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (s->byte_count < s->limit) {
|
||||
s->byte = s->bitstream[s->byte_count++];
|
||||
} else {
|
||||
s->eos = 1;
|
||||
s->byte = 0;
|
||||
}
|
||||
if (s->byte_count < s->limit) {
|
||||
s->byte = s->bitstream [s->byte_count++];
|
||||
} else {
|
||||
s->eos = 1;
|
||||
s->byte = 0;
|
||||
}
|
||||
|
||||
s->bit_count = 8;
|
||||
}
|
||||
s->bit_count = 8;
|
||||
}
|
||||
|
||||
ret = s->byte >> 7;
|
||||
s->byte <<= 1;
|
||||
s->bit_count--;
|
||||
ret = s->byte >> 7;
|
||||
s->byte <<= 1;
|
||||
s->bit_count--;
|
||||
|
||||
return ret & 1;
|
||||
return ret & 1;
|
||||
}
|
||||
|
||||
|
||||
|
@ -133,16 +132,17 @@ bitcoder_read_bit (BitCoderState * s)
|
|||
|
||||
|
||||
|
||||
static inline void
|
||||
bit_print (TYPE byte)
|
||||
static inline
|
||||
void bit_print (TYPE byte)
|
||||
{
|
||||
int bit = 8 * sizeof (TYPE);
|
||||
int bit = 8*sizeof(TYPE);
|
||||
|
||||
do {
|
||||
bit--;
|
||||
printf ((byte & (1 << bit)) ? "1" : "0");
|
||||
} while (bit);
|
||||
printf ("\n");
|
||||
do {
|
||||
bit--;
|
||||
printf ((byte & (1 << bit)) ? "1" : "0");
|
||||
} while (bit);
|
||||
printf ("\n");
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -5,126 +5,128 @@
|
|||
#include "bitcoder.h"
|
||||
|
||||
|
||||
static inline unsigned int
|
||||
required_bits (unsigned int x)
|
||||
static inline
|
||||
unsigned int required_bits (unsigned int x)
|
||||
{
|
||||
int bits = 31;
|
||||
int bits = 31;
|
||||
|
||||
while ((x & (1 << bits)) == 0 && bits)
|
||||
bits--;
|
||||
while ((x & (1 << bits)) == 0 && bits)
|
||||
bits--;
|
||||
|
||||
return bits;
|
||||
return bits;
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
write_number_binary (BitCoderState * b, unsigned int x, int bits, int u)
|
||||
static inline
|
||||
void write_number_binary (BitCoderState *b, unsigned int x, int bits, int u)
|
||||
{
|
||||
/*printf ("wrote %i with %i bits (%i+%i)\n", x, u+bits, u, bits); */
|
||||
while (bits) {
|
||||
bits--;
|
||||
bitcoder_write_bit (b, (x >> bits) & 1);
|
||||
}
|
||||
while (bits) {
|
||||
bits--;
|
||||
bitcoder_write_bit (b, (x >> bits) & 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static inline unsigned int
|
||||
read_number_binary (BitCoderState * b, int bits)
|
||||
static inline
|
||||
unsigned int read_number_binary (BitCoderState *b, int bits)
|
||||
{
|
||||
unsigned int x = 0;
|
||||
unsigned int x = 0;
|
||||
|
||||
while (bits) {
|
||||
bits--;
|
||||
x |= bitcoder_read_bit (b) << bits;
|
||||
}
|
||||
while (bits) {
|
||||
bits--;
|
||||
x |= bitcoder_read_bit (b) << bits;
|
||||
}
|
||||
|
||||
return x;
|
||||
return x;
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
golomb_write_number (BitCoderState * b, unsigned int x, int bits)
|
||||
static inline
|
||||
void golomb_write_number (BitCoderState *b, unsigned int x, int bits)
|
||||
{
|
||||
unsigned int q, r;
|
||||
int i = 0;
|
||||
unsigned int q, r;
|
||||
int i = 0;
|
||||
|
||||
assert (x > 0);
|
||||
assert (x > 0);
|
||||
|
||||
while ((q = (x - 1) >> bits) > 0) {
|
||||
bitcoder_write_bit (b, 1); /* fast temporary adaption, write */
|
||||
bits++; /* unary representation of q */
|
||||
i++;
|
||||
};
|
||||
while ((q = (x - 1) >> bits) > 0) {
|
||||
bitcoder_write_bit (b, 1); /* fast temporary adaption, write */
|
||||
bits++; /* unary representation of q */
|
||||
i++;
|
||||
};
|
||||
|
||||
bitcoder_write_bit (b, 0);
|
||||
bitcoder_write_bit (b, 0);
|
||||
|
||||
r = x - 1 - (q << bits);
|
||||
r = x - 1 - (q << bits);
|
||||
|
||||
write_number_binary (b, r, bits, i + 1);
|
||||
write_number_binary (b, r, bits, i+1);
|
||||
}
|
||||
|
||||
|
||||
static inline unsigned int
|
||||
golomb_read_number (BitCoderState * b, int bits)
|
||||
static inline
|
||||
unsigned int golomb_read_number (BitCoderState *b, int bits)
|
||||
{
|
||||
unsigned int q = 0, r, x;
|
||||
unsigned int q = 0, r, x;
|
||||
|
||||
while (bitcoder_read_bit (b) != 0) {
|
||||
bits++;
|
||||
}
|
||||
while (bitcoder_read_bit (b) != 0) {
|
||||
bits++;
|
||||
}
|
||||
|
||||
r = read_number_binary (b, bits);
|
||||
x = (q << bits) + r + 1;
|
||||
r = read_number_binary (b, bits);
|
||||
x = (q << bits) + r + 1;
|
||||
|
||||
return x;
|
||||
return x;
|
||||
}
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint8_t count;
|
||||
uint8_t bits; /* a 5.3 fixed point integer */
|
||||
typedef struct {
|
||||
uint8_t count;
|
||||
uint8_t bits; /* a 5.3 fixed point integer */
|
||||
} GolombAdaptiveCoderState;
|
||||
|
||||
#define GOLOMB_ADAPTIVE_CODER_STATE_INITIALIZER { 8<<3, 0 }
|
||||
|
||||
|
||||
static const int golomb_w_tab[] = { 256, 128, 64 };
|
||||
static const int golomb_w_tab [] = { 256, 128, 64 };
|
||||
|
||||
|
||||
|
||||
|
||||
static inline void
|
||||
golombcoder_encode_number (GolombAdaptiveCoderState * g,
|
||||
BitCoderState * b, unsigned int x)
|
||||
static inline
|
||||
void golombcoder_encode_number (GolombAdaptiveCoderState *g,
|
||||
BitCoderState *b,
|
||||
unsigned int x)
|
||||
{
|
||||
golomb_write_number (b, x, g->bits >> 3);
|
||||
golomb_write_number (b, x, g->bits >> 3);
|
||||
|
||||
g->bits = ((256 - golomb_w_tab[g->count]) * (int) g->bits +
|
||||
golomb_w_tab[g->count] * (required_bits (x) << 3)) / 256;
|
||||
g->count++;
|
||||
g->bits = ((256 - golomb_w_tab[g->count]) * (int) g->bits +
|
||||
golomb_w_tab[g->count] * (required_bits(x)<<3)) / 256;
|
||||
g->count++;
|
||||
|
||||
if (g->count > 2)
|
||||
g->count = 2;
|
||||
if (g->count > 2)
|
||||
g->count = 2;
|
||||
}
|
||||
|
||||
|
||||
static inline unsigned int
|
||||
golombcoder_decode_number (GolombAdaptiveCoderState * g, BitCoderState * b)
|
||||
static inline
|
||||
unsigned int golombcoder_decode_number (GolombAdaptiveCoderState *g,
|
||||
BitCoderState *b)
|
||||
{
|
||||
unsigned int x;
|
||||
unsigned int x;
|
||||
|
||||
x = golomb_read_number (b, g->bits >> 3);
|
||||
x = golomb_read_number (b, g->bits >> 3);
|
||||
|
||||
g->bits = ((256 - golomb_w_tab[g->count]) * g->bits +
|
||||
golomb_w_tab[g->count] * (required_bits (x) << 3)) / 256;
|
||||
g->count++;
|
||||
g->bits = ((256 - golomb_w_tab[g->count]) * g->bits +
|
||||
golomb_w_tab[g->count] * (required_bits(x)<<3)) / 256;
|
||||
g->count++;
|
||||
|
||||
if (g->count > 2)
|
||||
g->count = 2;
|
||||
if (g->count > 2)
|
||||
g->count = 2;
|
||||
|
||||
return x;
|
||||
return x;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
#include "tarkin.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_TARKINDEC \
|
||||
(tarkindec_get_type())
|
||||
|
@ -42,44 +41,42 @@ extern "C"
|
|||
#define GST_IS_TARKINDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_TARKINDEC))
|
||||
|
||||
typedef struct _TarkinDec TarkinDec;
|
||||
typedef struct _TarkinDecClass TarkinDecClass;
|
||||
typedef struct _TarkinDec TarkinDec;
|
||||
typedef struct _TarkinDecClass TarkinDecClass;
|
||||
|
||||
struct _TarkinDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _TarkinDec {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
ogg_sync_state oy;
|
||||
ogg_stream_state os;
|
||||
ogg_page og;
|
||||
ogg_packet op;
|
||||
ogg_sync_state oy;
|
||||
ogg_stream_state os;
|
||||
ogg_page og;
|
||||
ogg_packet op;
|
||||
|
||||
TarkinStream *tarkin_stream;
|
||||
TarkinComment tc;
|
||||
TarkinInfo ti;
|
||||
TarkinVideoLayerDesc layer[1];
|
||||
TarkinStream *tarkin_stream;
|
||||
TarkinComment tc;
|
||||
TarkinInfo ti;
|
||||
TarkinVideoLayerDesc layer[1];
|
||||
|
||||
gint frame_num;
|
||||
gint nheader;
|
||||
gint frame_num;
|
||||
gint nheader;
|
||||
|
||||
gboolean eos;
|
||||
gint bitrate;
|
||||
gboolean setup;
|
||||
};
|
||||
|
||||
gboolean eos;
|
||||
gint bitrate;
|
||||
gboolean setup;
|
||||
};
|
||||
struct _TarkinDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
struct _TarkinDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType tarkindec_get_type (void);
|
||||
GType tarkindec_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __TARKINDEC_H__ */
|
||||
#endif /* __TARKINDEC_H__ */
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
#include "tarkin.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_TARKINENC \
|
||||
(tarkinenc_get_type())
|
||||
|
@ -42,45 +41,43 @@ extern "C"
|
|||
#define GST_IS_TARKINENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_TARKINENC))
|
||||
|
||||
typedef struct _TarkinEnc TarkinEnc;
|
||||
typedef struct _TarkinEncClass TarkinEncClass;
|
||||
typedef struct _TarkinEnc TarkinEnc;
|
||||
typedef struct _TarkinEncClass TarkinEncClass;
|
||||
|
||||
struct _TarkinEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _TarkinEnc {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
ogg_stream_state os; /* take physical pages, weld into a logical
|
||||
stream of packets */
|
||||
ogg_page og; /* one Ogg bitstream page. Tarkin packets are inside */
|
||||
ogg_packet op[3]; /* one raw packet of data for decode */
|
||||
ogg_stream_state os; /* take physical pages, weld into a logical
|
||||
stream of packets */
|
||||
ogg_page og; /* one Ogg bitstream page. Tarkin packets are inside */
|
||||
ogg_packet op[3]; /* one raw packet of data for decode */
|
||||
|
||||
TarkinStream *tarkin_stream;
|
||||
TarkinComment tc;
|
||||
TarkinInfo ti;
|
||||
TarkinVideoLayerDesc layer[1];
|
||||
TarkinStream *tarkin_stream;
|
||||
TarkinComment tc;
|
||||
TarkinInfo ti;
|
||||
TarkinVideoLayerDesc layer[1];
|
||||
|
||||
gint frame_num;
|
||||
gint frame_num;
|
||||
|
||||
gboolean eos;
|
||||
gint bitrate;
|
||||
gint s_moments;
|
||||
gint a_moments;
|
||||
gboolean setup;
|
||||
};
|
||||
|
||||
gboolean eos;
|
||||
gint bitrate;
|
||||
gint s_moments;
|
||||
gint a_moments;
|
||||
gboolean setup;
|
||||
};
|
||||
struct _TarkinEncClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
struct _TarkinEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType tarkinenc_get_type (void);
|
||||
GType tarkinenc_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __TARKINENC_H__ */
|
||||
#endif /* __TARKINENC_H__ */
|
||||
|
|
|
@ -9,11 +9,9 @@
|
|||
|
||||
#if defined(DBG_MEMLEAKS)
|
||||
|
||||
extern void *dbg_malloc (char *file, int line, char *func, size_t bytes);
|
||||
extern void *dbg_calloc (char *file, int line, char *func, size_t count,
|
||||
size_t bytes);
|
||||
extern void *dbg_realloc (char *file, int line, char *func, char *what,
|
||||
void *mem, size_t bytes);
|
||||
extern void* dbg_malloc (char *file, int line, char *func, size_t bytes);
|
||||
extern void* dbg_calloc (char *file, int line, char *func, size_t count, size_t bytes);
|
||||
extern void* dbg_realloc (char *file, int line, char *func, char *what, void *mem, size_t bytes);
|
||||
extern void dbg_free (char *file, int line, char *func, char *what, void *mem);
|
||||
|
||||
#define MALLOC(bytes) dbg_malloc(__FILE__,__LINE__,__FUNCTION__,bytes)
|
||||
|
@ -31,3 +29,4 @@ extern void dbg_free (char *file, int line, char *func, char *what, void *mem);
|
|||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
|
142
ext/tarkin/rle.h
142
ext/tarkin/rle.h
|
@ -19,7 +19,7 @@
|
|||
#define ENTROPY_ENCODER_FLUSH(coder) rlecoder_encoder_flush(coder)
|
||||
#define ENTROPY_DECODER_INIT(coder,bitstream,limit) \
|
||||
rlecoder_decoder_init(coder,bitstream,limit)
|
||||
#define ENTROPY_DECODER_DONE(coder) /* nothing to do ... */
|
||||
#define ENTROPY_DECODER_DONE(coder) /* nothing to do ... */
|
||||
#define ENTROPY_CODER_BITSTREAM(coder) ((coder)->bitcoder.bitstream)
|
||||
#define ENTROPY_CODER_EOS(coder) ((coder)->bitcoder.eos)
|
||||
|
||||
|
@ -31,13 +31,12 @@
|
|||
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int symbol;
|
||||
uint32_t count; /* have seen count symbol's */
|
||||
BitCoderState bitcoder;
|
||||
GolombAdaptiveCoderState golomb_state[2]; /* 2 states for 2 symbols... */
|
||||
int have_seen_1;
|
||||
typedef struct {
|
||||
int symbol;
|
||||
uint32_t count; /* have seen count symbol's */
|
||||
BitCoderState bitcoder;
|
||||
GolombAdaptiveCoderState golomb_state [2]; /* 2 states for 2 symbols... */
|
||||
int have_seen_1;
|
||||
} RLECoderState;
|
||||
|
||||
|
||||
|
@ -45,99 +44,100 @@ typedef struct
|
|||
/*
|
||||
* bit should be 0 or 1 !!!
|
||||
*/
|
||||
static inline void
|
||||
rlecoder_write_bit (RLECoderState * s, int bit)
|
||||
static inline
|
||||
void rlecoder_write_bit (RLECoderState *s, int bit)
|
||||
{
|
||||
assert (bit == 0 || bit == 1);
|
||||
assert (bit == 0 || bit == 1);
|
||||
|
||||
if (s->symbol == -1) {
|
||||
s->symbol = bit & 1;
|
||||
s->count = 1;
|
||||
s->have_seen_1 = bit;
|
||||
bitcoder_write_bit (&s->bitcoder, bit);
|
||||
}
|
||||
if (s->symbol == -1) {
|
||||
s->symbol = bit & 1;
|
||||
s->count = 1;
|
||||
s->have_seen_1 = bit;
|
||||
bitcoder_write_bit (&s->bitcoder, bit);
|
||||
}
|
||||
|
||||
if (s->symbol != bit) {
|
||||
golombcoder_encode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder, s->count);
|
||||
s->symbol = ~s->symbol & 1;
|
||||
s->have_seen_1 = 1;
|
||||
s->count = 1;
|
||||
} else
|
||||
s->count++;
|
||||
if (s->symbol != bit) {
|
||||
golombcoder_encode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder, s->count);
|
||||
s->symbol = ~s->symbol & 1;
|
||||
s->have_seen_1 = 1;
|
||||
s->count = 1;
|
||||
} else
|
||||
s->count++;
|
||||
}
|
||||
|
||||
static inline int
|
||||
rlecoder_read_bit (RLECoderState * s)
|
||||
static inline
|
||||
int rlecoder_read_bit (RLECoderState *s)
|
||||
{
|
||||
if (s->count == 0) {
|
||||
s->symbol = ~s->symbol & 1;
|
||||
s->count = golombcoder_decode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder);
|
||||
if (s->bitcoder.eos) {
|
||||
s->symbol = 0;
|
||||
s->count = ~0;
|
||||
}
|
||||
}
|
||||
s->count--;
|
||||
return (s->symbol);
|
||||
if (s->count == 0) {
|
||||
s->symbol = ~s->symbol & 1;
|
||||
s->count = golombcoder_decode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder);
|
||||
if (s->bitcoder.eos) {
|
||||
s->symbol = 0;
|
||||
s->count = ~0;
|
||||
}
|
||||
}
|
||||
s->count--;
|
||||
return (s->symbol);
|
||||
}
|
||||
|
||||
|
||||
int coder_id = 0;
|
||||
FILE *file = NULL;
|
||||
|
||||
static inline void
|
||||
rlecoder_encoder_init (RLECoderState * s, uint32_t limit)
|
||||
static inline
|
||||
void rlecoder_encoder_init (RLECoderState *s, uint32_t limit)
|
||||
{
|
||||
bitcoder_encoder_init (&s->bitcoder, limit);
|
||||
s->symbol = -1;
|
||||
s->have_seen_1 = 0;
|
||||
s->golomb_state[0].count = 0;
|
||||
s->golomb_state[1].count = 0;
|
||||
s->golomb_state[0].bits = 5 << 3;
|
||||
s->golomb_state[1].bits = 5 << 3;
|
||||
bitcoder_encoder_init (&s->bitcoder, limit);
|
||||
s->symbol = -1;
|
||||
s->have_seen_1 = 0;
|
||||
s->golomb_state[0].count = 0;
|
||||
s->golomb_state[1].count = 0;
|
||||
s->golomb_state[0].bits = 5 << 3;
|
||||
s->golomb_state[1].bits = 5 << 3;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* once you called this, you better should not encode any more symbols ...
|
||||
*/
|
||||
static inline uint32_t
|
||||
rlecoder_encoder_flush (RLECoderState * s)
|
||||
static inline
|
||||
uint32_t rlecoder_encoder_flush (RLECoderState *s)
|
||||
{
|
||||
if (s->symbol == -1 || !s->have_seen_1)
|
||||
return 0;
|
||||
if (s->symbol == -1 || !s->have_seen_1)
|
||||
return 0;
|
||||
|
||||
golombcoder_encode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder, s->count);
|
||||
return bitcoder_flush (&s->bitcoder);
|
||||
golombcoder_encode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder, s->count);
|
||||
return bitcoder_flush (&s->bitcoder);
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
rlecoder_decoder_init (RLECoderState * s, uint8_t * bitstream, uint32_t limit)
|
||||
static inline
|
||||
void rlecoder_decoder_init (RLECoderState *s, uint8_t *bitstream, uint32_t limit)
|
||||
{
|
||||
bitcoder_decoder_init (&s->bitcoder, bitstream, limit);
|
||||
s->golomb_state[0].count = 0;
|
||||
s->golomb_state[1].count = 0;
|
||||
s->golomb_state[0].bits = 5 << 3;
|
||||
s->golomb_state[1].bits = 5 << 3;
|
||||
s->symbol = bitcoder_read_bit (&s->bitcoder);
|
||||
s->count = golombcoder_decode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder) - 1;
|
||||
if (s->bitcoder.eos) {
|
||||
s->symbol = 0;
|
||||
s->count = ~0;
|
||||
}
|
||||
bitcoder_decoder_init (&s->bitcoder, bitstream, limit);
|
||||
s->golomb_state[0].count = 0;
|
||||
s->golomb_state[1].count = 0;
|
||||
s->golomb_state[0].bits = 5 << 3;
|
||||
s->golomb_state[1].bits = 5 << 3;
|
||||
s->symbol = bitcoder_read_bit (&s->bitcoder);
|
||||
s->count = golombcoder_decode_number (&s->golomb_state[s->symbol],
|
||||
&s->bitcoder) - 1;
|
||||
if (s->bitcoder.eos) {
|
||||
s->symbol = 0;
|
||||
s->count = ~0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
rlecoder_encoder_done (RLECoderState * s)
|
||||
static inline
|
||||
void rlecoder_encoder_done (RLECoderState *s)
|
||||
{
|
||||
bitcoder_encoder_done (&s->bitcoder);
|
||||
bitcoder_encoder_done (&s->bitcoder);
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -18,115 +18,105 @@
|
|||
/* Theses determine what infos the packet comes with */
|
||||
#define TARKIN_PACK_EXAMPLE 1
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint8_t *data;
|
||||
uint32_t data_len;
|
||||
uint32_t storage;
|
||||
} TarkinPacket;
|
||||
typedef struct {
|
||||
uint8_t *data;
|
||||
uint32_t data_len;
|
||||
uint32_t storage;
|
||||
} TarkinPacket;
|
||||
|
||||
|
||||
typedef enum
|
||||
{
|
||||
TARKIN_GRAYSCALE,
|
||||
TARKIN_RGB24, /* tight packed RGB */
|
||||
TARKIN_RGB32, /* 32bit, no alphachannel */
|
||||
TARKIN_RGBA, /* dito w/ alphachannel */
|
||||
TARKIN_YUV2, /* 16 bits YUV */
|
||||
TARKIN_YUV12, /* 12 bits YUV */
|
||||
TARKIN_FYUV, /* Tarkin's Fast YUV-like? */
|
||||
typedef enum {
|
||||
TARKIN_GRAYSCALE,
|
||||
TARKIN_RGB24, /* tight packed RGB */
|
||||
TARKIN_RGB32, /* 32bit, no alphachannel */
|
||||
TARKIN_RGBA, /* dito w/ alphachannel */
|
||||
TARKIN_YUV2, /* 16 bits YUV */
|
||||
TARKIN_YUV12, /* 12 bits YUV */
|
||||
TARKIN_FYUV, /* Tarkin's Fast YUV-like? */
|
||||
} TarkinColorFormat;
|
||||
|
||||
#define TARKIN_INTERNAL_FORMAT TARKIN_FYUV
|
||||
|
||||
typedef enum
|
||||
{
|
||||
TARKIN_OK = 0,
|
||||
TARKIN_IO_ERROR,
|
||||
TARKIN_SIGNATURE_NOT_FOUND,
|
||||
TARKIN_INVALID_LAYER,
|
||||
TARKIN_INVALID_COLOR_FORMAT,
|
||||
TARKIN_VERSION,
|
||||
TARKIN_BAD_HEADER,
|
||||
TARKIN_NOT_TARKIN,
|
||||
TARKIN_FAULT,
|
||||
TARKIN_UNUSED,
|
||||
TARKIN_NEED_MORE,
|
||||
TARKIN_NOT_IMPLEMENTED
|
||||
typedef enum {
|
||||
TARKIN_OK = 0,
|
||||
TARKIN_IO_ERROR,
|
||||
TARKIN_SIGNATURE_NOT_FOUND,
|
||||
TARKIN_INVALID_LAYER,
|
||||
TARKIN_INVALID_COLOR_FORMAT,
|
||||
TARKIN_VERSION,
|
||||
TARKIN_BAD_HEADER,
|
||||
TARKIN_NOT_TARKIN,
|
||||
TARKIN_FAULT,
|
||||
TARKIN_UNUSED,
|
||||
TARKIN_NEED_MORE,
|
||||
TARKIN_NOT_IMPLEMENTED
|
||||
} TarkinError;
|
||||
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
uint32_t a_moments;
|
||||
uint32_t s_moments;
|
||||
uint32_t frames_per_buf;
|
||||
uint32_t bitstream_len; /* for all color components, bytes */
|
||||
TarkinColorFormat format;
|
||||
typedef struct {
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
uint32_t a_moments;
|
||||
uint32_t s_moments;
|
||||
uint32_t frames_per_buf;
|
||||
uint32_t bitstream_len; /* for all color components, bytes */
|
||||
TarkinColorFormat format;
|
||||
} TarkinVideoLayerDesc;
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
TarkinVideoLayerDesc desc;
|
||||
uint32_t n_comp; /* number of color components */
|
||||
Wavelet3DBuf **waveletbuf;
|
||||
TarkinPacket *packet;
|
||||
uint32_t current_frame_in_buf;
|
||||
uint32_t frameno;
|
||||
typedef struct {
|
||||
TarkinVideoLayerDesc desc;
|
||||
uint32_t n_comp; /* number of color components */
|
||||
Wavelet3DBuf **waveletbuf;
|
||||
TarkinPacket *packet;
|
||||
uint32_t current_frame_in_buf;
|
||||
uint32_t frameno;
|
||||
|
||||
void (*color_fwd_xform) (uint8_t * rgba, Wavelet3DBuf * yuva[],
|
||||
uint32_t count);
|
||||
void (*color_inv_xform) (Wavelet3DBuf * yuva[], uint8_t * rgba,
|
||||
uint32_t count);
|
||||
void (*color_fwd_xform) (uint8_t *rgba, Wavelet3DBuf *yuva [], uint32_t count);
|
||||
void (*color_inv_xform) (Wavelet3DBuf *yuva [], uint8_t *rgba, uint32_t count);
|
||||
} TarkinVideoLayer;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint32_t numerator;
|
||||
uint32_t denominator;
|
||||
} TarkinTime; /* Let's say the unit is 1 second */
|
||||
typedef struct {
|
||||
uint32_t numerator;
|
||||
uint32_t denominator;
|
||||
} TarkinTime; /* Let's say the unit is 1 second */
|
||||
|
||||
typedef struct TarkinInfo
|
||||
{
|
||||
int version;
|
||||
int n_layers;
|
||||
TarkinVideoLayer *layer;
|
||||
TarkinTime inter; /* numerator == O if per-frame time info. */
|
||||
int frames_per_block;
|
||||
int comp_per_block; /* AKA "packets per block" for now */
|
||||
uint32_t max_bitstream_len;
|
||||
typedef struct TarkinInfo {
|
||||
int version;
|
||||
int n_layers;
|
||||
TarkinVideoLayer *layer;
|
||||
TarkinTime inter; /* numerator == O if per-frame time info. */
|
||||
int frames_per_block;
|
||||
int comp_per_block; /* AKA "packets per block" for now */
|
||||
uint32_t max_bitstream_len;
|
||||
|
||||
/* The below bitrate declarations are *hints*.
|
||||
Combinations of the three values carry the following implications:
|
||||
|
||||
|
||||
all three set to the same value:
|
||||
implies a fixed rate bitstream
|
||||
implies a fixed rate bitstream
|
||||
only nominal set:
|
||||
implies a VBR stream that averages the nominal bitrate. No hard
|
||||
upper/lower limit
|
||||
implies a VBR stream that averages the nominal bitrate. No hard
|
||||
upper/lower limit
|
||||
upper and or lower set:
|
||||
implies a VBR bitstream that obeys the bitrate limits. nominal
|
||||
may also be set to give a nominal rate.
|
||||
implies a VBR bitstream that obeys the bitrate limits. nominal
|
||||
may also be set to give a nominal rate.
|
||||
none set:
|
||||
the coder does not care to speculate.
|
||||
*/
|
||||
the coder does not care to speculate.
|
||||
*/
|
||||
|
||||
long bitrate_upper;
|
||||
long bitrate_nominal;
|
||||
long bitrate_lower;
|
||||
long bitrate_window;
|
||||
long bitrate_upper;
|
||||
long bitrate_nominal;
|
||||
long bitrate_lower;
|
||||
long bitrate_window;
|
||||
} TarkinInfo;
|
||||
|
||||
/* This is used for encoding */
|
||||
typedef struct
|
||||
{
|
||||
unsigned char *header;
|
||||
unsigned char *header1;
|
||||
unsigned char *header2;
|
||||
typedef struct {
|
||||
unsigned char *header;
|
||||
unsigned char *header1;
|
||||
unsigned char *header2;
|
||||
} tarkin_header_store;
|
||||
|
||||
|
||||
|
@ -134,33 +124,31 @@ typedef struct
|
|||
|
||||
/* Some of the fields in TarkinStream are redundent with TarkinInfo ones
|
||||
* and will probably get deleted, namely n_layers and frames_per_buf */
|
||||
typedef struct TarkinStream
|
||||
{
|
||||
uint32_t n_layers;
|
||||
TarkinVideoLayer *layer;
|
||||
uint32_t current_frame;
|
||||
uint32_t current_frame_in_buf;
|
||||
ogg_int64_t packetno;
|
||||
uint32_t frames_per_buf;
|
||||
uint32_t max_bitstream_len;
|
||||
TarkinInfo *ti;
|
||||
tarkin_header_store headers;
|
||||
/* These callbacks are only used for encoding */
|
||||
TarkinError (*free_frame) (void *tarkinstream, void *ptr);
|
||||
/* These thing allows not to buffer but it needs global var in caller. */
|
||||
TarkinError (*packet_out) (void *tarkinstream, ogg_packet * ptr);
|
||||
void *user_ptr;
|
||||
typedef struct TarkinStream {
|
||||
uint32_t n_layers;
|
||||
TarkinVideoLayer *layer;
|
||||
uint32_t current_frame;
|
||||
uint32_t current_frame_in_buf;
|
||||
ogg_int64_t packetno;
|
||||
uint32_t frames_per_buf;
|
||||
uint32_t max_bitstream_len;
|
||||
TarkinInfo *ti;
|
||||
tarkin_header_store headers;
|
||||
/* These callbacks are only used for encoding */
|
||||
TarkinError (*free_frame)(void *tarkinstream, void *ptr);
|
||||
/* These thing allows not to buffer but it needs global var in caller. */
|
||||
TarkinError (*packet_out)(void *tarkinstream, ogg_packet *ptr);
|
||||
void * user_ptr;
|
||||
} TarkinStream;
|
||||
|
||||
|
||||
typedef struct TarkinComment
|
||||
{
|
||||
typedef struct TarkinComment{
|
||||
/* unlimited user comment fields. libtarkin writes 'libtarkin'
|
||||
whatever vendor is set to in encode */
|
||||
char **user_comments;
|
||||
int *comment_lengths;
|
||||
int comments;
|
||||
char *vendor;
|
||||
int *comment_lengths;
|
||||
int comments;
|
||||
char *vendor;
|
||||
|
||||
} TarkinComment;
|
||||
|
||||
|
@ -173,17 +161,17 @@ typedef struct TarkinComment
|
|||
|
||||
|
||||
/* Theses are the very same than Vorbis versions, they could be shared. */
|
||||
extern TarkinStream *tarkin_stream_new ();
|
||||
extern void tarkin_stream_destroy (TarkinStream * s);
|
||||
extern void tarkin_info_init (TarkinInfo * vi);
|
||||
extern void tarkin_info_clear (TarkinInfo * vi);
|
||||
extern void tarkin_comment_init (TarkinComment * vc);
|
||||
extern void tarkin_comment_add (TarkinComment * vc, char *comment);
|
||||
extern void tarkin_comment_add_tag (TarkinComment * vc,
|
||||
char *tag, char *contents);
|
||||
extern char *tarkin_comment_query (TarkinComment * vc, char *tag, int count);
|
||||
extern int tarkin_comment_query_count (TarkinComment * vc, char *tag);
|
||||
extern void tarkin_comment_clear (TarkinComment * vc);
|
||||
extern TarkinStream* tarkin_stream_new ();
|
||||
extern void tarkin_stream_destroy (TarkinStream *s);
|
||||
extern void tarkin_info_init(TarkinInfo *vi);
|
||||
extern void tarkin_info_clear(TarkinInfo *vi);
|
||||
extern void tarkin_comment_init(TarkinComment *vc);
|
||||
extern void tarkin_comment_add(TarkinComment *vc, char *comment);
|
||||
extern void tarkin_comment_add_tag(TarkinComment *vc,
|
||||
char *tag, char *contents);
|
||||
extern char *tarkin_comment_query(TarkinComment *vc, char *tag, int count);
|
||||
extern int tarkin_comment_query_count(TarkinComment *vc, char *tag);
|
||||
extern void tarkin_comment_clear(TarkinComment *vc);
|
||||
|
||||
/* Tarkin PRIMITIVES: analysis layer ****************************/
|
||||
/* Tarkin encoding is done this way : you init it passing a fresh
|
||||
|
@ -193,50 +181,59 @@ extern void tarkin_comment_clear (TarkinComment * vc);
|
|||
* is called when a packet is ready. The pointers given as arguments to
|
||||
* these callback functions are of course only valid at the function call
|
||||
* time. The user_ptr is stored in s and can be used by packet_out(). */
|
||||
extern int tarkin_analysis_init (TarkinStream * s,
|
||||
TarkinInfo * ti,
|
||||
TarkinError (*free_frame) (void *tarkinstream, void *ptr),
|
||||
TarkinError (*packet_out) (void *tarkinstream, ogg_packet * ptr),
|
||||
void *user_ptr);
|
||||
extern int tarkin_analysis_init(TarkinStream *s,
|
||||
TarkinInfo *ti,
|
||||
TarkinError (*free_frame)(void *tarkinstream, void *ptr),
|
||||
TarkinError (*packet_out)(void *tarkinstream, ogg_packet *ptr),
|
||||
void *user_ptr
|
||||
);
|
||||
/* Then you need to add at least a layer in your stream, passing a
|
||||
* TarkinVideoLayerDesc renseigned at least on the width, height and
|
||||
* format parameters. */
|
||||
extern int tarkin_analysis_add_layer (TarkinStream * s,
|
||||
TarkinVideoLayerDesc * tvld);
|
||||
extern int tarkin_analysis_add_layer(TarkinStream *s,
|
||||
TarkinVideoLayerDesc *tvld);
|
||||
/* At that point you are ready to get headers out the lib by calling
|
||||
* tarkin_analysis_headerout() passing it a renseigned TarkinComment
|
||||
* structure. It does fill your 3 ogg_packet headers, which are valid
|
||||
* till next call */
|
||||
extern int TarkinCommentheader_out (TarkinComment * vc, ogg_packet * op);
|
||||
extern TarkinError tarkin_analysis_headerout (TarkinStream * s,
|
||||
TarkinComment * vc,
|
||||
ogg_packet * op, ogg_packet * op_comm, ogg_packet * op_code);
|
||||
extern int TarkinCommentheader_out(TarkinComment *vc, ogg_packet *op);
|
||||
extern TarkinError tarkin_analysis_headerout(TarkinStream *s,
|
||||
TarkinComment *vc,
|
||||
ogg_packet *op,
|
||||
ogg_packet *op_comm,
|
||||
ogg_packet *op_code);
|
||||
/* You are now ready to pass in frames to the codec, however don't free
|
||||
* them before the codec told you so. It'll tell you when packets are
|
||||
* ready to be taken out. When you have no more frame, simply pass NULL.
|
||||
* If you encode multiple layers you have to do it synchronously, putting
|
||||
* one frame from each layer at a time. */
|
||||
extern uint32_t tarkin_analysis_framein (TarkinStream * s, uint8_t * frame, /* NULL for EOS */
|
||||
uint32_t layer, TarkinTime * date);
|
||||
extern uint32_t tarkin_analysis_framein(TarkinStream *s,
|
||||
uint8_t *frame, /* NULL for EOS */
|
||||
uint32_t layer,
|
||||
TarkinTime *date);
|
||||
|
||||
/* Tarkin PRIMITIVES: synthesis layer *******************************/
|
||||
/* For decoding, you needs first to give the three first packet of the
|
||||
* stream to tarkin_synthesis_headerin() which will fill for you blank
|
||||
* TarkinInfo and TarkinComment. */
|
||||
extern TarkinError tarkin_synthesis_headerin (TarkinInfo * vi,
|
||||
TarkinComment * vc, ogg_packet * op);
|
||||
extern TarkinError tarkin_synthesis_headerin(TarkinInfo *vi,TarkinComment *vc,
|
||||
ogg_packet *op);
|
||||
/* Then you can init your stream with your TarkinInfo struct. */
|
||||
extern TarkinError tarkin_synthesis_init (TarkinStream * s, TarkinInfo * ti);
|
||||
|
||||
extern TarkinError tarkin_synthesis_init(TarkinStream *s,TarkinInfo *ti);
|
||||
/* All subsequent packets are to this be passed to tarkin_synthesis_packetin*/
|
||||
extern TarkinError tarkin_synthesis_packetin (TarkinStream * s,
|
||||
ogg_packet * op);
|
||||
extern TarkinError tarkin_synthesis_packetin(TarkinStream *s, ogg_packet *op);
|
||||
/* and then tarkin_synthesis_frameout gives you ptr on next frame, or NULL. It
|
||||
* also fills for you date. */
|
||||
extern TarkinError tarkin_synthesis_frameout (TarkinStream * s,
|
||||
uint8_t ** frame, uint32_t layer_id, TarkinTime * date);
|
||||
extern TarkinError tarkin_synthesis_frameout(TarkinStream *s,
|
||||
uint8_t **frame, uint32_t layer_id, TarkinTime *date);
|
||||
/* When you're done with a frame, tell it to the codec with this. */
|
||||
extern int tarkin_synthesis_freeframe (TarkinStream * s, uint8_t * frame);
|
||||
extern int tarkin_synthesis_freeframe(TarkinStream *s, uint8_t *frame);
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -4,25 +4,24 @@
|
|||
#include <stdint.h>
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
TYPE *data;
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
uint32_t frames;
|
||||
uint32_t scales;
|
||||
uint32_t *w;
|
||||
uint32_t *h;
|
||||
uint32_t *f;
|
||||
uint32_t (*offset)[8];
|
||||
TYPE *scratchbuf;
|
||||
typedef struct {
|
||||
TYPE *data;
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
uint32_t frames;
|
||||
uint32_t scales;
|
||||
uint32_t *w;
|
||||
uint32_t *h;
|
||||
uint32_t *f;
|
||||
uint32_t (*offset)[8];
|
||||
TYPE *scratchbuf;
|
||||
} Wavelet3DBuf;
|
||||
|
||||
|
||||
extern Wavelet3DBuf *wavelet_3d_buf_new (uint32_t width, uint32_t height,
|
||||
uint32_t frames);
|
||||
extern Wavelet3DBuf* wavelet_3d_buf_new (uint32_t width, uint32_t height,
|
||||
uint32_t frames);
|
||||
|
||||
extern void wavelet_3d_buf_destroy (Wavelet3DBuf * buf);
|
||||
extern void wavelet_3d_buf_destroy (Wavelet3DBuf* buf);
|
||||
|
||||
/**
|
||||
* transform buf->data
|
||||
|
@ -30,21 +29,25 @@ extern void wavelet_3d_buf_destroy (Wavelet3DBuf * buf);
|
|||
* highpass filter,
|
||||
* s_moments the one of the synthesizing lowpass filter.
|
||||
*/
|
||||
extern void wavelet_3d_buf_fwd_xform (Wavelet3DBuf * buf,
|
||||
int a_moments, int s_moments);
|
||||
extern void wavelet_3d_buf_inv_xform (Wavelet3DBuf * buf,
|
||||
int a_moments, int s_moments);
|
||||
extern void wavelet_3d_buf_fwd_xform (Wavelet3DBuf* buf,
|
||||
int a_moments, int s_moments);
|
||||
extern void wavelet_3d_buf_inv_xform (Wavelet3DBuf* buf,
|
||||
int a_moments, int s_moments);
|
||||
|
||||
extern int wavelet_3d_buf_encode_coeff (const Wavelet3DBuf * buf,
|
||||
uint8_t * bitstream, uint32_t limit);
|
||||
extern int wavelet_3d_buf_encode_coeff (const Wavelet3DBuf* buf,
|
||||
uint8_t *bitstream,
|
||||
uint32_t limit);
|
||||
|
||||
extern void wavelet_3d_buf_decode_coeff (Wavelet3DBuf * buf,
|
||||
uint8_t * bitstream, uint32_t limit);
|
||||
extern void wavelet_3d_buf_decode_coeff (Wavelet3DBuf* buf,
|
||||
uint8_t *bitstream,
|
||||
uint32_t limit);
|
||||
|
||||
#if defined(DBG_XFORM)
|
||||
extern void wavelet_3d_buf_dump (char *fmt,
|
||||
uint32_t first_frame_in_buf,
|
||||
uint32_t id, Wavelet3DBuf * buf, int16_t offset);
|
||||
uint32_t first_frame_in_buf,
|
||||
uint32_t id,
|
||||
Wavelet3DBuf* buf,
|
||||
int16_t offset);
|
||||
#else
|
||||
#define wavelet_3d_buf_dump(x...)
|
||||
#endif
|
||||
|
|
|
@ -5,16 +5,17 @@
|
|||
#include <stdint.h>
|
||||
#include "wavelet.h"
|
||||
|
||||
extern void rgb24_to_yuv (uint8_t * rgb, Wavelet3DBuf * yuv[], uint32_t frame);
|
||||
extern void yuv_to_rgb24 (Wavelet3DBuf * yuv[], uint8_t * rgb, uint32_t frame);
|
||||
extern void rgb24_to_yuv (uint8_t *rgb, Wavelet3DBuf *yuv [], uint32_t frame);
|
||||
extern void yuv_to_rgb24 (Wavelet3DBuf *yuv [], uint8_t *rgb, uint32_t frame);
|
||||
|
||||
extern void rgb32_to_yuv (uint8_t * rgb, Wavelet3DBuf * yuv[], uint32_t frame);
|
||||
extern void yuv_to_rgb32 (Wavelet3DBuf * yuv[], uint8_t * rgb, uint32_t frame);
|
||||
extern void rgb32_to_yuv (uint8_t *rgb, Wavelet3DBuf *yuv [], uint32_t frame);
|
||||
extern void yuv_to_rgb32 (Wavelet3DBuf *yuv [], uint8_t *rgb, uint32_t frame);
|
||||
|
||||
extern void rgba_to_yuv (uint8_t * rgba, Wavelet3DBuf * yuva[], uint32_t frame);
|
||||
extern void yuv_to_rgba (Wavelet3DBuf * yuva[], uint8_t * rgba, uint32_t frame);
|
||||
extern void rgba_to_yuv (uint8_t *rgba, Wavelet3DBuf *yuva [], uint32_t frame);
|
||||
extern void yuv_to_rgba (Wavelet3DBuf *yuva [], uint8_t *rgba, uint32_t frame);
|
||||
|
||||
extern void grayscale_to_y (uint8_t * rgba, Wavelet3DBuf * y[], uint32_t frame);
|
||||
extern void y_to_grayscale (Wavelet3DBuf * y[], uint8_t * rgba, uint32_t frame);
|
||||
extern void grayscale_to_y (uint8_t *rgba, Wavelet3DBuf *y [], uint32_t frame);
|
||||
extern void y_to_grayscale (Wavelet3DBuf *y [], uint8_t *rgba, uint32_t frame);
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <xine/buffer.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_XINE \
|
||||
(gst_xine_get_type())
|
||||
#define GST_XINE(obj) \
|
||||
|
@ -37,45 +38,47 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_XINE))
|
||||
#define GST_IS_XINE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_XINE))
|
||||
typedef struct _GstXine GstXine;
|
||||
|
||||
typedef struct _GstXine GstXine;
|
||||
typedef struct _GstXineClass GstXineClass;
|
||||
|
||||
struct _GstXine
|
||||
{
|
||||
GstElement element;
|
||||
GstElement element;
|
||||
|
||||
xine_stream_t *stream;
|
||||
xine_ao_driver_t *audio_driver;
|
||||
xine_vo_driver_t *video_driver;
|
||||
xine_stream_t * stream;
|
||||
xine_ao_driver_t * audio_driver;
|
||||
xine_vo_driver_t * video_driver;
|
||||
};
|
||||
|
||||
struct _GstXineClass
|
||||
struct _GstXineClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
GstElementClass parent_class;
|
||||
|
||||
xine_t *xine;
|
||||
xine_t * xine;
|
||||
|
||||
xine_ao_driver_t *(*create_audio_driver) (GstXine * xine);
|
||||
xine_vo_driver_t *(*create_video_driver) (GstXine * xine);
|
||||
xine_ao_driver_t * (* create_audio_driver) (GstXine * xine);
|
||||
xine_vo_driver_t * (* create_video_driver) (GstXine * xine);
|
||||
};
|
||||
|
||||
GType gst_xine_get_type (void);
|
||||
GType gst_xine_get_type (void);
|
||||
|
||||
xine_stream_t *gst_xine_get_stream (GstXine * xine);
|
||||
void gst_xine_free_stream (GstXine * xine);
|
||||
xine_stream_t * gst_xine_get_stream (GstXine *xine);
|
||||
void gst_xine_free_stream (GstXine *xine);
|
||||
|
||||
void gst_buffer_to_xine_buffer (buf_element_t * element, GstBuffer * buffer);
|
||||
void gst_buffer_to_xine_buffer (buf_element_t *element, GstBuffer *buffer);
|
||||
|
||||
/* conversion functions from xinecaps.c */
|
||||
|
||||
const gchar *gst_xine_get_caps_for_format (guint32 format);
|
||||
guint32 gst_xine_get_format_for_caps (const GstCaps * caps);
|
||||
const gchar * gst_xine_get_caps_for_format (guint32 format);
|
||||
guint32 gst_xine_get_format_for_caps (const GstCaps *caps);
|
||||
|
||||
/* init functions for the plugins */
|
||||
|
||||
gboolean gst_xine_audio_sink_init_plugin (GstPlugin * plugin);
|
||||
gboolean gst_xine_audio_dec_init_plugin (GstPlugin * plugin);
|
||||
gboolean gst_xine_input_init_plugin (GstPlugin * plugin);
|
||||
|
||||
gboolean gst_xine_audio_sink_init_plugin (GstPlugin *plugin);
|
||||
gboolean gst_xine_audio_dec_init_plugin (GstPlugin *plugin);
|
||||
gboolean gst_xine_input_init_plugin (GstPlugin *plugin);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_XINE_H__ */
|
||||
|
|
|
@ -23,11 +23,13 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define gst_xvid_init_struct(s) \
|
||||
do { \
|
||||
memset (&s, 0, sizeof(s)); \
|
||||
s.version = XVID_VERSION; \
|
||||
} while (0);
|
||||
|
||||
#define RGB_24_32_STATIC_CAPS(bpp, r_mask,g_mask,b_mask) \
|
||||
"video/x-raw-rgb, " \
|
||||
"width = (int) [ 0, MAX ], " \
|
||||
|
@ -39,12 +41,14 @@ G_BEGIN_DECLS
|
|||
"red_mask = (int) " G_STRINGIFY (r_mask) ", " \
|
||||
"green_mask = (int) " G_STRINGIFY (g_mask) ", " \
|
||||
"blue_mask = (int) " G_STRINGIFY (b_mask)
|
||||
extern gchar *gst_xvid_error (int errorcode);
|
||||
extern gboolean gst_xvid_init (void);
|
||||
|
||||
extern gint gst_xvid_structure_to_csp (GstStructure * structure,
|
||||
gint w, gint * stride, gint * bpp);
|
||||
extern GstCaps *gst_xvid_csp_to_caps (gint csp, gint w, gint h, gdouble fps);
|
||||
extern gchar * gst_xvid_error (int errorcode);
|
||||
extern gboolean gst_xvid_init (void);
|
||||
|
||||
extern gint gst_xvid_structure_to_csp (GstStructure *structure,
|
||||
gint w, gint *stride, gint *bpp);
|
||||
extern GstCaps *gst_xvid_csp_to_caps (gint csp, gint w, gint h, gdouble fps);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_XVID_H__ */
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include "gstxvid.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_XVIDDEC \
|
||||
|
@ -40,34 +39,32 @@ extern "C"
|
|||
#define GST_IS_XVIDDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_XVIDDEC))
|
||||
|
||||
typedef struct _GstXvidDec GstXvidDec;
|
||||
typedef struct _GstXvidDecClass GstXvidDecClass;
|
||||
typedef struct _GstXvidDec GstXvidDec;
|
||||
typedef struct _GstXvidDecClass GstXvidDecClass;
|
||||
|
||||
struct _GstXvidDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstXvidDec {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
/* xvid handle */
|
||||
void *handle;
|
||||
/* xvid handle */
|
||||
void *handle;
|
||||
|
||||
/* video (output) settings */
|
||||
gint csp, bpp, stride;
|
||||
gint width, height;
|
||||
double fps;
|
||||
};
|
||||
/* video (output) settings */
|
||||
gint csp, bpp, stride;
|
||||
gint width, height;
|
||||
double fps;
|
||||
};
|
||||
|
||||
struct _GstXvidDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstXvidDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_xviddec_get_type (void);
|
||||
GType gst_xviddec_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_XVIDDEC_H__ */
|
||||
#endif /* __GST_XVIDDEC_H__ */
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include "gstxvid.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_XVIDENC \
|
||||
|
@ -40,48 +39,46 @@ extern "C"
|
|||
#define GST_IS_XVIDENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_XVIDENC))
|
||||
|
||||
typedef struct _GstXvidEnc GstXvidEnc;
|
||||
typedef struct _GstXvidEncClass GstXvidEncClass;
|
||||
typedef struct _GstXvidEnc GstXvidEnc;
|
||||
typedef struct _GstXvidEncClass GstXvidEncClass;
|
||||
|
||||
struct _GstXvidEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstXvidEnc {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
/* encoding profile */
|
||||
gint profile;
|
||||
/* encoding profile */
|
||||
gint profile;
|
||||
|
||||
/* quality of encoded image */
|
||||
gint bitrate;
|
||||
gint buffer_size;
|
||||
/* quality of encoded image */
|
||||
gint bitrate;
|
||||
gint buffer_size;
|
||||
|
||||
/* max number of B frames between I/P */
|
||||
gint max_b_frames;
|
||||
/* max number of B frames between I/P */
|
||||
gint max_b_frames;
|
||||
|
||||
/* max key interval */
|
||||
gint max_key_interval;
|
||||
/* max key interval */
|
||||
gint max_key_interval;
|
||||
|
||||
/* xvid handle */
|
||||
void *handle;
|
||||
gint csp;
|
||||
gint width, height, stride;
|
||||
gdouble fps;
|
||||
};
|
||||
/* xvid handle */
|
||||
void *handle;
|
||||
gint csp;
|
||||
gint width, height, stride;
|
||||
gdouble fps;
|
||||
};
|
||||
|
||||
struct _GstXvidEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
struct _GstXvidEncClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement * element);
|
||||
};
|
||||
/* signals */
|
||||
void (*frame_encoded) (GstElement *element);
|
||||
};
|
||||
|
||||
GType gst_xvidenc_get_type (void);
|
||||
GType gst_xvidenc_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_XVIDENC_H__ */
|
||||
#endif /* __GST_XVIDENC_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 @@
|
|||
#include <gst/bytestream/bytestream.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define GST_TYPE_CDXA_PARSE \
|
||||
(gst_cdxa_parse_get_type())
|
||||
|
@ -44,40 +43,38 @@ extern "C"
|
|||
#define CDXA_SECTOR_SIZE 2352
|
||||
#define CDXA_DATA_SIZE 2324
|
||||
|
||||
typedef enum
|
||||
{
|
||||
CDXA_PARSE_HEADER,
|
||||
CDXA_PARSE_DATA,
|
||||
} GstCDXAParseState;
|
||||
typedef enum
|
||||
{
|
||||
CDXA_PARSE_HEADER,
|
||||
CDXA_PARSE_DATA,
|
||||
} GstCDXAParseState;
|
||||
|
||||
typedef struct _GstCDXAParse GstCDXAParse;
|
||||
typedef struct _GstCDXAParseClass GstCDXAParseClass;
|
||||
typedef struct _GstCDXAParse GstCDXAParse;
|
||||
typedef struct _GstCDXAParseClass GstCDXAParseClass;
|
||||
|
||||
struct _GstCDXAParse
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstCDXAParse {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
||||
GstByteStream *bs;
|
||||
GstByteStream *bs;
|
||||
|
||||
GstCDXAParseState state;
|
||||
GstCDXAParseState state;
|
||||
|
||||
guint32 riff_size;
|
||||
guint32 data_size;
|
||||
guint32 sectors;
|
||||
};
|
||||
guint32 riff_size;
|
||||
guint32 data_size;
|
||||
guint32 sectors;
|
||||
};
|
||||
|
||||
struct _GstCDXAParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstCDXAParseClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_cdxa_parse_get_type (void);
|
||||
GType gst_cdxa_parse_get_type (void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_CDXA_PARSE_H__ */
|
||||
#endif /* __GST_CDXA_PARSE_H__ */
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_COLORSPACE \
|
||||
(gst_colorspace_get_type())
|
||||
#define GST_COLORSPACE(obj) \
|
||||
|
@ -33,11 +34,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_COLORSPACE))
|
||||
#define GST_IS_COLORSPACE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_COLORSPACE))
|
||||
|
||||
typedef struct _GstColorspace GstColorspace;
|
||||
typedef struct _GstColorspaceClass GstColorspaceClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_COLORSPACE_NONE,
|
||||
GST_COLORSPACE_HERMES,
|
||||
GST_COLORSPACE_YUV_RGB,
|
||||
|
@ -47,11 +48,10 @@ typedef enum
|
|||
GST_COLORSPACE_420_SWAP,
|
||||
} GstColorSpaceConverterType;
|
||||
|
||||
struct _GstColorspace
|
||||
{
|
||||
struct _GstColorspace {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
int converter_index;
|
||||
|
||||
|
@ -60,7 +60,7 @@ struct _GstColorspace
|
|||
|
||||
int src_size;
|
||||
int sink_size;
|
||||
|
||||
|
||||
int src_stride;
|
||||
int sink_stride;
|
||||
|
||||
|
@ -68,21 +68,18 @@ struct _GstColorspace
|
|||
gdouble fps;
|
||||
};
|
||||
|
||||
struct _GstColorspaceClass
|
||||
{
|
||||
struct _GstColorspaceClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_colorspace_get_type (void);
|
||||
GType gst_colorspace_get_type(void);
|
||||
|
||||
typedef struct _GstColorspaceFormat
|
||||
{
|
||||
typedef struct _GstColorspaceFormat {
|
||||
GstStaticCaps caps;
|
||||
|
||||
} GstColorspaceFormat;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_COLORSPACE_I420,
|
||||
GST_COLORSPACE_YV12,
|
||||
GST_COLORSPACE_RGB32,
|
||||
|
@ -90,13 +87,13 @@ typedef enum
|
|||
GST_COLORSPACE_RGB16,
|
||||
} GstColorSpaceFormatType;
|
||||
|
||||
typedef struct _GstColorspaceConverter
|
||||
{
|
||||
typedef struct _GstColorspaceConverter {
|
||||
GstColorSpaceFormatType from;
|
||||
GstColorSpaceFormatType to;
|
||||
void (*convert) (GstColorspace * colorspace, unsigned char *dest,
|
||||
unsigned char *src);
|
||||
void (*convert) (GstColorspace *colorspace, unsigned char *dest, unsigned char *src);
|
||||
} GstColorspaceConverter;
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -26,11 +26,11 @@
|
|||
#include <gstcolorspace.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#if 0
|
||||
typedef struct _GstColorspaceYUVTables GstColorspaceYUVTables;
|
||||
|
||||
struct _GstColorspaceYUVTables
|
||||
{
|
||||
struct _GstColorspaceYUVTables {
|
||||
int gammaCorrectFlag;
|
||||
double gammaCorrect;
|
||||
int chromaCorrectFlag;
|
||||
|
@ -50,11 +50,9 @@ struct _GstColorspaceYUVTables
|
|||
|
||||
|
||||
typedef struct _GstColorspaceConverter GstColorspaceConverter;
|
||||
typedef void (*GstColorspaceConvertFunction) (GstColorspaceConverter * space,
|
||||
guchar * src, guchar * dest);
|
||||
typedef void (*GstColorspaceConvertFunction) (GstColorspaceConverter *space, guchar *src, guchar *dest);
|
||||
|
||||
struct _GstColorspaceConverter
|
||||
{
|
||||
struct _GstColorspaceConverter {
|
||||
guint width;
|
||||
guint height;
|
||||
guint insize;
|
||||
|
@ -65,34 +63,35 @@ struct _GstColorspaceConverter
|
|||
};
|
||||
#endif
|
||||
|
||||
void gst_colorspace_table_init (GstColorspace * space);
|
||||
void gst_colorspace_table_init (GstColorspace *space);
|
||||
|
||||
void gst_colorspace_I420_to_rgb32 (GstColorspace * space,
|
||||
void gst_colorspace_I420_to_rgb32(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
void gst_colorspace_I420_to_rgb24 (GstColorspace * space,
|
||||
void gst_colorspace_I420_to_rgb24(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
void gst_colorspace_I420_to_rgb16 (GstColorspace * space,
|
||||
void gst_colorspace_I420_to_rgb16(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
void gst_colorspace_YV12_to_rgb32 (GstColorspace * space,
|
||||
void gst_colorspace_YV12_to_rgb32(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
void gst_colorspace_YV12_to_rgb24 (GstColorspace * space,
|
||||
void gst_colorspace_YV12_to_rgb24(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
void gst_colorspace_YV12_to_rgb16 (GstColorspace * space,
|
||||
void gst_colorspace_YV12_to_rgb16(GstColorspace *space,
|
||||
unsigned char *src, unsigned char *dest);
|
||||
|
||||
#if 0
|
||||
GstColorspaceYUVTables *gst_colorspace_init_yuv (long depth,
|
||||
GstColorspaceYUVTables * gst_colorspace_init_yuv(long depth,
|
||||
long red_mask, long green_mask, long blue_mask);
|
||||
#endif
|
||||
|
||||
|
||||
#if 0
|
||||
GstColorspaceConverter *gst_colorspace_yuv2rgb_get_converter (const GstCaps *
|
||||
from, const GstCaps * to);
|
||||
GstColorspaceConverter* gst_colorspace_yuv2rgb_get_converter (const GstCaps *from, const GstCaps *to);
|
||||
#define gst_colorspace_convert(converter, src, dest) \
|
||||
(converter)->convert((converter), (src), (dest))
|
||||
void gst_colorspace_converter_destroy (GstColorspaceConverter * space);
|
||||
void gst_colorspace_converter_destroy (GstColorspaceConverter *space);
|
||||
#endif
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
/* #include <gst/meta/audioraw.h> */
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_DEINTERLACE \
|
||||
(gst_deinterlace_get_type())
|
||||
#define GST_DEINTERLACE(obj) \
|
||||
|
@ -36,11 +37,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_DEINTERLACE))
|
||||
#define GST_IS_DEINTERLACE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_DEINTERLACE))
|
||||
|
||||
typedef struct _GstDeInterlace GstDeInterlace;
|
||||
typedef struct _GstDeInterlaceClass GstDeInterlaceClass;
|
||||
|
||||
struct _GstDeInterlace
|
||||
{
|
||||
struct _GstDeInterlace {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
@ -49,8 +50,8 @@ struct _GstDeInterlace
|
|||
|
||||
gboolean show_deinterlaced_area_only;
|
||||
gboolean blend;
|
||||
gint threshold_blend; /* here we start blending */
|
||||
gint threshold; /* here we start interpolating TODO FIXME */
|
||||
gint threshold_blend; /* here we start blending */
|
||||
gint threshold; /* here we start interpolating TODO FIXME */
|
||||
gint edge_detect;
|
||||
|
||||
gint picsize;
|
||||
|
@ -58,10 +59,10 @@ struct _GstDeInterlace
|
|||
|
||||
};
|
||||
|
||||
struct _GstDeInterlaceClass
|
||||
{
|
||||
struct _GstDeInterlaceClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_DEINTERLACE_H__ */
|
||||
|
|
|
@ -64,24 +64,23 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define FESTIVAL_DEFAULT_SERVER_HOST "localhost"
|
||||
#define FESTIVAL_DEFAULT_SERVER_PORT 1314
|
||||
#define FESTIVAL_DEFAULT_TEXT_MODE "fundamental"
|
||||
|
||||
typedef struct FT_Info
|
||||
{
|
||||
typedef struct FT_Info
|
||||
{
|
||||
int encoding;
|
||||
char *server_host;
|
||||
int server_port;
|
||||
char *text_mode;
|
||||
|
||||
|
||||
int server_fd;
|
||||
} FT_Info;
|
||||
} FT_Info;
|
||||
|
||||
#define GST_TYPE_FESTIVAL \
|
||||
(gst_festival_get_type())
|
||||
|
@ -94,35 +93,32 @@ extern "C"
|
|||
#define GST_IS_FESTIVAL_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FESTIVAL))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_FESTIVAL_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
typedef enum {
|
||||
GST_FESTIVAL_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_FESTIVAL_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstFestivalFlags;
|
||||
GST_FESTIVAL_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2,
|
||||
} GstFestivalFlags;
|
||||
|
||||
typedef struct _GstFestival GstFestival;
|
||||
typedef struct _GstFestivalClass GstFestivalClass;
|
||||
typedef struct _GstFestival GstFestival;
|
||||
typedef struct _GstFestivalClass GstFestivalClass;
|
||||
|
||||
struct _GstFestival
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstFestival {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad, *srcpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
FT_Info *info;
|
||||
};
|
||||
FT_Info *info;
|
||||
};
|
||||
|
||||
struct _GstFestivalClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstFestivalClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_festival_get_type (void);
|
||||
GType gst_festival_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_FESTIVAL_H__ */
|
||||
#endif /* __GST_FESTIVAL_H__ */
|
||||
|
|
|
@ -19,8 +19,7 @@
|
|||
#ifndef _V_IIR_H_
|
||||
#define _V_IIR_H_
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
int stages;
|
||||
double *coeff_A;
|
||||
double *coeff_B;
|
||||
|
@ -30,9 +29,9 @@ typedef struct
|
|||
double gain;
|
||||
} IIR_state;
|
||||
|
||||
void IIR_init (IIR_state * s, int stages, double gain, double *A, double *B);
|
||||
void IIR_clear (IIR_state * s);
|
||||
double IIR_filter (IIR_state * s, double in);
|
||||
double IIR_filter_ChebBand (IIR_state * s, double in);
|
||||
void IIR_init(IIR_state *s,int stages,double gain, double *A, double *B);
|
||||
void IIR_clear(IIR_state *s);
|
||||
double IIR_filter(IIR_state *s,double in);
|
||||
double IIR_filter_ChebBand(IIR_state *s,double in);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -17,8 +17,7 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
FLX_COLORSPACE_RGB8,
|
||||
FLX_COLORSPACE_RGB32,
|
||||
} FlxColorSpaceType;
|
||||
|
@ -26,20 +25,19 @@ typedef enum
|
|||
|
||||
typedef struct _FlxColorSpaceConverter FlxColorSpaceConverter;
|
||||
|
||||
struct _FlxColorSpaceConverter
|
||||
{
|
||||
guint width;
|
||||
guint height;
|
||||
guchar palvec[768];
|
||||
struct _FlxColorSpaceConverter {
|
||||
guint width;
|
||||
guint height;
|
||||
guchar palvec[768];
|
||||
};
|
||||
|
||||
|
||||
void flx_colorspace_converter_destroy (FlxColorSpaceConverter * flxpal);
|
||||
void flx_colorspace_convert (FlxColorSpaceConverter * flxpal, guchar * src,
|
||||
guchar * dest);
|
||||
FlxColorSpaceConverter *flx_colorspace_converter_new (gint width, gint height);
|
||||
void flx_colorspace_converter_destroy(FlxColorSpaceConverter *flxpal);
|
||||
void flx_colorspace_convert(FlxColorSpaceConverter *flxpal, guchar *src, guchar *dest);
|
||||
FlxColorSpaceConverter * flx_colorspace_converter_new(gint width, gint height);
|
||||
|
||||
void flx_set_palette_vector(FlxColorSpaceConverter *flxpal, guint start, guint num,
|
||||
guchar *newpal, gint scale);
|
||||
void flx_set_color(FlxColorSpaceConverter *flxpal, guint colr, guint red, guint green,
|
||||
guint blue, gint scale);
|
||||
|
||||
void flx_set_palette_vector (FlxColorSpaceConverter * flxpal, guint start,
|
||||
guint num, guchar * newpal, gint scale);
|
||||
void flx_set_color (FlxColorSpaceConverter * flxpal, guint colr, guint red,
|
||||
guint green, guint blue, gint scale);
|
||||
|
|
|
@ -24,114 +24,113 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
enum Flx_TypeChunk
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
/* frame chunks */
|
||||
FLX_PREFIX_TYPE = 0xf100,
|
||||
FLX_SCRIPT_CHUNK = 0xf1e0,
|
||||
FLX_FRAME_TYPE = 0xf1fa,
|
||||
FLX_SEGMENT_TABLE = 0xf1fb,
|
||||
FLX_HUFFMAN_TABLE = 0xf1fc,
|
||||
|
||||
enum Flx_TypeChunk
|
||||
{
|
||||
/* frame chunks */
|
||||
FLX_PREFIX_TYPE = 0xf100,
|
||||
FLX_SCRIPT_CHUNK = 0xf1e0,
|
||||
FLX_FRAME_TYPE = 0xf1fa,
|
||||
FLX_SEGMENT_TABLE = 0xf1fb,
|
||||
FLX_HUFFMAN_TABLE = 0xf1fc,
|
||||
/* sub chunks */
|
||||
FLX_CEL_DATA = 3,
|
||||
FLX_COLOR256 = 4,
|
||||
FLX_SS2 = 7,
|
||||
FLX_COLOR64 = 11,
|
||||
FLX_LC = 12,
|
||||
FLX_BLACK = 13,
|
||||
FLX_BRUN = 15,
|
||||
FLX_COPY = 16,
|
||||
FLX_MINI = 18,
|
||||
FLX_DTA_RUN = 25,
|
||||
FLX_DTA_COPY = 26,
|
||||
FLX_DTA_LC = 27,
|
||||
FLX_LABEL = 31,
|
||||
FLX_BMP_MASK = 32,
|
||||
FLX_MLEV_MASK = 33,
|
||||
FLX_SEGMENT = 34,
|
||||
FLX_KEY_IMAGE = 35,
|
||||
FLX_KEY_PAL = 36,
|
||||
FLX_REGION = 37,
|
||||
FLX_WAVE = 38,
|
||||
FLX_USERSTRING = 39,
|
||||
FLX_RGN_MASK = 40,
|
||||
|
||||
/* sub chunks */
|
||||
FLX_CEL_DATA = 3,
|
||||
FLX_COLOR256 = 4,
|
||||
FLX_SS2 = 7,
|
||||
FLX_COLOR64 = 11,
|
||||
FLX_LC = 12,
|
||||
FLX_BLACK = 13,
|
||||
FLX_BRUN = 15,
|
||||
FLX_COPY = 16,
|
||||
FLX_MINI = 18,
|
||||
FLX_DTA_RUN = 25,
|
||||
FLX_DTA_COPY = 26,
|
||||
FLX_DTA_LC = 27,
|
||||
FLX_LABEL = 31,
|
||||
FLX_BMP_MASK = 32,
|
||||
FLX_MLEV_MASK = 33,
|
||||
FLX_SEGMENT = 34,
|
||||
FLX_KEY_IMAGE = 35,
|
||||
FLX_KEY_PAL = 36,
|
||||
FLX_REGION = 37,
|
||||
FLX_WAVE = 38,
|
||||
FLX_USERSTRING = 39,
|
||||
FLX_RGN_MASK = 40,
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
enum Flx_MagicHdr
|
||||
{
|
||||
FLX_MAGICHDR_FLI = 0xaf11,
|
||||
FLX_MAGICHDR_FLC = 0xaf12,
|
||||
FLX_MAGICHDR_FLX = 0xaf44,
|
||||
FLX_MAGICHDR_HUFFBWT = 0xaf30,
|
||||
};
|
||||
enum Flx_MagicHdr
|
||||
{
|
||||
FLX_MAGICHDR_FLI = 0xaf11,
|
||||
FLX_MAGICHDR_FLC = 0xaf12,
|
||||
FLX_MAGICHDR_FLX = 0xaf44,
|
||||
FLX_MAGICHDR_HUFFBWT = 0xaf30,
|
||||
};
|
||||
|
||||
|
||||
|
||||
typedef struct _FlxHeader
|
||||
{
|
||||
guint32 size;
|
||||
guint16 type;
|
||||
guint16 frames;
|
||||
guint16 width, height, depth, flags;
|
||||
guint32 speed;
|
||||
guint16 reserved1;
|
||||
/* FLC */
|
||||
guint32 created, creator, updated, updater;
|
||||
guint16 aspect_dx, aspect_dy;
|
||||
/* EGI */
|
||||
guint16 ext_flags, keyframes, totalframes;
|
||||
guint32 req_memory;
|
||||
guint16 max_regions, transp_num;
|
||||
guchar reserved2[24];
|
||||
/* FLC */
|
||||
guint32 oframe1, oframe2;
|
||||
guchar reserved3[40];
|
||||
} FlxHeader;
|
||||
typedef struct _FlxHeader
|
||||
{
|
||||
guint32 size;
|
||||
guint16 type;
|
||||
guint16 frames;
|
||||
guint16 width,height,depth,flags;
|
||||
guint32 speed;
|
||||
guint16 reserved1;
|
||||
/* FLC */
|
||||
guint32 created,creator,updated,updater;
|
||||
guint16 aspect_dx, aspect_dy;
|
||||
/* EGI */
|
||||
guint16 ext_flags,keyframes,totalframes;
|
||||
guint32 req_memory;
|
||||
guint16 max_regions,transp_num;
|
||||
guchar reserved2[24];
|
||||
/* FLC */
|
||||
guint32 oframe1,oframe2;
|
||||
guchar reserved3[40];
|
||||
} FlxHeader;
|
||||
#define FlxHeaderSize 128
|
||||
|
||||
typedef struct _FlxFrameChunk
|
||||
{
|
||||
guint32 size;
|
||||
guint16 id;
|
||||
} FlxFrameChunk;
|
||||
typedef struct _FlxFrameChunk
|
||||
{
|
||||
guint32 size;
|
||||
guint16 id;
|
||||
} FlxFrameChunk;
|
||||
#define FlxFrameChunkSize 6
|
||||
|
||||
typedef struct _FlxPrefixChunk
|
||||
{
|
||||
guint16 chunks;
|
||||
guchar reserved[8];
|
||||
} FlxPrefixChunk;
|
||||
typedef struct _FlxPrefixChunk
|
||||
{
|
||||
guint16 chunks;
|
||||
guchar reserved[8];
|
||||
} FlxPrefixChunk;
|
||||
|
||||
typedef struct _FlxSegmentTable
|
||||
{
|
||||
guint16 segments;
|
||||
} FlxSegmentTable;
|
||||
typedef struct _FlxSegmentTable
|
||||
{
|
||||
guint16 segments;
|
||||
} FlxSegmentTable;
|
||||
|
||||
typedef struct _FlxHuffmanTable
|
||||
{
|
||||
guint16 codelength;
|
||||
guint16 numcodes;
|
||||
guchar reserved[6];
|
||||
} FlxHuffmanTable;
|
||||
typedef struct _FlxHuffmanTable
|
||||
{
|
||||
guint16 codelength;
|
||||
guint16 numcodes;
|
||||
guchar reserved[6];
|
||||
} FlxHuffmanTable;
|
||||
|
||||
typedef struct _FlxFrameType
|
||||
{
|
||||
guint16 chunks;
|
||||
guint16 delay;
|
||||
guchar reserved[6];
|
||||
} FlxFrameType;
|
||||
typedef struct _FlxFrameType
|
||||
{
|
||||
guint16 chunks;
|
||||
guint16 delay;
|
||||
guchar reserved[6];
|
||||
} FlxFrameType;
|
||||
#define FlxFrameTypeSize 10
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_FLX_FMT_H__ */
|
||||
#endif /* __GST_FLX_FMT_H__ */
|
||||
|
|
|
@ -27,46 +27,42 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
typedef enum
|
||||
{
|
||||
GST_FLXDEC_READ_HEADER,
|
||||
GST_FLXDEC_PLAYING,
|
||||
} GstFlxDecState;
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
typedef enum {
|
||||
GST_FLXDEC_READ_HEADER,
|
||||
GST_FLXDEC_PLAYING,
|
||||
} GstFlxDecState;
|
||||
|
||||
|
||||
/* Definition of structure storing data for this element. */
|
||||
typedef struct _GstFlxDec GstFlxDec;
|
||||
typedef struct _GstFlxDec GstFlxDec;
|
||||
|
||||
struct _GstFlxDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstFlxDec {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gboolean active, new_meta;
|
||||
gboolean active, new_meta;
|
||||
|
||||
GstBuffer *delta, *frame;
|
||||
GstByteStream *bs;
|
||||
gulong size;
|
||||
GstFlxDecState state;
|
||||
glong frame_time;
|
||||
gint64 next_time;
|
||||
GstBuffer *delta, *frame;
|
||||
GstByteStream *bs;
|
||||
gulong size;
|
||||
GstFlxDecState state;
|
||||
glong frame_time;
|
||||
gint64 next_time;
|
||||
|
||||
FlxColorSpaceConverter *converter;
|
||||
FlxColorSpaceConverter *converter;
|
||||
|
||||
FlxHeader hdr;
|
||||
};
|
||||
FlxHeader hdr;
|
||||
};
|
||||
|
||||
/* Standard definition defining a class for this element. */
|
||||
typedef struct _GstFlxDecClass GstFlxDecClass;
|
||||
struct _GstFlxDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
typedef struct _GstFlxDecClass GstFlxDecClass;
|
||||
struct _GstFlxDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
/* Standard macros for defining types for this element. */
|
||||
#define GST_TYPE_FLXDEC \
|
||||
|
@ -81,12 +77,12 @@ extern "C"
|
|||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FLXDEC))
|
||||
|
||||
/* Standard function returning type information. */
|
||||
GType gst_flxdec_get_type (void);
|
||||
GType gst_flxdec_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_FLX_DECODER_H__ */
|
||||
#endif /* __GST_FLX_DECODER_H__ */
|
||||
|
|
|
@ -22,16 +22,15 @@
|
|||
#define __GST_MODPLUG_H__
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#include <gst/gst.h>
|
||||
#include <gst/bytestream/bytestream.h>
|
||||
|
||||
|
||||
#define GST_TYPE_MODPLUG \
|
||||
(gst_modplug_get_type())
|
||||
|
||||
|
||||
#define GST_MODPLUG(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_MODPLUG,GstModPlug))
|
||||
#define GST_MODPLUG_CLASS(klass) \
|
||||
|
@ -40,59 +39,57 @@ extern "C"
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_MODPLUG))
|
||||
#define GST_IS_MODPLUG_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MODPLUG))
|
||||
|
||||
struct _GstModPlug {
|
||||
GstElement element;
|
||||
GstPad *sinkpad, *srcpad;
|
||||
guint8 *buffer_in;
|
||||
GstByteStream *bs;
|
||||
|
||||
struct _GstModPlug
|
||||
{
|
||||
GstElement element;
|
||||
GstPad *sinkpad, *srcpad;
|
||||
guint8 *buffer_in;
|
||||
GstByteStream *bs;
|
||||
const gchar *songname;
|
||||
gboolean reverb;
|
||||
gint reverb_depth;
|
||||
gint reverb_delay;
|
||||
gboolean megabass;
|
||||
gint megabass_amount;
|
||||
gint megabass_range;
|
||||
gboolean surround;
|
||||
gint surround_depth;
|
||||
gint surround_delay;
|
||||
gboolean noise_reduction;
|
||||
gboolean _16bit;
|
||||
gboolean oversamp;
|
||||
gint channel;
|
||||
gint frequency;
|
||||
|
||||
const gchar *songname;
|
||||
gboolean reverb;
|
||||
gint reverb_depth;
|
||||
gint reverb_delay;
|
||||
gboolean megabass;
|
||||
gint megabass_amount;
|
||||
gint megabass_range;
|
||||
gboolean surround;
|
||||
gint surround_depth;
|
||||
gint surround_delay;
|
||||
gboolean noise_reduction;
|
||||
gboolean _16bit;
|
||||
gboolean oversamp;
|
||||
gint channel;
|
||||
gint frequency;
|
||||
guchar *audiobuffer;
|
||||
gint32 length;
|
||||
guint state;
|
||||
guint bitsPerSample;
|
||||
gboolean need_discont;
|
||||
gboolean eos;
|
||||
gint64 seek_at;
|
||||
guint64 song_size;
|
||||
guint64 timestamp;
|
||||
|
||||
guchar *audiobuffer;
|
||||
gint32 length;
|
||||
guint state;
|
||||
guint bitsPerSample;
|
||||
gboolean need_discont;
|
||||
gboolean eos;
|
||||
gint64 seek_at;
|
||||
guint64 song_size;
|
||||
guint64 timestamp;
|
||||
CSoundFile *mSoundFile;
|
||||
gboolean opened; /* set to TRUE when mSoundFile is created */
|
||||
};
|
||||
|
||||
CSoundFile *mSoundFile;
|
||||
gboolean opened; /* set to TRUE when mSoundFile is created */
|
||||
};
|
||||
struct _GstModPlugClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
struct _GstModPlugClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
typedef struct _GstModPlug GstModPlug;
|
||||
typedef struct _GstModPlugClass GstModPlugClass;
|
||||
|
||||
typedef struct _GstModPlug GstModPlug;
|
||||
typedef struct _GstModPlugClass GstModPlugClass;
|
||||
GstPad *srcpad;
|
||||
int need_sync;
|
||||
|
||||
GstPad *srcpad;
|
||||
int need_sync;
|
||||
|
||||
GType gst_modplug_get_type (void);
|
||||
GType gst_modplug_get_type(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_MODPLUG_H__ */
|
||||
#endif /* __GST_MODPLUG_H__ */
|
||||
|
|
|
@ -5,125 +5,125 @@
|
|||
|
||||
typedef struct tagITFILEHEADER
|
||||
{
|
||||
DWORD id; /* 0x4D504D49 */
|
||||
CHAR songname[26];
|
||||
WORD reserved1; /* 0x1004 */
|
||||
WORD ordnum;
|
||||
WORD insnum;
|
||||
WORD smpnum;
|
||||
WORD patnum;
|
||||
WORD cwtv;
|
||||
WORD cmwt;
|
||||
WORD flags;
|
||||
WORD special;
|
||||
BYTE globalvol;
|
||||
BYTE mv;
|
||||
BYTE speed;
|
||||
BYTE tempo;
|
||||
BYTE sep;
|
||||
BYTE zero;
|
||||
WORD msglength;
|
||||
DWORD msgoffset;
|
||||
DWORD reserved2;
|
||||
BYTE chnpan[64];
|
||||
BYTE chnvol[64];
|
||||
DWORD id; /* 0x4D504D49 */
|
||||
CHAR songname[26];
|
||||
WORD reserved1; /* 0x1004 */
|
||||
WORD ordnum;
|
||||
WORD insnum;
|
||||
WORD smpnum;
|
||||
WORD patnum;
|
||||
WORD cwtv;
|
||||
WORD cmwt;
|
||||
WORD flags;
|
||||
WORD special;
|
||||
BYTE globalvol;
|
||||
BYTE mv;
|
||||
BYTE speed;
|
||||
BYTE tempo;
|
||||
BYTE sep;
|
||||
BYTE zero;
|
||||
WORD msglength;
|
||||
DWORD msgoffset;
|
||||
DWORD reserved2;
|
||||
BYTE chnpan[64];
|
||||
BYTE chnvol[64];
|
||||
} ITFILEHEADER;
|
||||
|
||||
|
||||
typedef struct tagITENVELOPE
|
||||
{
|
||||
BYTE flags;
|
||||
BYTE num;
|
||||
BYTE lpb;
|
||||
BYTE lpe;
|
||||
BYTE slb;
|
||||
BYTE sle;
|
||||
BYTE data[25 * 3];
|
||||
BYTE reserved;
|
||||
BYTE flags;
|
||||
BYTE num;
|
||||
BYTE lpb;
|
||||
BYTE lpe;
|
||||
BYTE slb;
|
||||
BYTE sle;
|
||||
BYTE data[25*3];
|
||||
BYTE reserved;
|
||||
} ITENVELOPE;
|
||||
|
||||
/* Old Impulse Instrument Format (cmwt < 0x200) */
|
||||
typedef struct tagITOLDINSTRUMENT
|
||||
{
|
||||
DWORD id; /* IMPI = 0x49504D49 */
|
||||
CHAR filename[12]; /* DOS file name */
|
||||
BYTE zero;
|
||||
BYTE flags;
|
||||
BYTE vls;
|
||||
BYTE vle;
|
||||
BYTE sls;
|
||||
BYTE sle;
|
||||
WORD reserved1;
|
||||
WORD fadeout;
|
||||
BYTE nna;
|
||||
BYTE dnc;
|
||||
WORD trkvers;
|
||||
BYTE nos;
|
||||
BYTE reserved2;
|
||||
CHAR name[26];
|
||||
WORD reserved3[3];
|
||||
BYTE keyboard[240];
|
||||
BYTE volenv[200];
|
||||
BYTE nodes[50];
|
||||
DWORD id; /* IMPI = 0x49504D49 */
|
||||
CHAR filename[12]; /* DOS file name */
|
||||
BYTE zero;
|
||||
BYTE flags;
|
||||
BYTE vls;
|
||||
BYTE vle;
|
||||
BYTE sls;
|
||||
BYTE sle;
|
||||
WORD reserved1;
|
||||
WORD fadeout;
|
||||
BYTE nna;
|
||||
BYTE dnc;
|
||||
WORD trkvers;
|
||||
BYTE nos;
|
||||
BYTE reserved2;
|
||||
CHAR name[26];
|
||||
WORD reserved3[3];
|
||||
BYTE keyboard[240];
|
||||
BYTE volenv[200];
|
||||
BYTE nodes[50];
|
||||
} ITOLDINSTRUMENT;
|
||||
|
||||
|
||||
/* Impulse Instrument Format */
|
||||
typedef struct tagITINSTRUMENT
|
||||
{
|
||||
DWORD id;
|
||||
CHAR filename[12];
|
||||
BYTE zero;
|
||||
BYTE nna;
|
||||
BYTE dct;
|
||||
BYTE dca;
|
||||
WORD fadeout;
|
||||
signed char pps;
|
||||
BYTE ppc;
|
||||
BYTE gbv;
|
||||
BYTE dfp;
|
||||
BYTE rv;
|
||||
BYTE rp;
|
||||
WORD trkvers;
|
||||
BYTE nos;
|
||||
BYTE reserved1;
|
||||
CHAR name[26];
|
||||
BYTE ifc;
|
||||
BYTE ifr;
|
||||
BYTE mch;
|
||||
BYTE mpr;
|
||||
WORD mbank;
|
||||
BYTE keyboard[240];
|
||||
ITENVELOPE volenv;
|
||||
ITENVELOPE panenv;
|
||||
ITENVELOPE pitchenv;
|
||||
BYTE dummy[4]; /* was 7, but IT v2.17 saves 554 bytes */
|
||||
DWORD id;
|
||||
CHAR filename[12];
|
||||
BYTE zero;
|
||||
BYTE nna;
|
||||
BYTE dct;
|
||||
BYTE dca;
|
||||
WORD fadeout;
|
||||
signed char pps;
|
||||
BYTE ppc;
|
||||
BYTE gbv;
|
||||
BYTE dfp;
|
||||
BYTE rv;
|
||||
BYTE rp;
|
||||
WORD trkvers;
|
||||
BYTE nos;
|
||||
BYTE reserved1;
|
||||
CHAR name[26];
|
||||
BYTE ifc;
|
||||
BYTE ifr;
|
||||
BYTE mch;
|
||||
BYTE mpr;
|
||||
WORD mbank;
|
||||
BYTE keyboard[240];
|
||||
ITENVELOPE volenv;
|
||||
ITENVELOPE panenv;
|
||||
ITENVELOPE pitchenv;
|
||||
BYTE dummy[4]; /* was 7, but IT v2.17 saves 554 bytes */
|
||||
} ITINSTRUMENT;
|
||||
|
||||
|
||||
/* IT Sample Format */
|
||||
typedef struct ITSAMPLESTRUCT
|
||||
{
|
||||
DWORD id; /* 0x53504D49 */
|
||||
CHAR filename[12];
|
||||
BYTE zero;
|
||||
BYTE gvl;
|
||||
BYTE flags;
|
||||
BYTE vol;
|
||||
CHAR name[26];
|
||||
BYTE cvt;
|
||||
BYTE dfp;
|
||||
DWORD length;
|
||||
DWORD loopbegin;
|
||||
DWORD loopend;
|
||||
DWORD C5Speed;
|
||||
DWORD susloopbegin;
|
||||
DWORD susloopend;
|
||||
DWORD samplepointer;
|
||||
BYTE vis;
|
||||
BYTE vid;
|
||||
BYTE vir;
|
||||
BYTE vit;
|
||||
DWORD id; /* 0x53504D49 */
|
||||
CHAR filename[12];
|
||||
BYTE zero;
|
||||
BYTE gvl;
|
||||
BYTE flags;
|
||||
BYTE vol;
|
||||
CHAR name[26];
|
||||
BYTE cvt;
|
||||
BYTE dfp;
|
||||
DWORD length;
|
||||
DWORD loopbegin;
|
||||
DWORD loopend;
|
||||
DWORD C5Speed;
|
||||
DWORD susloopbegin;
|
||||
DWORD susloopend;
|
||||
DWORD samplepointer;
|
||||
BYTE vis;
|
||||
BYTE vid;
|
||||
BYTE vir;
|
||||
BYTE vit;
|
||||
} ITSAMPLESTRUCT;
|
||||
|
||||
#pragma pack()
|
||||
|
|
|
@ -8,31 +8,30 @@
|
|||
#define MODPLUG_H__INCLUDED
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct _ModPlugFile;
|
||||
typedef struct _ModPlugFile ModPlugFile;
|
||||
struct _ModPlugFile;
|
||||
typedef struct _ModPlugFile ModPlugFile;
|
||||
|
||||
/* Load a mod file. [data] should point to a block of memory containing the complete
|
||||
* file, and [size] should be the size of that block.
|
||||
* Return the loaded mod file on success, or NULL on failure. */
|
||||
ModPlugFile *ModPlug_Load (const void *data, int size);
|
||||
ModPlugFile* ModPlug_Load(const void* data, int size);
|
||||
/* Unload a mod file. */
|
||||
void ModPlug_Unload (ModPlugFile * file);
|
||||
void ModPlug_Unload(ModPlugFile* file);
|
||||
|
||||
/* Read sample data into the buffer. Returns the number of bytes read. If the end
|
||||
* of the mod has been reached, zero is returned. */
|
||||
int ModPlug_Read (ModPlugFile * file, void *buffer, int size);
|
||||
int ModPlug_Read(ModPlugFile* file, void* buffer, int size);
|
||||
|
||||
/* Get the name of the mod. The returned buffer is stored within the ModPlugFile
|
||||
* structure and will remain valid until you unload the file. */
|
||||
const char *ModPlug_GetName (ModPlugFile * file);
|
||||
const char* ModPlug_GetName(ModPlugFile* file);
|
||||
|
||||
/* Get the length of the mod, in milliseconds. Note that this result is not always
|
||||
* accurate, especially in the case of mods with loops. */
|
||||
int ModPlug_GetLength (ModPlugFile * file);
|
||||
int ModPlug_GetLength(ModPlugFile* file);
|
||||
|
||||
/* Seek to a particular position in the song. Note that seeking and MODs don't mix very
|
||||
* well. Some mods will be missing instruments for a short time after a seek, as ModPlug
|
||||
|
@ -40,54 +39,54 @@ extern "C"
|
|||
* playing at that time. (Doing so would be difficult and not very reliable.) Also,
|
||||
* note that seeking is not very exact in some mods -- especially those for which
|
||||
* ModPlug_GetLength() does not report the full length. */
|
||||
void ModPlug_Seek (ModPlugFile * file, int millisecond);
|
||||
void ModPlug_Seek(ModPlugFile* file, int millisecond);
|
||||
|
||||
enum _ModPlug_Flags
|
||||
{
|
||||
MODPLUG_ENABLE_OVERSAMPLING = 1 << 0, /* Enable oversampling (*highly* recommended) */
|
||||
MODPLUG_ENABLE_NOISE_REDUCTION = 1 << 1, /* Enable noise reduction */
|
||||
MODPLUG_ENABLE_REVERB = 1 << 2, /* Enable reverb */
|
||||
MODPLUG_ENABLE_MEGABASS = 1 << 3, /* Enable megabass */
|
||||
MODPLUG_ENABLE_SURROUND = 1 << 4 /* Enable surround sound. */
|
||||
};
|
||||
enum _ModPlug_Flags
|
||||
{
|
||||
MODPLUG_ENABLE_OVERSAMPLING = 1 << 0, /* Enable oversampling (*highly* recommended) */
|
||||
MODPLUG_ENABLE_NOISE_REDUCTION = 1 << 1, /* Enable noise reduction */
|
||||
MODPLUG_ENABLE_REVERB = 1 << 2, /* Enable reverb */
|
||||
MODPLUG_ENABLE_MEGABASS = 1 << 3, /* Enable megabass */
|
||||
MODPLUG_ENABLE_SURROUND = 1 << 4 /* Enable surround sound. */
|
||||
};
|
||||
|
||||
enum _ModPlug_ResamplingMode
|
||||
{
|
||||
MODPLUG_RESAMPLE_NEAREST = 0, /* No interpolation (very fast, extremely bad sound quality) */
|
||||
MODPLUG_RESAMPLE_LINEAR = 1, /* Linear interpolation (fast, good quality) */
|
||||
MODPLUG_RESAMPLE_SPLINE = 2, /* Cubic spline interpolation (high quality) */
|
||||
MODPLUG_RESAMPLE_FIR = 3 /* 8-tap fir filter (extremely high quality) */
|
||||
};
|
||||
enum _ModPlug_ResamplingMode
|
||||
{
|
||||
MODPLUG_RESAMPLE_NEAREST = 0, /* No interpolation (very fast, extremely bad sound quality) */
|
||||
MODPLUG_RESAMPLE_LINEAR = 1, /* Linear interpolation (fast, good quality) */
|
||||
MODPLUG_RESAMPLE_SPLINE = 2, /* Cubic spline interpolation (high quality) */
|
||||
MODPLUG_RESAMPLE_FIR = 3 /* 8-tap fir filter (extremely high quality) */
|
||||
};
|
||||
|
||||
typedef struct _ModPlug_Settings
|
||||
{
|
||||
int mFlags; /* One or more of the MODPLUG_ENABLE_* flags above, bitwise-OR'ed */
|
||||
|
||||
/* Note that ModPlug always decodes sound at 44100kHz, 32 bit, stereo and then
|
||||
* down-mixes to the settings you choose. */
|
||||
int mChannels; /* Number of channels - 1 for mono or 2 for stereo */
|
||||
int mBits; /* Bits per sample - 8, 16, or 32 */
|
||||
int mFrequency; /* Sampling rate - 11025, 22050, or 44100 */
|
||||
int mResamplingMode; /* One of MODPLUG_RESAMPLE_*, above */
|
||||
|
||||
int mReverbDepth; /* Reverb level 0(quiet)-100(loud) */
|
||||
int mReverbDelay; /* Reverb delay in ms, usually 40-200ms */
|
||||
int mBassAmount; /* XBass level 0(quiet)-100(loud) */
|
||||
int mBassRange; /* XBass cutoff in Hz 10-100 */
|
||||
int mSurroundDepth; /* Surround level 0(quiet)-100(heavy) */
|
||||
int mSurroundDelay; /* Surround delay in ms, usually 5-40ms */
|
||||
int mLoopCount; /* Number of times to loop. Zero prevents looping.
|
||||
-1 loops forever. */
|
||||
} ModPlug_Settings;
|
||||
typedef struct _ModPlug_Settings
|
||||
{
|
||||
int mFlags; /* One or more of the MODPLUG_ENABLE_* flags above, bitwise-OR'ed */
|
||||
|
||||
/* Note that ModPlug always decodes sound at 44100kHz, 32 bit, stereo and then
|
||||
* down-mixes to the settings you choose. */
|
||||
int mChannels; /* Number of channels - 1 for mono or 2 for stereo */
|
||||
int mBits; /* Bits per sample - 8, 16, or 32 */
|
||||
int mFrequency; /* Sampling rate - 11025, 22050, or 44100 */
|
||||
int mResamplingMode; /* One of MODPLUG_RESAMPLE_*, above */
|
||||
|
||||
int mReverbDepth; /* Reverb level 0(quiet)-100(loud) */
|
||||
int mReverbDelay; /* Reverb delay in ms, usually 40-200ms */
|
||||
int mBassAmount; /* XBass level 0(quiet)-100(loud) */
|
||||
int mBassRange; /* XBass cutoff in Hz 10-100 */
|
||||
int mSurroundDepth; /* Surround level 0(quiet)-100(heavy) */
|
||||
int mSurroundDelay; /* Surround delay in ms, usually 5-40ms */
|
||||
int mLoopCount; /* Number of times to loop. Zero prevents looping.
|
||||
-1 loops forever. */
|
||||
} ModPlug_Settings;
|
||||
|
||||
/* Get and set the mod decoder settings. All options, except for channels, bits-per-sample,
|
||||
* sampling rate, and loop count, will take effect immediately. Those options which don't
|
||||
* take effect immediately will take effect the next time you load a mod. */
|
||||
void ModPlug_GetSettings (ModPlug_Settings * settings);
|
||||
void ModPlug_SetSettings (const ModPlug_Settings * settings);
|
||||
void ModPlug_GetSettings(ModPlug_Settings* settings);
|
||||
void ModPlug_SetSettings(const ModPlug_Settings* settings);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
} /* extern "C" */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -19,10 +19,7 @@
|
|||
#include <mmsystem.h>
|
||||
#include <stdio.h>
|
||||
|
||||
inline void
|
||||
ProcessPlugins (int n)
|
||||
{
|
||||
}
|
||||
inline void ProcessPlugins(int n) {}
|
||||
|
||||
#else
|
||||
|
||||
|
@ -32,7 +29,7 @@ ProcessPlugins (int n)
|
|||
|
||||
typedef signed char CHAR;
|
||||
typedef unsigned char UCHAR;
|
||||
typedef unsigned char *PUCHAR;
|
||||
typedef unsigned char* PUCHAR;
|
||||
typedef unsigned short USHORT;
|
||||
typedef unsigned long ULONG;
|
||||
typedef unsigned long UINT;
|
||||
|
@ -40,24 +37,23 @@ typedef unsigned long DWORD;
|
|||
typedef long LONG;
|
||||
typedef unsigned short WORD;
|
||||
typedef unsigned char BYTE;
|
||||
typedef unsigned char *LPBYTE;
|
||||
typedef unsigned char * LPBYTE;
|
||||
typedef bool BOOL;
|
||||
typedef char *LPSTR;
|
||||
typedef void *LPVOID;
|
||||
typedef long *LPLONG;
|
||||
typedef unsigned long *LPDWORD;
|
||||
typedef unsigned short *LPWORD;
|
||||
typedef const char *LPCSTR;
|
||||
typedef char * LPSTR;
|
||||
typedef void * LPVOID;
|
||||
typedef long * LPLONG;
|
||||
typedef unsigned long * LPDWORD;
|
||||
typedef unsigned short * LPWORD;
|
||||
typedef const char * LPCSTR;
|
||||
typedef long long LONGLONG;
|
||||
typedef void *PVOID;
|
||||
typedef void * PVOID;
|
||||
typedef void VOID;
|
||||
|
||||
|
||||
inline LONG
|
||||
MulDiv (long a, long b, long c)
|
||||
inline LONG MulDiv (long a, long b, long c)
|
||||
{
|
||||
/* if (!c) return 0; */
|
||||
return ((unsigned long long) a * (unsigned long long) b) / c;
|
||||
return ((unsigned long long) a * (unsigned long long) b ) / c;
|
||||
}
|
||||
|
||||
#define MODPLUG_NO_FILESAVE
|
||||
|
@ -71,20 +67,15 @@ MulDiv (long a, long b, long c)
|
|||
|
||||
#define GHND 0
|
||||
|
||||
inline signed char *
|
||||
GlobalAllocPtr (unsigned int, size_t size)
|
||||
inline signed char * GlobalAllocPtr(unsigned int, size_t size)
|
||||
{
|
||||
signed char *p = (signed char *) malloc (size);
|
||||
signed char * p = (signed char *) malloc(size);
|
||||
|
||||
if (p != NULL)
|
||||
memset (p, 0, size);
|
||||
if (p != NULL) memset(p, 0, size);
|
||||
return p;
|
||||
}
|
||||
|
||||
inline void
|
||||
ProcessPlugins (int n)
|
||||
{
|
||||
}
|
||||
inline void ProcessPlugins(int n) {}
|
||||
|
||||
#define GlobalFreePtr(p) free((void *)(p))
|
||||
|
||||
|
@ -102,3 +93,6 @@ ProcessPlugins (int n)
|
|||
#endif /* MSC_VER */
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -24,9 +24,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#define MPEG1MUX_BUFFER_QUEUED(mb) (g_list_length((mb)->timecode_list))
|
||||
#define MPEG1MUX_BUFFER_SPACE(mb) ((mb)->length)
|
||||
|
@ -42,104 +41,101 @@ extern "C"
|
|||
#define FRAME_TYPE_PFRAME 3
|
||||
#define FRAME_TYPE_AUDIO 4
|
||||
|
||||
typedef struct _Mpeg1MuxBuffer Mpeg1MuxBuffer;
|
||||
typedef struct _Mpeg1MuxTimecode Mpeg1MuxTimecode;
|
||||
typedef struct _Mpeg1MuxBuffer Mpeg1MuxBuffer;
|
||||
typedef struct _Mpeg1MuxTimecode Mpeg1MuxTimecode;
|
||||
|
||||
typedef struct video_struc /* Informationen ueber Video Stream */
|
||||
{
|
||||
unsigned int stream_length;
|
||||
unsigned int num_sequence;
|
||||
unsigned int num_seq_end;
|
||||
unsigned int num_pictures;
|
||||
unsigned int num_groups;
|
||||
unsigned int num_frames[4];
|
||||
unsigned int avg_frames[4];
|
||||
typedef struct video_struc /* Informationen ueber Video Stream */
|
||||
{
|
||||
unsigned int stream_length ;
|
||||
unsigned int num_sequence ;
|
||||
unsigned int num_seq_end ;
|
||||
unsigned int num_pictures ;
|
||||
unsigned int num_groups ;
|
||||
unsigned int num_frames[4] ;
|
||||
unsigned int avg_frames[4] ;
|
||||
|
||||
unsigned int horizontal_size;
|
||||
unsigned int vertical_size;
|
||||
unsigned int aspect_ratio;
|
||||
unsigned int picture_rate;
|
||||
unsigned int bit_rate;
|
||||
unsigned int comp_bit_rate;
|
||||
unsigned int vbv_buffer_size;
|
||||
unsigned int CSPF;
|
||||
unsigned int horizontal_size;
|
||||
unsigned int vertical_size ;
|
||||
unsigned int aspect_ratio ;
|
||||
unsigned int picture_rate ;
|
||||
unsigned int bit_rate ;
|
||||
unsigned int comp_bit_rate ;
|
||||
unsigned int vbv_buffer_size;
|
||||
unsigned int CSPF ;
|
||||
|
||||
guint64 PTS;
|
||||
guint64 DTS;
|
||||
guint64 PTS;
|
||||
guint64 DTS;
|
||||
|
||||
guint64 current_PTS;
|
||||
guint64 current_DTS;
|
||||
guchar current_type;
|
||||
guint64 current_PTS;
|
||||
guint64 current_DTS;
|
||||
guchar current_type;
|
||||
|
||||
double secs_per_frame;
|
||||
gulong group_order, decoding_order;
|
||||
} Video_struc;
|
||||
double secs_per_frame;
|
||||
gulong group_order, decoding_order;
|
||||
} Video_struc;
|
||||
|
||||
typedef struct audio_struc /* Informationen ueber Audio Stream */
|
||||
{
|
||||
unsigned int stream_length;
|
||||
unsigned int num_syncword;
|
||||
unsigned int num_frames[2];
|
||||
unsigned int framesize;
|
||||
unsigned int layer;
|
||||
unsigned int protection;
|
||||
unsigned int bit_rate;
|
||||
unsigned int frequency;
|
||||
unsigned int mode;
|
||||
unsigned int mode_extension;
|
||||
unsigned int copyright;
|
||||
unsigned int original_copy;
|
||||
unsigned int emphasis;
|
||||
typedef struct audio_struc /* Informationen ueber Audio Stream */
|
||||
{
|
||||
unsigned int stream_length ;
|
||||
unsigned int num_syncword ;
|
||||
unsigned int num_frames [2] ;
|
||||
unsigned int framesize ;
|
||||
unsigned int layer ;
|
||||
unsigned int protection ;
|
||||
unsigned int bit_rate ;
|
||||
unsigned int frequency ;
|
||||
unsigned int mode ;
|
||||
unsigned int mode_extension ;
|
||||
unsigned int copyright ;
|
||||
unsigned int original_copy ;
|
||||
unsigned int emphasis ;
|
||||
|
||||
guint64 PTS;
|
||||
guint64 PTS;
|
||||
|
||||
guint64 current_PTS;
|
||||
guint64 current_PTS;
|
||||
|
||||
double samples_per_second;
|
||||
gulong decoding_order;
|
||||
} Audio_struc;
|
||||
double samples_per_second;
|
||||
gulong decoding_order;
|
||||
} Audio_struc;
|
||||
|
||||
struct _Mpeg1MuxTimecode
|
||||
{
|
||||
gulong length;
|
||||
gulong original_length;
|
||||
guchar frame_type;
|
||||
guint64 PTS;
|
||||
guint64 DTS;
|
||||
};
|
||||
struct _Mpeg1MuxTimecode {
|
||||
gulong length;
|
||||
gulong original_length;
|
||||
guchar frame_type;
|
||||
guint64 PTS;
|
||||
guint64 DTS;
|
||||
};
|
||||
|
||||
struct _Mpeg1MuxBuffer
|
||||
{
|
||||
unsigned char *buffer;
|
||||
gulong length;
|
||||
gulong base;
|
||||
gulong scan_pos;
|
||||
gulong last_pos;
|
||||
gulong current_start;
|
||||
guchar buffer_type;
|
||||
guchar stream_id;
|
||||
gboolean new_frame;
|
||||
guint64 next_frame_time;
|
||||
struct _Mpeg1MuxBuffer {
|
||||
unsigned char *buffer;
|
||||
gulong length;
|
||||
gulong base;
|
||||
gulong scan_pos;
|
||||
gulong last_pos;
|
||||
gulong current_start;
|
||||
guchar buffer_type;
|
||||
guchar stream_id;
|
||||
gboolean new_frame;
|
||||
guint64 next_frame_time;
|
||||
|
||||
union
|
||||
{
|
||||
Video_struc video;
|
||||
Audio_struc audio;
|
||||
} info;
|
||||
union {
|
||||
Video_struc video;
|
||||
Audio_struc audio;
|
||||
} info;
|
||||
|
||||
GList *timecode_list;
|
||||
GList *queued_list;
|
||||
};
|
||||
GList *timecode_list;
|
||||
GList *queued_list;
|
||||
};
|
||||
|
||||
Mpeg1MuxBuffer *mpeg1mux_buffer_new (guchar type, guchar id);
|
||||
Mpeg1MuxBuffer *mpeg1mux_buffer_new(guchar type, guchar id);
|
||||
|
||||
void mpeg1mux_buffer_queue (Mpeg1MuxBuffer * mb, GstBuffer * buf);
|
||||
void mpeg1mux_buffer_shrink (Mpeg1MuxBuffer * mb, gulong size);
|
||||
gulong mpeg1mux_buffer_update_queued (Mpeg1MuxBuffer * mb, guint64 scr);
|
||||
void mpeg1mux_buffer_queue(Mpeg1MuxBuffer *mb, GstBuffer *buf);
|
||||
void mpeg1mux_buffer_shrink(Mpeg1MuxBuffer *mb, gulong size);
|
||||
gulong mpeg1mux_buffer_update_queued(Mpeg1MuxBuffer *mb, guint64 scr);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __BUFFER_H__ */
|
||||
#endif /* __BUFFER_H__ */
|
||||
|
|
|
@ -29,9 +29,8 @@
|
|||
#include "main.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SYSTEM_ENCODE \
|
||||
|
@ -45,68 +44,66 @@ extern "C"
|
|||
#define GST_IS_SYSTEM_ENCODE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SYSTEM_ENCODE))
|
||||
|
||||
typedef struct _GstMPEG1SystemEncode GstMPEG1SystemEncode;
|
||||
typedef struct _GstMPEG1SystemEncodeClass GstMPEG1SystemEncodeClass;
|
||||
typedef struct _GstMPEG1SystemEncode GstMPEG1SystemEncode;
|
||||
typedef struct _GstMPEG1SystemEncodeClass GstMPEG1SystemEncodeClass;
|
||||
|
||||
struct _GstMPEG1SystemEncode
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMPEG1SystemEncode {
|
||||
GstElement element;
|
||||
|
||||
GstPad *srcpad;
|
||||
GstPad *srcpad;
|
||||
|
||||
gboolean have_setup;
|
||||
gboolean have_setup;
|
||||
|
||||
GMutex *lock;
|
||||
GMutex *lock;
|
||||
|
||||
guint num_audio_pads;
|
||||
guint num_video_pads;
|
||||
guint num_audio_pads;
|
||||
guint num_video_pads;
|
||||
|
||||
Mpeg1MuxBuffer *audio_buffer;
|
||||
Mpeg1MuxBuffer *video_buffer;
|
||||
Mpeg1MuxBuffer *audio_buffer;
|
||||
Mpeg1MuxBuffer *video_buffer;
|
||||
|
||||
Pack_struc *pack;
|
||||
Sys_header_struc *sys_header;
|
||||
Sector_struc *sector;
|
||||
Pack_struc *pack;
|
||||
Sys_header_struc *sys_header;
|
||||
Sector_struc *sector;
|
||||
|
||||
guint data_rate, video_rate, audio_rate;
|
||||
gdouble delay, audio_delay, video_delay;
|
||||
gdouble clock_cycles;
|
||||
gulong sectors_delay, video_delay_ms, audio_delay_ms;
|
||||
gulong startup_delay;
|
||||
gulong audio_buffer_size;
|
||||
gulong video_buffer_size;
|
||||
gulong mux_rate, dmux_rate;
|
||||
guint64 SCR;
|
||||
gint which_streams;
|
||||
guint data_rate, video_rate, audio_rate;
|
||||
gdouble delay, audio_delay, video_delay;
|
||||
gdouble clock_cycles;
|
||||
gulong sectors_delay, video_delay_ms, audio_delay_ms;
|
||||
gulong startup_delay;
|
||||
gulong audio_buffer_size;
|
||||
gulong video_buffer_size;
|
||||
gulong mux_rate, dmux_rate;
|
||||
guint64 SCR;
|
||||
gint which_streams;
|
||||
|
||||
gint current_pack;
|
||||
gulong min_packet_data;
|
||||
gulong max_packet_data;
|
||||
gint packets_per_pack;
|
||||
gulong packet_size;
|
||||
gulong bytes_output;
|
||||
gint current_pack;
|
||||
gulong min_packet_data;
|
||||
gulong max_packet_data;
|
||||
gint packets_per_pack;
|
||||
gulong packet_size;
|
||||
gulong bytes_output;
|
||||
|
||||
GList *mta;
|
||||
GList *mta;
|
||||
|
||||
/* stream input pads */
|
||||
GstPad *private_1_pad[8]; /* up to 8 ac3 audio tracks <grumble> */
|
||||
GstPad *private_2_pad;
|
||||
GstPad *video_pad[16];
|
||||
GstPad *audio_pad[32];
|
||||
};
|
||||
/* stream input pads */
|
||||
GstPad *private_1_pad[8]; /* up to 8 ac3 audio tracks <grumble> */
|
||||
GstPad *private_2_pad;
|
||||
GstPad *video_pad[16];
|
||||
GstPad *audio_pad[32];
|
||||
};
|
||||
|
||||
struct _GstMPEG1SystemEncodeClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstMPEG1SystemEncodeClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mpeg1_system_encode_get_type (void);
|
||||
GType gst_mpeg1_system_encode_get_type(void);
|
||||
|
||||
/* multplex.c */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __SYSTEM_ENCODE_H__ */
|
||||
#endif /* __SYSTEM_ENCODE_H__ */
|
||||
|
|
|
@ -45,82 +45,79 @@
|
|||
#define ISO11172_END 0x000001b9
|
||||
#define PACKET_START 0x000001
|
||||
|
||||
#define CLOCKS 90000.0 /* System Clock Hertz */
|
||||
#define CLOCKS 90000.0 /* System Clock Hertz */
|
||||
|
||||
#define AFTER_PACKET_LENGTH 15 /* No of non-data-bytes */
|
||||
/* following the packet */
|
||||
/* length field */
|
||||
#define LAST_SCR_BYTE_IN_PACK 9 /* No of bytes in pack */
|
||||
/* preceding, and */
|
||||
/* including, the SCR */
|
||||
#define AFTER_PACKET_LENGTH 15 /* No of non-data-bytes */
|
||||
/* following the packet */
|
||||
/* length field */
|
||||
#define LAST_SCR_BYTE_IN_PACK 9 /* No of bytes in pack */
|
||||
/* preceding, and */
|
||||
/* including, the SCR */
|
||||
|
||||
/* The following values for sys_header_length & size are only valid for */
|
||||
/* System streams consisting of two basic streams. When wrapping around */
|
||||
/* the system layer on a single video or a single audio stream, those */
|
||||
/* values get decreased by 3. */
|
||||
|
||||
#define SYS_HEADER_LENGTH 12 /* length of Sys Header */
|
||||
/* after start code and */
|
||||
/* length field */
|
||||
#define SYS_HEADER_LENGTH 12 /* length of Sys Header */
|
||||
/* after start code and */
|
||||
/* length field */
|
||||
|
||||
#define SYS_HEADER_SIZE 18 /* incl. start code and */
|
||||
/* length field */
|
||||
#define SYS_HEADER_SIZE 18 /* incl. start code and */
|
||||
/* length field */
|
||||
#define PACK_HEADER_SIZE 12
|
||||
|
||||
#define PACKET_HEADER_SIZE 6
|
||||
|
||||
#define MAX_SECTOR_SIZE 0x20000 /* Max Sektor Groesse */
|
||||
#define MAX_SECTOR_SIZE 0x20000 /* Max Sektor Groesse */
|
||||
|
||||
#define STREAMS_VIDEO 1
|
||||
#define STREAMS_AUDIO 2
|
||||
#define STREAMS_BOTH 3
|
||||
|
||||
#define AUDIO_STREAMS 0xb8 /* Marker Audio Streams */
|
||||
#define VIDEO_STREAMS 0xb9 /* Marker Video Streams */
|
||||
#define AUDIO_STR_0 0xc0 /* Marker Audio Stream0 */
|
||||
#define VIDEO_STR_0 0xe0 /* Marker Video Stream0 */
|
||||
#define PADDING_STR 0xbe /* Marker Padding Stream */
|
||||
#define AUDIO_STREAMS 0xb8 /* Marker Audio Streams */
|
||||
#define VIDEO_STREAMS 0xb9 /* Marker Video Streams */
|
||||
#define AUDIO_STR_0 0xc0 /* Marker Audio Stream0 */
|
||||
#define VIDEO_STR_0 0xe0 /* Marker Video Stream0 */
|
||||
#define PADDING_STR 0xbe /* Marker Padding Stream*/
|
||||
|
||||
#define ZERO_STUFFING_BYTE 0
|
||||
#define STUFFING_BYTE 0xff
|
||||
#define RESERVED_BYTE 0xff
|
||||
#define TIMESTAMPS_NO 0 /* Flag NO timestamps */
|
||||
#define TIMESTAMPS_PTS 1 /* Flag PTS timestamp */
|
||||
#define TIMESTAMPS_PTS_DTS 2 /* Flag BOTH timestamps */
|
||||
#define TIMESTAMPS_NO 0 /* Flag NO timestamps */
|
||||
#define TIMESTAMPS_PTS 1 /* Flag PTS timestamp */
|
||||
#define TIMESTAMPS_PTS_DTS 2 /* Flag BOTH timestamps */
|
||||
|
||||
#define MARKER_SCR 2 /* Marker SCR */
|
||||
#define MARKER_JUST_PTS 2 /* Marker only PTS */
|
||||
#define MARKER_PTS 3 /* Marker PTS */
|
||||
#define MARKER_DTS 1 /* Marker DTS */
|
||||
#define MARKER_NO_TIMESTAMPS 0x0f /* Marker NO timestamps */
|
||||
#define MARKER_SCR 2 /* Marker SCR */
|
||||
#define MARKER_JUST_PTS 2 /* Marker only PTS */
|
||||
#define MARKER_PTS 3 /* Marker PTS */
|
||||
#define MARKER_DTS 1 /* Marker DTS */
|
||||
#define MARKER_NO_TIMESTAMPS 0x0f /* Marker NO timestamps */
|
||||
|
||||
#define STATUS_AUDIO_END 0 /* Statusmessage A end */
|
||||
#define STATUS_VIDEO_END 1 /* Statusmessage V end */
|
||||
#define STATUS_AUDIO_TIME_OUT 2 /* Statusmessage A out */
|
||||
#define STATUS_VIDEO_TIME_OUT 3 /* Statusmessage V out */
|
||||
#define STATUS_AUDIO_END 0 /* Statusmessage A end */
|
||||
#define STATUS_VIDEO_END 1 /* Statusmessage V end */
|
||||
#define STATUS_AUDIO_TIME_OUT 2 /* Statusmessage A out */
|
||||
#define STATUS_VIDEO_TIME_OUT 3 /* Statusmessage V out */
|
||||
|
||||
/*************************************************************************
|
||||
Typ- und Strukturdefinitionen
|
||||
*************************************************************************/
|
||||
|
||||
typedef struct sector_struc /* A sector, can contain pack, sys header */
|
||||
/* and packet. */
|
||||
{
|
||||
unsigned char buf[MAX_SECTOR_SIZE];
|
||||
unsigned int length_of_sector;
|
||||
unsigned int length_of_packet_data;
|
||||
guint64 TS;
|
||||
typedef struct sector_struc /* A sector, can contain pack, sys header */
|
||||
/* and packet. */
|
||||
{ unsigned char buf [MAX_SECTOR_SIZE] ;
|
||||
unsigned int length_of_sector ;
|
||||
unsigned int length_of_packet_data ;
|
||||
guint64 TS ;
|
||||
} Sector_struc;
|
||||
|
||||
typedef struct pack_struc /* Pack Info */
|
||||
{
|
||||
unsigned char buf[PACK_HEADER_SIZE];
|
||||
guint64 SCR;
|
||||
typedef struct pack_struc /* Pack Info */
|
||||
{ unsigned char buf [PACK_HEADER_SIZE];
|
||||
guint64 SCR;
|
||||
} Pack_struc;
|
||||
|
||||
typedef struct sys_header_struc /* System Header Info */
|
||||
{
|
||||
unsigned char buf[SYS_HEADER_SIZE];
|
||||
typedef struct sys_header_struc /* System Header Info */
|
||||
{ unsigned char buf [SYS_HEADER_SIZE];
|
||||
} Sys_header_struc;
|
||||
|
||||
/*************************************************************************
|
||||
|
@ -128,20 +125,16 @@ typedef struct sys_header_struc /* System Header Info */
|
|||
*************************************************************************/
|
||||
|
||||
/* systems.c */
|
||||
void create_sector (Sector_struc * sector, Pack_struc * pack,
|
||||
Sys_header_struc * sys_header, unsigned int packet_size,
|
||||
unsigned char *inputbuffer, unsigned char type, unsigned char buffer_scale,
|
||||
unsigned int buffer_size, unsigned char buffers, guint64 PTS, guint64 DTS,
|
||||
unsigned char timestamps, unsigned int which_streams);
|
||||
void create_sector (Sector_struc *sector, Pack_struc *pack, Sys_header_struc *sys_header,
|
||||
unsigned int packet_size, unsigned char *inputbuffer, unsigned char type, unsigned char buffer_scale,
|
||||
unsigned int buffer_size, unsigned char buffers, guint64 PTS, guint64 DTS,
|
||||
unsigned char timestamps, unsigned int which_streams);
|
||||
|
||||
void create_pack (Pack_struc * pack, guint64 SCR, unsigned int mux_rate);
|
||||
void create_pack (Pack_struc *pack, guint64 SCR, unsigned int mux_rate);
|
||||
|
||||
void create_sys_header (Sys_header_struc * sys_header, unsigned int rate_bound,
|
||||
unsigned char audio_bound, unsigned char fixed, unsigned char CSPS,
|
||||
unsigned char audio_lock, unsigned char video_lock,
|
||||
unsigned char video_bound, unsigned char stream1,
|
||||
unsigned char buffer1_scale, unsigned int buffer1_size,
|
||||
unsigned char stream2, unsigned char buffer2_scale,
|
||||
unsigned int buffer2_size, unsigned int which_streams);
|
||||
void create_sys_header (Sys_header_struc *sys_header, unsigned int rate_bound, unsigned char audio_bound,
|
||||
unsigned char fixed, unsigned char CSPS, unsigned char audio_lock, unsigned char video_lock,
|
||||
unsigned char video_bound, unsigned char stream1, unsigned char buffer1_scale, unsigned int buffer1_size,
|
||||
unsigned char stream2, unsigned char buffer2_scale, unsigned int buffer2_size, unsigned int which_streams);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MP1VIDEOPARSE \
|
||||
|
@ -42,37 +41,35 @@ extern "C"
|
|||
#define GST_IS_MP1VIDEOPARSE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MP1VIDEOPARSE))
|
||||
|
||||
typedef struct _Mp1VideoParse Mp1VideoParse;
|
||||
typedef struct _Mp1VideoParseClass Mp1VideoParseClass;
|
||||
typedef struct _Mp1VideoParse Mp1VideoParse;
|
||||
typedef struct _Mp1VideoParseClass Mp1VideoParseClass;
|
||||
|
||||
struct _Mp1VideoParse
|
||||
{
|
||||
GstElement element;
|
||||
struct _Mp1VideoParse {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
gulong next_buffer_offset;
|
||||
gboolean need_resync;
|
||||
gboolean in_flush;
|
||||
guint64 last_pts;
|
||||
gint picture_in_buffer;
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
gulong next_buffer_offset;
|
||||
gboolean need_resync;
|
||||
gboolean in_flush;
|
||||
guint64 last_pts;
|
||||
gint picture_in_buffer;
|
||||
|
||||
gint width, height;
|
||||
gfloat fps, asr;
|
||||
};
|
||||
gint width, height;
|
||||
gfloat fps, asr;
|
||||
};
|
||||
|
||||
struct _Mp1VideoParseClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _Mp1VideoParseClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mp1videoparse_get_type (void);
|
||||
GType gst_mp1videoparse_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __MP1VIDEOPARSE_H__ */
|
||||
#endif /* __MP1VIDEOPARSE_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_MPEG2SUBT \
|
||||
|
@ -42,43 +41,41 @@ extern "C"
|
|||
#define GST_IS_MPEG2SUBT_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MPEG2SUBT))
|
||||
|
||||
typedef struct _GstMpeg2Subt GstMpeg2Subt;
|
||||
typedef struct _GstMpeg2SubtClass GstMpeg2SubtClass;
|
||||
typedef struct _GstMpeg2Subt GstMpeg2Subt;
|
||||
typedef struct _GstMpeg2SubtClass GstMpeg2SubtClass;
|
||||
|
||||
struct _GstMpeg2Subt
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstMpeg2Subt {
|
||||
GstElement element;
|
||||
|
||||
GstPad *videopad, *subtitlepad, *srcpad;
|
||||
GstPad *videopad,*subtitlepad,*srcpad;
|
||||
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
|
||||
gboolean have_title;
|
||||
gboolean have_title;
|
||||
|
||||
guint16 packet_size;
|
||||
guint16 data_size;
|
||||
guint16 packet_size;
|
||||
guint16 data_size;
|
||||
|
||||
gint offset[2];
|
||||
guchar color[5];
|
||||
guchar trans[4];
|
||||
gint offset[2];
|
||||
guchar color[5];
|
||||
guchar trans[4];
|
||||
|
||||
guint duration;
|
||||
guint duration;
|
||||
|
||||
gint width, height;
|
||||
gint width, height;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
struct _GstMpeg2SubtClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstMpeg2SubtClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_mpeg2subt_get_type (void);
|
||||
GType gst_mpeg2subt_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_MPEG2SUBT_H__ */
|
||||
#endif /* __GST_MPEG2SUBT_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__ */
|
||||
|
|
|
@ -37,32 +37,30 @@
|
|||
typedef struct _GstOverlay GstOverlay;
|
||||
typedef struct _GstOverlayClass GstOverlayClass;
|
||||
|
||||
struct _GstOverlay
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstOverlay {
|
||||
GstElement element;
|
||||
|
||||
GstPad *srcpad;
|
||||
GstPad *sinkpad1;
|
||||
GstPad *sinkpad2;
|
||||
GstPad *sinkpad3;
|
||||
GstPad *srcpad;
|
||||
GstPad *sinkpad1;
|
||||
GstPad *sinkpad2;
|
||||
GstPad *sinkpad3;
|
||||
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
|
||||
gint duration;
|
||||
gint position;
|
||||
gint duration;
|
||||
gint position;
|
||||
|
||||
gint type;
|
||||
gint fps;
|
||||
gint border;
|
||||
gint depth;
|
||||
gint type;
|
||||
gint fps;
|
||||
gint border;
|
||||
gint depth;
|
||||
|
||||
gdouble framerate;
|
||||
gdouble framerate;
|
||||
};
|
||||
|
||||
struct _GstOverlayClass
|
||||
{
|
||||
struct _GstOverlayClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_PASSTHROUGH \
|
||||
(gst_passthrough_get_type())
|
||||
#define GST_PASSTHROUGH(obj) \
|
||||
|
@ -35,18 +36,17 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_PASSTHROUGH))
|
||||
#define GST_IS_PASSTHROUGH_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_PASSTHROUGH))
|
||||
|
||||
typedef struct _GstPassthrough GstPassthrough;
|
||||
typedef struct _GstPassthroughClass GstPassthroughClass;
|
||||
typedef enum _GstPassthroughFormat GstPassthroughFormat;
|
||||
typedef enum _GstPassthroughFormat GstPassthroughFormat;
|
||||
|
||||
enum _GstPassthroughFormat
|
||||
{
|
||||
enum _GstPassthroughFormat {
|
||||
GST_PASSTHROUGH_FORMAT_INT,
|
||||
GST_PASSTHROUGH_FORMAT_FLOAT
|
||||
};
|
||||
|
||||
struct _GstPassthrough
|
||||
{
|
||||
struct _GstPassthrough {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
|
@ -66,12 +66,12 @@ struct _GstPassthrough
|
|||
gboolean is_signed;
|
||||
};
|
||||
|
||||
struct _GstPassthroughClass
|
||||
{
|
||||
struct _GstPassthroughClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_passthrough_get_type (void);
|
||||
GType gst_passthrough_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PASSTHROUGH_H__ */
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_PLAYONDEMAND \
|
||||
(gst_play_on_demand_get_type())
|
||||
#define GST_PLAYONDEMAND(obj) \
|
||||
|
@ -39,59 +40,58 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_PLAYONDEMAND))
|
||||
#define GST_IS_PLAYONDEMAND_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_PLAYONDEMAND))
|
||||
typedef struct _GstPlayOnDemand GstPlayOnDemand;
|
||||
typedef struct _GstPlayOnDemandClass GstPlayOnDemandClass;
|
||||
typedef enum _GstPlayOnDemandFormat GstPlayOnDemandFormat;
|
||||
|
||||
enum _GstPlayOnDemandFormat
|
||||
{
|
||||
typedef struct _GstPlayOnDemand GstPlayOnDemand;
|
||||
typedef struct _GstPlayOnDemandClass GstPlayOnDemandClass;
|
||||
typedef enum _GstPlayOnDemandFormat GstPlayOnDemandFormat;
|
||||
|
||||
enum _GstPlayOnDemandFormat {
|
||||
GST_PLAYONDEMAND_FORMAT_INT,
|
||||
GST_PLAYONDEMAND_FORMAT_FLOAT
|
||||
};
|
||||
|
||||
struct _GstPlayOnDemand
|
||||
{
|
||||
struct _GstPlayOnDemand {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstClock *clock;
|
||||
|
||||
/* filter properties */
|
||||
gboolean mute;
|
||||
gfloat buffer_time;
|
||||
guint max_plays;
|
||||
gfloat tick_rate;
|
||||
guint total_ticks;
|
||||
guint32 *ticks;
|
||||
gboolean mute;
|
||||
gfloat buffer_time;
|
||||
guint max_plays;
|
||||
gfloat tick_rate;
|
||||
guint total_ticks;
|
||||
guint32 *ticks;
|
||||
|
||||
/* internal buffer info */
|
||||
gchar *buffer;
|
||||
guint buffer_bytes;
|
||||
gboolean eos;
|
||||
gchar *buffer;
|
||||
guint buffer_bytes;
|
||||
gboolean eos;
|
||||
|
||||
/* play pointers == internal buffer offsets for producing output sound */
|
||||
guint *plays;
|
||||
guint write;
|
||||
guint *plays;
|
||||
guint write;
|
||||
|
||||
/* audio format info (used to calculate buffer_samples) */
|
||||
GstPlayOnDemandFormat format;
|
||||
guint rate;
|
||||
guint channels;
|
||||
guint width;
|
||||
guint rate;
|
||||
guint channels;
|
||||
guint width;
|
||||
};
|
||||
|
||||
struct _GstPlayOnDemandClass
|
||||
{
|
||||
struct _GstPlayOnDemandClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
void (*play) (GstElement * elem);
|
||||
void (*clear) (GstElement * elem);
|
||||
void (*reset) (GstElement * elem);
|
||||
void (*played) (GstElement * elem);
|
||||
void (*stopped) (GstElement * elem);
|
||||
void (*play) (GstElement *elem);
|
||||
void (*clear) (GstElement *elem);
|
||||
void (*reset) (GstElement *elem);
|
||||
void (*played) (GstElement *elem);
|
||||
void (*stopped) (GstElement *elem);
|
||||
};
|
||||
|
||||
GType gst_play_on_demand_get_type (void);
|
||||
GType gst_play_on_demand_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PLAYONDEMAND_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <gst/getbits/getbits.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_QTDEMUX \
|
||||
|
@ -44,45 +43,43 @@ extern "C"
|
|||
|
||||
#define GST_QTDEMUX_MAX_STREAMS 8
|
||||
|
||||
typedef struct _GstQTDemux GstQTDemux;
|
||||
typedef struct _GstQTDemuxClass GstQTDemuxClass;
|
||||
typedef struct _QtDemuxStream QtDemuxStream;
|
||||
typedef struct _GstQTDemux GstQTDemux;
|
||||
typedef struct _GstQTDemuxClass GstQTDemuxClass;
|
||||
typedef struct _QtDemuxStream QtDemuxStream;
|
||||
|
||||
struct _GstQTDemux
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstQTDemux {
|
||||
GstElement element;
|
||||
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
/* pads */
|
||||
GstPad *sinkpad;
|
||||
|
||||
QtDemuxStream *streams[GST_QTDEMUX_MAX_STREAMS];
|
||||
int n_streams;
|
||||
int n_video_streams;
|
||||
int n_audio_streams;
|
||||
QtDemuxStream *streams[GST_QTDEMUX_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 offset;
|
||||
|
||||
/* track stuff */
|
||||
/* track stuff */
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
struct _GstQTDemuxClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstQTDemuxClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* __GST_QTDEMUX_H__ */
|
||||
#endif /* __GST_QTDEMUX_H__ */
|
||||
|
|
|
@ -23,32 +23,30 @@
|
|||
|
||||
#include <inttypes.h>
|
||||
|
||||
typedef uint8_t __u8;
|
||||
typedef uint8_t __u8;
|
||||
typedef uint32_t __u32;
|
||||
typedef int8_t __s8;
|
||||
typedef int8_t __s8;
|
||||
typedef uint16_t __u16;
|
||||
|
||||
extern void RTjpeg_init_Q (__u8 Q);
|
||||
extern void RTjpeg_init_compress (long unsigned int *buf, int width, int height,
|
||||
__u8 Q);
|
||||
extern void RTjpeg_init_decompress (long unsigned int *buf, int width,
|
||||
int height);
|
||||
extern int RTjpeg_compressYUV420 (__s8 * sp, unsigned char *bp);
|
||||
extern int RTjpeg_compressYUV422 (__s8 * sp, unsigned char *bp);
|
||||
extern void RTjpeg_decompressYUV420 (__s8 * sp, __u8 * bp);
|
||||
extern void RTjpeg_decompressYUV422 (__s8 * sp, __u8 * bp);
|
||||
extern int RTjpeg_compress8 (__s8 * sp, unsigned char *bp);
|
||||
extern void RTjpeg_decompress8 (__s8 * sp, __u8 * bp);
|
||||
extern void RTjpeg_init_Q(__u8 Q);
|
||||
extern void RTjpeg_init_compress(long unsigned int *buf, int width, int height, __u8 Q);
|
||||
extern void RTjpeg_init_decompress(long unsigned int *buf, int width, int height);
|
||||
extern int RTjpeg_compressYUV420(__s8 *sp, unsigned char *bp);
|
||||
extern int RTjpeg_compressYUV422(__s8 *sp, unsigned char *bp);
|
||||
extern void RTjpeg_decompressYUV420(__s8 *sp, __u8 *bp);
|
||||
extern void RTjpeg_decompressYUV422(__s8 *sp, __u8 *bp);
|
||||
extern int RTjpeg_compress8(__s8 *sp, unsigned char *bp);
|
||||
extern void RTjpeg_decompress8(__s8 *sp, __u8 *bp);
|
||||
|
||||
extern void RTjpeg_init_mcompress (void);
|
||||
extern int RTjpeg_mcompress (__s8 * sp, unsigned char *bp, __u16 lmask,
|
||||
__u16 cmask);
|
||||
extern int RTjpeg_mcompress8 (__s8 * sp, unsigned char *bp, __u16 lmask);
|
||||
extern void RTjpeg_set_test (int i);
|
||||
extern void RTjpeg_init_mcompress(void);
|
||||
extern int RTjpeg_mcompress(__s8 *sp, unsigned char *bp, __u16 lmask, __u16 cmask);
|
||||
extern int RTjpeg_mcompress8(__s8 *sp, unsigned char *bp, __u16 lmask);
|
||||
extern void RTjpeg_set_test(int i);
|
||||
|
||||
extern void RTjpeg_yuv420rgb (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuv422rgb (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuvrgb8 (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuvrgb16 (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuvrgb24 (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuvrgb32 (__u8 * buf, __u8 * rgb);
|
||||
extern void RTjpeg_yuv420rgb(__u8 *buf, __u8 *rgb);
|
||||
extern void RTjpeg_yuv422rgb(__u8 *buf, __u8 *rgb);
|
||||
extern void RTjpeg_yuvrgb8(__u8 *buf, __u8 *rgb);
|
||||
extern void RTjpeg_yuvrgb16(__u8 *buf, __u8 *rgb);
|
||||
extern void RTjpeg_yuvrgb24(__u8 *buf, __u8 *rgb);
|
||||
extern void RTjpeg_yuvrgb32(__u8 *buf, __u8 *rgb);
|
||||
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_RTJPEGDEC \
|
||||
|
@ -42,32 +41,30 @@ extern "C"
|
|||
#define GST_IS_RTJPEGDEC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_RTJPEGDEC)))
|
||||
|
||||
typedef struct _GstRTJpegDec GstRTJpegDec;
|
||||
typedef struct _GstRTJpegDecClass GstRTJpegDecClass;
|
||||
typedef struct _GstRTJpegDec GstRTJpegDec;
|
||||
typedef struct _GstRTJpegDecClass GstRTJpegDecClass;
|
||||
|
||||
struct _GstRTJpegDec
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstRTJpegDec {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gint width, height;
|
||||
gint quality;
|
||||
gint quant[128];
|
||||
gint width,height;
|
||||
gint quality;
|
||||
gint quant[128];
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
struct _GstRTJpegDecClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstRTJpegDecClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_rtjpegdec_get_type (void);
|
||||
GType gst_rtjpegdec_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __RTJPEGDEC_H__ */
|
||||
#endif /* __RTJPEGDEC_H__ */
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_RTJPEGENC \
|
||||
|
@ -44,31 +43,29 @@ extern "C"
|
|||
#define GST_IS_RTJPEGENC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_RTJPEGENC))
|
||||
|
||||
typedef struct _GstRTJpegEnc GstRTJpegEnc;
|
||||
typedef struct _GstRTJpegEncClass GstRTJpegEncClass;
|
||||
typedef struct _GstRTJpegEnc GstRTJpegEnc;
|
||||
typedef struct _GstRTJpegEncClass GstRTJpegEncClass;
|
||||
|
||||
struct _GstRTJpegEnc
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstRTJpegEnc {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gint width, height;
|
||||
gint quality;
|
||||
gint quant[128];
|
||||
};
|
||||
gint width,height;
|
||||
gint quality;
|
||||
gint quant[128];
|
||||
};
|
||||
|
||||
struct _GstRTJpegEncClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstRTJpegEncClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_rtjpegenc_get_type (void);
|
||||
GType gst_rtjpegenc_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __RTJPEGENC_H__ */
|
||||
#endif /* __RTJPEGENC_H__ */
|
||||
|
|
|
@ -25,9 +25,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SMOOTH \
|
||||
|
@ -41,36 +40,34 @@ extern "C"
|
|||
#define GST_IS_SMOOTH_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SMOOTH))
|
||||
|
||||
typedef struct _GstSmooth GstSmooth;
|
||||
typedef struct _GstSmoothClass GstSmoothClass;
|
||||
typedef struct _GstSmooth GstSmooth;
|
||||
typedef struct _GstSmoothClass GstSmoothClass;
|
||||
|
||||
struct _GstSmooth
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSmooth {
|
||||
GstElement element;
|
||||
|
||||
int format;
|
||||
int width;
|
||||
int height;
|
||||
int format;
|
||||
int width;
|
||||
int height;
|
||||
|
||||
gboolean active;
|
||||
int tolerance;
|
||||
int filtersize;
|
||||
gboolean lum_only;
|
||||
gboolean active;
|
||||
int tolerance;
|
||||
int filtersize;
|
||||
gboolean lum_only;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
};
|
||||
GstPad *sinkpad,*srcpad;
|
||||
};
|
||||
|
||||
struct _GstSmoothClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstSmoothClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_smooth_get_type (void);
|
||||
GType gst_smooth_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_SMOOTH_H__ */
|
||||
#endif /* __GST_SMOOTH_H__ */
|
||||
|
|
|
@ -26,9 +26,8 @@
|
|||
#include <gtk/gtk.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#define GST_TYPE_SMOOTHWAVE \
|
||||
|
@ -42,33 +41,31 @@ extern "C"
|
|||
#define GST_IS_SMOOTHWAVE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SMOOTHWAVE))
|
||||
|
||||
typedef struct _GstSmoothWave GstSmoothWave;
|
||||
typedef struct _GstSmoothWaveClass GstSmoothWaveClass;
|
||||
typedef struct _GstSmoothWave GstSmoothWave;
|
||||
typedef struct _GstSmoothWaveClass GstSmoothWaveClass;
|
||||
|
||||
struct _GstSmoothWave
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSmoothWave {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad, *srcpad;
|
||||
GstPad *sinkpad,*srcpad;
|
||||
|
||||
gint width, height;
|
||||
gint width,height;
|
||||
|
||||
GdkRgbCmap *cmap;
|
||||
GtkWidget *image;
|
||||
guchar *imagebuffer;
|
||||
};
|
||||
GdkRgbCmap *cmap;
|
||||
GtkWidget *image;
|
||||
guchar *imagebuffer;
|
||||
};
|
||||
|
||||
struct _GstSmoothWaveClass
|
||||
{
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
struct _GstSmoothWaveClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_smoothwave_get_type (void);
|
||||
GType gst_smoothwave_get_type(void);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
#endif /* __GST_SMOOTHWAVE_H__ */
|
||||
#endif /* __GST_SMOOTHWAVE_H__ */
|
||||
|
|
|
@ -27,39 +27,37 @@
|
|||
typedef struct _GstMask GstMask;
|
||||
typedef struct _GstMaskDefinition GstMaskDefinition;
|
||||
|
||||
typedef void (*GstMaskDrawFunc) (GstMask * mask);
|
||||
typedef void (*GstMaskDestroyFunc) (GstMask * mask);
|
||||
typedef void (*GstMaskDrawFunc) (GstMask *mask);
|
||||
typedef void (*GstMaskDestroyFunc) (GstMask *mask);
|
||||
|
||||
struct _GstMaskDefinition
|
||||
{
|
||||
gint type;
|
||||
gchar *short_name;
|
||||
gchar *long_name;
|
||||
GstMaskDrawFunc draw_func;
|
||||
GstMaskDestroyFunc destroy_func;
|
||||
gpointer user_data;
|
||||
struct _GstMaskDefinition {
|
||||
gint type;
|
||||
gchar *short_name;
|
||||
gchar *long_name;
|
||||
GstMaskDrawFunc draw_func;
|
||||
GstMaskDestroyFunc destroy_func;
|
||||
gpointer user_data;
|
||||
};
|
||||
|
||||
struct _GstMask
|
||||
{
|
||||
gint type;
|
||||
guint32 *data;
|
||||
gpointer user_data;
|
||||
struct _GstMask {
|
||||
gint type;
|
||||
guint32 *data;
|
||||
gpointer user_data;
|
||||
|
||||
gint width;
|
||||
gint height;
|
||||
gint bpp;
|
||||
gint width;
|
||||
gint height;
|
||||
gint bpp;
|
||||
|
||||
GstMaskDestroyFunc destroy_func;
|
||||
GstMaskDestroyFunc destroy_func;
|
||||
};
|
||||
|
||||
void _gst_mask_init (void);
|
||||
void _gst_mask_register (GstMaskDefinition * definition);
|
||||
void _gst_mask_init (void);
|
||||
void _gst_mask_register (GstMaskDefinition *definition);
|
||||
|
||||
void _gst_mask_default_destroy (GstMask * mask);
|
||||
void _gst_mask_default_destroy (GstMask *mask);
|
||||
|
||||
const GList *gst_mask_get_definitions (void);
|
||||
GstMask *gst_mask_factory_new (gint type, gint bpp, gint width, gint height);
|
||||
void gst_mask_destroy (GstMask * mask);
|
||||
const GList* gst_mask_get_definitions (void);
|
||||
GstMask* gst_mask_factory_new (gint type, gint bpp, gint width, gint height);
|
||||
void gst_mask_destroy (GstMask *mask);
|
||||
|
||||
#endif /* __GST_MASK_H__ */
|
||||
|
|
|
@ -38,28 +38,28 @@
|
|||
typedef struct _GstSMPTE GstSMPTE;
|
||||
typedef struct _GstSMPTEClass GstSMPTEClass;
|
||||
|
||||
struct _GstSMPTE
|
||||
{
|
||||
GstElement element;
|
||||
struct _GstSMPTE {
|
||||
GstElement element;
|
||||
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
gdouble fps;
|
||||
gint format;
|
||||
gint width;
|
||||
gint height;
|
||||
gdouble fps;
|
||||
|
||||
gint duration;
|
||||
gint position;
|
||||
gint duration;
|
||||
gint position;
|
||||
|
||||
GstPad *srcpad, *sinkpad1, *sinkpad2;
|
||||
GstPad *srcpad,
|
||||
*sinkpad1,
|
||||
*sinkpad2;
|
||||
|
||||
gint type;
|
||||
gint border;
|
||||
gint depth;
|
||||
GstMask *mask;
|
||||
gint type;
|
||||
gint border;
|
||||
gint depth;
|
||||
GstMask *mask;
|
||||
};
|
||||
|
||||
struct _GstSMPTEClass
|
||||
{
|
||||
struct _GstSMPTEClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue