Changeset - r14061:72fed11a54de
[Not reviewed]
master
0 1 0
smatz - 14 years ago 2009-12-23 17:59:34
smatz@openttd.org
(svn r18614) -Fix [FS#3412](r18602): too many signs were drawn, causing slowdowns
1 file changed with 4 insertions and 4 deletions:
0 comments (0 inline, 0 general)
src/viewport.cpp
Show inline comments
 
@@ -1085,10 +1085,10 @@ void ViewportAddString(const DrawPixelIn
 
	int sign_height     = ScaleByZoom(VPSM_TOP + FONT_HEIGHT_NORMAL + VPSM_BOTTOM, dpi->zoom);
 
	int sign_half_width = ScaleByZoom((small ? sign->width_small : sign->width_normal) / 2, dpi->zoom);
 

	
 
	if (bottom < sign->top &&
 
			top    > sign->top + sign_height &&
 
			right  < sign->center - sign_half_width &&
 
			left   > sign->center + sign_half_width) {
 
	if (bottom < sign->top ||
 
			top   > sign->top + sign_height ||
 
			right < sign->center - sign_half_width ||
 
			left  > sign->center + sign_half_width) {
 
		return;
 
	}
 

	
0 comments (0 inline, 0 general)