comparison mencoder.c @ 25783:8d46379da327

Extend the precision of rationale conversion so it would give proper result for framerate 60000/1001 . Otherwise framerate restrained encoders like lavc mpeg2video would refuse to encode, even if -ofps 60000/1001 is given.
author iive
date Sat, 19 Jan 2008 23:19:41 +0000
parents 273c1eaae7c8
children afaf3ec733d3
comparison
equal deleted inserted replaced
25782:aac51b420d89 25783:8d46379da327
755 mux_v->source=sh_video; 755 mux_v->source=sh_video;
756 756
757 mux_v->h.dwSampleSize=0; // VBR 757 mux_v->h.dwSampleSize=0; // VBR
758 #ifdef USE_LIBAVCODEC 758 #ifdef USE_LIBAVCODEC
759 { 759 {
760 AVRational q= av_d2q(force_ofps?force_ofps:sh_video->fps*playback_speed, 30000); 760 AVRational q= av_d2q(force_ofps?force_ofps:sh_video->fps*playback_speed, 60000);
761 mux_v->h.dwScale= q.den; 761 mux_v->h.dwScale= q.den;
762 mux_v->h.dwRate = q.num; 762 mux_v->h.dwRate = q.num;
763 } 763 }
764 #else 764 #else
765 mux_v->h.dwScale=10000; 765 mux_v->h.dwScale=10000;