X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=tools%2Fquake3%2Fq3data%2Fvideo.c;h=ae67138e55d15eb8f173013fe6bea77f62e2f8d8;hb=e2900e168ea677efd1cdfac7fc91fb1fc071a269;hp=b7be982cf0d6599ae0855e9569374489c4c1efe3;hpb=e4287c28bb2dafedc81c66e63951d947cfbeb225;p=xonotic%2Fnetradiant.git diff --git a/tools/quake3/q3data/video.c b/tools/quake3/q3data/video.c index b7be982c..ae67138e 100644 --- a/tools/quake3/q3data/video.c +++ b/tools/quake3/q3data/video.c @@ -106,7 +106,7 @@ void FindNextChunk( char *name ){ // Sys_Error ("FindNextChunk: %i length is past the 1 meg sanity limit", iff_chunk_len); data_p -= 8; last_chunk = data_p + 8 + ( ( iff_chunk_len + 1 ) & ~1 ); - if ( !strncmp( data_p, name, 4 ) ) { + if ( !strncmp((const char *) data_p, name, 4 ) ) { return; } } @@ -128,7 +128,7 @@ void DumpChunks( void ){ memcpy( str, data_p, 4 ); data_p += 4; iff_chunk_len = GetLittleLong(); - printf( "0x%x : %s (%d)\n", (int)( data_p - 4 ), str, iff_chunk_len ); + printf( "%p : %s (%d)\n", (void *) ( data_p - 4 ), str, iff_chunk_len ); data_p += ( iff_chunk_len + 1 ) & ~1; } while ( data_p < iff_end ); } @@ -155,7 +155,7 @@ wavinfo_t GetWavinfo( char *name, byte *wav, int wavlength ){ // find "RIFF" chunk FindChunk( "RIFF" ); - if ( !( data_p && !strncmp( data_p + 8, "WAVE", 4 ) ) ) { + if ( !( data_p && !strncmp((const char *) (data_p + 8), "WAVE", 4 ) ) ) { printf( "Missing RIFF/WAVE chunks\n" ); return info; } @@ -191,7 +191,7 @@ wavinfo_t GetWavinfo( char *name, byte *wav, int wavlength ){ // if the next chunk is a LIST chunk, look for a cue length marker FindNextChunk( "LIST" ); if ( data_p ) { - if ( !strncmp( data_p + 28, "mark", 4 ) ) { // this is not a proper parse, but it works with cooledit... + if ( !strncmp((const char *) (data_p + 28), "mark", 4 ) ) { // this is not a proper parse, but it works with cooledit... data_p += 24; i = GetLittleLong(); // samples in loop info.samples = info.loopstart + i; @@ -596,11 +596,11 @@ static float BTCCompressBlock( float inBlock[4][4][3], unsigned long out[2] ){ int i; int btcQuantizedBlock[4][4]; // values should be [0..3] unsigned long encodedEndPoints, encodedBitmap; - unsigned int endPoints[2][2]; // endPoints[0] = color start, endPoints[1] = color end + unsigned long endPoints[2][2]; // endPoints[0] = color start, endPoints[1] = color end int blockY, blockX; float error = 0; float bestError = 10000000000; - unsigned int bestEndPoints[2][2]; + unsigned long bestEndPoints[2][2]; #if 0 // @@ -1107,7 +1107,7 @@ void Cmd_Video( void ){ printf( "\n" ); - printf( "Total size: %i\n", ftell( output ) ); + printf( "Total size: %ld\n", ftell( output ) ); printf( "Average error: %f\n", sumError / ( frame - startframe ) ); printf( "Max error: %f\n", maxError );