Code: Select all
if (DebugDataVisible == scene::EDS_NORMALS || DebugDataVisible == scene::EDS_FULL)
{
video::SMaterial m;
m.Lighting = false;
driver->setMaterial(m);
for(s32 j=0; j<Sector.height(); j++)
for(s32 i=0; i<Sector.width(); i++)
{
video::S3DVertex2TCoords* v = &Sector(i,j).Vertex[0];
video::SColor c ( 255, 128 ,0, 0 );
for (u32 n = 0; n<Sector(i,j).Vertex.size(); ++n )
{
core::vector3df h = v[n].Normal * (TileSize/2);
driver->draw3DLine ( v[n].Pos, v[n].Pos + h, c );
}
}
}
But you are right, there is quit big difference between them when debuging normals are enabled.