]> git.lizzy.rs Git - irrlicht.git/blobdiff - source/Irrlicht/CTRTextureLightMap2_M2.cpp
Merging r6145 through r6171 from trunk to ogl-es branch
[irrlicht.git] / source / Irrlicht / CTRTextureLightMap2_M2.cpp
index 5976cfb8b97e38d400b223411cb6d492120d6870..19d051f34ff917b01c6c56a8edde0e5c9f06b1e1 100644 (file)
@@ -121,7 +121,7 @@ REALINLINE void CTRTextureLightMap2_M2::scanline_bilinear2 ()
                return;\r
 \r
        // slopes\r
-       const f32 invDeltaX = reciprocal_zero2( line.x[1] - line.x[0] );\r
+       const f32 invDeltaX = fill_step_x( line.x[1] - line.x[0] );\r
 \r
        // search z-buffer for first not occulled pixel\r
        z = (fp24*) DepthBuffer->lock() + ( line.y * RenderTarget->getDimension().Width ) + xStart;\r
@@ -254,9 +254,9 @@ void CTRTextureLightMap2_M2::drawTriangle(const s4DVertex* burning_restrict a, c
        const f32 ba = b->Pos.y - a->Pos.y;\r
        const f32 cb = c->Pos.y - b->Pos.y;\r
        // calculate delta y of the edges\r
-       scan.invDeltaY[0] = reciprocal_zero( ca );\r
-       scan.invDeltaY[1] = reciprocal_zero( ba );\r
-       scan.invDeltaY[2] = reciprocal_zero( cb );\r
+       scan.invDeltaY[0] = fill_step_y( ca );\r
+       scan.invDeltaY[1] = fill_step_y( ba );\r
+       scan.invDeltaY[2] = fill_step_y( cb );\r
 \r
        if ( F32_LOWER_EQUAL_0 ( scan.invDeltaY[0] )  )\r
                return;\r
@@ -380,7 +380,7 @@ void CTRTextureLightMap2_M2::drawTriangle(const s4DVertex* burning_restrict a, c
 #endif\r
 \r
                // rasterize the edge scanlines\r
-               for( line.y = yStart; line.y <= yEnd; ++line.y)\r
+               for( line.y = yStart; line.y <= yEnd; line.y += SOFTWARE_DRIVER_2_STEP_Y)\r
                {\r
                        line.x[scan.left] = scan.x[0];\r
                        line.x[scan.right] = scan.x[1];\r
@@ -411,7 +411,7 @@ void CTRTextureLightMap2_M2::drawTriangle(const s4DVertex* burning_restrict a, c
 #endif\r
 \r
                        // render a scanline\r
-                       scanline_bilinear2 ();\r
+                       interlace_scanline scanline_bilinear2 ();\r
 \r
                        scan.x[0] += scan.slopeX[0];\r
                        scan.x[1] += scan.slopeX[1];\r
@@ -541,7 +541,7 @@ void CTRTextureLightMap2_M2::drawTriangle(const s4DVertex* burning_restrict a, c
 #endif\r
 \r
                // rasterize the edge scanlines\r
-               for( line.y = yStart; line.y <= yEnd; ++line.y)\r
+               for( line.y = yStart; line.y <= yEnd; line.y += SOFTWARE_DRIVER_2_STEP_Y)\r
                {\r
                        line.x[scan.left] = scan.x[0];\r
                        line.x[scan.right] = scan.x[1];\r
@@ -572,7 +572,7 @@ void CTRTextureLightMap2_M2::drawTriangle(const s4DVertex* burning_restrict a, c
 #endif\r
 \r
                        // render a scanline\r
-                       scanline_bilinear2 ();\r
+                       interlace_scanline scanline_bilinear2 ();\r
 \r
                        scan.x[0] += scan.slopeX[0];\r
                        scan.x[1] += scan.slopeX[1];\r