You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The only thing the code currently does to prevent blitted glyphs from going outside of the surfaces pixels is this line of code:
/* Adding bound checking to avoid all kinds of memory corruption errors
that may occur. */
dst_check = (Uint8*)textbuf->pixels + textbuf->pitch * textbuf->h;
However that will only prevent memory overruns, it does not actually clip properly, so glyphs at the right edge might overdraw and end up showing up on the left.
ef0b2f8 fixes one occurance of this, but the glyph blitting code is copy&pasted in numerous places. So this needs further work and should be refactored to fix this properly. Some test cases wouldn't hurt either.
The text was updated successfully, but these errors were encountered:
The only thing the code currently does to prevent blitted glyphs from going outside of the surfaces pixels is this line of code:
However that will only prevent memory overruns, it does not actually clip properly, so glyphs at the right edge might overdraw and end up showing up on the left.
ef0b2f8 fixes one occurance of this, but the glyph blitting code is copy&pasted in numerous places. So this needs further work and should be refactored to fix this properly. Some test cases wouldn't hurt either.
The text was updated successfully, but these errors were encountered: