Software surface locking

Hello everyone !

Can we make the following assumption in SDL ?

“In a single threaded application, a software surface
(that is not the off-screen surface) never needs locking.”–

Xavier Le Pasteur

Can we make the following assumption in SDL ?

“In a single threaded application, a software surface
(that is not the off-screen surface) never needs locking.”

no, RLE surfaces also need locking. Use the macro MUSTLOCK() to find
out you need to lock or not

(it doesn’t have anything to do with threading by the way - SDL is not
thread-safe in that regard)