关于glew安装【转】

Windows下OpenGL注意事项:
1.随时更新glew.h文件,可以到http://glew.sourceforge.net/下载。目前,最新版应该是glew1.5.4,网站自动根据你的电脑系统下载对应版本。
2.把下载文件中的dll文件放到系统目录windows下的system32目录下,把lib文件放到vc中的lib目录,而头文件----h文件则放到include下。
3.glew.h必须在所有gl类型的头文件的最前面,而windows.h以及stdio.h等IDE开发环境自带的库文件则放在glew.h的前面。开始没有注意,结果直接报错,让将glew放在gl前。
4.为了链接的时候够顺利通过,可以在开发环境中加入,也可使用

   #paragma comment(lib,"*.lib")的方式将要调入的lib文件进行加载。

   如:对于glew.h,就要加载glew32.lib文件。

    这个过程,在vs2005不需要了。

 

本文来自优快云博客,转载请标明出处:http://blog.youkuaiyun.com/qinson12321/archive/2010/06/22/5685391.aspx

c++ opengl的glew, # GLEW - The OpenGL Extension Wrangler Library ![](http://glew.sourceforge.net/glew.png) http://glew.sourceforge.net/ https://github.com/nigels-com/glew [![Build Status](https://travis-ci.org/nigels-com/glew.svg?branch=master)](https://travis-ci.org/nigels-com/glew) [![Gitter](https://badges.gitter.im/nigels-com/glew.svg)](https://gitter.im/nigels-com/glew?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) [![Download](https://img.shields.io/sourceforge/dm/glew.svg)](https://sourceforge.net/projects/glew/files/latest/download) ## Downloads Current release is [2.1.0](https://sourceforge.net/projects/glew/files/glew/2.1.0/). [(Change Log)](http://glew.sourceforge.net/log.html) Sources available as [ZIP](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0.zip/download) or [TGZ](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0.tgz/download). Windows binaries for [32-bit and 64-bit](https://sourceforge.net/projects/glew/files/glew/2.1.0/glew-2.1.0-win32.zip/download). ### Recent snapshots Snapshots may contain new features, bug-fixes or new OpenGL extensions ahead of tested, official releases. ## Build It is highly recommended to build from a tgz or zip release snapshot. The code generation workflow is a complex brew of gnu make, perl and python, that works best on Linux or Mac. For most end-users of GLEW the official releases are the best choice, with first class support. ### Linux and Mac #### Using GNU Make ##### Install build tools Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev libosmesa-dev` RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel` ##### Build $ make $ sudo make install $ make clean Targets: `all, glew.lib (sub-targets: glew.lib.shared, glew.lib.static), glew.bin, clean, install, uninstall` Variables: `SYSTEM=linux-clang, GLEW_DEST=/usr/local, STRIP=` _Note: may need to make **auto** folder_ ####
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值