summaryrefslogtreecommitdiff
path: root/src/opengl.c
diff options
context:
space:
mode:
authorSteven Fuller <relnev@icculus.org>2003-05-22 01:55:16 +0000
committerPatryk Obara <dreamer.tan@gmail.com>2019-08-20 02:22:37 +0200
commit638b22362e1d8dbda5313af6377cb6d0bd70795f (patch)
tree6707528c5e521e9a47093c6734b8b08cddf28c68 /src/opengl.c
parentedfaaf9b962c98c475a1f5896c7c95081ca67ad1 (diff)
changed incorrect (int)char casts to (unsigned char)char casts.
Diffstat (limited to 'src/opengl.c')
-rw-r--r--src/opengl.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/opengl.c b/src/opengl.c
index 8eea18c..c5dbc5d 100644
--- a/src/opengl.c
+++ b/src/opengl.c
@@ -1643,7 +1643,7 @@ if (stringPtr == NULL) return;
colour
);
}
- x += AAFontWidths[(int)c];
+ x += AAFontWidths[(unsigned char)c];
}
}
@@ -1691,7 +1691,7 @@ if (stringPtr == NULL) return;
colour
);
}
- x += AAFontWidths[(int)c];
+ x += AAFontWidths[(unsigned char)c];
}
}
@@ -1705,7 +1705,7 @@ if (stringPtr == NULL) return;
while(*ptr)
{
- length+=AAFontWidths[(int)*ptr++];
+ length+=AAFontWidths[(unsigned char)*ptr++];
}
length = MUL_FIXED(HUDScaleFactor,length);
@@ -1747,7 +1747,7 @@ if (stringPtr == NULL) return;
colour
);
}
- x += MUL_FIXED(HUDScaleFactor,AAFontWidths[(int)c]);
+ x += MUL_FIXED(HUDScaleFactor,AAFontWidths[(unsigned char)c]);
}
}
@@ -1763,7 +1763,7 @@ void RenderStringCentred(char *stringPtr, int centreX, int y, int colour)
while(*ptr)
{
- length+=AAFontWidths[(int)*ptr++];
+ length+=AAFontWidths[(unsigned char)*ptr++];
}
D3D_RenderHUDString(stringPtr,centreX-length/2,y,colour);
}
@@ -1808,7 +1808,7 @@ void RenderStringVertically(char *stringPtr, int centreX, int bottomY, int colou
colour
);
}
- y -= AAFontWidths[(int)c];
+ y -= AAFontWidths[(unsigned char)c];
}
}