[FFmpeg-user] recording @ 120fps on mac fails with 'activeVideoMinFrameDuration not supported'

Roman Puttkammer rputtkammer at gmail.com
Wed Nov 15 05:58:03 EET 2017


I did run into another issue; though the frame rate 320/240 @ 120fps is set
successfully, ffmpeg reports only 30+ fps later on. (It starts off at 50,
then drops down to 30+ shortly thereafter.) This seems less straightforward
- unless I'm not using the command line options right (or am
misunderstanding how the frame rate works.)

See the third before the last line below - "frame=  220 fps= 37 ..."

Any suggestions?


*Romans-MBP:ffmpeg putt$ ffmpeg/ffmpeg -y -f avfoundation -video_size
320x240 -r 120.101366 -pixel_format uyvy422 -i "0:none" out.avi*
ffmpeg version N-89047-g54f8ac199f Copyright (c) 2000-2017 the FFmpeg
developers
  built with Apple LLVM version 9.0.0 (clang-900.0.38)
  configuration: --prefix=/usr/local --enable-gpl --enable-nonfree
--enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
--enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264
--enable-libx265 --enable-libopus --enable-libxvid
  libavutil      56.  0.100 / 56.  0.100
  libavcodec     58.  3.101 / 58.  3.101
  libavformat    58.  2.100 / 58.  2.100
  libavdevice    58.  0.100 / 58.  0.100
  libavfilter     7.  0.101 /  7.  0.101
  libswscale      5.  0.101 /  5.  0.101
  libswresample   3.  0.101 /  3.  0.101
  libpostproc    55.  0.100 / 55.  0.100
Input #0, avfoundation, from '0:none':
  Duration: N/A, start: 12615.043733, bitrate: N/A
    Stream #0:0: Video: rawvideo (UYVY / 0x59565955), uyvy422, 320x240, 33
tbr, 1000k tbn, 1000k tbc
Stream mapping:
  Stream #0:0 -> #0:0 (rawvideo (native) -> mpeg4 (native))
Press [q] to stop, [?] for help
Output #0, avi, to 'out.avi':
  Metadata:
    ISFT            : Lavf58.2.100
    Stream #0:0: Video: mpeg4 (FMP4 / 0x34504D46), yuv420p, 320x240,
q=2-31, 200 kb/s, 120.10 fps, 120.10 tbn, 120.10 tbc
    Metadata:
      encoder         : Lavc58.3.101 mpeg4
    Side data:
      cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: -1
*frame=  220 fps= 37 q=19.6 Lsize=     112kB time=00:00:01.83 bitrate=
499.0kbits/s speed=0.305x    *
video:101kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB
muxing overhead: 10.726502%
Exiting normally, received signal 2.


On Tue, Nov 14, 2017 at 9:18 PM Roman Puttkammer <rputtkammer at gmail.com>
wrote:

> Never mind, found the issue. The code in avfoundation.m breaks out of one
> loop only instead of two. I'll submit a patch.
>
>
> On Tue, Nov 14, 2017 at 9:03 PM Roman Puttkammer <rputtkammer at gmail.com>
> wrote:
>
>> Carl - thanks, I tried that now. Same thing happens.
>>
>> I found this link that seems to describe a similar problem,
>> https://github.com/piemonte/PBJVision/issues/127, but that's for the
>> iOS; that said, could it be also related to the order in which the
>> format/frame rate or other properties are set?
>>
>> I'll look at the code but I'm a newbie with ffmpeg and video capture.
>> Any/all pointers really appreciated.
>>
>>
>> ### Version - compiled as per
>> https://trac.ffmpeg.org/wiki/CompilationGuide/macOS but without libass
>> ###
>> Romans-MBP:ffmpeg putt$ ffmpeg/ffmpeg -h
>> ffmpeg version N-89047-g54f8ac199f Copyright (c) 2000-2017 the FFmpeg
>> developers
>>   built with Apple LLVM version 9.0.0 (clang-900.0.38)
>>   configuration: --prefix=/usr/local --enable-gpl --enable-nonfree
>> --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
>> --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264
>> --enable-libx265 --enable-libopus --enable-libxvid
>>   libavutil      56.  0.100 / 56.  0.100
>>   libavcodec     58.  3.101 / 58.  3.101
>>   libavformat    58.  2.100 / 58.  2.100
>>   libavdevice    58.  0.100 / 58.  0.100
>>   libavfilter     7.  0.101 /  7.  0.101
>>   libswscale      5.  0.101 /  5.  0.101
>>   libswresample   3.  0.101 /  3.  0.101
>>   libpostproc    55.  0.100 / 55.  0.100
>>
>> ### FAIL: framerate 120.101366
>> ###
>> Romans-MBP:ffmpeg putt$ ffmpeg/ffmpeg -f avfoundation -video_size 320x240
>> -framerate 120.101366 -pixel_format uyvy422 -i "0:none" out.avi
>> ffmpeg version N-89047-g54f8ac199f Copyright (c) 2000-2017 the FFmpeg
>> developers
>>   built with Apple LLVM version 9.0.0 (clang-900.0.38)
>>   configuration: --prefix=/usr/local --enable-gpl --enable-nonfree
>> --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
>> --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264
>> --enable-libx265 --enable-libopus --enable-libxvid
>>   libavutil      56.  0.100 / 56.  0.100
>>   libavcodec     58.  3.101 / 58.  3.101
>>   libavformat    58.  2.100 / 58.  2.100
>>   libavdevice    58.  0.100 / 58.  0.100
>>   libavfilter     7.  0.101 /  7.  0.101
>>   libswscale      5.  0.101 /  5.  0.101
>>   libswresample   3.  0.101 /  3.  0.101
>>   libpostproc    55.  0.100 / 55.  0.100
>> [avfoundation @ 0x7fc399003400] An error occurred: The
>> activeVideoMinFrameDuration passed is not supported by the device.  Use
>> -activeFormat.videoSupportedFrameRateRanges to discover valid
>> ranges.0:none: Input/output error
>>
>> ### Fail: framerate 120
>> ###
>> Romans-MBP:ffmpeg putt$ ffmpeg/ffmpeg -f avfoundation -video_size 320x240
>> -framerate 120 -pixel_format uyvy422 -i "0:none" out.avi
>> ffmpeg version N-89047-g54f8ac199f Copyright (c) 2000-2017 the FFmpeg
>> developers
>>   built with Apple LLVM version 9.0.0 (clang-900.0.38)
>>   configuration: --prefix=/usr/local --enable-gpl --enable-nonfree
>> --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
>> --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264
>> --enable-libx265 --enable-libopus --enable-libxvid
>>   libavutil      56.  0.100 / 56.  0.100
>>   libavcodec     58.  3.101 / 58.  3.101
>>   libavformat    58.  2.100 / 58.  2.100
>>   libavdevice    58.  0.100 / 58.  0.100
>>   libavfilter     7.  0.101 /  7.  0.101
>>   libswscale      5.  0.101 /  5.  0.101
>>   libswresample   3.  0.101 /  3.  0.101
>>   libpostproc    55.  0.100 / 55.  0.100
>> [avfoundation @ 0x7fd85b803400] Selected framerate (120.000000) is not
>> supported by the device
>> [avfoundation @ 0x7fd85b803400] Supported modes:
>> [avfoundation @ 0x7fd85b803400]   320x240@[120.101366 120.101366]fps
>> [avfoundation @ 0x7fd85b803400]   640x480@[120.101366 120.101366]fps
>> [avfoundation @ 0x7fd85b803400]   800x600@[60.000240 60.000240]fps
>> [avfoundation @ 0x7fd85b803400]   1024x768@[30.000030 30.000030]fps
>> [avfoundation @ 0x7fd85b803400]   1280x720@[60.000240 60.000240]fps
>> [avfoundation @ 0x7fd85b803400]   1280x1024@[30.000030 30.000030]fps
>> [avfoundation @ 0x7fd85b803400]   1920x1080@[30.000030 30.000030]fps
>> [avfoundation @ 0x7fd85b803400]   320x240@[30.000030 30.000030]fps
>> [avfoundation @ 0x7fd85b803400]   640x480@[30.000030 30.000030]fps
>> [avfoundation @ 0x7fd85b803400]   800x600@[20.000000 20.000000]fps
>> [avfoundation @ 0x7fd85b803400]   1024x768@[6.000002 6.000002]fps
>> 0:none: Input/output error
>>
>>
>> On Tue, Nov 14, 2017 at 12:11 PM Carl Eugen Hoyos <ceffmpeg at gmail.com>
>> wrote:
>>
>>> 2017-11-14 4:54 GMT+01:00 Roman Puttkammer <rputtkammer at gmail.com>:
>>>
>>> > ffmpeg version 3.4 Copyright (c) 2000-2017 the FFmpeg developers
>>>
>>> Please test current FFmpeg git head.
>>>
>>> Carl Eugen
>>> _______________________________________________
>>> ffmpeg-user mailing list
>>> ffmpeg-user at ffmpeg.org
>>> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>>>
>>> To unsubscribe, visit link above, or email
>>> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
>>
>>


More information about the ffmpeg-user mailing list