Discussion:
[directfb-users] avoid using surface's lock()/unlock()?
Ha Nguyen
2013-10-28 13:05:08 UTC
Permalink
Hi,

In projects I'm working with, sometimes we check out the surfaces to access
their data directly either to READ or to WRITE and in our blitter, we don't
flush the surfaces if they had been checked out for READ only.

In my opinion, if possible I would avoid using lock/unlock() and let
DirectFB core decide whether to flush the surfaces or not. This would
simplify our code and also avoid problems with synchronizations in
multi-threaded applications?

Could someone please comment on this for me?

Thanks!
/ha

Loading...