Dmitry Timoshkov dmitry@baikal.ru writes:
Alexandre Julliard julliard@winehq.org wrote:
I expect it would also cause less code duplication to directly create a 1-bpp bitmap.
What kind of code duplication do you have in mind?
The duplicate setting of biBitCount and the StretchDIBits call. If you generate a 1-bpp mask you can get rid of all that and simply fall through to the normal code path.
With the setting of biBitCount and the StretchDIBits call it's still going to be considerably less code than the 1-bpp mask generarion from the 32-bpp RGBA bitmap.
I don't see why, it should be about the same amount of code as an 8-bpp mask, with just a couple of extra shifts and masks.