#include "gsth263parse.h"
GST_DEBUG_CATEGORY (h263_parse_debug);
+#define GST_CAT_DEFAULT h263_parse_debug
static GstStaticPadTemplate srctemplate =
GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC,
static gboolean
gst_h263_parse_start (GstBaseParse * parse)
{
- GstH263Parse *h263parse = GST_H263PARSE (parse);
+ GstH263Parse *h263parse = GST_H263_PARSE (parse);
GST_DEBUG ("Start");
h263parse->state = PARSING;
+ gst_base_parse_set_min_frame_size (parse, 512);
gst_base_parse_set_passthrough (parse, FALSE);
return TRUE;
GstH263Parse *h263parse;
gboolean res = FALSE;
- h263parse = GST_H263PARSE (parse);
+ h263parse = GST_H263_PARSE (parse);
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_TAG:
GstH263Parse *h263parse;
guint psc_pos, next_psc_pos;
- h263parse = GST_H263PARSE (parse);
+ h263parse = GST_H263_PARSE (parse);
+
+ if (GST_BUFFER_SIZE (buffer) < 3)
+ return FALSE;
psc_pos = find_psc (buffer, 0);
GstFlowReturn res;
H263Params *params = NULL;
- h263parse = GST_H263PARSE (parse);
+ h263parse = GST_H263_PARSE (parse);
res = gst_h263_parse_get_params (h263parse, buffer, ¶ms, TRUE);
if (res != GST_FLOW_OK)
#include <gst/gst.h>
#include <gst/base/gstadapter.h>
-#include "gstbaseparse.h"
-
-GST_DEBUG_CATEGORY_EXTERN (h263_parse_debug);
-#define GST_CAT_DEFAULT h263_parse_debug
+#include <gstbaseparse.h>
G_BEGIN_DECLS
typedef struct _H263Params H263Params;
-#define GST_TYPE_H263PARSE \
+#define GST_TYPE_H263_PARSE \
(gst_h263_parse_get_type())
-#define GST_H263PARSE(obj) \
- (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_H263PARSE,GstH263Parse))
-#define GST_H263PARSE_CLASS(klass) \
- (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_H263PARSE,GstH263ParseClass))
-#define GST_IS_H263PARSE(obj) \
- (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_H263PARSE))
-#define GST_IS_H263PARSE_CLASS(klass) \
- (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_H263PARSE))
+#define GST_H263_PARSE(obj) \
+ (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_H263_PARSE,GstH263Parse))
+#define GST_H263_PARSE_CLASS(klass) \
+ (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_H263_PARSE,GstH263ParseClass))
+#define GST_IS_H263_PARSE(obj) \
+ (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_H263_PARSE))
+#define GST_IS_H263_PARSE_CLASS(klass) \
+ (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_H263_PARSE))
+
GType gst_h263_parse_get_type (void);
typedef struct _GstH263Parse GstH263Parse;