-
大小: 0.02M文件類型: .cpp金幣: 1下載: 0 次發(fā)布日期: 2021-02-01
- 標(biāo)簽: OpenGL??pe??設(shè)計(jì)??
資源簡介
opengl人物設(shè)計(jì)博士臉
代碼片段和文件信息
#include
#include
#include
#include?
#include?
#define?GL_BGR_EXT?0x80E0
#define?GL_BGRA_EXT?0x80E1
GLfloat?light_position1[]={028-201.0};
GLfloat?model_ambient[]={0.05f0.05f0.05f1.0f};
GLfloat?mat_specular[]={0.81.01.01.0};
GLfloat?mat_shininess[]={5.0};
GLfloat?mat_ambient[]={0.10.10.11};
GLfloat?white_light[]={1.01.01.01.0};
GLfloat?light[]={1.01.01.01};
GLfloat?light_position0[]={028201.0};
GLint?WinWidth;
GLint?WinHeight;
//define?the?eyepoint
typedef?struct?EyePoint
{
GLfloat?x;
GLfloat?y;
GLfloat?z;
}EyePoint;
EyePoint?myEye;
EyePoint?vPoint;
GLfloat?vAngle=0;
//the?function?about?the?texture
#define?BMP_Header_Length?54
void?grab(void)?{
FILE*?pDummyFile;?FILE*?pWritingFile;
GLubyte*?pPixelData;
GLubyte?BMP_Header[BMP_Header_Length];
GLint?i?j;
GLint?PixelDataLength;
i?=?WinWidth?*?3;
while(?i%4?!=?0?)
??i;
PixelDataLength?=?i?*?
評(píng)論
共有 條評(píng)論