branch | RCL_3 |
changeset 7 | 567bb019e3e3 |
parent 0 | 0e761a78d257 |
child 8 | 7e817e7e631c |
6:9b2c3c7a1a9c | 7:567bb019e3e3 |
---|---|
25 #define __GSTINFO_H__ |
25 #define __GSTINFO_H__ |
26 |
26 |
27 #include <glib.h> |
27 #include <glib.h> |
28 #include <glib-object.h> |
28 #include <glib-object.h> |
29 #include <gst/gstconfig.h> |
29 #include <gst/gstconfig.h> |
30 |
|
31 |
|
32 #ifndef _MSC_VER |
|
33 #define IMPORT_SYMBOL |
|
34 #else /* _MSC_VER */ |
|
35 #ifndef LIBGSTREAMER_EXPORTS |
|
36 #define IMPORT_SYMBOL __declspec(dllimport) |
|
37 #else |
|
38 #define IMPORT_SYMBOL |
|
39 #endif |
|
40 #endif |
|
41 |
30 |
42 #ifndef M_PI |
31 #ifndef M_PI |
43 #define M_PI 3.14159265358979323846 |
32 #define M_PI 3.14159265358979323846 |
44 #endif |
33 #endif |
45 |
34 |
68 * events. |
57 * events. |
69 * @GST_LEVEL_LOG: Log messages are messages that are very common but might be |
58 * @GST_LEVEL_LOG: Log messages are messages that are very common but might be |
70 * useful to know. As a rule of thumb a pipeline that is iterating as expected |
59 * useful to know. As a rule of thumb a pipeline that is iterating as expected |
71 * should never output anzthing else but LOG messages. |
60 * should never output anzthing else but LOG messages. |
72 * Examples for this are referencing/dereferencing of objects or cothread switches. |
61 * Examples for this are referencing/dereferencing of objects or cothread switches. |
62 * @GST_LEVEL_FIXME: Fixme messages are messages that indicate that something |
|
63 * in the executed code path is not fully implemented or handled yet. Note |
|
64 * that this does not replace proper error handling in any way, the purpose |
|
65 * of this message is to make it easier to spot incomplete/unfinished pieces |
|
66 * of code when reading the debug log. (Since: 0.10.23) |
|
67 * @GST_LEVEL_MEMDUMP: memory dump messages are used to log (small) chunks of |
|
68 * data as memory dumps in the log. They will be displayed as hexdump with |
|
69 * ASCII characters. (Since: 0.10.23) |
|
73 * @GST_LEVEL_COUNT: The number of defined debugging levels. |
70 * @GST_LEVEL_COUNT: The number of defined debugging levels. |
74 * |
71 * |
75 * The level defines the importance of a debugging message. The more important a |
72 * The level defines the importance of a debugging message. The more important a |
76 * message is, the greater the probability that the debugging system outputs it. |
73 * message is, the greater the probability that the debugging system outputs it. |
77 */ |
74 */ |
80 GST_LEVEL_ERROR, |
77 GST_LEVEL_ERROR, |
81 GST_LEVEL_WARNING, |
78 GST_LEVEL_WARNING, |
82 GST_LEVEL_INFO, |
79 GST_LEVEL_INFO, |
83 GST_LEVEL_DEBUG, |
80 GST_LEVEL_DEBUG, |
84 GST_LEVEL_LOG, |
81 GST_LEVEL_LOG, |
82 GST_LEVEL_FIXME = 6, |
|
83 /* add more */ |
|
84 GST_LEVEL_MEMDUMP = 9, |
|
85 /* add more */ |
85 /* add more */ |
86 GST_LEVEL_COUNT |
86 GST_LEVEL_COUNT |
87 } GstDebugLevel; |
87 } GstDebugLevel; |
88 |
88 |
89 /** |
89 /** |
211 * |
211 * |
212 * This macro should evaluate to the name of the current function and be should |
212 * This macro should evaluate to the name of the current function and be should |
213 * be defined when configuring your project, as it is compiler dependant. If it |
213 * be defined when configuring your project, as it is compiler dependant. If it |
214 * is not defined, some default value is used. It is used to provide debugging |
214 * is not defined, some default value is used. It is used to provide debugging |
215 * output with the function name of the message. |
215 * output with the function name of the message. |
216 * |
|
217 * Note that this is different from G_STRFUNC as we do not want the full |
|
218 * function signature in C++ code. |
|
216 */ |
219 */ |
217 #ifndef GST_FUNCTION |
220 #ifndef GST_FUNCTION |
218 #if defined (__GNUC__) |
221 #if defined (__GNUC__) || (defined (_MSC_VER) && _MSC_VER >= 1300) |
219 # define GST_FUNCTION ((const char*) (__FUNCTION__)) |
222 # define GST_FUNCTION ((const char*) (__FUNCTION__)) |
220 #elif defined (G_HAVE_ISO_VARARGS) |
223 #elif defined (__STDC__) && defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L |
221 # define GST_FUNCTION ((const char*) (__func__)) |
224 # define GST_FUNCTION ((const char*) (__func__)) |
222 #else |
225 #else |
223 # define GST_FUNCTION ((const char*) ("???")) |
226 # define GST_FUNCTION ((const char*) (__PRETTY_FUNCTION__)) |
224 #endif |
227 #endif |
225 #endif /* ifndef GST_FUNCTION */ |
228 #endif /* ifndef GST_FUNCTION */ |
226 |
229 |
227 |
230 |
228 typedef struct _GstDebugMessage GstDebugMessage; |
231 typedef struct _GstDebugMessage GstDebugMessage; |
413 * |
416 * |
414 * Defines a static GstDebugCategory variable. |
417 * Defines a static GstDebugCategory variable. |
415 * This macro expands to nothing if debugging is disabled. |
418 * This macro expands to nothing if debugging is disabled. |
416 */ |
419 */ |
417 #define GST_DEBUG_CATEGORY_STATIC(cat) static GstDebugCategory *cat = NULL |
420 #define GST_DEBUG_CATEGORY_STATIC(cat) static GstDebugCategory *cat = NULL |
418 /* do not use this function, use the macros below */ |
421 |
422 /* do not use this function, use the GST_DEBUG_CATEGORY_INIT macro below */ |
|
419 #ifdef __SYMBIAN32__ |
423 #ifdef __SYMBIAN32__ |
420 IMPORT_C |
424 IMPORT_C |
421 #endif |
425 #endif |
422 |
426 |
423 GstDebugCategory *_gst_debug_category_new (const gchar * name, |
427 GstDebugCategory *_gst_debug_category_new (const gchar * name, |
506 IMPORT_C |
510 IMPORT_C |
507 #endif |
511 #endif |
508 |
512 |
509 GSList * |
513 GSList * |
510 gst_debug_get_all_categories (void); |
514 gst_debug_get_all_categories (void); |
511 #ifdef __SYMBIAN32__ |
515 |
512 IMPORT_C |
516 /* do not use this function, use the GST_DEBUG_CATEGORY_GET macro below */ |
513 #endif |
517 #ifdef __SYMBIAN32__ |
514 |
518 IMPORT_C |
515 |
519 #endif |
516 gchar * gst_debug_construct_term_color (guint colorinfo); |
520 |
521 GstDebugCategory *_gst_debug_get_category (const gchar *name); |
|
522 |
|
523 /** |
|
524 * GST_DEBUG_CATEGORY_GET: |
|
525 * @cat: the category to initialize. |
|
526 * @name: log category name |
|
527 * |
|
528 * Lookup an exiting #GstDebugCategory by its @name and sets @cat. If category |
|
529 * is not found, but %GST_CAT_DEFAULT is defined, that is assigned to @cat. |
|
530 * Otherwise cat will be NULL. |
|
531 * |
|
532 * |[ |
|
533 * GST_DEBUG_CATEGORY_STATIC (gst_myplugin_debug); |
|
534 * #define GST_CAT_DEFAULT gst_myplugin_debug |
|
535 * GST_DEBUG_CATEGORY_STATIC (GST_CAT_PERFORMANCE); |
|
536 * ... |
|
537 * GST_DEBUG_CATEGORY_INIT (gst_myplugin_debug, "myplugin", 0, "nice element"); |
|
538 * GST_DEBUG_CATEGORY_GET (GST_CAT_PERFORMANCE, "performance); |
|
539 * ]| |
|
540 * |
|
541 * Since: 0.10.24 |
|
542 */ |
|
543 #ifdef GST_CAT_DEFAULT |
|
544 #define GST_DEBUG_CATEGORY_GET(cat,name) G_STMT_START{\ |
|
545 cat = _gst_debug_get_category (name); \ |
|
546 if (!cat) { \ |
|
547 cat = GST_CAT_DEFAULT; \ |
|
548 } \ |
|
549 }G_STMT_END |
|
550 #else |
|
551 #define GST_DEBUG_CATEGORY_GET(cat,name) G_STMT_START{\ |
|
552 cat = _gst_debug_get_category (name); \ |
|
553 }G_STMT_END |
|
554 #endif |
|
555 |
|
556 #ifdef __SYMBIAN32__ |
|
557 IMPORT_C |
|
558 #endif |
|
559 gchar * gst_debug_construct_term_color (guint colorinfo); |
|
560 #ifdef __SYMBIAN32__ |
|
561 IMPORT_C |
|
562 #endif |
|
563 |
|
564 gint gst_debug_construct_win_color (guint colorinfo); |
|
517 |
565 |
518 |
566 |
519 /** |
567 /** |
520 * GST_CAT_DEFAULT: |
568 * GST_CAT_DEFAULT: |
521 * |
569 * |
522 * Default gstreamer core debug log category. Please define your own. |
570 * Default gstreamer core debug log category. Please define your own. |
523 */ |
571 */ |
524 GST_EXPORT GstDebugCategory * GST_CAT_DEFAULT; |
572 GST_EXPORT GstDebugCategory * GST_CAT_DEFAULT; |
573 GST_EXPORT GstDebugLevel __gst_debug_min; |
|
574 |
|
525 /* this symbol may not be used */ |
575 /* this symbol may not be used */ |
526 extern gboolean __gst_debug_enabled; |
576 extern gboolean __gst_debug_enabled; |
527 |
577 |
528 #ifdef __SYMBIAN32__ |
|
529 GstDebugCategory ** _GST_CAT_DEFAULT(); |
|
530 #ifdef __SYMBIAN32__ |
|
531 IMPORT_C |
|
532 #endif |
|
533 |
|
534 gboolean* gst_debug_enabled(); |
|
535 #ifdef __SYMBIAN32__ |
|
536 IMPORT_C |
|
537 #endif |
|
538 |
|
539 GstDebugCategory** _GST_CAT_QOS(); |
|
540 #ifdef __SYMBIAN32__ |
|
541 IMPORT_C |
|
542 #endif |
|
543 |
|
544 GstDebugCategory ** _GST_CAT_DEFAULT(); |
|
545 #endif |
|
546 /* since 0.10.7, the min debug level, used for quickly discarding debug |
578 /* since 0.10.7, the min debug level, used for quickly discarding debug |
547 * messages that fall under the threshold. */ |
579 * messages that fall under the threshold. */ |
548 extern IMPORT_SYMBOL GstDebugLevel __gst_debug_min; |
580 #ifdef __SYMBIAN32__ |
581 #ifdef __SYMBIAN32__ |
|
582 IMPORT_C |
|
583 #endif |
|
584 GstDebugCategory ** _GST_CAT_DEFAULT(); |
|
585 #ifdef __SYMBIAN32__ |
|
586 IMPORT_C |
|
587 #endif |
|
588 |
|
589 gboolean* gst_debug_enabled(); |
|
590 #ifdef __SYMBIAN32__ |
|
591 IMPORT_C |
|
592 #endif |
|
593 GstDebugCategory** _GST_CAT_QOS(); |
|
594 |
|
595 #ifdef __SYMBIAN32__ |
|
596 IMPORT_C |
|
597 #endif |
|
598 GstDebugLevel* gst_debug_min(); |
|
599 #endif |
|
549 |
600 |
550 /** |
601 /** |
551 * GST_CAT_LEVEL_LOG: |
602 * GST_CAT_LEVEL_LOG: |
552 * @cat: category to use |
603 * @cat: category to use |
553 * @level: the severity of the message |
604 * @level: the severity of the message |
576 #else /* no variadic macros, use inline */ |
627 #else /* no variadic macros, use inline */ |
577 static inline void |
628 static inline void |
578 GST_CAT_LEVEL_LOG_valist (GstDebugCategory * cat, |
629 GST_CAT_LEVEL_LOG_valist (GstDebugCategory * cat, |
579 GstDebugLevel level, gpointer object, const char *format, va_list varargs) |
630 GstDebugLevel level, gpointer object, const char *format, va_list varargs) |
580 { |
631 { |
581 #ifdef DEBUG_ENABLE |
632 #ifdef __SYMBIAN32__ |
582 GstDebugCategory** cat1; |
633 GstDebugCategory** cat1; |
583 GstDebugCategory* p; |
634 GstDebugCategory* p; |
584 cat1 = _GST_CAT_DEFAULT(); |
635 cat1 = _GST_CAT_DEFAULT(); |
585 p = *cat1; |
636 p = *cat1; |
586 if (G_UNLIKELY (level <= __gst_debug_min)) { |
637 if (G_UNLIKELY (level <= __gst_debug_min)) { |
587 gst_debug_log_valist (p, level, "", "", 0, (GObject *) object, format, |
638 gst_debug_log_valist (p, level, "", "", 0, (GObject *) object, format, |
588 varargs); |
639 varargs); |
640 } |
|
641 #else |
|
642 if (G_UNLIKELY (level <= __gst_debug_min)) { |
|
643 gst_debug_log_valist (cat, level, "", "", 0, (GObject *) object, format, |
|
644 varargs); |
|
589 } |
645 } |
590 #endif |
646 #endif |
591 } |
647 } |
592 |
648 |
593 static inline void |
649 static inline void |
600 GST_CAT_LEVEL_LOG_valist (cat, level, object, format, varargs); |
656 GST_CAT_LEVEL_LOG_valist (cat, level, object, format, varargs); |
601 va_end (varargs); |
657 va_end (varargs); |
602 } |
658 } |
603 #endif |
659 #endif |
604 #endif /* G_HAVE_ISO_VARARGS */ |
660 #endif /* G_HAVE_ISO_VARARGS */ |
661 |
|
662 /* private helper function */ |
|
663 #ifdef __SYMBIAN32__ |
|
664 IMPORT_C |
|
665 #endif |
|
666 |
|
667 void _gst_debug_dump_mem (GstDebugCategory * cat, const gchar * file, |
|
668 const gchar * func, gint line, GObject * obj, const gchar * msg, |
|
669 const guint8 * data, guint length); |
|
670 |
|
671 /* This one doesn't have varargs in the macro, so it's different than all the |
|
672 * other macros and hence in a separate block right here. Docs chunks are |
|
673 * with the other doc chunks below though. */ |
|
674 #define __GST_CAT_MEMDUMP_LOG(cat,object,msg,data,length) G_STMT_START{ \ |
|
675 if (G_UNLIKELY (GST_LEVEL_MEMDUMP <= __gst_debug_min)) { \ |
|
676 _gst_debug_dump_mem ((cat), __FILE__, GST_FUNCTION, __LINE__, \ |
|
677 (GObject *) (object), (msg), (data), (length)); \ |
|
678 } \ |
|
679 }G_STMT_END |
|
680 |
|
681 #define GST_CAT_MEMDUMP_OBJECT(cat,obj,msg,data,length) \ |
|
682 __GST_CAT_MEMDUMP_LOG(cat,obj,msg,data,length) |
|
683 #define GST_CAT_MEMDUMP(cat,msg,data,length) \ |
|
684 __GST_CAT_MEMDUMP_LOG(cat,NULL,msg,data,length) |
|
685 #define GST_MEMDUMP_OBJECT(obj,msg,data,length) \ |
|
686 __GST_CAT_MEMDUMP_LOG(GST_CAT_DEFAULT,obj,msg,data,length) |
|
687 #define GST_MEMDUMP(msg,data,length) \ |
|
688 __GST_CAT_MEMDUMP_LOG(GST_CAT_DEFAULT,NULL,msg,data,length) |
|
605 |
689 |
606 /** |
690 /** |
607 * GST_CAT_ERROR_OBJECT: |
691 * GST_CAT_ERROR_OBJECT: |
608 * @cat: category to use |
692 * @cat: category to use |
609 * @obj: the #GObject the message belongs to |
693 * @obj: the #GObject the message belongs to |
642 * @obj: the #GObject the message belongs to |
726 * @obj: the #GObject the message belongs to |
643 * @...: printf-style message to output |
727 * @...: printf-style message to output |
644 * |
728 * |
645 * Output an logging message belonging to the given object in the given category. |
729 * Output an logging message belonging to the given object in the given category. |
646 */ |
730 */ |
731 /** |
|
732 * GST_CAT_FIXME_OBJECT: |
|
733 * @cat: category to use |
|
734 * @obj: the #GObject the message belongs to |
|
735 * @...: printf-style message to output |
|
736 * |
|
737 * Output a fixme message belonging to the given object in the given category. |
|
738 * |
|
739 * Since: 0.10.23 |
|
740 */ |
|
741 /** |
|
742 * GST_CAT_MEMDUMP_OBJECT: |
|
743 * @cat: category to use |
|
744 * @obj: the #GObject the message belongs to |
|
745 * @msg: message string to log with the data |
|
746 * @data: pointer to the data to output |
|
747 * @length: length of the data to output |
|
748 * |
|
749 * Output a hexdump of @data relating to the given object in the given |
|
750 * category. |
|
751 * |
|
752 * Since: 0.10.23 |
|
753 */ |
|
647 |
754 |
648 |
755 |
649 /** |
756 /** |
650 * GST_CAT_ERROR: |
757 * GST_CAT_ERROR: |
651 * @cat: category to use |
758 * @cat: category to use |
679 * @cat: category to use |
786 * @cat: category to use |
680 * @...: printf-style message to output |
787 * @...: printf-style message to output |
681 * |
788 * |
682 * Output an logging message in the given category. |
789 * Output an logging message in the given category. |
683 */ |
790 */ |
791 /** |
|
792 * GST_CAT_FIXME: |
|
793 * @cat: category to use |
|
794 * @...: printf-style message to output |
|
795 * |
|
796 * Output an fixme message in the given category. |
|
797 * |
|
798 * Since: 0.10.23 |
|
799 */ |
|
800 /** |
|
801 * GST_CAT_MEMDUMP: |
|
802 * @cat: category to use |
|
803 * @msg: message string to log with the data |
|
804 * @data: pointer to the data to output |
|
805 * @length: length of the data to output |
|
806 * |
|
807 * Output a hexdump of @data in the given category. |
|
808 * |
|
809 * Since: 0.10.23 |
|
810 */ |
|
684 |
811 |
685 |
812 |
686 /** |
813 /** |
687 * GST_ERROR_OBJECT: |
814 * GST_ERROR_OBJECT: |
688 * @obj: the #GObject the message belongs to |
815 * @obj: the #GObject the message belongs to |
718 * @obj: the #GObject the message belongs to |
845 * @obj: the #GObject the message belongs to |
719 * @...: printf-style message to output |
846 * @...: printf-style message to output |
720 * |
847 * |
721 * Output a logging message belonging to the given object in the default category. |
848 * Output a logging message belonging to the given object in the default category. |
722 */ |
849 */ |
850 /** |
|
851 * GST_FIXME_OBJECT: |
|
852 * @obj: the #GObject the message belongs to |
|
853 * @...: printf-style message to output |
|
854 * |
|
855 * Output a logging message belonging to the given object in the default category. |
|
856 * |
|
857 * Since: 0.10.23 |
|
858 */ |
|
859 /** |
|
860 * GST_MEMDUMP_OBJECT: |
|
861 * @obj: the #GObject the message belongs to |
|
862 * @msg: message string to log with the data |
|
863 * @data: pointer to the data to output |
|
864 * @length: length of the data to output |
|
865 * |
|
866 * Output a logging message belonging to the given object in the default category. |
|
867 * |
|
868 * Since: 0.10.23 |
|
869 */ |
|
723 |
870 |
724 |
871 |
725 /** |
872 /** |
726 * GST_ERROR: |
873 * GST_ERROR: |
727 * @...: printf-style message to output |
874 * @...: printf-style message to output |
749 /** |
896 /** |
750 * GST_LOG: |
897 * GST_LOG: |
751 * @...: printf-style message to output |
898 * @...: printf-style message to output |
752 * |
899 * |
753 * Output a logging message in the default category. |
900 * Output a logging message in the default category. |
901 */ |
|
902 /** |
|
903 * GST_FIXME: |
|
904 * @...: printf-style message to output |
|
905 * |
|
906 * Output a fixme message in the default category. |
|
907 * |
|
908 * Since: 0.10.23 |
|
909 */ |
|
910 /** |
|
911 * GST_MEMDUMP: |
|
912 * @msg: message string to log with the data |
|
913 * @data: pointer to the data to output |
|
914 * @length: length of the data to output |
|
915 * |
|
916 * Output a hexdump of @data. |
|
917 * |
|
918 * Since: 0.10.23 |
|
754 */ |
919 */ |
755 |
920 |
756 #ifdef G_HAVE_ISO_VARARGS |
921 #ifdef G_HAVE_ISO_VARARGS |
757 |
922 |
758 #define GST_CAT_ERROR_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, obj, __VA_ARGS__) |
923 #define GST_CAT_ERROR_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, obj, __VA_ARGS__) |
759 #define GST_CAT_WARNING_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, obj, __VA_ARGS__) |
924 #define GST_CAT_WARNING_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, obj, __VA_ARGS__) |
760 #define GST_CAT_INFO_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, obj, __VA_ARGS__) |
925 #define GST_CAT_INFO_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, obj, __VA_ARGS__) |
761 #define GST_CAT_DEBUG_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, obj, __VA_ARGS__) |
926 #define GST_CAT_DEBUG_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, obj, __VA_ARGS__) |
762 #define GST_CAT_LOG_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, obj, __VA_ARGS__) |
927 #define GST_CAT_LOG_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, obj, __VA_ARGS__) |
928 #define GST_CAT_FIXME_OBJECT(cat,obj,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_FIXME, obj, __VA_ARGS__) |
|
763 |
929 |
764 #define GST_CAT_ERROR(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, NULL, __VA_ARGS__) |
930 #define GST_CAT_ERROR(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, NULL, __VA_ARGS__) |
765 #define GST_CAT_WARNING(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, NULL, __VA_ARGS__) |
931 #define GST_CAT_WARNING(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, NULL, __VA_ARGS__) |
766 #define GST_CAT_INFO(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, NULL, __VA_ARGS__) |
932 #define GST_CAT_INFO(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, NULL, __VA_ARGS__) |
767 #define GST_CAT_DEBUG(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, NULL, __VA_ARGS__) |
933 #define GST_CAT_DEBUG(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, NULL, __VA_ARGS__) |
768 #define GST_CAT_LOG(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, NULL, __VA_ARGS__) |
934 #define GST_CAT_LOG(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, NULL, __VA_ARGS__) |
935 #define GST_CAT_FIXME(cat,...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_FIXME, NULL, __VA_ARGS__) |
|
769 |
936 |
770 #define GST_ERROR_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, obj, __VA_ARGS__) |
937 #define GST_ERROR_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, obj, __VA_ARGS__) |
771 #define GST_WARNING_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, obj, __VA_ARGS__) |
938 #define GST_WARNING_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, obj, __VA_ARGS__) |
772 #define GST_INFO_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, obj, __VA_ARGS__) |
939 #define GST_INFO_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, obj, __VA_ARGS__) |
773 #define GST_DEBUG_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, obj, __VA_ARGS__) |
940 #define GST_DEBUG_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, obj, __VA_ARGS__) |
774 #define GST_LOG_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, obj, __VA_ARGS__) |
941 #define GST_LOG_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, obj, __VA_ARGS__) |
942 #define GST_FIXME_OBJECT(obj,...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_FIXME, obj, __VA_ARGS__) |
|
775 |
943 |
776 #define GST_ERROR(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, NULL, __VA_ARGS__) |
944 #define GST_ERROR(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, NULL, __VA_ARGS__) |
777 #define GST_WARNING(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, NULL, __VA_ARGS__) |
945 #define GST_WARNING(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, NULL, __VA_ARGS__) |
778 #define GST_INFO(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, NULL, __VA_ARGS__) |
946 #define GST_INFO(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, NULL, __VA_ARGS__) |
779 #define GST_DEBUG(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, NULL, __VA_ARGS__) |
947 #define GST_DEBUG(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, NULL, __VA_ARGS__) |
780 #define GST_LOG(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, __VA_ARGS__) |
948 #define GST_LOG(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, __VA_ARGS__) |
949 #define GST_FIXME(...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_FIXME, NULL, __VA_ARGS__) |
|
781 |
950 |
782 #else |
951 #else |
783 #ifdef G_HAVE_GNUC_VARARGS |
952 #ifdef G_HAVE_GNUC_VARARGS |
784 |
953 |
785 #define GST_CAT_ERROR_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, obj, ##args ) |
954 #define GST_CAT_ERROR_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, obj, ##args ) |
786 #define GST_CAT_WARNING_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, obj, ##args ) |
955 #define GST_CAT_WARNING_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, obj, ##args ) |
787 #define GST_CAT_INFO_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, obj, ##args ) |
956 #define GST_CAT_INFO_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, obj, ##args ) |
788 #define GST_CAT_DEBUG_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, obj, ##args ) |
957 #define GST_CAT_DEBUG_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, obj, ##args ) |
789 #define GST_CAT_LOG_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, obj, ##args ) |
958 #define GST_CAT_LOG_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, obj, ##args ) |
959 #define GST_CAT_FIXME_OBJECT(cat,obj,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_FIXME, obj, ##args ) |
|
790 |
960 |
791 #define GST_CAT_ERROR(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, NULL, ##args ) |
961 #define GST_CAT_ERROR(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_ERROR, NULL, ##args ) |
792 #define GST_CAT_WARNING(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, NULL, ##args ) |
962 #define GST_CAT_WARNING(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_WARNING, NULL, ##args ) |
793 #define GST_CAT_INFO(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, NULL, ##args ) |
963 #define GST_CAT_INFO(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_INFO, NULL, ##args ) |
794 #define GST_CAT_DEBUG(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, NULL, ##args ) |
964 #define GST_CAT_DEBUG(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_DEBUG, NULL, ##args ) |
795 #define GST_CAT_LOG(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, NULL, ##args ) |
965 #define GST_CAT_LOG(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_LOG, NULL, ##args ) |
966 #define GST_CAT_FIXME(cat,args...) GST_CAT_LEVEL_LOG (cat, GST_LEVEL_FIXME, NULL, ##args ) |
|
796 |
967 |
797 #define GST_ERROR_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, obj, ##args ) |
968 #define GST_ERROR_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, obj, ##args ) |
798 #define GST_WARNING_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, obj, ##args ) |
969 #define GST_WARNING_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, obj, ##args ) |
799 #define GST_INFO_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, obj, ##args ) |
970 #define GST_INFO_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, obj, ##args ) |
800 #define GST_DEBUG_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, obj, ##args ) |
971 #define GST_DEBUG_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, obj, ##args ) |
801 #define GST_LOG_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, obj, ##args ) |
972 #define GST_LOG_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, obj, ##args ) |
973 #define GST_FIXME_OBJECT(obj,args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_FIXME, obj, ##args ) |
|
802 |
974 |
803 #define GST_ERROR(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, NULL, ##args ) |
975 #define GST_ERROR(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_ERROR, NULL, ##args ) |
804 #define GST_WARNING(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, NULL, ##args ) |
976 #define GST_WARNING(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_WARNING, NULL, ##args ) |
805 #define GST_INFO(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, NULL, ##args ) |
977 #define GST_INFO(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_INFO, NULL, ##args ) |
806 #define GST_DEBUG(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, NULL, ##args ) |
978 #define GST_DEBUG(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_DEBUG, NULL, ##args ) |
807 #define GST_LOG(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, ##args ) |
979 #define GST_LOG(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, ##args ) |
980 #define GST_FIXME(args...) GST_CAT_LEVEL_LOG (GST_CAT_DEFAULT, GST_LEVEL_FIXME, NULL, ##args ) |
|
808 |
981 |
809 #else |
982 #else |
810 /* no variadic macros, use inline */ |
983 /* no variadic macros, use inline */ |
811 static inline void |
984 static inline void |
812 GST_CAT_ERROR_OBJECT (GstDebugCategory * cat, gpointer obj, const char *format, |
985 GST_CAT_ERROR_OBJECT (GstDebugCategory * cat, gpointer obj, const char *format, |
862 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_LOG, obj, format, varargs); |
1035 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_LOG, obj, format, varargs); |
863 va_end (varargs); |
1036 va_end (varargs); |
864 } |
1037 } |
865 |
1038 |
866 static inline void |
1039 static inline void |
1040 GST_CAT_FIXME_OBJECT (GstDebugCategory * cat, gpointer obj, const char *format, |
|
1041 ...) |
|
1042 { |
|
1043 va_list varargs; |
|
1044 |
|
1045 va_start (varargs, format); |
|
1046 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_FIXME, obj, format, varargs); |
|
1047 va_end (varargs); |
|
1048 } |
|
1049 |
|
1050 static inline void |
|
867 GST_CAT_ERROR (GstDebugCategory * cat, const char *format, ...) |
1051 GST_CAT_ERROR (GstDebugCategory * cat, const char *format, ...) |
868 { |
1052 { |
869 va_list varargs; |
1053 va_list varargs; |
870 |
1054 |
871 va_start (varargs, format); |
1055 va_start (varargs, format); |
908 { |
1092 { |
909 va_list varargs; |
1093 va_list varargs; |
910 |
1094 |
911 va_start (varargs, format); |
1095 va_start (varargs, format); |
912 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_LOG, NULL, format, varargs); |
1096 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_LOG, NULL, format, varargs); |
1097 va_end (varargs); |
|
1098 } |
|
1099 |
|
1100 static inline void |
|
1101 GST_CAT_FIXME (GstDebugCategory * cat, const char *format, ...) |
|
1102 { |
|
1103 va_list varargs; |
|
1104 |
|
1105 va_start (varargs, format); |
|
1106 GST_CAT_LEVEL_LOG_valist (cat, GST_LEVEL_FIXME, NULL, format, varargs); |
|
913 va_end (varargs); |
1107 va_end (varargs); |
914 } |
1108 } |
915 |
1109 |
916 static inline void |
1110 static inline void |
917 GST_ERROR_OBJECT (gpointer obj, const char *format, ...) |
1111 GST_ERROR_OBJECT (gpointer obj, const char *format, ...) |
967 varargs); |
1161 varargs); |
968 va_end (varargs); |
1162 va_end (varargs); |
969 } |
1163 } |
970 |
1164 |
971 static inline void |
1165 static inline void |
1166 GST_FIXME_OBJECT (gpointer obj, const char *format, ...) |
|
1167 { |
|
1168 va_list varargs; |
|
1169 |
|
1170 va_start (varargs, format); |
|
1171 GST_CAT_LEVEL_LOG_valist (GST_CAT_DEFAULT, GST_LEVEL_FIXME, obj, format, |
|
1172 varargs); |
|
1173 va_end (varargs); |
|
1174 } |
|
1175 |
|
1176 static inline void |
|
972 GST_ERROR (const char *format, ...) |
1177 GST_ERROR (const char *format, ...) |
973 { |
1178 { |
974 va_list varargs; |
1179 va_list varargs; |
975 |
1180 |
976 va_start (varargs, format); |
1181 va_start (varargs, format); |
1020 va_start (varargs, format); |
1225 va_start (varargs, format); |
1021 GST_CAT_LEVEL_LOG_valist (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, |
1226 GST_CAT_LEVEL_LOG_valist (GST_CAT_DEFAULT, GST_LEVEL_LOG, NULL, |
1022 format, varargs); |
1227 format, varargs); |
1023 va_end (varargs); |
1228 va_end (varargs); |
1024 } |
1229 } |
1230 |
|
1231 static inline void |
|
1232 GST_FIXME (const char *format, ...) |
|
1233 { |
|
1234 va_list varargs; |
|
1235 |
|
1236 va_start (varargs, format); |
|
1237 GST_CAT_LEVEL_LOG_valist (GST_CAT_DEFAULT, GST_LEVEL_FIXME, NULL, format, |
|
1238 varargs); |
|
1239 va_end (varargs); |
|
1240 } |
|
1025 #endif |
1241 #endif |
1026 #endif |
1242 #endif |
1027 |
1243 |
1028 |
1244 |
1029 /********** function pointer stuff **********/ |
1245 /********** function pointer stuff **********/ |
1066 _gst_debug_nameof_funcptr((GstDebugFuncPtr)ptr) |
1282 _gst_debug_nameof_funcptr((GstDebugFuncPtr)ptr) |
1067 |
1283 |
1068 |
1284 |
1069 #else /* GST_DISABLE_GST_DEBUG */ |
1285 #else /* GST_DISABLE_GST_DEBUG */ |
1070 |
1286 |
1287 |
|
1288 #ifndef GST_INFO_C |
|
1071 |
1289 |
1072 #if defined(__GNUC__) && __GNUC__ >= 3 |
1290 #if defined(__GNUC__) && __GNUC__ >= 3 |
1073 # pragma GCC poison gst_debug_log |
1291 # pragma GCC poison gst_debug_log |
1074 # pragma GCC poison gst_debug_log_valist |
1292 # pragma GCC poison gst_debug_log_valist |
1075 # pragma GCC poison _gst_debug_category_new |
1293 # pragma GCC poison _gst_debug_category_new |
1076 #endif |
1294 #endif |
1077 |
1295 |
1296 #define __gst_debug_min GST_LEVEL_NONE |
|
1297 |
|
1078 #define _gst_debug_init() /* NOP */ |
1298 #define _gst_debug_init() /* NOP */ |
1079 |
1299 |
1080 #define gst_debug_set_default_threshold(level) /* NOP */ |
1300 #define gst_debug_set_default_threshold(level) /* NOP */ |
1081 #define gst_debug_get_default_threshold() (GST_LEVEL_NONE) |
1301 #define gst_debug_get_default_threshold() (GST_LEVEL_NONE) |
1082 |
1302 |
1083 #define gst_debug_level_get_name(level) ("NONE") |
1303 #define gst_debug_level_get_name(level) ("NONE") |
1084 #define gst_debug_message_get(message) ("NONE") |
1304 #define gst_debug_message_get(message) ("") |
1085 #define gst_debug_add_log_function(func,data) /* NOP */ |
1305 #define gst_debug_add_log_function(func,data) /* NOP */ |
1086 guint gst_debug_remove_log_function (GstLogFunction func); |
1306 guint gst_debug_remove_log_function (GstLogFunction func); |
1087 guint gst_debug_remove_log_function_by_data (gpointer data); |
1307 guint gst_debug_remove_log_function_by_data (gpointer data); |
1088 #define gst_debug_set_active(active) /* NOP */ |
1308 #define gst_debug_set_active(active) /* NOP */ |
1089 #define gst_debug_is_active() (FALSE) |
1309 #define gst_debug_is_active() (FALSE) |
1100 #define GST_DEBUG_CATEGORY_STATIC(var) static GstDebugCategory *var = NULL |
1320 #define GST_DEBUG_CATEGORY_STATIC(var) static GstDebugCategory *var = NULL |
1101 #else |
1321 #else |
1102 #define GST_DEBUG_CATEGORY_STATIC(var) /* NOP */ |
1322 #define GST_DEBUG_CATEGORY_STATIC(var) /* NOP */ |
1103 #endif |
1323 #endif |
1104 #define GST_DEBUG_CATEGORY_INIT(var,name,color,desc) /* NOP */ |
1324 #define GST_DEBUG_CATEGORY_INIT(var,name,color,desc) /* NOP */ |
1325 #define GST_DEBUG_CATEGORY_GET(var,name) /* NOP */ |
|
1105 #define gst_debug_category_free(category) /* NOP */ |
1326 #define gst_debug_category_free(category) /* NOP */ |
1106 #define gst_debug_category_set_threshold(category,level) /* NOP */ |
1327 #define gst_debug_category_set_threshold(category,level) /* NOP */ |
1107 #define gst_debug_category_reset_threshold(category) /* NOP */ |
1328 #define gst_debug_category_reset_threshold(category) /* NOP */ |
1108 #define gst_debug_category_get_threshold(category) (GST_LEVEL_NONE) |
1329 #define gst_debug_category_get_threshold(category) (GST_LEVEL_NONE) |
1109 #define gst_debug_category_get_name(cat) ("") |
1330 #define gst_debug_category_get_name(cat) ("") |
1110 #define gst_debug_category_get_color(cat) (0) |
1331 #define gst_debug_category_get_color(cat) (0) |
1111 #define gst_debug_category_get_description(cat) ("") |
1332 #define gst_debug_category_get_description(cat) ("") |
1112 #define gst_debug_get_all_categories() (NULL) |
1333 #define gst_debug_get_all_categories() (NULL) |
1113 #define gst_debug_construct_term_color(colorinfo) (g_strdup ("00")) |
1334 #define gst_debug_construct_term_color(colorinfo) (g_strdup ("00")) |
1335 #define gst_debug_construct_win_color(colorinfo) (0) |
|
1336 |
|
1337 #endif /* !GST_INFO_C */ |
|
1114 |
1338 |
1115 #ifdef G_HAVE_ISO_VARARGS |
1339 #ifdef G_HAVE_ISO_VARARGS |
1116 |
1340 |
1117 #define GST_CAT_LEVEL_LOG(cat,level,...) /* NOP */ |
1341 #define GST_CAT_LEVEL_LOG(cat,level,...) /* NOP */ |
1118 |
1342 |
1119 #define GST_CAT_ERROR_OBJECT(...) /* NOP */ |
1343 #define GST_CAT_ERROR_OBJECT(...) /* NOP */ |
1120 #define GST_CAT_WARNING_OBJECT(...) /* NOP */ |
1344 #define GST_CAT_WARNING_OBJECT(...) /* NOP */ |
1121 #define GST_CAT_INFO_OBJECT(...) /* NOP */ |
1345 #define GST_CAT_INFO_OBJECT(...) /* NOP */ |
1122 #define GST_CAT_DEBUG_OBJECT(...) /* NOP */ |
1346 #define GST_CAT_DEBUG_OBJECT(...) /* NOP */ |
1123 #define GST_CAT_LOG_OBJECT(...) /* NOP */ |
1347 #define GST_CAT_LOG_OBJECT(...) /* NOP */ |
1348 #define GST_CAT_FIXME_OBJECT(...) /* NOP */ |
|
1124 |
1349 |
1125 #define GST_CAT_ERROR(...) /* NOP */ |
1350 #define GST_CAT_ERROR(...) /* NOP */ |
1126 #define GST_CAT_WARNING(...) /* NOP */ |
1351 #define GST_CAT_WARNING(...) /* NOP */ |
1127 #define GST_CAT_INFO(...) /* NOP */ |
1352 #define GST_CAT_INFO(...) /* NOP */ |
1128 #define GST_CAT_DEBUG(...) /* NOP */ |
1353 #define GST_CAT_DEBUG(...) /* NOP */ |
1129 #define GST_CAT_LOG(...) /* NOP */ |
1354 #define GST_CAT_LOG(...) /* NOP */ |
1355 #define GST_CAT_FIXME(...) /* NOP */ |
|
1130 |
1356 |
1131 #define GST_ERROR_OBJECT(...) /* NOP */ |
1357 #define GST_ERROR_OBJECT(...) /* NOP */ |
1132 #define GST_WARNING_OBJECT(...) /* NOP */ |
1358 #define GST_WARNING_OBJECT(...) /* NOP */ |
1133 #define GST_INFO_OBJECT(...) /* NOP */ |
1359 #define GST_INFO_OBJECT(...) /* NOP */ |
1134 #define GST_DEBUG_OBJECT(...) /* NOP */ |
1360 #define GST_DEBUG_OBJECT(...) /* NOP */ |
1135 #define GST_LOG_OBJECT(...) /* NOP */ |
1361 #define GST_LOG_OBJECT(...) /* NOP */ |
1362 #define GST_FIXME_OBJECT(...) /* NOP */ |
|
1136 |
1363 |
1137 #define GST_ERROR(...) /* NOP */ |
1364 #define GST_ERROR(...) /* NOP */ |
1138 #define GST_WARNING(...) /* NOP */ |
1365 #define GST_WARNING(...) /* NOP */ |
1139 #define GST_INFO(...) /* NOP */ |
1366 #define GST_INFO(...) /* NOP */ |
1140 #define GST_DEBUG(...) /* NOP */ |
1367 #define GST_DEBUG(...) /* NOP */ |
1141 #define GST_LOG(...) /* NOP */ |
1368 #define GST_LOG(...) /* NOP */ |
1142 |
1369 #define GST_FIXME(...) /* NOP */ |
1143 #else |
1370 |
1371 #else /* !G_HAVE_ISO_VARARGS */ |
|
1144 #ifdef G_HAVE_GNUC_VARARGS |
1372 #ifdef G_HAVE_GNUC_VARARGS |
1145 |
1373 |
1146 #define GST_CAT_LEVEL_LOG(cat,level,args...) /* NOP */ |
1374 #define GST_CAT_LEVEL_LOG(cat,level,args...) /* NOP */ |
1147 |
1375 |
1148 #define GST_CAT_ERROR_OBJECT(args...) /* NOP */ |
1376 #define GST_CAT_ERROR_OBJECT(args...) /* NOP */ |
1149 #define GST_CAT_WARNING_OBJECT(args...) /* NOP */ |
1377 #define GST_CAT_WARNING_OBJECT(args...) /* NOP */ |
1150 #define GST_CAT_INFO_OBJECT(args...) /* NOP */ |
1378 #define GST_CAT_INFO_OBJECT(args...) /* NOP */ |
1151 #define GST_CAT_DEBUG_OBJECT(args...) /* NOP */ |
1379 #define GST_CAT_DEBUG_OBJECT(args...) /* NOP */ |
1152 #define GST_CAT_LOG_OBJECT(args...) /* NOP */ |
1380 #define GST_CAT_LOG_OBJECT(args...) /* NOP */ |
1381 #define GST_CAT_FIXME_OBJECT(args...) /* NOP */ |
|
1153 |
1382 |
1154 #define GST_CAT_ERROR(args...) /* NOP */ |
1383 #define GST_CAT_ERROR(args...) /* NOP */ |
1155 #define GST_CAT_WARNING(args...) /* NOP */ |
1384 #define GST_CAT_WARNING(args...) /* NOP */ |
1156 #define GST_CAT_INFO(args...) /* NOP */ |
1385 #define GST_CAT_INFO(args...) /* NOP */ |
1157 #define GST_CAT_DEBUG(args...) /* NOP */ |
1386 #define GST_CAT_DEBUG(args...) /* NOP */ |
1158 #define GST_CAT_LOG(args...) /* NOP */ |
1387 #define GST_CAT_LOG(args...) /* NOP */ |
1388 #define GST_CAT_FIXME(args...) /* NOP */ |
|
1159 |
1389 |
1160 #define GST_ERROR_OBJECT(args...) /* NOP */ |
1390 #define GST_ERROR_OBJECT(args...) /* NOP */ |
1161 #define GST_WARNING_OBJECT(args...) /* NOP */ |
1391 #define GST_WARNING_OBJECT(args...) /* NOP */ |
1162 #define GST_INFO_OBJECT(args...) /* NOP */ |
1392 #define GST_INFO_OBJECT(args...) /* NOP */ |
1163 #define GST_DEBUG_OBJECT(args...) /* NOP */ |
1393 #define GST_DEBUG_OBJECT(args...) /* NOP */ |
1164 #define GST_LOG_OBJECT(args...) /* NOP */ |
1394 #define GST_LOG_OBJECT(args...) /* NOP */ |
1395 #define GST_FIXME_OBJECT(args...) /* NOP */ |
|
1165 |
1396 |
1166 #define GST_ERROR(args...) /* NOP */ |
1397 #define GST_ERROR(args...) /* NOP */ |
1167 #define GST_WARNING(args...) /* NOP */ |
1398 #define GST_WARNING(args...) /* NOP */ |
1168 #define GST_INFO(args...) /* NOP */ |
1399 #define GST_INFO(args...) /* NOP */ |
1169 #define GST_DEBUG(args...) /* NOP */ |
1400 #define GST_DEBUG(args...) /* NOP */ |
1170 #define GST_LOG(args...) /* NOP */ |
1401 #define GST_LOG(args...) /* NOP */ |
1171 |
1402 #define GST_FIXME(args...) /* NOP */ |
1172 #else |
1403 |
1404 #else /* !G_HAVE_GNUC_VARARGS */ |
|
1173 static inline void |
1405 static inline void |
1174 GST_CAT_LEVEL_LOG_valist (GstDebugCategory * cat, |
1406 GST_CAT_LEVEL_LOG_valist (GstDebugCategory * cat, |
1175 GstDebugLevel level, gpointer object, const char *format, va_list varargs) |
1407 GstDebugLevel level, gpointer object, const char *format, va_list varargs) |
1176 { |
1408 { |
1177 } |
1409 } |
1205 ...) |
1437 ...) |
1206 { |
1438 { |
1207 } |
1439 } |
1208 |
1440 |
1209 static inline void |
1441 static inline void |
1442 GST_CAT_FIXME_OBJECT (GstDebugCategory * cat, gpointer obj, const char *format, |
|
1443 ...) |
|
1444 { |
|
1445 } |
|
1446 |
|
1447 static inline void |
|
1210 GST_CAT_ERROR (GstDebugCategory * cat, const char *format, ...) |
1448 GST_CAT_ERROR (GstDebugCategory * cat, const char *format, ...) |
1211 { |
1449 { |
1212 } |
1450 } |
1213 |
1451 |
1214 static inline void |
1452 static inline void |
1230 GST_CAT_LOG (GstDebugCategory * cat, const char *format, ...) |
1468 GST_CAT_LOG (GstDebugCategory * cat, const char *format, ...) |
1231 { |
1469 { |
1232 } |
1470 } |
1233 |
1471 |
1234 static inline void |
1472 static inline void |
1473 GST_CAT_FIXME (GstDebugCategory * cat, const char *format, ...) |
|
1474 { |
|
1475 } |
|
1476 |
|
1477 static inline void |
|
1235 GST_ERROR_OBJECT (gpointer obj, const char *format, ...) |
1478 GST_ERROR_OBJECT (gpointer obj, const char *format, ...) |
1236 { |
1479 { |
1237 } |
1480 } |
1238 |
1481 |
1239 static inline void |
1482 static inline void |
1255 GST_LOG_OBJECT (gpointer obj, const char *format, ...) |
1498 GST_LOG_OBJECT (gpointer obj, const char *format, ...) |
1256 { |
1499 { |
1257 } |
1500 } |
1258 |
1501 |
1259 static inline void |
1502 static inline void |
1503 GST_FIXME_OBJECT (gpointer obj, const char *format, ...) |
|
1504 { |
|
1505 } |
|
1506 |
|
1507 static inline void |
|
1260 GST_ERROR (const char *format, ...) |
1508 GST_ERROR (const char *format, ...) |
1261 { |
1509 { |
1262 } |
1510 } |
1263 |
1511 |
1264 static inline void |
1512 static inline void |
1278 |
1526 |
1279 static inline void |
1527 static inline void |
1280 GST_LOG (const char *format, ...) |
1528 GST_LOG (const char *format, ...) |
1281 { |
1529 { |
1282 } |
1530 } |
1283 #endif |
1531 |
1284 #endif |
1532 static inline void |
1533 GST_FIXME (const char *format, ...) |
|
1534 { |
|
1535 } |
|
1536 |
|
1537 #endif /* G_HAVE_GNUC_VARARGS */ |
|
1538 #endif /* G_HAVE_ISO_VARARGS */ |
|
1285 |
1539 |
1286 #define GST_DEBUG_FUNCPTR(ptr) (ptr) |
1540 #define GST_DEBUG_FUNCPTR(ptr) (ptr) |
1287 #define GST_DEBUG_FUNCPTR_NAME(ptr) (g_strdup_printf ("%p", ptr)) |
1541 #define GST_DEBUG_FUNCPTR_NAME(ptr) (g_strdup_printf ("%p", ptr)) |
1288 |
1542 |
1543 #define GST_CAT_MEMDUMP_OBJECT(cat,obj,msg,data,length) /* NOP */ |
|
1544 #define GST_CAT_MEMDUMP(cat,msg,data,length) /* NOP */ |
|
1545 #define GST_MEMDUMP_OBJECT(obj,msg,data,length) /* NOP */ |
|
1546 #define GST_MEMDUMP(msg,data,length) /* NOP */ |
|
1547 |
|
1289 #endif /* GST_DISABLE_GST_DEBUG */ |
1548 #endif /* GST_DISABLE_GST_DEBUG */ |
1549 #ifdef __SYMBIAN32__ |
|
1550 IMPORT_C |
|
1551 #endif |
|
1290 |
1552 |
1291 |
1553 |
1292 void gst_debug_print_stack_trace (void); |
1554 void gst_debug_print_stack_trace (void); |
1293 |
1555 |
1294 G_END_DECLS |
1556 G_END_DECLS |