Graphics 版 (精华区)

发信人: killest (victor), 信区: Graphics
标  题: [转载] VC 4.0中使用OpenGL(14)
发信站: 紫 丁 香 (Wed Apr 22 10:29:53 1998), 站内信件

【 以下文字转载自 Programming 讨论区 】
【 原文由 xiaojun 所发表 】
       glVertex3d(-0.5, 0.5, -0.5);
        glVertex3d(-0.5, -0.5, -0.5);
        glNormal3d(0.0, 1.0, 0.0);
        glVertex3d(-0.5, 0.5, 0.5);
        glVertex3d(0.5, 0.5, 0.5);
        glVertex3d(0.5, 0.5, -0.5);
        glVertex3d(-0.5, 0.5, -0.5);
        glEnd();
        glFlush();
        wglMakeCurrent(NULL, NULL);
        EndPaint(hwnd, &paintStruct);
    }
}
LRESULT CALLBACK WndProc(HWND hwnd, UINT uMsg,
                         WPARAM wParam, LPARAM lParam)
{
    switch(uMsg)
    {
        case WM_PAINT:
            DrawHello(hwnd);
            break;
        case WM_DESTROY:
            PostQuitMessage(0);                      

--
※ 来源:.紫 丁 香 bbs.hit.edu.cn.[FROM: hs6.hit.edu.cn]
--
※ 转载:.紫 丁 香 bbs.hit.edu.cn.[FROM: victor.hit.edu.c]
[百宝箱] [返回首页] [上级目录] [根目录] [返回顶部] [刷新] [返回]
Powered by KBS BBS 2.0 (http://dev.kcn.cn)
页面执行时间:8.419毫秒