Name: libmm-streamrecorder
Summary: Media Stream Recorder library
-Version: 0.0.31
+Version: 0.0.32
Release: 0
Group: Multimedia/Other
License: Apache-2.0
gchar supported_video_encoders[STREAMRECORDER_ATTRIBUTE_NUM_MAX][STREAMRECORDER_INI_MAX_STRLEN];
gchar supported_file_formats[STREAMRECORDER_ATTRIBUTE_NUM_MAX][STREAMRECORDER_INI_MAX_STRLEN];
+ /* debug */
+ gboolean generate_dot;
} mm_streamrecorder_ini_t;
/*Default sink ini values*/
#define DEFAULT_SUPPORTED_VIDEO_ENCODERS ""
#define DEFAULT_SUPPORTED_FILE_FORMATS ""
+/*debug*/
+#define DEFAULT_GENERATE_DOT FALSE
+
int _mm_streamrecorder_ini_load(mm_streamrecorder_ini_t * ini);
int _mm_streamrecorder_ini_unload(mm_streamrecorder_ini_t * ini);
vnewstate = (GValue *) gst_structure_get_value(gst_message_get_structure(message), "new-state");
newstate = (GstState) vnewstate->data[0].v_int;
_mmstreamrec_dbg_log("GST_MESSAGE_STATE_CHANGED[%s]", gst_element_state_get_name(newstate));
+ if (newstate == 4) {
+ if (hstreamrecorder->ini.generate_dot) {
+ _mmstreamrec_dbg_log("GST_MESSAGE_STATE_PLAYING! DOT would be generated.");
+ g_setenv("GST_DEBUG_DUMP_DOT_DIR", "/tmp/", FALSE);
+ GST_DEBUG_BIN_TO_DOT_FILE(GST_BIN(sc->encode_element[_MMSTREAMRECORDER_ENCODE_MAIN_PIPE].gst), GST_DEBUG_GRAPH_SHOW_ALL, "streamrecorder_pipeline");
+ }
+ }
}
}
}
__get_element_list(ini, iniparser_getstring(dict, "attribute:supported video encoders", (char*)DEFAULT_SUPPORTED_VIDEO_ENCODERS), KEYWORD_VIDEO_ENCODERS);
__get_element_list(ini, iniparser_getstring(dict, "attribute:supported file formats", (char*)DEFAULT_SUPPORTED_FILE_FORMATS), KEYWORD_FILE_FORMATS);
+ /* debug */
+ ini->generate_dot = iniparser_getboolean(dict, "debug:generate dot", DEFAULT_GENERATE_DOT);
+
} else { /* if dict is not available just fill the structure with default value */
_mmstreamrec_dbg_err("failed to load ini. using hardcoded default\n");
/* general */
__get_element_list(ini, (char *)DEFAULT_SUPPORTED_AUDIO_ENCODERS, KEYWORD_AUDIO_ENCODERS);
__get_element_list(ini, (char *)DEFAULT_SUPPORTED_VIDEO_ENCODERS, KEYWORD_VIDEO_ENCODERS);
__get_element_list(ini, (char *)DEFAULT_SUPPORTED_FILE_FORMATS, KEYWORD_FILE_FORMATS);
+
+ /* debug */
+ ini->generate_dot = DEFAULT_GENERATE_DOT;
}
/* free dict as we got our own structure */