qtdemux: Apply qtdemux debug category to gstisoff
authorSeungha Yang <pudding8757@gmail.com>
Mon, 11 Dec 2017 15:11:24 +0000 (00:11 +0900)
committerTim-Philipp Müller <tim@centricular.com>
Mon, 29 Jan 2018 18:40:02 +0000 (18:40 +0000)
.. instead of the use of default debug category.
And, make new header to declare the debug category

https://bugzilla.gnome.org/show_bug.cgi?id=791483

gst/isomp4/Makefile.am
gst/isomp4/gstisoff.c
gst/isomp4/qtdemux.c
gst/isomp4/qtdemux.h
gst/isomp4/qtdemux_debug.h [new file with mode: 0644]
gst/isomp4/qtdemux_dump.c
gst/isomp4/qtdemux_lang.c
gst/isomp4/qtdemux_types.c

index de91ff6..d76cb42 100644 (file)
@@ -24,6 +24,7 @@ noinst_HEADERS = \
        qtatomparser.h   \
        qtdemux.h        \
        qtdemux_types.h  \
+       qtdemux_debug.h  \
        qtdemux_dump.h   \
        qtdemux_lang.h   \
        qtpalette.h      \
index 5c9f1ed..829a73a 100644 (file)
  * Boston, MA 02111-1307, USA.
  */
 
+#include "qtdemux_debug.h"
 #include "gstisoff.h"
 #include <gst/base/gstbytereader.h>
 
+#define GST_CAT_DEFAULT qtdemux_debug
+
 void
 gst_isoff_qt_sidx_parser_init (GstSidxParser * parser)
 {
index 6064750..4fda82a 100644 (file)
 #define ABSDIFF(x, y) ( (x) > (y) ? ((x) - (y)) : ((y) - (x)) )
 
 GST_DEBUG_CATEGORY (qtdemux_debug);
+#define GST_CAT_DEFAULT qtdemux_debug
 
 typedef struct _QtDemuxSegment QtDemuxSegment;
 typedef struct _QtDemuxSample QtDemuxSample;
index ebd7258..18a1398 100644 (file)
@@ -28,9 +28,6 @@
 
 G_BEGIN_DECLS
 
-GST_DEBUG_CATEGORY_EXTERN (qtdemux_debug);
-#define GST_CAT_DEFAULT qtdemux_debug
-
 #define GST_TYPE_QTDEMUX \
   (gst_qtdemux_get_type())
 #define GST_QTDEMUX(obj) \
diff --git a/gst/isomp4/qtdemux_debug.h b/gst/isomp4/qtdemux_debug.h
new file mode 100644 (file)
index 0000000..26da268
--- /dev/null
@@ -0,0 +1,12 @@
+#ifndef __GST_QTDEMUX_DEBUG_H__
+#define __GST_QTDEMUX_DEBUG_H__
+
+#include <gst/gst.h>
+
+G_BEGIN_DECLS
+
+GST_DEBUG_CATEGORY_EXTERN (qtdemux_debug);
+
+G_END_DECLS
+
+#endif /* __GST_QTDEMUX_DEBUG_H__ */
index de37811..57e0bc6 100644 (file)
@@ -19,6 +19,7 @@
  * Boston, MA 02110-1301, USA.
  */
 
+#include "qtdemux_debug.h"
 #include "qtdemux_types.h"
 #include "qtdemux_dump.h"
 #include "fourcc.h"
@@ -27,6 +28,8 @@
 
 #include <string.h>
 
+#define GST_CAT_DEFAULT qtdemux_debug
+
 #define GET_UINT8(data)   gst_byte_reader_get_uint8_unchecked(data)
 #define GET_UINT16(data)  gst_byte_reader_get_uint16_be_unchecked(data)
 #define GET_UINT32(data)  gst_byte_reader_get_uint32_be_unchecked(data)
index 59a78d7..c9646b2 100644 (file)
  * Boston, MA 02110-1301, USA.
  */
 
-#include "qtdemux.h"
+#include "qtdemux_debug.h"
 #include "qtdemux_lang.h"
 
 #include <string.h>
 
+#define GST_CAT_DEFAULT qtdemux_debug
+
 /* http://developer.apple.com/mac/library/documentation/QuickTime/QTFF/QTFFChap4/qtff4.html */
 
 static const gchar qt_lang_map[][4] = {
index d14ea30..e4fa3b4 100644 (file)
  * Boston, MA 02110-1301, USA.
  */
 
+#include "qtdemux_debug.h"
 #include "qtdemux_types.h"
 #include "qtdemux_dump.h"
 #include "fourcc.h"
 
+#define GST_CAT_DEFAULT qtdemux_debug
+
 static const QtNodeType qt_node_types[] = {
   {FOURCC_moov, "movie", QT_FLAG_CONTAINER,},
   {FOURCC_mvhd, "movie header", 0,