来源请注明,本文永久地址为
OpenGL®作为业界最为广泛使用的2D和3D图形接口标准,应用在成千上万的各式各样的计算机的程序中。从初期的崭露头角,到与Direct3D激烈竞争,后经历黯淡被Khronos接手又发扬光大,已经历经波折发展了20年。由于过去的黯淡,至今甚至仍有人站在错误的时间角度认为它是落后的——它从未停止它前进的步伐,这篇文章就来简述OpenGL的版本历史和发展。
OpenGL1.0
发布时间:1992年1月
OpenGL的最早版本OpenGL1.0由MarkSegal和KurtAkeley发布于1992年1月。从这之后,OpenGL每隔一段时间都会发布一个新版本的规范,这些规范定义了一些显卡必须支持的新扩展。这就决定了OpenGL的每个版本其实就是由各个扩展组成的,当硬件的驱动全部支持相应的扩展的时候,相应的OpenGL版本就被支持了。
OpenGL1.1
发布时间:1997年1月
扩展
特性增加
GL_EXT_vertex_array
Vertexarrays
GL_EXT_polygon_offset
Polygonoffset
GL_EXT_blend_logic_op
Logicaloperation
GL_EXT_texture
Internaltextureformats,textureproxy,andtextureenv
GL_EXT_copy_texture
GL_EXT_subtexture
Copytextureandsubtexture from framebuffer
GL_EXT_texture_object
Textureobject
时隔5年OpenGL才发布新的版本OpenGL 1.1,而Direct3D的出现(尤其是红色警戒的大卖)使得OpenGL感觉到了压力。顶点数组(Vertex arrays)的出现取代了glVertex*这类立即模式绘图函数,多个数据可以被一个函数调用绘制了,降低了调用函数带来的CPU循环开销;polygon offset解决了z-fighting和stitching的问题;在pre-fragment operation开始支持逻辑操作(logic operation);纹理方面开始支持纹理代理(texture proxy)和纹理环境映射(texture environment),以及从帧缓冲(frameuffer)复制像素至texture或者subtexture;纹理对象(texture object)的出现改变了过去只能使用显示表(display list)来静态地使用纹理的方法,现在纹理和参数(texture parameter)能被改变了。
OpenGL1.2
发布时间:1998年3月16日
扩展
特性
GL_EXT_texture3D
Three-dimensional texture
GL_EXT_bgra
BGR or BGRA pixel format
GL_EXT_packed_pixels
Packed pixel formats
GL_EXT_rescale_normal
Normal rescaling
GL_EXT_separate_specular_color
Separate specular color
GL_SGIS_texture_edge_clamp
Texture coordinate edge clamping
GL_SGIS_texture_lod
Texture LOD control
GL_EXT_draw_range_elements
Vertex array draw element range
这个版本的OpenGL开始支持可以用于体渲染(volume rendering)和体纹理(solid texture)的texture 3D;BGRA和BGA的出现主要是为了兼容某些平台和硬件;包装像素(pack pixel)的出现使得像素可以在不同的对象之间进行像素传输(pixel transfer),这也就是像素缓冲对象(pixel buffer object)的前身;GL_SGIS_texture_edge_clamp扩展的出现将texture coordinate规范在[0,1]这个区间;GL_SGIS_Texture_lod扩展则带来了重要的MipMap技术,可以通过对纹理参数(texture parameter)的控制来完成对MipMap的控制。
OpenGL1.2.1
发布时间:1998年10月14日
这个版本的OpenGL没有什么重大的改变,但是专门介绍了ARB扩展的概念。ARB扩展是经过OpenGL ARB认证的扩展,这样的扩展将被广泛地实现。
OpenGL1.3
发布时间:2001年8月14日
扩展
特性增加
GL_ARB_texture_compression
compressed texture format
GL_ARB_texture_cube_map
texture cube
GL_ARB_multisample
MSAA(multisample anti-aliasing)
GL_ARB_multitexture(removed)
multi-texture
GL_ARB_texture_env_add
GL_ARB_texture_env_combine
GL_ARB_texture_env_dot3
Texture add env mode, texture combine env mode, texture dot3 env mode
GL_ARB_texture_border_clamp
Texture border clamp
GL_ARB_transpose_matrix
transpose matrix
这个版本开始支持压缩纹理(compressed texture),可以有效地减少存储和带宽的压力,现在广泛的应用于各种对存储大小和带宽敏感的手持设备上;立方体纹理(texture cube)的出现主要用于在天空盒(skybox)、动态反射(dynamic reflection)等技术上;而multisample的出现让OpenGL可以支持纹理和Framebuffer的MSAA抗锯齿技术,代替了过去在光栅化状态(rasterizer state)中趋近无用的抗锯齿设置。
OpenGL1.4
发布版本:2002年7月24日
扩展
特性增加
GL_SGIS_generate_mipmap
Automatic mipmap generation
GL_NV_blend_square
Blend squaring
GL_ARB_depth_texture
GL_ARB_shadow
Depth texture adn shadows
GL_EXT_fog_coord
Fog coordinate
GL_EXT_multi_draw_arrays
Multi draw arrays
GL_ARB_point_parameters
Point parameters
GL_EXT_secondary_color
Secondary color
GL_EXT_blend_func_separate
Separate blend functions
GL_EXT_stencil_wrap
Stencil warp
GL_ARB_texture_env_crossbar
Texture crossbar env mode
GL_ARB_texture_mirrored_repeat
Texture mirrored repeat
GL_ARB_window_pos
Window raster position
这个版本开始支持纹理自动生成Mipmap; 以及关于point光栅化的parameter。
OpenGL1.5
发布时间:2003年7月29日
扩展
特性增加
GL_ARB_vertex_buffer_object
Buffer object
GL_ARB_occlusion_query
Occlusion query
GL_EXT_shadow_funcs
Shadow functions
也就越容易失败,还不如怀揣一颗平常心,