OpenGL使用glDrawPixels绘制图像,其中一个参数是GLenum format,请问假使已经将一个256色的单波段的灰度图像的像素值读入缓存,那么这个GLenum format要设置为哪个值呢?我发现并没有合适的值啊!
解决方案 »
- 如何点击树控件弹出一个对话框
- 请教通过snmp获取网络打印机状态(未开机,缺纸等)的思路
- 使用VC读EXCEL后,EXCEL程序还在后台运行,我用的是OLE方法
- 这年头,换个工作不容易啊
- TCP套接字连接失败的问题
- 关于DECLARE_OLECREATE和IMPLEMENT_OLECREATE
- (原创)请问一下各位高手,学习多线程前是否应该对MFC有一定理解呢?学习多线程时需要对操作系统有很深入的理解吗??
- WINAPI问题
- 简单问题(见笑)
- 如何发一个鼠标单击消息到按钮,重谢
- MFC中初学文件保存与打开白痴问题请高手指点,谢! 急急急.......(小弟初来分数不多愿倾囊而赠!)
- 菜鸟问题:请问如何接受编辑框里面的内容!急
Each pixel is a single luminance component.
The glDrawPixels function converts this component to the internal floating-point format in the same way that the red component of an RGBA pixel is, and then converts it to an RGBA pixel with red, green, and blue set to the converted luminance value, and alpha set to 1.0. After this conversion, the pixel is treated just as if it had been read as an RGBA pixel. GL_UNSIGNED_BYTE