[AD] possible improvement for trans blending routines (and others) |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
Hi!
I just noticed that allegro blending routines doesn't check for special
cases that could speed up things a lot
For example, in the trans blender, it doesnt check if the alpha is 0 and
therefore do not putpixel (or simply return the pixel got) or if the alpha
is 255 skip the pixel read and simply use the write pixel
Since in trans images almost all the pixels are usually of alpha 255 | 0,
this could improve slow allegro routines quite a bit
Probably this special cases could be used in another blending methods too
Thanks