David Li | 55c94cc | 2011-03-04 17:50:48 -0800 | [diff] [blame] | 1 | /* |
| 2 | ** Copyright 2011, The Android Open Source Project |
| 3 | ** |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 4 | ** Licensed under the Apache License, Version 2.0 (the "License") |
David Li | 55c94cc | 2011-03-04 17:50:48 -0800 | [diff] [blame] | 5 | ** you may not use this file except in compliance with the License. |
| 6 | ** You may obtain a copy of the License at |
| 7 | ** |
| 8 | ** http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | ** |
| 10 | ** Unless required by applicable law or agreed to in writing, software |
| 11 | ** distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | ** See the License for the specific language governing permissions and |
| 14 | ** limitations under the License. |
| 15 | */ |
| 16 | |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 17 | static const int * GenerateCall_glCompressedTexImage2D(DbgContext * const dbg, |
| 18 | const glesv2debugger::Message & cmd, |
| 19 | glesv2debugger::Message & msg, const int * const prevRet) |
| 20 | { |
| 21 | assert(0); |
| 22 | return prevRet; |
| 23 | } |
David Li | 55c94cc | 2011-03-04 17:50:48 -0800 | [diff] [blame] | 24 | |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 25 | static const int * GenerateCall_glCompressedTexSubImage2D(DbgContext * const dbg, |
| 26 | const glesv2debugger::Message & cmd, |
| 27 | glesv2debugger::Message & msg, const int * const prevRet) |
| 28 | { |
| 29 | assert(0); |
| 30 | return prevRet; |
| 31 | } |
David Li | 55c94cc | 2011-03-04 17:50:48 -0800 | [diff] [blame] | 32 | |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 33 | static const int * GenerateCall_glDrawElements(DbgContext * const dbg, |
| 34 | const glesv2debugger::Message & cmd, |
| 35 | glesv2debugger::Message & msg, const int * const prevRet) |
| 36 | { |
| 37 | assert(0); |
| 38 | return prevRet; |
| 39 | } |
| 40 | |
| 41 | static const int * GenerateCall_glGenBuffers(DbgContext * const dbg, |
| 42 | const glesv2debugger::Message & cmd, |
| 43 | glesv2debugger::Message & msg, const int * const prevRet) |
| 44 | { |
| 45 | assert(0); |
| 46 | return prevRet; |
| 47 | } |
| 48 | |
| 49 | static const int * GenerateCall_glGenFramebuffers(DbgContext * const dbg, |
| 50 | const glesv2debugger::Message & cmd, |
| 51 | glesv2debugger::Message & msg, const int * const prevRet) |
| 52 | { |
| 53 | assert(0); |
| 54 | return prevRet; |
| 55 | } |
| 56 | |
| 57 | static const int * GenerateCall_glGenRenderbuffers(DbgContext * const dbg, |
| 58 | const glesv2debugger::Message & cmd, |
| 59 | glesv2debugger::Message & msg, const int * const prevRet) |
| 60 | { |
| 61 | assert(0); |
| 62 | return prevRet; |
| 63 | } |
| 64 | |
| 65 | static const int * GenerateCall_glGenTextures(DbgContext * const dbg, |
| 66 | const glesv2debugger::Message & cmd, |
| 67 | glesv2debugger::Message & msg, const int * const prevRet) |
| 68 | { |
| 69 | assert(0); |
| 70 | return prevRet; |
| 71 | } |
| 72 | |
| 73 | static const int * GenerateCall_glGetActiveAttrib(DbgContext * const dbg, |
| 74 | const glesv2debugger::Message & cmd, |
| 75 | glesv2debugger::Message & msg, const int * const prevRet) |
| 76 | { |
| 77 | assert(0); |
| 78 | return prevRet; |
| 79 | } |
| 80 | |
| 81 | static const int * GenerateCall_glGetActiveUniform(DbgContext * const dbg, |
| 82 | const glesv2debugger::Message & cmd, |
| 83 | glesv2debugger::Message & msg, const int * const prevRet) |
| 84 | { |
| 85 | assert(0); |
| 86 | return prevRet; |
| 87 | } |
| 88 | |
| 89 | static const int * GenerateCall_glGetAttachedShaders(DbgContext * const dbg, |
| 90 | const glesv2debugger::Message & cmd, |
| 91 | glesv2debugger::Message & msg, const int * const prevRet) |
| 92 | { |
| 93 | assert(0); |
| 94 | return prevRet; |
| 95 | } |
| 96 | |
| 97 | static const int * GenerateCall_glGetBooleanv(DbgContext * const dbg, |
| 98 | const glesv2debugger::Message & cmd, |
| 99 | glesv2debugger::Message & msg, const int * const prevRet) |
| 100 | { |
| 101 | assert(0); |
| 102 | return prevRet; |
| 103 | } |
| 104 | |
| 105 | static const int * GenerateCall_glGetBufferParameteriv(DbgContext * const dbg, |
| 106 | const glesv2debugger::Message & cmd, |
| 107 | glesv2debugger::Message & msg, const int * const prevRet) |
| 108 | { |
| 109 | assert(0); |
| 110 | return prevRet; |
| 111 | } |
| 112 | |
| 113 | static const int * GenerateCall_glGetFloatv(DbgContext * const dbg, |
| 114 | const glesv2debugger::Message & cmd, |
| 115 | glesv2debugger::Message & msg, const int * const prevRet) |
| 116 | { |
| 117 | assert(0); |
| 118 | return prevRet; |
| 119 | } |
| 120 | |
| 121 | static const int * GenerateCall_glGetFramebufferAttachmentParameteriv(DbgContext * const dbg, |
| 122 | const glesv2debugger::Message & cmd, |
| 123 | glesv2debugger::Message & msg, const int * const prevRet) |
| 124 | { |
| 125 | assert(0); |
| 126 | return prevRet; |
| 127 | } |
| 128 | |
| 129 | static const int * GenerateCall_glGetIntegerv(DbgContext * const dbg, |
| 130 | const glesv2debugger::Message & cmd, |
| 131 | glesv2debugger::Message & msg, const int * const prevRet) |
| 132 | { |
| 133 | assert(0); |
| 134 | return prevRet; |
| 135 | } |
| 136 | |
| 137 | static const int * GenerateCall_glGetProgramiv(DbgContext * const dbg, |
| 138 | const glesv2debugger::Message & cmd, |
| 139 | glesv2debugger::Message & msg, const int * const prevRet) |
| 140 | { |
David Li | e2ad4d0 | 2011-04-08 18:41:00 -0700 | [diff] [blame] | 141 | GLint params = -1; |
| 142 | dbg->hooks->gl.glGetProgramiv(cmd.arg0(), cmd.arg1(), ¶ms); |
| 143 | msg.mutable_data()->append(reinterpret_cast<char *>(¶ms), sizeof(params)); |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 144 | return prevRet; |
| 145 | } |
| 146 | |
| 147 | static const int * GenerateCall_glGetProgramInfoLog(DbgContext * const dbg, |
| 148 | const glesv2debugger::Message & cmd, |
| 149 | glesv2debugger::Message & msg, const int * const prevRet) |
| 150 | { |
David Li | e2ad4d0 | 2011-04-08 18:41:00 -0700 | [diff] [blame] | 151 | const GLsizei bufSize = static_cast<GLsizei>(dbg->GetBufferSize()); |
| 152 | GLsizei length = -1; |
| 153 | dbg->hooks->gl.glGetProgramInfoLog(cmd.arg0(), bufSize, &length, dbg->GetBuffer()); |
| 154 | msg.mutable_data()->append(dbg->GetBuffer(), length); |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 155 | return prevRet; |
| 156 | } |
| 157 | |
| 158 | static const int * GenerateCall_glGetRenderbufferParameteriv(DbgContext * const dbg, |
| 159 | const glesv2debugger::Message & cmd, |
| 160 | glesv2debugger::Message & msg, const int * const prevRet) |
| 161 | { |
| 162 | assert(0); |
| 163 | return prevRet; |
| 164 | } |
| 165 | |
| 166 | static const int * GenerateCall_glGetShaderiv(DbgContext * const dbg, |
| 167 | const glesv2debugger::Message & cmd, |
| 168 | glesv2debugger::Message & msg, const int * const prevRet) |
| 169 | { |
David Li | e2ad4d0 | 2011-04-08 18:41:00 -0700 | [diff] [blame] | 170 | GLint params = -1; |
| 171 | dbg->hooks->gl.glGetShaderiv(cmd.arg0(), cmd.arg1(), ¶ms); |
| 172 | msg.mutable_data()->append(reinterpret_cast<char *>(¶ms), sizeof(params)); |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 173 | return prevRet; |
| 174 | } |
| 175 | |
| 176 | static const int * GenerateCall_glGetShaderInfoLog(DbgContext * const dbg, |
| 177 | const glesv2debugger::Message & cmd, |
| 178 | glesv2debugger::Message & msg, const int * const prevRet) |
| 179 | { |
David Li | e2ad4d0 | 2011-04-08 18:41:00 -0700 | [diff] [blame] | 180 | const GLsizei bufSize = static_cast<GLsizei>(dbg->GetBufferSize()); |
| 181 | GLsizei length = -1; |
| 182 | dbg->hooks->gl.glGetShaderInfoLog(cmd.arg0(), bufSize, &length, dbg->GetBuffer()); |
| 183 | msg.mutable_data()->append(dbg->GetBuffer(), length); |
David Li | 291f5fe | 2011-03-21 17:42:50 -0700 | [diff] [blame] | 184 | return prevRet; |
| 185 | } |
| 186 | |
| 187 | static const int * GenerateCall_glGetShaderPrecisionFormat(DbgContext * const dbg, |
| 188 | const glesv2debugger::Message & cmd, |
| 189 | glesv2debugger::Message & msg, const int * const prevRet) |
| 190 | { |
| 191 | assert(0); |
| 192 | return prevRet; |
| 193 | } |
| 194 | |
| 195 | static const int * GenerateCall_glGetShaderSource(DbgContext * const dbg, |
| 196 | const glesv2debugger::Message & cmd, |
| 197 | glesv2debugger::Message & msg, const int * const prevRet) |
| 198 | { |
| 199 | assert(0); |
| 200 | return prevRet; |
| 201 | } |
| 202 | |
| 203 | static const int * GenerateCall_glGetString(DbgContext * const dbg, |
| 204 | const glesv2debugger::Message & cmd, |
| 205 | glesv2debugger::Message & msg, const int * const prevRet) |
| 206 | { |
| 207 | assert(0); |
| 208 | return prevRet; |
| 209 | } |
| 210 | |
| 211 | static const int * GenerateCall_glGetTexParameterfv(DbgContext * const dbg, |
| 212 | const glesv2debugger::Message & cmd, |
| 213 | glesv2debugger::Message & msg, const int * const prevRet) |
| 214 | { |
| 215 | assert(0); |
| 216 | return prevRet; |
| 217 | } |
| 218 | |
| 219 | static const int * GenerateCall_glGetTexParameteriv(DbgContext * const dbg, |
| 220 | const glesv2debugger::Message & cmd, |
| 221 | glesv2debugger::Message & msg, const int * const prevRet) |
| 222 | { |
| 223 | assert(0); |
| 224 | return prevRet; |
| 225 | } |
| 226 | |
| 227 | static const int * GenerateCall_glGetUniformfv(DbgContext * const dbg, |
| 228 | const glesv2debugger::Message & cmd, |
| 229 | glesv2debugger::Message & msg, const int * const prevRet) |
| 230 | { |
| 231 | assert(0); |
| 232 | return prevRet; |
| 233 | } |
| 234 | |
| 235 | static const int * GenerateCall_glGetUniformiv(DbgContext * const dbg, |
| 236 | const glesv2debugger::Message & cmd, |
| 237 | glesv2debugger::Message & msg, const int * const prevRet) |
| 238 | { |
| 239 | assert(0); |
| 240 | return prevRet; |
| 241 | } |
| 242 | |
| 243 | static const int * GenerateCall_glGetVertexAttribfv(DbgContext * const dbg, |
| 244 | const glesv2debugger::Message & cmd, |
| 245 | glesv2debugger::Message & msg, const int * const prevRet) |
| 246 | { |
| 247 | assert(0); |
| 248 | return prevRet; |
| 249 | } |
| 250 | |
| 251 | static const int * GenerateCall_glGetVertexAttribiv(DbgContext * const dbg, |
| 252 | const glesv2debugger::Message & cmd, |
| 253 | glesv2debugger::Message & msg, const int * const prevRet) |
| 254 | { |
| 255 | assert(0); |
| 256 | return prevRet; |
| 257 | } |
| 258 | |
| 259 | static const int * GenerateCall_glGetVertexAttribPointerv(DbgContext * const dbg, |
| 260 | const glesv2debugger::Message & cmd, |
| 261 | glesv2debugger::Message & msg, const int * const prevRet) |
| 262 | { |
| 263 | assert(0); |
| 264 | return prevRet; |
| 265 | } |
| 266 | |
| 267 | static const int * GenerateCall_glReadPixels(DbgContext * const dbg, |
| 268 | const glesv2debugger::Message & cmd, |
| 269 | glesv2debugger::Message & msg, const int * const prevRet) |
| 270 | { |
| 271 | assert(0); |
| 272 | return prevRet; |
| 273 | } |
| 274 | |
| 275 | static const int * GenerateCall_glShaderBinary(DbgContext * const dbg, |
| 276 | const glesv2debugger::Message & cmd, |
| 277 | glesv2debugger::Message & msg, const int * const prevRet) |
| 278 | { |
| 279 | assert(0); |
| 280 | return prevRet; |
| 281 | } |
| 282 | |
| 283 | static const int * GenerateCall_glShaderSource(DbgContext * const dbg, |
| 284 | const glesv2debugger::Message & cmd, |
| 285 | glesv2debugger::Message & msg, const int * const prevRet) |
| 286 | { |
| 287 | const char * string = cmd.data().data(); |
| 288 | dbg->hooks->gl.glShaderSource(cmd.arg0(), 1, &string, NULL); |
| 289 | return prevRet; |
| 290 | } |
| 291 | |
| 292 | static const int * GenerateCall_glTexImage2D(DbgContext * const dbg, |
| 293 | const glesv2debugger::Message & cmd, |
| 294 | glesv2debugger::Message & msg, const int * const prevRet) |
| 295 | { |
| 296 | assert(0); |
| 297 | return prevRet; |
| 298 | } |
| 299 | |
| 300 | static const int * GenerateCall_glTexParameterfv(DbgContext * const dbg, |
| 301 | const glesv2debugger::Message & cmd, |
| 302 | glesv2debugger::Message & msg, const int * const prevRet) |
| 303 | { |
| 304 | assert(0); |
| 305 | return prevRet; |
| 306 | } |
| 307 | |
| 308 | static const int * GenerateCall_glTexParameteriv(DbgContext * const dbg, |
| 309 | const glesv2debugger::Message & cmd, |
| 310 | glesv2debugger::Message & msg, const int * const prevRet) |
| 311 | { |
| 312 | assert(0); |
| 313 | return prevRet; |
| 314 | } |
| 315 | |
| 316 | static const int * GenerateCall_glTexSubImage2D(DbgContext * const dbg, |
| 317 | const glesv2debugger::Message & cmd, |
| 318 | glesv2debugger::Message & msg, const int * const prevRet) |
| 319 | { |
| 320 | assert(0); |
| 321 | return prevRet; |
| 322 | } |
| 323 | |
| 324 | static const int * GenerateCall_glVertexAttribPointer(DbgContext * const dbg, |
| 325 | const glesv2debugger::Message & cmd, |
| 326 | glesv2debugger::Message & msg, const int * const prevRet) |
| 327 | { |
| 328 | assert(0); |
| 329 | return prevRet; |
| 330 | } |