[x264-devel] Question about x264 real time encoding
Bo SONG
benben841212 at gmail.com
Tue Apr 6 16:27:36 CEST 2010
Hi, I'm new to here. Hope that I'm not posting in the wrong place.
I use x264 to encode my camera video in real time. The original video is in
720P/30 format and captured by my AJA card. I en-capsuled x264 into a
Directshow filter.
I wrote some lines to measure the average return time of
x264_encoder_encode, which should be throughput I think; and also some
lines measuring the average corresponding latency of specific frame
(currenttime - pts returned by x264_encoder_encoder ).
Here is my result:
1. Commandline:
--bframes 0 --force-cfr --rc-lookahead 0
--sync-lookahead 0 -B 2500
Result:
X264Enc: 15.16 ms/frame, throughtput 30.0481 frames/sec, latency
367.031 ms/frame
2. Commandline:
--tune zerolatency -B 2500
Result:
X264Enc: 59.99 ms/frame, throughtput 16.2417 frames/sec, latency 0
ms/frame
So it seems that high throughput leads to long latency, while low latency
cannot get such throughput. It is really frustrating. Anyone has some clue
to fix this?
Thanks!
P.S. There is only one source thread producing 720P/30 video, and x264
should
process it as fast as possible. In the result, the 1st number is the avg
x264_encoder_encode return time. 2nd one is the number of times
x264_encoder_encode called per second, third one is the frame
corresponding latency.
--
Bo SONG
More information about the x264-devel
mailing list