zoukankan      html  css  js  c++  java
  • win7-opengl开发环境的搭建

    1. glut的安装:

    下载glutdlls37beta.zip,下载链接直接opengl.org上找。

    把glut.h 复制到include下;

    glut.lib, glut32.lib复制到C:Program Files (x86)Microsoft Visual Studio 10.0VClib下;

    将glut.dll和glut32.dll复制到C:WindowsSysWOW64(32位放在C:WindowsSystem32)下。

     在工程中的链接器里面输出项目加入opengl32.lib, glu32.lib, glut32.lib

    2. glew的安装和glut一样,略

    3.

    #include <GL/glew.h>

    #include <glut.h>

    #pragma comment(lib, "glew32.lib")

    void init(){

    ...

    }

    void display(){...}

    void reshape(GLint h, GLint w){...}

    int main()

    {

        glutInit();// step1. 

        glutInitDisplayMode();  //step2

        glutInitWindowPosition(); 

     glutInitWindowSize();//step3

      glutCreateWindow(); //step4

      glewInit();  //step5

      init();

      glutDisplayFunc(display);  //step6

      glutReshapeFunc(reshape);  //step7

      glutMainLoop();    //step8  

    }

  • 相关阅读:
    写的好的功能参考地址
    碰撞检测原理
    懒加载原理的实现
    jQuery图片延迟加载插件jQuery.lazyload 的使用
    电子工厂生产楼职位解析
    打印条码方式
    条码打印二
    条码打印三
    CSS实现圆角矩形
    条码打印四
  • 原文地址:https://www.cnblogs.com/bubbler/p/3444150.html
Copyright © 2011-2022 走看看