vlc-cvs video output jerky

Gildas Bazin gbazin at netcourrier.com
Wed Jan 9 19:54:32 CET 2002


On Wednesday 09 January 2002 18:27, Samuel Hocevar wrote:
> On Wed, Jan 09, 2002, Steven M. Schultz wrote:
> > 	Ok, recompiling with MAX_DIRECTBUFFERS set to 1 and running "vlc -v":
> > 
> > 	While I do see infrequent "late picture" messages the playback with
> > 	MAX_DIRECTBUFFERS = 1 is smooth (as it is with the 0.2.92 release
> > 	version).
> 
>    Fine. The "late picture" messages mean it dropped a few pictures here
> and there, but nothing noticeable.
> 
> 
>    While setting MAX_DIRECTBUFFERS to 1 improved the quality, you lost
> lots of performances, so it'd be interesting to see what is wrong with
> more direct buffers allocated, and I thought our Shm code could have
> been an issue.
> 

I think I also noticed the same performance problem (0.2.92 better than main 
branch) on my old computer. I know for sure things were really bad before the 
XSync() (or XFlush()) call was added at the end of vout_Display(). But I 
think even now I can see a performance difference (I will need to 
double-check).

My guess was also on the Shm code because we never check for the Xserver 
completion event before overwriting a direct buffer. And I guess this could 
create this kind of stutter in the video.
When you want to display a picture with XvPutImage(), the picture is not 
displayed straight away because the Xserver needs to copy the Shm buffer into 
video memory. You then have to wait until the server sends you the display 
completion event before modifying again the buffer.

I wanted to play with this but haven't had time yet.

--
Gildas




More information about the vlc mailing list