[x264-devel] x264 crosses video information when numerous encoders running in multiple threads

Loren Merritt lorenm at u.washington.edu
Sat Jan 31 20:25:11 CET 2009


On Sat, 24 Jan 2009, anton kropp wrote:

> Loren, thanks for the reply.  This has been causing me a bunch of
> grief in the last week once I realized what was happening.  I'm not
> very familiar with the inner workings of x264, however, do you have
> any suggestions of where I can try to debug this issue within the
> code?  I have 2 320x240 video streams and 1 1024x768 video stream and
> its most apparent in the larger stream. Sometimes it also seems that
> x264 is dropping a keyframe, though I'm not sure if this has to do
> with the reentrant issue or not.

The obvious questions are:
Does it depend on whether each instance of x264 is multithreaded?
Does it depends on whether they're running concurrently, or if you just 
interleave calls to multiple instances of x264 in a single thread?
If you run the same encode twice, do you get the same corrupted output?

But regardless of the answers to those questions, I don't have any easy 
suggestions, only: Run each of the encodes on their own to get a working 
reference stream. Then run them together, and compare each bit of output 
to the respective reference as soon as it's generated, and break to a 
debugger if they differ. Then run the reference encode again, breaking at 
the same point, and compare all the accessible data structures.

--Loren Merritt


More information about the x264-devel mailing list