mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-26 17:18:15 +00:00
gst/avi/: Port from -THREADED to HEAD, and fix for latest API changes of the day. Keep avimux dead for now.
Original commit message from CVS: * gst/avi/Makefile.am: * gst/avi/gstavi.c: (plugin_init): * gst/avi/gstavidemux.c: (gst_avi_demux_get_type), (gst_avi_demux_class_init), (gst_avi_demux_init), (gst_avi_demux_reset), (gst_avi_demux_index_next), (gst_avi_demux_index_entry_for_time), (gst_avi_demux_index_entry_for_byte), (gst_avi_demux_index_entry_for_frame), (gst_avi_demux_src_convert), (gst_avi_demux_handle_src_query), (gst_avi_demux_handle_src_event), (gst_avi_demux_parse_file_header), (gst_avi_demux_stream_init), (gst_avi_demux_parse_avih), (gst_avi_demux_parse_superindex), (gst_avi_demux_parse_subindex), (gst_avi_demux_read_subindexes), (gst_avi_demux_parse_stream), (gst_avi_demux_parse_odml), (gst_avi_demux_parse_index), (gst_avi_demux_stream_index), (gst_avi_demux_stream_scan), (gst_avi_demux_massage_index), (gst_avi_demux_stream_header), (gst_avi_demux_handle_seek), (gst_avi_demux_process_next_entry), (gst_avi_demux_stream_data), (gst_avi_demux_loop), (gst_avi_demux_sink_activate), (gst_avi_demux_sink_activate_pull): * gst/avi/gstavidemux.h: Port from -THREADED to HEAD, and fix for latest API changes of the day. Keep avimux dead for now.
This commit is contained in:
parent
094d0b4794
commit
aa254e4374
5 changed files with 903 additions and 934 deletions
25
ChangeLog
25
ChangeLog
|
@ -1,3 +1,28 @@
|
||||||
|
2005-06-30 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||||
|
|
||||||
|
* gst/avi/Makefile.am:
|
||||||
|
* gst/avi/gstavi.c: (plugin_init):
|
||||||
|
* gst/avi/gstavidemux.c: (gst_avi_demux_get_type),
|
||||||
|
(gst_avi_demux_class_init), (gst_avi_demux_init),
|
||||||
|
(gst_avi_demux_reset), (gst_avi_demux_index_next),
|
||||||
|
(gst_avi_demux_index_entry_for_time),
|
||||||
|
(gst_avi_demux_index_entry_for_byte),
|
||||||
|
(gst_avi_demux_index_entry_for_frame), (gst_avi_demux_src_convert),
|
||||||
|
(gst_avi_demux_handle_src_query), (gst_avi_demux_handle_src_event),
|
||||||
|
(gst_avi_demux_parse_file_header), (gst_avi_demux_stream_init),
|
||||||
|
(gst_avi_demux_parse_avih), (gst_avi_demux_parse_superindex),
|
||||||
|
(gst_avi_demux_parse_subindex), (gst_avi_demux_read_subindexes),
|
||||||
|
(gst_avi_demux_parse_stream), (gst_avi_demux_parse_odml),
|
||||||
|
(gst_avi_demux_parse_index), (gst_avi_demux_stream_index),
|
||||||
|
(gst_avi_demux_stream_scan), (gst_avi_demux_massage_index),
|
||||||
|
(gst_avi_demux_stream_header), (gst_avi_demux_handle_seek),
|
||||||
|
(gst_avi_demux_process_next_entry), (gst_avi_demux_stream_data),
|
||||||
|
(gst_avi_demux_loop), (gst_avi_demux_sink_activate),
|
||||||
|
(gst_avi_demux_sink_activate_pull):
|
||||||
|
* gst/avi/gstavidemux.h:
|
||||||
|
Port from -THREADED to HEAD, and fix for latest API changes of
|
||||||
|
the day. Keep avimux dead for now.
|
||||||
|
|
||||||
2005-06-29 Wim Taymans <wim@fluendo.com>
|
2005-06-29 Wim Taymans <wim@fluendo.com>
|
||||||
|
|
||||||
* ext/shout2/gstshout2.c: (gst_shout2send_render):
|
* ext/shout2/gstshout2.c: (gst_shout2send_render):
|
||||||
|
|
|
@ -2,16 +2,17 @@ plugin_LTLIBRARIES = libgstavi.la
|
||||||
|
|
||||||
libgstavi_la_SOURCES = \
|
libgstavi_la_SOURCES = \
|
||||||
gstavi.c \
|
gstavi.c \
|
||||||
gstavidemux.c \
|
gstavidemux.c
|
||||||
gstavimux.c
|
|
||||||
|
|
||||||
noinst_HEADERS = \
|
noinst_HEADERS = \
|
||||||
avi-ids.h \
|
avi-ids.h \
|
||||||
gstavimux.h \
|
gstavimux.h \
|
||||||
gstavidemux.h
|
gstavidemux.h
|
||||||
|
|
||||||
libgstavi_la_CFLAGS = $(GST_CFLAGS)
|
libgstavi_la_CFLAGS = $(GST_CFLAGS) $(GST_PLUGINS_LIBS) \
|
||||||
|
-DGETTEXT_PACKAGE="\"gst-plugins\""
|
||||||
libgstavi_la_LIBADD =
|
libgstavi_la_LIBADD =
|
||||||
libgstavi_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
libgstavi_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) \
|
||||||
|
../../../gst-plugins-base/gst-libs/gst/riff/libgstriff-0.9.la
|
||||||
|
|
||||||
EXTRA_DIST = README
|
EXTRA_DIST = README gstavimux.c
|
||||||
|
|
|
@ -26,23 +26,21 @@
|
||||||
#include "gst/gst-i18n-plugin.h"
|
#include "gst/gst-i18n-plugin.h"
|
||||||
|
|
||||||
#include "gstavidemux.h"
|
#include "gstavidemux.h"
|
||||||
#include "gstavimux.h"
|
/*#include "gstavimux.h"*/
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
plugin_init (GstPlugin * plugin)
|
plugin_init (GstPlugin * plugin)
|
||||||
{
|
{
|
||||||
if (!gst_library_load ("riff"))
|
gst_riff_init ();
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
#ifdef ENABLE_NLS
|
#ifdef ENABLE_NLS
|
||||||
setlocale (LC_ALL, "");
|
setlocale (LC_ALL, "");
|
||||||
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
|
bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR);
|
||||||
#endif /* ENABLE_NLS */
|
#endif /* ENABLE_NLS */
|
||||||
|
|
||||||
return (gst_element_register (plugin, "avidemux",
|
return (gst_element_register (plugin, "avidemux", GST_RANK_PRIMARY, GST_TYPE_AVI_DEMUX) /*&&
|
||||||
GST_RANK_PRIMARY,
|
gst_element_register (plugin, "avimux", GST_RANK_NONE, GST_TYPE_AVIMUX) */
|
||||||
GST_TYPE_AVI_DEMUX) &&
|
);
|
||||||
gst_element_register (plugin, "avimux", GST_RANK_NONE, GST_TYPE_AVIMUX));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -22,6 +22,7 @@
|
||||||
|
|
||||||
#include <gst/gst.h>
|
#include <gst/gst.h>
|
||||||
|
|
||||||
|
#include "avi-ids.h"
|
||||||
#include "gst/riff/riff-ids.h"
|
#include "gst/riff/riff-ids.h"
|
||||||
#include "gst/riff/riff-read.h"
|
#include "gst/riff/riff-read.h"
|
||||||
|
|
||||||
|
@ -61,25 +62,25 @@ typedef struct {
|
||||||
|
|
||||||
/* pad, strh */
|
/* pad, strh */
|
||||||
GstPad *pad;
|
GstPad *pad;
|
||||||
GstCaps *caps;
|
|
||||||
gst_riff_strh *strh;
|
gst_riff_strh *strh;
|
||||||
gint blockalign, bitrate;
|
union {
|
||||||
gint width, height;
|
gst_riff_strf_vids *vids;
|
||||||
|
gst_riff_strf_auds *auds;
|
||||||
|
gst_riff_strf_iavs *iavs;
|
||||||
|
gpointer data;
|
||||||
|
} strf;
|
||||||
|
GstBuffer *extradata, *initdata;
|
||||||
|
gchar *name;
|
||||||
|
|
||||||
/* current position (byte, frame, time) */
|
/* current position (byte, frame, time) */
|
||||||
guint current_frame;
|
guint current_frame;
|
||||||
guint64 current_byte;
|
guint64 current_byte;
|
||||||
gint current_entry;
|
gint current_entry;
|
||||||
|
|
||||||
/* delay in time (init_frames) */
|
|
||||||
guint64 delay;
|
|
||||||
|
|
||||||
/* stream length */
|
/* stream length */
|
||||||
guint64 total_bytes;
|
guint64 total_bytes;
|
||||||
guint32 total_frames;
|
guint32 total_frames;
|
||||||
|
|
||||||
guint32 skip;
|
|
||||||
|
|
||||||
guint64 *indexes;
|
guint64 *indexes;
|
||||||
} avi_stream_context;
|
} avi_stream_context;
|
||||||
|
|
||||||
|
@ -90,14 +91,14 @@ typedef enum {
|
||||||
} GstAviDemuxState;
|
} GstAviDemuxState;
|
||||||
|
|
||||||
typedef struct _GstAviDemux {
|
typedef struct _GstAviDemux {
|
||||||
GstRiffRead parent;
|
GstElement parent;
|
||||||
|
|
||||||
/* pads */
|
/* pads */
|
||||||
GstPad *sinkpad;
|
GstPad *sinkpad;
|
||||||
|
|
||||||
/* AVI decoding state */
|
/* AVI decoding state */
|
||||||
GstAviDemuxState state;
|
GstAviDemuxState state;
|
||||||
guint level_up;
|
guint64 offset;
|
||||||
|
|
||||||
/* index */
|
/* index */
|
||||||
gst_avi_index_entry *index_entries;
|
gst_avi_index_entry *index_entries;
|
||||||
|
@ -112,18 +113,18 @@ typedef struct _GstAviDemux {
|
||||||
avi_stream_context stream[GST_AVI_DEMUX_MAX_STREAMS];
|
avi_stream_context stream[GST_AVI_DEMUX_MAX_STREAMS];
|
||||||
|
|
||||||
/* some stream info for length */
|
/* some stream info for length */
|
||||||
guint32 us_per_frame;
|
gst_riff_avih *avih;
|
||||||
guint32 num_frames;
|
|
||||||
|
|
||||||
/* seeking */
|
/* seeking */
|
||||||
guint64 seek_offset;
|
guint64 seek_offset;
|
||||||
guint64 last_seek;
|
guint64 last_seek;
|
||||||
gint seek_entry;
|
gint seek_entry;
|
||||||
gboolean seek_flush;
|
gboolean seek_flush;
|
||||||
|
GstEvent *seek_event;
|
||||||
} GstAviDemux;
|
} GstAviDemux;
|
||||||
|
|
||||||
typedef struct _GstAviDemuxClass {
|
typedef struct _GstAviDemuxClass {
|
||||||
GstRiffReadClass parent_class;
|
GstElementClass parent_class;
|
||||||
} GstAviDemuxClass;
|
} GstAviDemuxClass;
|
||||||
|
|
||||||
GType gst_avi_demux_get_type (void);
|
GType gst_avi_demux_get_type (void);
|
||||||
|
|
Loading…
Reference in a new issue