For some reason when I try to add a normal map to a object using "dbSetBumpMappingOn();" it instead makes it disappear. I thought that was "dbHideObject();"'s job, not one that seems like it should apply a bump map to a object.
Here's the code and the two media files are attached.
#include "DarkGDK.h"
void DarkGDK ( void )
{
dbSyncOn ( );
dbSyncRate ( 60 );
dbSetDisplayMode( 1024, 768, 32 );
dbRandomize ( dbTimer ( ) );
////////////////////////////////////
dbMakeObjectCube(1,5);
float boxPitch,boxYaw;
dbLoadImage("metalx1d.png",5);
dbLoadImage("metalx1normal.png",6);
dbTextureObject(1,0,5);
//dbSetBumpMappingOn(1,6); // Uncomment this to make the cube disappear, AKA apply the normal map.
while ( LoopGDK ( ) )
{
dbText ( 0, 0, "Test" );
boxPitch += 0.1;
boxYaw += 0.25;
dbRotateObject(1,boxPitch,boxYaw,0);
dbSync ( );
}
return;
}
The trouble part has been commented out so you can see the cube, then uncomment it and see how it magicly disappears. Please help me!