Commit eadc6196 authored by Rafaël Carré's avatar Rafaël Carré

x265: default to 25fps if frame rate is not set

parent 4867c2a6
...@@ -170,9 +170,17 @@ static int Open (vlc_object_t *p_this) ...@@ -170,9 +170,17 @@ static int Open (vlc_object_t *p_this)
#if X265_BUILD >= 6 #if X265_BUILD >= 6
param->fpsNum = p_enc->fmt_in.video.i_frame_rate; param->fpsNum = p_enc->fmt_in.video.i_frame_rate;
param->fpsDenom = p_enc->fmt_in.video.i_frame_rate_base; param->fpsDenom = p_enc->fmt_in.video.i_frame_rate_base;
if (!param->fpsNum) {
param->fpsNum = 25;
param->fpsDenom = 1;
}
#else #else
if (p_enc->fmt_in.video.i_frame_rate_base) {
param->frameRate = p_enc->fmt_in.video.i_frame_rate / param->frameRate = p_enc->fmt_in.video.i_frame_rate /
p_enc->fmt_in.video.i_frame_rate_base; p_enc->fmt_in.video.i_frame_rate_base;
} else {
param->frameRate = 25;
}
#endif #endif
param->sourceWidth = p_enc->fmt_in.video.i_visible_width; param->sourceWidth = p_enc->fmt_in.video.i_visible_width;
param->sourceHeight = p_enc->fmt_in.video.i_visible_height; param->sourceHeight = p_enc->fmt_in.video.i_visible_height;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment