2010-07-12 20:31:20     video encoding reccomendations

Document created by Aaronwu Employee on Aug 22, 2013
Version 1Show Document
  • View in full screen mode

2010-07-12 20:31:20     video encoding reccomendations

Peter Naulls (UNITED STATES)

Message: 91178   

 

I've been looking at the options for video encoding on uClinux.  For experimentation purposes, I've been something like this:

 

ffmpeg -f video4linux -r 15 -s 640x480 -i /dev/video0 -an -qscale 3 -f avi udp:192.168.0.2:1234

 

This gives me about 9 fps.  In practice, we won't be streaming, but rather writing to flash.

 

I experimented with SVN trunk ffmpeg (I have patches for that if anyone is interested) and then libx264 encoding and the ultrafast presets.   This takes a number of seconds to start and then gives about 3fps encoding to a file (not sure if you could stream this).

 

H264 is preferrable for various reasons, but there's no reason we can't transcode later on a server.  libx264 has no Blackfin-specific optimizations in it, which I presume is why it's so slow.

 

I'd like to get at least 16fps.  The quality doesn't have to be really high - think youtube.  Does anyone have any recommendations here on what the best formats would be in terms of blackfin vs ffmpeg.  A rate of 200-400Kbps is a nice target too in terms of end file size.

 

Regards

QuoteReplyEditDelete

 

 

2010-07-13 01:55:17     Re: video encoding reccomendations

Sonic Zhang (CHINA)

Message: 91181   

 

For the ffmpeg performance on blackfin Linux, please refer to:

 

  docs.blackfin.uclinux.org/doku.php?id=uclinux-dist:ffmpeg#performance_as_april_1st

QuoteReplyEditDelete

 

 

2010-07-13 15:42:24     Re: video encoding reccomendations

Howard Gordon (UNITED STATES)

Message: 91210   

 

Probably the only way to hit your target framerate is to encode to JPEG and transcode to h264 later.  In any case, your target bitrates are pretty far off for 640x480, though they are reasonable for 320x240.  For the higher resolution, you need to allocate 3x to 4x as many bits.

Attachments

    Outcomes