[FFmpeg-cvslog] Add a work-around for msvc compilation until c99-to-c89 issue 7 is fixed.
Carl Eugen Hoyos
git at videolan.org
Thu Apr 4 00:26:34 CEST 2013
ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Wed Apr 3 23:58:20 2013 +0200| [1c0d8f2563cc2a5b3ce78056572a7ee40b0f5987] | committer: Carl Eugen Hoyos
Add a work-around for msvc compilation until c99-to-c89 issue 7 is fixed.
Tested-by: Nevcairiel
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1c0d8f2563cc2a5b3ce78056572a7ee40b0f5987
---
ffmpeg.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/ffmpeg.c b/ffmpeg.c
index 8a3179b..effb042 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1884,8 +1884,10 @@ static int output_packet(InputStream *ist, const AVPacket *pkt)
break;
case AVMEDIA_TYPE_VIDEO:
if (ist->framerate.num) {
- int64_t next_dts = av_rescale_q(ist->next_dts, AV_TIME_BASE_Q, av_inv_q(ist->framerate));
- ist->next_dts = av_rescale_q(next_dts + 1, av_inv_q(ist->framerate), AV_TIME_BASE_Q);
+ // TODO: Remove work-around for c99-to-c89 issue 7
+ AVRational time_base_q = AV_TIME_BASE_Q;
+ int64_t next_dts = av_rescale_q(ist->next_dts, time_base_q, av_inv_q(ist->framerate));
+ ist->next_dts = av_rescale_q(next_dts + 1, av_inv_q(ist->framerate), time_base_q);
} else if (pkt->duration) {
ist->next_dts += av_rescale_q(pkt->duration, ist->st->time_base, AV_TIME_BASE_Q);
} else if(ist->st->codec->time_base.num != 0) {
More information about the ffmpeg-cvslog
mailing list