Prevents GetScaledExtent from truncating values to 0; fixes partially
'small-objects-disappearing-bug' (#34), from chmmravatar git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@882 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -273,6 +273,10 @@ TFB_DrawCanvas_GetScaledExtent (TFB_Canvas src_canvas, int scale, PEXTENT size)
|
||||
SDL_Surface *src = (SDL_Surface *)src_canvas;
|
||||
size->width = (int) (src->w * scale / (float)GSCALE_IDENTITY);
|
||||
size->height = (int) (src->h * scale / (float)GSCALE_IDENTITY);
|
||||
if (!size->width)
|
||||
size->width = 1;
|
||||
if (!size->height)
|
||||
size->height = 1;
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
Reference in New Issue
Block a user