mpeg4videoparse: Move to the videoparsers plugin

Rename a few variables to use the same convention as others elements in this
plugin

Conflicts:

	gst/videoparsers/gstmpeg4videoparse.c
This commit is contained in:
Thibault Saunier 2011-09-26 10:39:31 -03:00
parent e464370163
commit db4d4979ab
8 changed files with 35 additions and 71 deletions

View file

@ -337,7 +337,6 @@ AG_GST_CHECK_PLUGIN(mpegdemux)
AG_GST_CHECK_PLUGIN(mpegtsdemux)
AG_GST_CHECK_PLUGIN(mpegtsmux)
AG_GST_CHECK_PLUGIN(mpegpsmux)
AG_GST_CHECK_PLUGIN(mpeg4videoparse)
AG_GST_CHECK_PLUGIN(mpegvideoparse)
AG_GST_CHECK_PLUGIN(mve)
AG_GST_CHECK_PLUGIN(mxf)
@ -1948,7 +1947,6 @@ gst/mpegtsdemux/Makefile
gst/mpegtsmux/Makefile
gst/mpegtsmux/tsmux/Makefile
gst/mpegpsmux/Makefile
gst/mpeg4videoparse/Makefile
gst/mpegvideoparse/Makefile
gst/mve/Makefile
gst/mxf/Makefile

View file

@ -1,24 +0,0 @@
plugin_LTLIBRARIES = libgstmpeg4videoparse.la
libgstmpeg4videoparse_la_SOURCES = mpeg4videoparse.c mpeg4parse.c
libgstmpeg4videoparse_la_CFLAGS = $(GST_BASE_CFLAGS) $(GST_CFLAGS)
libgstmpeg4videoparse_la_LIBADD = $(GST_BASE_LIBS) $(GST_LIBS)
libgstmpeg4videoparse_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstmpeg4videoparse_la_LIBTOOLFLAGS = --tag=disable-static
noinst_HEADERS = mpeg4videoparse.h mpeg4parse.h
Android.mk: Makefile.am $(BUILT_SOURCES)
androgenizer \
-:PROJECT libgstmpeg4videoparse -:SHARED libgstmpeg4videoparse \
-:TAGS eng debug \
-:REL_TOP $(top_srcdir) -:ABS_TOP $(abs_top_srcdir) \
-:SOURCES $(libgstmpeg4videoparse_la_SOURCES) \
-:CFLAGS $(DEFS) $(DEFAULT_INCLUDES) $(libgstmpeg4videoparse_la_CFLAGS) \
-:LDFLAGS $(libgstmpeg4videoparse_la_LDFLAGS) \
$(libgstmpeg4videoparse_la_LIBADD) \
-ldl \
-:PASSTHROUGH LOCAL_ARM_MODE:=arm \
LOCAL_MODULE_PATH:='$$(TARGET_OUT)/lib/gstreamer-0.10' \
> $@

View file

@ -3,7 +3,8 @@ plugin_LTLIBRARIES = libgstvideoparsersbad.la
libgstvideoparsersbad_la_SOURCES = plugin.c \
h263parse.c gsth263parse.c \
gstdiracparse.c dirac_parse.c \
gsth264parse.c gstmpegvideoparse.c
gsth264parse.c gstmpegvideoparse.c \
gstmpeg4videoparse.c mpeg4parse.c
libgstvideoparsersbad_la_CFLAGS = \
$(GST_PLUGINS_BAD_CFLAGS) $(GST_PLUGINS_BASE_CFLAGS) \
@ -17,7 +18,8 @@ libgstvideoparsersbad_la_LIBTOOLFLAGS = --tag=disable-static
noinst_HEADERS = gsth263parse.h h263parse.h \
gstdiracparse.h dirac_parse.h \
gsth264parse.h gstmpegvideoparse.h
gsth264parse.h gstmpegvideoparse.h \
gstmpeg4videoparse.h mpeg4parse.h
Android.mk: Makefile.am $(BUILT_SOURCES)
androgenizer \

