mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-08 00:59:48 +00:00
basevideodecoder: Better handling of invalid par
This commit is contained in:
parent
33d96b69be
commit
929603d56c
1 changed files with 3 additions and 3 deletions
|
@ -1808,12 +1808,12 @@ gst_base_video_decoder_set_src_caps (GstBaseVideoDecoder * base_video_decoder)
|
|||
g_return_val_if_fail (state->height != 0, FALSE);
|
||||
|
||||
/* sanitize */
|
||||
if (state->fps_d == 0) {
|
||||
if (state->fps_n == 0 || state->fps_d == 0) {
|
||||
state->fps_n = 0;
|
||||
state->fps_d = 1;
|
||||
}
|
||||
if (state->par_d == 0) {
|
||||
state->par_n = 0;
|
||||
if (state->par_n == 0 || state->par_d == 0) {
|
||||
state->par_n = 1;
|
||||
state->par_d = 1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue