OpenGL

             

20. - 10


glEnable(GL_DEPTH_TEST); //

glDisable(GL_BLEND); //

 

roll. roll , 1.0, 1.0. roll.

roll+=0.002f; //

if (roll>1.0f) // Roll

{

roll-=1.0f; // 1 Roll

}

 

return TRUE; // OK

}

 

KillGLWindow(), CreateGLWindow() WndProc() , .

WinMain() - . " NeHe". , . :)

int WINAPI WinMain(

HINSTANCE hInstance, //

HINSTANCE hPrevInstance, //

LPSTR lpCmdLine, //

int nCmdShow) //

{

MSG msg; //

BOOL done=FALSE; //

//

if (MessageBox(NULL,"Would You Like To Run In Fullscreen Mode?",

"Start FullScreen?",MB_YESNO|MB_ICONQUESTION)==IDNO)

{

fullscreen=FALSE; //

}

 

// OpenGL

if (!CreateGLWindow("NeHe's Masking Tutorial",640,480,16,fullscreen))

{

return 0; //

}

while (!done) // , done=FALSE

{

if (PeekMessage(&msg,NULL,0,0,PM_REMOVE)) // ?

{

if (msg.message==WM_QUIT) // ?

{

done=TRUE; // done=TRUE

}

else // ,

{

TranslateMessage(&msg); //