int _gst_build_pipeline(webrtc_s *webrtc)
{
+ gchar *webrtcbin_name;
+
RET_VAL_IF(webrtc == NULL, WEBRTC_ERROR_INVALID_PARAMETER, "webrtc is NULL");
webrtc->gst.pipeline = gst_pipeline_new("main-pipeline");
goto error;
}
- if (!(webrtc->gst.webrtcbin = _create_element("webrtcbin", NULL))) {
+ webrtcbin_name = g_strdup_printf("webrtcbin_%p", webrtc);
+ if (!(webrtc->gst.webrtcbin = _create_element("webrtcbin", webrtcbin_name))) {
LOG_ERROR("failed to create webrtcbin");
+ g_free(webrtcbin_name);
goto error;
}
+ g_free(webrtcbin_name);
g_object_set(G_OBJECT(webrtc->gst.webrtcbin), "bundle-policy", 3, NULL); /* 3 for max-bundle */