mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-25 03:01:03 +00:00
videodecoder: Output mono multiview caps if none specified
Always put multiview-caps onto the output caps, assuming mono if we've got no other information. It's still easy for downstream elements to override using a capssetter or event probe if desired. https://bugzilla.gnome.org/show_bug.cgi?id=776172
This commit is contained in:
parent
cc281e80d6
commit
2980e96a50
1 changed files with 14 additions and 0 deletions
|
@ -657,6 +657,10 @@ _new_output_state (GstVideoFormat fmt, guint width, guint height,
|
|||
GST_VIDEO_INFO_MULTIVIEW_MODE (tgt) = GST_VIDEO_INFO_MULTIVIEW_MODE (ref);
|
||||
GST_VIDEO_INFO_MULTIVIEW_FLAGS (tgt) =
|
||||
GST_VIDEO_INFO_MULTIVIEW_FLAGS (ref);
|
||||
} else {
|
||||
/* Default to MONO, overridden as needed by sub-classes */
|
||||
GST_VIDEO_INFO_MULTIVIEW_MODE (tgt) = GST_VIDEO_MULTIVIEW_MODE_MONO;
|
||||
GST_VIDEO_INFO_MULTIVIEW_FLAGS (tgt) = GST_VIDEO_MULTIVIEW_FLAGS_NONE;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3786,6 +3790,16 @@ gst_video_decoder_negotiate_default (GstVideoDecoder * decoder)
|
|||
g_return_val_if_fail (GST_VIDEO_INFO_WIDTH (&state->info) != 0, FALSE);
|
||||
g_return_val_if_fail (GST_VIDEO_INFO_HEIGHT (&state->info) != 0, FALSE);
|
||||
|
||||
/* If the base class didn't set any multiview params, assume mono
|
||||
* now */
|
||||
if (GST_VIDEO_INFO_MULTIVIEW_MODE (&state->info) ==
|
||||
GST_VIDEO_MULTIVIEW_MODE_NONE) {
|
||||
GST_VIDEO_INFO_MULTIVIEW_MODE (&state->info) =
|
||||
GST_VIDEO_MULTIVIEW_MODE_MONO;
|
||||
GST_VIDEO_INFO_MULTIVIEW_FLAGS (&state->info) =
|
||||
GST_VIDEO_MULTIVIEW_FLAGS_NONE;
|
||||
}
|
||||
|
||||
GST_DEBUG_OBJECT (decoder, "output_state par %d/%d fps %d/%d",
|
||||
state->info.par_n, state->info.par_d,
|
||||
state->info.fps_n, state->info.fps_d);
|
||||
|
|
Loading…
Reference in a new issue