1Name 2 3 ARB_texture_env_add 4 5Name Strings 6 7 GL_ARB_texture_env_add 8 9Contact 10 11 Michael Gold, NVIDIA (gold 'at' nvidia.com) 12 Tom Frisinger, ATI (tfrisinger 'at' atitech.com) 13 14Notice 15 16 Copyright (c) 1999-2013 The Khronos Group Inc. Copyright terms at 17 http://www.khronos.org/registry/speccopyright.html 18 19Specification Update Policy 20 21 Khronos-approved extension specifications are updated in response to 22 issues and bugs prioritized by the Khronos OpenGL Working Group. For 23 extensions which have been promoted to a core Specification, fixes will 24 first appear in the latest version of that core Specification, and will 25 eventually be backported to the extension document. This policy is 26 described in more detail at 27 https://www.khronos.org/registry/OpenGL/docs/update_policy.php 28 29Status 30 31 Complete. Approved by ARB on 12/8/1999 32 33Version 34 35 Last Modified Date: June 22, 2000 36 Author Revision: 0.3 37 38 Based on: EXT_texture_env_add 39 Date: 1999/03/22 Revision: 1.1 40 41Number 42 43 ARB Extension #6 44 45Dependencies 46 47 None 48 49Overview 50 51 New texture environment function ADD is supported with the following 52 equation: 53 Cv = min(1, Cf + Ct) 54 55 New function may be specified by calling TexEnv with ADD token. 56 57 One possible application is to add a specular highlight texture to 58 a Gouraud-shaded primitive to emulate Phong shading, in a single 59 pass. 60 61 62New Procedures and Functions 63 64 None 65 66New Tokens 67 68 Accepted by the <params> parameter of TexEnvf, TexEnvi, TexEnvfv, and 69 TexEnvfi when the <pname> parameter value is GL_TEXTURE_ENV_MODE 70 71 ADD 72 73Additions to Chapter 2 of the GL Specification (OpenGL Operation) 74 75 None 76 77Additions to Chapter 3 of the GL Specification (Rasterization) 78 79 The description of TEXTURE_ENV_MODE in the first paragraph of 80 section 3.8.9 should be modified as follows: 81 82 TEXTURE_ENV_MODE may be set to one of REPLACE, MODULATE, DECAL, 83 BLEND or ADD; 84 85 Table 3.19 is augmented as follows: 86 87 Base DECAL BLEND ADD 88 Internal Format tex func tex func tex func 89 --------------- ----- ----- --- 90 91 ALPHA ... ... Rv = Rf 92 ... ... Gv = Gf 93 ... ... Bv = Bf 94 ... ... Av = AfAt 95 96 LUMINANCE ... ... Rv = min(1, Rf+Lt) 97 (or 1) ... ... Gv = min(1, Gf+Lt) 98 ... ... Bv = min(1, Bf+Lt) 99 ... ... Av = Af 100 101 LUMINANCE_ALPHA ... ... Rv = min(1, Rf+Lt) 102 (or 2) ... ... Gv = min(1, Gf+Lt) 103 ... ... Bv = min(1, Bf+Lt) 104 ... ... Av = AfAt 105 106 INTENSITY ... ... Rv = min(1, Rf+It) 107 ... ... Gv = min(1, Gf+It) 108 ... ... Bv = min(1, Bf+It) 109 ... ... Av = min(1, Af+It) 110 111 RGB ... ... Rv = min(1, Rf+Rt) 112 (or 3) ... ... Gv = min(1, Gf+Gt) 113 ... ... Bv = min(1, Bf+Bt) 114 ... ... Av = Af 115 116 RGBA ... ... Rv = min(1, Rf+Rt) 117 (or 4) ... ... Gv = min(1, Gf+Gt) 118 ... ... Bv = min(1, Bf+Bt) 119 ... ... Av = AfAt 120 121 122 Table 3.19: Decal, blend and add texture functions. 123 124 125Additions to Chapter 4 of the GL Specification (Per-Fragment Operations 126and the Framebuffer) 127 128 None 129 130Additions to Chapter 5 of the GL Specification (Special Functions) 131 132 None 133 134Additions to Chapter 6 of the GL Specification (State and State Requests) 135 136 None 137 138Additions to the GLX / WGL / AGL Specifications 139 140 None 141 142GLX Protocol 143 144 None 145 146Errors 147 148 None 149 150New State 151 152 The Type of TEXTURE_ENV_MODE in Table F.2 should be changed to 153 154 1 * xZ5 155 156New Implementation Dependent State 157 158 None 159 160Revision History 161 162 11/09/1999 0.1 163 - First ARB draft based on the original EXT draft. 164 165 1/13/2000 0.2 166 - Added justification to the overview 167 - Updated to describe modifications to 1.2.1 specification 168 - Added changes to description of TEXTURE_ENV_MODE parameter 169 to TexEnv{if} and TexEnv{if}v 170 - Added change to TEXTURE_ENV_MODE type (Z4 -> Z5) 171 172 6/22/2000 0.3 173 - The addition should saturate to 1. 174