diff --git a/code/qcommon/cm_draw.cpp b/code/qcommon/cm_draw.cpp index f291207..11facb4 100644 --- a/code/qcommon/cm_draw.cpp +++ b/code/qcommon/cm_draw.cpp @@ -548,7 +548,7 @@ void CDraw32::DrawLineAANC(long x0, long y0, long x1, long y1, CPixel32 color) // Y-major line; calculate 16-bit fixed-point fractional part of a // pixel that X advances each time Y advances 1 pixel, truncating the // result so that we won't overrun the endpoint along the X axis - unsigned short ErrorAdj = unsigned short + unsigned short ErrorAdj = (unsigned short) (((unsigned long) DeltaX << 16) / (unsigned long) DeltaY); // Draw all pixels other than the first and last @@ -580,7 +580,7 @@ void CDraw32::DrawLineAANC(long x0, long y0, long x1, long y1, CPixel32 color) // It's an X-major line; calculate 16-bit fixed-point fractional part of a // pixel that Y advances each time X advances 1 pixel, truncating the // result to avoid overrunning the endpoint along the X axis - unsigned short ErrorAdj = unsigned short + unsigned short ErrorAdj = (unsigned short) (((unsigned long) DeltaY << 16) / (unsigned long) DeltaX); // Draw all pixels other than the first and last while (--DeltaX) diff --git a/code/renderer/tr_image.cpp b/code/renderer/tr_image.cpp index f6c2368..ff6254c 100644 --- a/code/renderer/tr_image.cpp +++ b/code/renderer/tr_image.cpp @@ -748,7 +748,7 @@ static void Upload32( unsigned *data, qboolean isLightmap, qboolean allowTC, int *pformat, - USHORT *pUploadWidth, USHORT *pUploadHeight ) + unsigned short *pUploadWidth, unsigned short *pUploadHeight ) { if (format == GL_RGBA) { diff --git a/code/renderer/tr_local.h b/code/renderer/tr_local.h index b31c37e..381672f 100644 --- a/code/renderer/tr_local.h +++ b/code/renderer/tr_local.h @@ -119,7 +119,7 @@ typedef struct image_s { char imgName[MAX_QPATH]; // game path, including extension int frameUsed; // for texture usage in frame statistics #endif - USHORT width, height; // source image + unsigned short width, height; // source image // int imgfileSize; GLuint texnum; // gl texture binding