[MPlayer-cvslog] r19932 - trunk/libmpdemux/muxer_avi.c
ods15
subversion at mplayerhq.hu
Fri Sep 22 12:27:17 CEST 2006
Author: ods15
Date: Fri Sep 22 12:27:17 2006
New Revision: 19932
Modified:
trunk/libmpdemux/muxer_avi.c
Log:
better rounding for audio_delay_fix in muxer_avi.c
Modified: trunk/libmpdemux/muxer_avi.c
==============================================================================
--- trunk/libmpdemux/muxer_avi.c (original)
+++ trunk/libmpdemux/muxer_avi.c Fri Sep 22 12:27:17 2006
@@ -288,11 +288,11 @@
for (i = 0; muxer->streams[i] && i < MUXER_MAX_STREAMS; ++i) {
muxer_stream_t *s = muxer->streams[i];
if (s->type == MUXER_TYPE_AUDIO && muxer->audio_delay_fix > 0.0) {
- s->h.dwStart = muxer->audio_delay_fix * s->h.dwRate/s->h.dwScale;
+ s->h.dwStart = muxer->audio_delay_fix * s->h.dwRate/s->h.dwScale + 0.5;
mp_msg(MSGT_MUXER, MSGL_INFO, MSGTR_SettingAudioDelay, (float)s->h.dwStart * s->h.dwScale/s->h.dwRate);
}
if (s->type == MUXER_TYPE_VIDEO && muxer->audio_delay_fix < 0.0) {
- s->h.dwStart = -muxer->audio_delay_fix * s->h.dwRate/s->h.dwScale;
+ s->h.dwStart = -muxer->audio_delay_fix * s->h.dwRate/s->h.dwScale + 0.5;
mp_msg(MSGT_MUXER, MSGL_INFO, MSGTR_SettingVideoDelay, (float)s->h.dwStart * s->h.dwScale/s->h.dwRate);
}
}
More information about the MPlayer-cvslog
mailing list