Fixed over 500 compile warnings. Mostly:
* Unused variables. * Missing newlines at ends of #included files. * signed int loop variables where the termination condition is an unsigned 'get number of' function. * 'NULL' used inappropriately for an integer or character constant (NULL is a pointer) * abstract base classes with no virtual destructor. * Floating point constants used to initialise integer variables.
This commit is contained in:
@@ -75,7 +75,7 @@ void BMF_BitmapFont::DrawString(const char* str)
|
||||
glGetIntegerv(GL_UNPACK_ALIGNMENT, &alignment);
|
||||
glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
|
||||
|
||||
while (c = (unsigned char) *str++) {
|
||||
while ((c = (unsigned char) *str++)) {
|
||||
BMF_CharData & cd = m_fontData->chars[c];
|
||||
|
||||
if (cd.data_offset==-1) {
|
||||
@@ -98,7 +98,7 @@ int BMF_BitmapFont::GetStringWidth(char* str)
|
||||
unsigned char c;
|
||||
int length = 0;
|
||||
|
||||
while (c = (unsigned char) *str++) {
|
||||
while ((c = (unsigned char) *str++)) {
|
||||
length += m_fontData->chars[c].advance;
|
||||
}
|
||||
|
||||
@@ -182,7 +182,7 @@ void BMF_BitmapFont::DrawStringTexture(char *str, float x, float y, float z)
|
||||
int baseLine = -(m_fontData->ymin);
|
||||
|
||||
glBegin(GL_QUADS);
|
||||
while (c = (unsigned char) *str++) {
|
||||
while ((c = (unsigned char) *str++)) {
|
||||
BMF_CharData & cd = m_fontData->chars[c];
|
||||
|
||||
if (cd.data_offset != -1) {
|
||||
|
||||
Reference in New Issue
Block a user