[FFmpeg-devel] v4l2.c : numerator and denominator are alternated
henk devolder
henk.devolder at telenet.be
Fri Nov 11 03:30:37 CET 2011
Hi,
I had a look in the v4l2.c source ...
In the v4l2_set_parameters function it seems to me
that the numerator and denominator variables are alternated.
if (framerate_q.num && framerate_q.den) {
av_log(s1, AV_LOG_DEBUG, "Setting time per frame to %d/%d\n",
framerate_q.den, framerate_q.num);
--> tpf->numerator = framerate_q.den;
--> tpf->denominator = framerate_q.num;
if (v4l2_ioctl(s->fd, VIDIOC_S_PARM, &streamparm) != 0) {
av_log(s1, AV_LOG_ERROR,
"ioctl set time per frame(%d/%d) failed\n",
framerate_q.den, framerate_q.num);
return AVERROR(EIO);
}
--> if (framerate_q.num != tpf->denominator ||
--> framerate_q.den != tpf->numerator) {
av_log(s1, AV_LOG_INFO,
"The driver changed the time per frame from %d/%d to
%d/%d\n",
framerate_q.den, framerate_q.num,
tpf->numerator, tpf->denominator);
}
Kr,
Henk
--
Using Opera's revolutionary email client: http://www.opera.com/mail/
More information about the ffmpeg-devel
mailing list