Merging r6364 through r6379 from trunk to ogl-es branch
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@6380 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
@@ -93,7 +93,7 @@ private:
|
||||
|
||||
//! constructor
|
||||
CTRGouraudAlphaNoZ2::CTRGouraudAlphaNoZ2(CBurningVideoDriver* driver)
|
||||
: IBurningShader(driver)
|
||||
: IBurningShader(driver, EMT_TRANSPARENT_ALPHA_CHANNEL)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
setDebugName("CTRGouraudAlphaNoZ2");
|
||||
@@ -286,7 +286,7 @@ void CTRGouraudAlphaNoZ2::drawTriangle(const s4DVertex* burning_restrict a, cons
|
||||
temp[2] = b->Pos.x - a->Pos.x;
|
||||
temp[3] = ba;
|
||||
|
||||
scan.left = ( temp[0] * temp[3] - temp[1] * temp[2] ) > 0.f ? 0 : 1;
|
||||
scan.left = ( temp[0] * temp[3] - temp[1] * temp[2] ) < 0.f ? 1 : 0;
|
||||
scan.right = 1 - scan.left;
|
||||
|
||||
// calculate slopes for the major edge
|
||||
@@ -359,8 +359,8 @@ void CTRGouraudAlphaNoZ2::drawTriangle(const s4DVertex* burning_restrict a, cons
|
||||
#endif
|
||||
|
||||
// apply top-left fill convention, top part
|
||||
yStart = fill_convention_left( a->Pos.y );
|
||||
yEnd = fill_convention_right( b->Pos.y );
|
||||
yStart = fill_convention_top( a->Pos.y );
|
||||
yEnd = fill_convention_down( b->Pos.y );
|
||||
|
||||
#ifdef SUBTEXEL
|
||||
subPixel = ( (f32) yStart ) - a->Pos.y;
|
||||
@@ -428,7 +428,7 @@ void CTRGouraudAlphaNoZ2::drawTriangle(const s4DVertex* burning_restrict a, cons
|
||||
#endif
|
||||
|
||||
// render a scanline
|
||||
interlace_scanline fragmentShader();
|
||||
if_interlace_scanline fragmentShader();
|
||||
|
||||
scan.x[0] += scan.slopeX[0];
|
||||
scan.x[1] += scan.slopeX[1];
|
||||
@@ -518,8 +518,8 @@ void CTRGouraudAlphaNoZ2::drawTriangle(const s4DVertex* burning_restrict a, cons
|
||||
#endif
|
||||
|
||||
// apply top-left fill convention, top part
|
||||
yStart = fill_convention_left( b->Pos.y );
|
||||
yEnd = fill_convention_right( c->Pos.y );
|
||||
yStart = fill_convention_top( b->Pos.y );
|
||||
yEnd = fill_convention_down( c->Pos.y );
|
||||
|
||||
#ifdef SUBTEXEL
|
||||
|
||||
@@ -588,7 +588,7 @@ void CTRGouraudAlphaNoZ2::drawTriangle(const s4DVertex* burning_restrict a, cons
|
||||
#endif
|
||||
|
||||
// render a scanline
|
||||
interlace_scanline fragmentShader();
|
||||
if_interlace_scanline fragmentShader();
|
||||
|
||||
scan.x[0] += scan.slopeX[0];
|
||||
scan.x[1] += scan.slopeX[1];
|
||||
@@ -636,7 +636,7 @@ namespace video
|
||||
//! creates a flat triangle renderer
|
||||
IBurningShader* createTRGouraudAlphaNoZ2(CBurningVideoDriver* driver)
|
||||
{
|
||||
//ETR_GOURAUD_ALPHA_NOZ - draw2DRectangle Gradient
|
||||
// ETR_GOURAUD_ALPHA_NOZ - draw2DRectangle Gradient
|
||||
#ifdef _IRR_COMPILE_WITH_BURNINGSVIDEO_
|
||||
return new CTRGouraudAlphaNoZ2(driver);
|
||||
#else
|
||||
|
Reference in New Issue
Block a user