camerabin: Replacing ffmpegcolorspace with videoconvert

This commit is contained in:
Thiago Santos 2012-05-01 10:18:52 -03:00
parent 7394deef33
commit 79d3cc533f
3 changed files with 8 additions and 8 deletions

View file

@ -140,7 +140,7 @@ gst_camerabin_create_preview_pipeline (GstElement * element,
data->pipeline = gst_pipeline_new ("preview-pipeline"); data->pipeline = gst_pipeline_new ("preview-pipeline");
data->appsrc = gst_element_factory_make ("appsrc", "preview-appsrc"); data->appsrc = gst_element_factory_make ("appsrc", "preview-appsrc");
data->appsink = gst_element_factory_make ("appsink", "preview-appsink"); data->appsink = gst_element_factory_make ("appsink", "preview-appsink");
csp = gst_element_factory_make ("ffmpegcolorspace", "preview-csp"); csp = gst_element_factory_make ("videoconvert", "preview-vconv");
vscale = gst_element_factory_make ("videoscale", "preview-vscale"); vscale = gst_element_factory_make ("videoscale", "preview-vscale");
if (!data->appsrc || !data->appsink || !csp || !vscale) { if (!data->appsrc || !data->appsink || !csp || !vscale) {

View file

@ -199,9 +199,9 @@ gst_viewfinder_bin_create_elements (GstViewfinderBin * vfbin)
gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), NULL); gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), NULL);
/* add the elements, user wants them */ /* add the elements, user wants them */
csp = gst_element_factory_make ("ffmpegcolorspace", "vfbin-csp"); csp = gst_element_factory_make ("videoconvert", "vfbin-csp");
if (!csp) { if (!csp) {
missing_element_name = "ffmpegcolorspace"; missing_element_name = "videoconvert";
goto missing_element; goto missing_element;
} }
gst_bin_add (GST_BIN_CAST (vfbin), csp); gst_bin_add (GST_BIN_CAST (vfbin), csp);

View file

@ -480,8 +480,8 @@ gst_wrapper_camera_bin_src_construct_pipeline (GstBaseCameraSrc * bcamsrc)
gst_object_unref (pad); gst_object_unref (pad);
} }
if (!gst_camerabin_create_and_add_element (cbin, "ffmpegcolorspace", if (!gst_camerabin_create_and_add_element (cbin, "videoconvert",
"src-colorspace")) "src-videoconvert"))
goto done; goto done;
if (!(self->src_filter = if (!(self->src_filter =
@ -590,10 +590,10 @@ gst_wrapper_camera_bin_src_construct_pipeline (GstBaseCameraSrc * bcamsrc)
if (!self->video_filter) { if (!self->video_filter) {
if (self->app_vid_filter) { if (self->app_vid_filter) {
self->video_filter = gst_object_ref (self->app_vid_filter); self->video_filter = gst_object_ref (self->app_vid_filter);
filter_csp = gst_element_factory_make ("ffmpegcolorspace", filter_csp = gst_element_factory_make ("videoconvert",
"filter-colorspace"); "filter-videoconvert");
gst_bin_add_many (cbin, self->video_filter, filter_csp, NULL); gst_bin_add_many (cbin, self->video_filter, filter_csp, NULL);
src_csp = gst_bin_get_by_name (cbin, "src-colorspace"); src_csp = gst_bin_get_by_name (cbin, "src-videoconvert");
capsfilter = gst_bin_get_by_name (cbin, "src-capsfilter"); capsfilter = gst_bin_get_by_name (cbin, "src-capsfilter");
if (gst_pad_is_linked (gst_element_get_static_pad (src_csp, "src"))) if (gst_pad_is_linked (gst_element_get_static_pad (src_csp, "src")))
gst_element_unlink (src_csp, capsfilter); gst_element_unlink (src_csp, capsfilter);