Do you think I should check for the OVERLAY flag into CreateSurface or into createoffscreen ?
I would put this before the 'else assume ...' case and would return the error here (so as the day we will support them, it would be just another case in the if / else if / else if / else code).
Something like that :
else if (ZBUFFER) { (...) } else if (OVERLAY) { return ERROR; } else { FIXME(....) }