- //
- // find bounds of all the verts on the base frame
- //
- ClearBounds (mins, maxs);
-
- for (i=0 ; i<numtri ; i++)
- for (j=0 ; j<3 ; j++)
- AddPointToBounds (ptri[i].verts[j], mins, maxs);
-
- for (i=0 ; i<3 ; i++)
- {
- mins[i] = floor(mins[i]);
- maxs[i] = ceil(maxs[i]);
- }
-
- width = maxs[0] - mins[0];
- height = maxs[2] - mins[2];
-
- if (!g_data.fixedwidth)
- { // old style
- scale = 8;
- if (width*scale >= 150)
- scale = 150.0 / width;
- if (height*scale >= 190)
- scale = 190.0 / height;
-
- s_scale = t_scale = scale;
-
- iwidth = ceil(width*s_scale);
- iheight = ceil(height*t_scale);
-
- iwidth += 4;
- iheight += 4;
- }
- else
- { // new style
- iwidth = g_data.fixedwidth / 2;
- iheight = g_data.fixedheight;
-
- s_scale = (float)(iwidth-4) / width;
- t_scale = (float)(iheight-4) / height;
- }
-
- // make the width a multiple of 4; some hardware requires this, and it ensures
- // dword alignment for each scan
- swidth = iwidth*2;
- g_data.skinwidth = (swidth + 3) & ~3;
- g_data.skinheight = iheight;
-*/
-
- for (i=0; i<numtri ; i++, ptri++, bTri++)
+ //
+ // find bounds of all the verts on the base frame
+ //
+ ClearBounds (mins, maxs);
+
+ for (i=0 ; i<numtri ; i++)
+ for (j=0 ; j<3 ; j++)
+ AddPointToBounds (ptri[i].verts[j], mins, maxs);
+
+ for (i=0 ; i<3 ; i++)
+ {
+ mins[i] = floor(mins[i]);
+ maxs[i] = ceil(maxs[i]);
+ }
+
+ width = maxs[0] - mins[0];
+ height = maxs[2] - mins[2];
+
+ if (!g_data.fixedwidth)
+ { // old style
+ scale = 8;
+ if (width*scale >= 150)
+ scale = 150.0 / width;
+ if (height*scale >= 190)
+ scale = 190.0 / height;
+
+ s_scale = t_scale = scale;
+
+ iwidth = ceil(width*s_scale);
+ iheight = ceil(height*t_scale);
+
+ iwidth += 4;
+ iheight += 4;
+ }
+ else
+ { // new style
+ iwidth = g_data.fixedwidth / 2;
+ iheight = g_data.fixedheight;
+
+ s_scale = (float)(iwidth-4) / width;
+ t_scale = (float)(iheight-4) / height;
+ }
+
+ // make the width a multiple of 4; some hardware requires this, and it ensures
+ // dword alignment for each scan
+ swidth = iwidth*2;
+ g_data.skinwidth = (swidth + 3) & ~3;
+ g_data.skinheight = iheight;
+ */
+
+ for ( i = 0; i < numtri ; i++, ptri++, bTri++ )