diff -ur povray-3.50c/src/bbox.cpp povray-3.50c-amd64/src/bbox.cpp --- povray-3.50c/src/bbox.cpp 2003-01-06 20:08:26.000000000 -0500 +++ povray-3.50c-amd64/src/bbox.cpp 2003-11-19 01:10:02.648820136 -0500 @@ -1869,7 +1869,7 @@ { /* Prim array overrun, increase array by 50%. */ - maxfinitecount = 1.5 * maxfinitecount; + maxfinitecount = (long) (1.5 * maxfinitecount); /* For debugging only. */ diff -ur povray-3.50c/src/bsphere.cpp povray-3.50c-amd64/src/bsphere.cpp --- povray-3.50c/src/bsphere.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/bsphere.cpp 2003-11-19 01:10:41.131969808 -0500 @@ -513,7 +513,7 @@ { /* Prim array overrun, increase array by 50%. */ - maxelements = 1.5 * maxelements; + maxelements = (int) (1.5 * maxelements); /* For debugging only. */ diff -ur povray-3.50c/src/chi2.cpp povray-3.50c-amd64/src/chi2.cpp --- povray-3.50c/src/chi2.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/chi2.cpp 2003-11-19 01:11:08.342833128 -0500 @@ -344,7 +344,7 @@ goto loverf; } - i = p; + i = (int)p; if ((i & 1) == 0) { diff -ur povray-3.50c/src/express.cpp povray-3.50c-amd64/src/express.cpp --- povray-3.50c/src/express.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/express.cpp 2003-11-19 01:11:37.258437288 -0500 @@ -1020,7 +1020,7 @@ GET(ARRAY_ID_TOKEN) Parse_Comma(); a = (POV_ARRAY *)(*(Token.DataPtr)); - i = (int)Parse_Float()-1.0; + i = (int)(Parse_Float()-1.0); if ((i < 0) || (i > a->Dims)) Val = 0.0; else diff -ur povray-3.50c/src/fncode.cpp povray-3.50c-amd64/src/fncode.cpp --- povray-3.50c/src/fncode.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/fncode.cpp 2003-11-19 01:12:13.384945224 -0500 @@ -1869,11 +1869,11 @@ } if(had_x == false) - compile_instruction(OPCODE_LOADI, 0, 2, 0.0); + compile_instruction(OPCODE_LOADI, 0, 2, 0); if(had_y == false) - compile_instruction(OPCODE_LOADI, 0, 3, 0.0); + compile_instruction(OPCODE_LOADI, 0, 3, 0); if(had_z == false) - compile_instruction(OPCODE_LOADI, 0, 4, 0.0); + compile_instruction(OPCODE_LOADI, 0, 4, 0); } diff -ur povray-3.50c/src/fnintern.cpp povray-3.50c-amd64/src/fnintern.cpp --- povray-3.50c/src/fnintern.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/fnintern.cpp 2003-11-19 10:46:33.619193328 -0500 @@ -638,13 +638,13 @@ V1[Y]=PARAM_Y; V1[Z]=PARAM_Z; TPATTERN TPat; - int Tmp = PARAM(5); + int Tmp = (int)PARAM(5); TPat.Flags = (Tmp & 3) << 4; if (f->private_data == NULL) { - ea =(DBL *)POV_MALLOC((PARAM(2) + 1)*sizeof(DBL), "exponent array"); + ea =(DBL *)POV_MALLOC((long)(PARAM(2) + 1)*sizeof(DBL), "exponent array"); freq = 1.0; for (i=0; i<=PARAM(2);i++) { @@ -953,7 +953,7 @@ VECTOR temp; int Octaves; TPATTERN TPat; - int Tmp = PARAM(5); + int Tmp = (int)PARAM(5); TPat.Flags = (Tmp & 3) << 4; @@ -997,7 +997,7 @@ int i; VECTOR V1; TPATTERN TPat; - int Tmp = PARAM(5); + int Tmp = (int)PARAM(5); TPat.Flags = (Tmp & 3) << 4; @@ -1006,7 +1006,7 @@ V1[Z]=PARAM_Z; if (f->private_data == NULL) { - ea = (DBL*)POV_MALLOC((PARAM(2) + 1)*sizeof(DBL), "exponent array"); + ea = (DBL*)POV_MALLOC((long)(PARAM(2) + 1)*sizeof(DBL), "exponent array"); freq = 1.0; for (i=0; i<=PARAM(2);i++) { @@ -1221,7 +1221,7 @@ { VECTOR Vec = { PARAM_X, PARAM_Y, PARAM_Z }; TPATTERN TPat; - int Tmp = PARAM(0); + int Tmp = (int)PARAM(0); TPat.Flags = (Tmp & 3) << 4; diff -ur povray-3.50c/src/frame.h povray-3.50c-amd64/src/frame.h --- povray-3.50c/src/frame.h 2003-01-06 20:08:30.000000000 -0500 +++ povray-3.50c-amd64/src/frame.h 2003-11-19 11:38:51.368182976 -0500 @@ -49,7 +49,9 @@ typedef unsigned char u_int8 ; typedef unsigned char byte ; -typedef signed long int32 ; +// removed because of conflict with tiff.h +// typedef signed long int32 ; +typedef signed int int32 ; typedef signed short int16 ; typedef signed char int8 ; diff -ur povray-3.50c/src/hfield.cpp povray-3.50c-amd64/src/hfield.cpp --- povray-3.50c/src/hfield.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/hfield.cpp 2003-11-19 10:48:10.641443704 -0500 @@ -1706,8 +1706,8 @@ x0 = px - floor(px); z0 = pz - floor(pz); - signx = sign(dx); - signz = sign(dz); + signx = (int)sign(dx); + signz = (int)sign(dz); /* Get initial error. */ @@ -1837,8 +1837,8 @@ x0 = px - floor(px); z0 = pz - floor(pz); - signx = sign(dx); - signz = sign(dz); + signx = (int)sign(dx); + signz = (int)sign(dz); /* Get initial error. */ @@ -2064,8 +2064,8 @@ dx_zero = (fabs(dx) < EPSILON); dz_zero = (fabs(dz) < EPSILON); - signx = sign(dx); - signz = sign(dz); + signx = (int)sign(dx); + signz = (int)sign(dz); /* Walk on the block grid. */ diff -ur povray-3.50c/src/image.cpp povray-3.50c-amd64/src/image.cpp --- povray-3.50c/src/image.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/image.cpp 2003-11-19 10:48:42.546593384 -0500 @@ -537,7 +537,7 @@ temp2 = Image->data.gray16_lines[y][x]; else { - temp2 = GREY_SCALE3( + temp2 = (int)GREY_SCALE3( Image->data.rgb16_lines[y].red[x], Image->data.rgb16_lines[y].green[x], Image->data.rgb16_lines[y].blue[x] diff -ur povray-3.50c/src/lightgrp.cpp povray-3.50c-amd64/src/lightgrp.cpp --- povray-3.50c/src/lightgrp.cpp 2003-01-06 20:08:27.000000000 -0500 +++ povray-3.50c-amd64/src/lightgrp.cpp 2003-11-19 10:49:18.417140232 -0500 @@ -267,4 +267,5 @@ } return false; } -} \ No newline at end of file +} + diff -ur povray-3.50c/src/parse.cpp povray-3.50c-amd64/src/parse.cpp --- povray-3.50c/src/parse.cpp 2003-01-06 20:08:28.000000000 -0500 +++ povray-3.50c-amd64/src/parse.cpp 2003-11-19 10:59:50.048117728 -0500 @@ -1669,7 +1669,7 @@ END_CASE CASE (BLUR_SAMPLES_TOKEN) - New->Blur_Samples = Parse_Float(); + New->Blur_Samples = (int)Parse_Float(); if (New->Blur_Samples <= 0) Error("Illegal number of focal blur samples."); END_CASE @@ -1797,7 +1797,7 @@ END_CASE CASE (BLUR_SAMPLES_TOKEN) - New->Blur_Samples = Parse_Float(); + New->Blur_Samples = (int)Parse_Float(); if (New->Blur_Samples <= 0) Error("Illegal number of focal blur samples."); END_CASE @@ -3829,7 +3829,7 @@ Parse_Begin(); /* number faces is mandatory, so we ask how many there are */ - number_of_triangles = Parse_Float(); Parse_Comma(); + number_of_triangles = (int)Parse_Float(); Parse_Comma(); if (number_of_triangles == 0) { @@ -3870,7 +3870,7 @@ /* look for a texture index */ EXPECT CASE_FLOAT - Triangles[i].Texture = Parse_Float(); Parse_Comma(); + Triangles[i].Texture = (int)Parse_Float(); Parse_Comma(); if (Triangles[i].Texture >= number_of_textures || Triangles[i].Texture < 0) Error("Texture index out of range in mesh2."); @@ -3887,7 +3887,7 @@ /* look for a texture index */ EXPECT CASE_FLOAT - Triangles[i].Texture2 = Parse_Float(); Parse_Comma(); + Triangles[i].Texture2 = (int)Parse_Float(); Parse_Comma(); if (Triangles[i].Texture2 >= number_of_textures || Triangles[i].Texture2 < 0) Error("Texture index out of range in mesh2."); @@ -3903,7 +3903,7 @@ /* look for a texture index */ EXPECT CASE_FLOAT - Triangles[i].Texture3 = Parse_Float(); Parse_Comma(); + Triangles[i].Texture3 = (int)Parse_Float(); Parse_Comma(); if (Triangles[i].Texture3 >= number_of_textures || Triangles[i].Texture3 < 0) Error("Texture index out of range in mesh2."); @@ -3987,7 +3987,7 @@ if (Parse_Float() != number_of_triangles) Error("Number of normal indices must equal number of faces."); */ - number_of_normal_indices = Parse_Float(); + number_of_normal_indices = (int)Parse_Float(); if (number_of_normal_indices > number_of_triangles) Error("Number of normal indices cannot be more than the number of faces."); @@ -4401,7 +4401,7 @@ END_CASE CASE(PRECOMPUTE_TOKEN) - PrecompDepth= Parse_Float(); + PrecompDepth= (int)Parse_Float(); Parse_Comma(); EXPECT @@ -6319,7 +6319,7 @@ CASE (EXPAND_THRESHOLDS_TOKEN) photonOptions.expandTolerance = Parse_Float(); Parse_Comma(); - photonOptions.minExpandCount = Parse_Float(); + photonOptions.minExpandCount = (int)Parse_Float(); if (photonOptions.expandTolerance<0.0) { Warning(100,"The first parameter of expand_thresholds must be greater than or equal to 0.\nSetting it to 0 now."); @@ -6355,7 +6355,7 @@ END_CASE CASE (MAX_TRACE_LEVEL_TOKEN) - photonOptions.Max_Trace_Level = Parse_Float(); + photonOptions.Max_Trace_Level = (int)Parse_Float(); END_CASE CASE(LOAD_FILE_TOKEN) diff -ur povray-3.50c/src/parsestr.cpp povray-3.50c-amd64/src/parsestr.cpp --- povray-3.50c/src/parsestr.cpp 2003-01-06 20:08:28.000000000 -0500 +++ povray-3.50c-amd64/src/parsestr.cpp 2003-11-19 11:04:57.434387912 -0500 @@ -1060,7 +1060,7 @@ while(true) { - if (((int) *str < 0) || (*str > 127)) + if ((int) *str > 127) err = true; else if(*str == 0) break; @@ -1098,7 +1098,7 @@ while(true) { - if (((int) *str < 0) || (*str > 127)) + if ((int) *str > 127) err = true; else if(*str == 0) break; diff -ur povray-3.50c/src/parstxtr.cpp povray-3.50c-amd64/src/parstxtr.cpp --- povray-3.50c/src/parstxtr.cpp 2003-01-06 20:08:28.000000000 -0500 +++ povray-3.50c-amd64/src/parstxtr.cpp 2003-11-19 11:25:55.745095608 -0500 @@ -132,8 +132,8 @@ unsigned short *gray16_line; VECTOR Point; - Image->iwidth = Image->width; - Image->iheight = Image->height; + Image->iwidth = (int)Image->width; + Image->iheight = (int)Image->height; Image->width--; Image->height--; Image->Colour_Map_Size = 0; @@ -159,7 +159,7 @@ POVFPU_SetLocal(Y, Point[Y]); POVFPU_SetLocal(Z, Point[Z]); - gray16_line[j] = 65535.0 * POVFPU_Run(*fn); + gray16_line[j] = (unsigned short)(65535.0 * POVFPU_Run(*fn)); } } } @@ -189,10 +189,10 @@ (void)POVFPU_Run(*fn); - rgb16_line->red[j] = 65535.0 * POVFPU_GetLocal(pRED); - rgb16_line->green[j] = 65535.0 * POVFPU_GetLocal(pGREEN); - rgb16_line->blue[j] = 65535.0 * POVFPU_GetLocal(pBLUE); - rgb16_line->transm[j] = 65535.0 * POVFPU_GetLocal(pTRANSM); + rgb16_line->red[j] = (unsigned short)(65535.0 * POVFPU_GetLocal(pRED)); + rgb16_line->green[j] = (unsigned short)(65535.0 * POVFPU_GetLocal(pGREEN)); + rgb16_line->blue[j] = (unsigned short)(65535.0 * POVFPU_GetLocal(pBLUE)); + rgb16_line->transm[j] = (unsigned short)(65535.0 * POVFPU_GetLocal(pTRANSM)); } } } diff -ur povray-3.50c/src/povray.cpp povray-3.50c-amd64/src/povray.cpp --- povray-3.50c/src/povray.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/povray.cpp 2003-11-19 11:28:18.792349120 -0500 @@ -1444,7 +1444,7 @@ if (opts.FrameSeq.SubsetStartPercent != DBL_VALUE_UNSET) { - FrameIncr = FrameDiff * opts.FrameSeq.SubsetStartPercent + 0.5; /* w/rounding */ + FrameIncr = (int)(FrameDiff * opts.FrameSeq.SubsetStartPercent + 0.5); /* w/rounding */ opts.FrameSeq.SubsetStartFrame = opts.FrameSeq.InitialFrame + FrameIncr; } @@ -1466,7 +1466,7 @@ * it via FinalFrame-FrameDiff */ - FrameIncr = FrameDiff * opts.FrameSeq.SubsetEndPercent + 0.5; /* w/rounding */ + FrameIncr = (int)(FrameDiff * opts.FrameSeq.SubsetEndPercent + 0.5); /* w/rounding */ opts.FrameSeq.SubsetEndFrame = (opts.FrameSeq.FinalFrame - FrameDiff) + FrameIncr; } diff -ur povray-3.50c/src/ppm.cpp povray-3.50c-amd64/src/ppm.cpp --- povray-3.50c/src/ppm.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/ppm.cpp 2003-11-19 11:29:02.923640144 -0500 @@ -282,9 +282,9 @@ { if (opts.Options & HF_GRAY_16) /* 16 bit grayscale output */ { - gray = ((0.30 * line_data[x][pRED]) + + gray = (unsigned int)(((0.30 * line_data[x][pRED]) + (0.59 * line_data[x][pGREEN]) + - (0.11 * line_data[x][pBLUE])) * 65535; + (0.11 * line_data[x][pBLUE])) * 65535); out_file->Write_Byte((gray >> 8) & 0xFF); if (!out_file->Write_Byte(gray & 0xFF)) diff -ur povray-3.50c/src/render.cpp povray-3.50c-amd64/src/render.cpp --- povray-3.50c/src/render.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/render.cpp 2003-11-19 11:31:57.572089544 -0500 @@ -980,8 +980,8 @@ else { /* lets use some percentages instead of the INI options!! */ - StartPixelSize = max(Frame.Screen_Height,Frame.Screen_Width)*opts.radPretraceStart; - EndPixelSize = max(Frame.Screen_Height,Frame.Screen_Width)*opts.radPretraceEnd; + StartPixelSize = (int)(max(Frame.Screen_Height,Frame.Screen_Width)*opts.radPretraceStart); + EndPixelSize = (int)(max(Frame.Screen_Height,Frame.Screen_Width)*opts.radPretraceEnd); } } diff -ur povray-3.50c/src/statspov.cpp povray-3.50c-amd64/src/statspov.cpp --- povray-3.50c/src/statspov.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/statspov.cpp 2003-11-19 11:32:31.295962736 -0500 @@ -452,7 +452,7 @@ SPLIT_TIME(time_dif, &hrs, &mins, &secs); Status_Info("%3ld:%02ld:%02ld ", hrs, mins, (long)secs); - Send_RenderTime(0, 0, time_dif); + Send_RenderTime(0, 0, (int)time_dif); Send_RenderStatus("Rendering"); } else diff -ur povray-3.50c/src/targa.cpp povray-3.50c-amd64/src/targa.cpp --- povray-3.50c/src/targa.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/targa.cpp 2003-11-19 11:33:02.219261680 -0500 @@ -368,7 +368,7 @@ if (opts.Options & HF_GRAY_16) { /* Ouput heightfield in POV red/green format */ - gray = ((0.30 * r) + (0.59 * g) + (0.11 * b)) * 65535; + gray = (unsigned int)(((0.30 * r) + (0.59 * g) + (0.11 * b)) * 65535); out_file->Write_Byte(0); out_file->Write_Byte(gray & 0xFF); diff -ur povray-3.50c/src/truetype.cpp povray-3.50c-amd64/src/truetype.cpp --- povray-3.50c/src/truetype.cpp 2003-01-06 20:08:29.000000000 -0500 +++ povray-3.50c-amd64/src/truetype.cpp 2003-11-19 11:39:50.407207680 -0500 @@ -2340,16 +2340,16 @@ #endif if (ttglyph->x[i + n] < ttglyph->header.xMin) - ttglyph->header.xMin = ttglyph->x[i + n]; + ttglyph->header.xMin = (short)ttglyph->x[i + n]; if (ttglyph->x[i + n] > ttglyph->header.xMax) - ttglyph->header.xMax = ttglyph->x[i + n]; + ttglyph->header.xMax = (short)ttglyph->x[i + n]; if (ttglyph->y[i + n] < ttglyph->header.yMin) - ttglyph->header.yMin = ttglyph->y[i + n]; + ttglyph->header.yMin = (short)ttglyph->y[i + n]; if (ttglyph->y[i + n] > ttglyph->header.yMax) - ttglyph->header.yMax = ttglyph->y[i + n]; + ttglyph->header.yMax = (short)ttglyph->y[i + n]; } /* Free up the sub glyph outline information */