Cube.cpp
上传用户:sz83729876
上传日期:2013-03-07
资源大小:4140k
文件大小:1k
- //
- // a64ki
- // Copyright (c) 2002 Henrik Carlgren
- // http://ziruz.cjb.net
- // ziruz@hotpop.com
- //
- #include "cube.h"
- #include <windows.h>
- #include <glgl.h>
- void renderCube(float size)
- {
- glBegin(GL_QUADS);
- glVertex3f(-size,-size,-size);
- glVertex3f(-size,+size,-size);
- glVertex3f(+size,+size,-size);
- glVertex3f(+size,-size,-size);
- glVertex3f(-size,-size,+size);
- glVertex3f(-size,+size,+size);
- glVertex3f(+size,+size,+size);
- glVertex3f(+size,-size,+size);
- glVertex3f(-size,-size,-size);
- glVertex3f(-size,-size,+size);
- glVertex3f(+size,-size,+size);
- glVertex3f(+size,-size,-size);
- glVertex3f(-size,+size,-size);
- glVertex3f(-size,+size,+size);
- glVertex3f(+size,+size,+size);
- glVertex3f(+size,+size,-size);
- glVertex3f(-size,-size,-size);
- glVertex3f(-size,-size,+size);
- glVertex3f(-size,+size,+size);
- glVertex3f(-size,+size,-size);
- glVertex3f(+size,-size,-size);
- glVertex3f(+size,-size,+size);
- glVertex3f(+size,+size,+size);
- glVertex3f(+size,+size,-size);
- glEnd();
- }