View file

@ -28,7 +28,7 @@
#include <string.h>
#include <gst/base/gstbytereader.h>
#include "mpeg4videoparse.h"
#include "gstmpeg4videoparse.h"
GST_DEBUG_CATEGORY (mpeg4v_parse_debug);
#define GST_CAT_DEFAULT mpeg4v_parse_debug
@ -92,13 +92,16 @@ gst_mpeg4vparse_base_init (gpointer klass)
"MPEG 4 video elementary stream parser", "Codec/Parser/Video",
"Parses MPEG-4 Part 2 elementary video streams",
"Julien Moutte <julien@fluendo.com>");
GST_DEBUG_CATEGORY_INIT (mpeg4v_parse_debug, "mpeg4videoparse", 0,
"MPEG-4 video parser");
}
static void
gst_mpeg4vparse_set_property (GObject * object, guint property_id,
const GValue * value, GParamSpec * pspec)
{
GstMpeg4VParse *parse = GST_MPEG4VIDEOPARSE (object);
GstMpeg4VParse *parse = GST_MPEG4VIDEO_PARSE (object);
switch (property_id) {
case PROP_DROP:
@ -116,7 +119,7 @@ static void
gst_mpeg4vparse_get_property (GObject * object, guint property_id,
GValue * value, GParamSpec * pspec)
{
GstMpeg4VParse *parse = GST_MPEG4VIDEOPARSE (object);
GstMpeg4VParse *parse = GST_MPEG4VIDEO_PARSE (object);
switch (property_id) {
case PROP_DROP:
@ -198,7 +201,7 @@ gst_mpeg4vparse_reset (GstMpeg4VParse * mp4vparse)
static gboolean
gst_mpeg4vparse_start (GstBaseParse * parse)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GST_DEBUG_OBJECT (parse, "start");
@ -212,7 +215,7 @@ gst_mpeg4vparse_start (GstBaseParse * parse)
static gboolean
gst_mpeg4vparse_stop (GstBaseParse * parse)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GST_DEBUG_OBJECT (parse, "stop");
@ -332,7 +335,7 @@ static gboolean
gst_mpeg4vparse_check_valid_frame (GstBaseParse * parse,
GstBaseParseFrame * frame, guint * framesize, gint * skipsize)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GstBuffer *buf = frame->buffer;
GstByteReader reader = GST_BYTE_READER_INIT_FROM_BUFFER (buf);
gint off = 0;
@ -504,7 +507,7 @@ gst_mpeg4vparse_update_src_caps (GstMpeg4VParse * mp4vparse)
static GstFlowReturn
gst_mpeg4vparse_parse_frame (GstBaseParse * parse, GstBaseParseFrame * frame)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GstBuffer *buffer = frame->buffer;
gst_mpeg4vparse_update_src_caps (mp4vparse);
@ -524,7 +527,7 @@ gst_mpeg4vparse_parse_frame (GstBaseParse * parse, GstBaseParseFrame * frame)
static GstFlowReturn
gst_mpeg4vparse_pre_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GstBuffer *buffer = frame->buffer;
/* periodic SPS/PPS sending */
@ -583,7 +586,7 @@ gst_mpeg4vparse_pre_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame)
static gboolean
gst_mpeg4vparse_set_caps (GstBaseParse * parse, GstCaps * caps)
{
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEOPARSE (parse);
GstMpeg4VParse *mp4vparse = GST_MPEG4VIDEO_PARSE (parse);
GstStructure *s;
const GValue *value;
GstBuffer *buf;
@ -605,6 +608,7 @@ gst_mpeg4vparse_set_caps (GstBaseParse * parse, GstCaps * caps)
return TRUE;
}
static GstCaps *
gst_mpeg4vparse_get_caps (GstBaseParse * parse)
{
@ -637,22 +641,3 @@ gst_mpeg4vparse_get_caps (GstBaseParse * parse)
return res;
}
static gboolean
plugin_init (GstPlugin * plugin)
{
GST_DEBUG_CATEGORY_INIT (mpeg4v_parse_debug, "mpeg4videoparse", 0,
"MPEG-4 video parser");
if (!gst_element_register (plugin, "mpeg4videoparse", GST_RANK_PRIMARY + 1,
gst_mpeg4vparse_get_type ()))
return FALSE;
return TRUE;
}
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
GST_VERSION_MINOR,
"mpeg4videoparse",
"MPEG-4 video parser",
plugin_init, VERSION, GST_LICENSE, GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)

View file

@ -16,9 +16,9 @@
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef __MPEG4VIDEOPARSE_H__
#define __MPEG4VIDEOPARSE_H__
#ifndef __MPEG4VIDEO_PARSE_H__
#define __MPEG4VIDEO_PARSE_H__
#include <gst/gst.h>
#include <gst/base/gstbaseparse.h>
@ -27,17 +27,17 @@
G_BEGIN_DECLS
#define GST_TYPE_MPEG4VIDEOPARSE (gst_mpeg4vparse_get_type())
#define GST_MPEG4VIDEOPARSE(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),\
GST_TYPE_MPEG4VIDEOPARSE, GstMpeg4VParse))
#define GST_MPEG4VIDEOPARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),\
GST_TYPE_MPEG4VIDEOPARSE, GstMpeg4VParseClass))
#define GST_MPEG4VIDEOPARSE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj),\
GST_TYPE_MPEG4VIDEOPARSE, GstMpeg4VParseClass))
#define GST_IS_MPEG4VIDEOPARSE(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),\
GST_TYPE_MPEG4VIDEOPARSE))
#define GST_IS_MPEG4VIDEOPARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),\
GST_TYPE_MPEG4VIDEOPARSE))
#define GST_TYPE_MPEG4VIDEO_PARSE (gst_mpeg4vparse_get_type())
#define GST_MPEG4VIDEO_PARSE(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),\
GST_TYPE_MPEG4VIDEO_PARSE, GstMpeg4VParse))
#define GST_MPEG4VIDEO_PARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),\
GST_TYPE_MPEG4VIDEO_PARSE, GstMpeg4VParseClass))
#define GST_MPEG4VIDEO_PARSE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj),\
GST_TYPE_MPEG4VIDEO_PARSE, GstMpeg4VParseClass))
#define GST_IS_MPEG4VIDEO_PARSE(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),\
GST_TYPE_MPEG4VIDEO_PARSE))
#define GST_IS_MPEG4VIDEO_PARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),\
GST_TYPE_MPEG4VIDEO_PARSE))
typedef struct _GstMpeg4VParse GstMpeg4VParse;
typedef struct _GstMpeg4VParseClass GstMpeg4VParseClass;
@ -72,4 +72,4 @@ GType gst_mpeg4vparse_get_type (void);
G_END_DECLS
#endif /* __MPEG4VIDEOPARSE_H__ */
#endif /* __MPEG4VIDEO_PARSE_H__ */

View file

@ -26,6 +26,7 @@
#include "gsth264parse.h"
#include "gstdiracparse.h"
#include "gstmpegvideoparse.h"
#include "gstmpeg4videoparse.h"
static gboolean
plugin_init (GstPlugin * plugin)
@ -40,6 +41,8 @@ plugin_init (GstPlugin * plugin)
GST_RANK_NONE, GST_TYPE_DIRAC_PARSE);
ret |= gst_element_register (plugin, "mpegvideoparse",
GST_RANK_PRIMARY + 1, GST_TYPE_MPEGVIDEO_PARSE);
ret |= gst_element_register (plugin, "mpeg4videoparse",
GST_RANK_PRIMARY + 1, GST_TYPE_MPEG4VIDEO_PARSE);
return ret;
}