冯要文 wrote: > Hi, All > > I'm developing applications based on directfb with HW acceleration.
Which hardware and DirectFB version? > I'm using a single buffer. I assume that you do this because you're not rendering directly into the displayed memory portion anyhow and require a Flip() even with a single buffer (exclusive layer). What's your way of setting up the output surface (primary)? > My application look like this: > > ... > CreateSurface > Drawing/Blitting > Flip > WaitIdle Why not first WaitIdle() and then Flip()? Maybe in your case the Flip() is performed asynchronously, a bit later? I guess that's why you wait afterwards, but it's most likely a coincidence that the WaitIdle() is about the right time to wait... I assume, but are you running this in a loop? Otherwise it would be even more strange, like some commands not being flushed... Are you missing the last pieces that were drawn, or do you see the the first piece overwriting the rendered frame already? > My questions are: > 1. Is WaitIdle the synchronization primitive for directfb? > I use WaitIdle to make sure the HW has been finished the drawing/blitting. > Otherwise the pictures on the screen are incomplete - lost a corner, etc. Yes, WaitIdle() is the global synchronization method for the one accelerator. > 2. Are the synchronizations automatically done by Flip if I use > double/triple buffer? Yes, but they are also done with single buffering. Have a look at dfb_layer_region_flip_update() in src/core/layer_region.c. -- Best regards, Denis Oliver Kropp .------------------------------------------. | DirectFB - Hardware accelerated graphics | | http://www.directfb.org/ | "------------------------------------------" _______________________________________________ directfb-dev mailing list directfb-dev@directfb.org http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev