[vlc-commits] src/image: correctly handle anamorphic content sizes (closes #13862)
Felix Paul Kühne
git at videolan.org
Tue Jun 23 19:46:31 CEST 2015
vlc | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Tue Jun 23 15:18:12 2015 +0200| [c342e2ef72c9ab83f5bd7add27b41b5de6eeab2c] | committer: Felix Paul Kühne
src/image: correctly handle anamorphic content sizes (closes #13862)
This fixes a regression introduced in e3b809c1
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c342e2ef72c9ab83f5bd7add27b41b5de6eeab2c
---
src/misc/image.c | 21 ++++++++++-----------
1 file changed, 10 insertions(+), 11 deletions(-)
diff --git a/src/misc/image.c b/src/misc/image.c
index 02db3cb..142b82c 100644
--- a/src/misc/image.c
+++ b/src/misc/image.c
@@ -677,17 +677,16 @@ static encoder_t *CreateEncoder( vlc_object_t *p_this, video_format_t *fmt_in,
p_enc->fmt_in.video.i_visible_height = fmt_out->i_height;
}
}
- else if( fmt_out->i_sar_num && fmt_out->i_sar_den &&
- fmt_out->i_sar_num * fmt_in->i_sar_den !=
- fmt_out->i_sar_den * fmt_in->i_sar_num )
- {
- p_enc->fmt_in.video.i_width =
- fmt_in->i_sar_num * (int64_t)fmt_out->i_sar_den * fmt_in->i_width /
- fmt_in->i_sar_den / fmt_out->i_sar_num;
- p_enc->fmt_in.video.i_visible_width =
- fmt_in->i_sar_num * (int64_t)fmt_out->i_sar_den *
- fmt_in->i_visible_width / fmt_in->i_sar_den / fmt_out->i_sar_num;
- }
+ } else if( fmt_out->i_sar_num && fmt_out->i_sar_den &&
+ fmt_out->i_sar_num * fmt_in->i_sar_den !=
+ fmt_out->i_sar_den * fmt_in->i_sar_num )
+ {
+ p_enc->fmt_in.video.i_width =
+ fmt_in->i_sar_num * (int64_t)fmt_out->i_sar_den * fmt_in->i_width /
+ fmt_in->i_sar_den / fmt_out->i_sar_num;
+ p_enc->fmt_in.video.i_visible_width =
+ fmt_in->i_sar_num * (int64_t)fmt_out->i_sar_den *
+ fmt_in->i_visible_width / fmt_in->i_sar_den / fmt_out->i_sar_num;
}
p_enc->fmt_in.video.i_frame_rate = 25;
More information about the vlc-commits
mailing list