Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Side by Side Diff: src/gpu/gl/GrGLCreateNullInterface.cpp

Issue 23513006: Add glTexGen funcs to interface (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: mesa Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | src/gpu/gl/GrGLDefines.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 #include "gl/GrGLInterface.h" 9 #include "gl/GrGLInterface.h"
10 #include "GrGLDefines.h" 10 #include "GrGLDefines.h"
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 gBuffers[id] = gBuffers[0]; 93 gBuffers[id] = gBuffers[0];
94 gBuffers[0] = SkTCast<GrBufferObj*>((const void*)(intptr_t)id); 94 gBuffers[0] = SkTCast<GrBufferObj*>((const void*)(intptr_t)id);
95 } 95 }
96 96
97 GrGLvoid GR_GL_FUNCTION_TYPE nullGLActiveTexture(GrGLenum texture) {} 97 GrGLvoid GR_GL_FUNCTION_TYPE nullGLActiveTexture(GrGLenum texture) {}
98 GrGLvoid GR_GL_FUNCTION_TYPE nullGLAttachShader(GrGLuint program, GrGLuint shade r) {} 98 GrGLvoid GR_GL_FUNCTION_TYPE nullGLAttachShader(GrGLuint program, GrGLuint shade r) {}
99 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBeginQuery(GrGLenum target, GrGLuint id) {} 99 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBeginQuery(GrGLenum target, GrGLuint id) {}
100 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindAttribLocation(GrGLuint program, GrGLuint index, const char* name) {} 100 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindAttribLocation(GrGLuint program, GrGLuint index, const char* name) {}
101 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindTexture(GrGLenum target, GrGLuint texture ) {} 101 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindTexture(GrGLenum target, GrGLuint texture ) {}
102 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindVertexArray(GrGLuint id) {} 102 GrGLvoid GR_GL_FUNCTION_TYPE nullGLBindVertexArray(GrGLuint id) {}
103 GrGLvoid GR_GL_FUNCTION_TYPE nullGLClientActiveTexture(GrGLenum) {}
103 104
104 GrGLvoid GR_GL_FUNCTION_TYPE nullGLGenBuffers(GrGLsizei n, GrGLuint* ids) { 105 GrGLvoid GR_GL_FUNCTION_TYPE nullGLGenBuffers(GrGLsizei n, GrGLuint* ids) {
105 106
106 for (int i = 0; i < n; ++i) { 107 for (int i = 0; i < n; ++i) {
107 GrBufferObj* buffer = create_buffer(); 108 GrBufferObj* buffer = create_buffer();
108 ids[i] = buffer->id(); 109 ids[i] = buffer->id();
109 } 110 }
110 } 111 }
111 112
112 GrGLvoid GR_GL_FUNCTION_TYPE nullGLGenerateMipmap(GrGLenum target) {} 113 GrGLvoid GR_GL_FUNCTION_TYPE nullGLGenerateMipmap(GrGLenum target) {}
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 interface->fBindFragDataLocation = noOpGLBindFragDataLocation; 275 interface->fBindFragDataLocation = noOpGLBindFragDataLocation;
275 interface->fBindTexture = nullGLBindTexture; 276 interface->fBindTexture = nullGLBindTexture;
276 interface->fBindVertexArray = nullGLBindVertexArray; 277 interface->fBindVertexArray = nullGLBindVertexArray;
277 interface->fBlendColor = noOpGLBlendColor; 278 interface->fBlendColor = noOpGLBlendColor;
278 interface->fBlendFunc = noOpGLBlendFunc; 279 interface->fBlendFunc = noOpGLBlendFunc;
279 interface->fBufferData = nullGLBufferData; 280 interface->fBufferData = nullGLBufferData;
280 interface->fBufferSubData = noOpGLBufferSubData; 281 interface->fBufferSubData = noOpGLBufferSubData;
281 interface->fClear = noOpGLClear; 282 interface->fClear = noOpGLClear;
282 interface->fClearColor = noOpGLClearColor; 283 interface->fClearColor = noOpGLClearColor;
283 interface->fClearStencil = noOpGLClearStencil; 284 interface->fClearStencil = noOpGLClearStencil;
285 interface->fClientActiveTexture = nullGLClientActiveTexture;
284 interface->fColorMask = noOpGLColorMask; 286 interface->fColorMask = noOpGLColorMask;
285 interface->fCompileShader = noOpGLCompileShader; 287 interface->fCompileShader = noOpGLCompileShader;
286 interface->fCompressedTexImage2D = noOpGLCompressedTexImage2D; 288 interface->fCompressedTexImage2D = noOpGLCompressedTexImage2D;
287 interface->fCopyTexSubImage2D = noOpGLCopyTexSubImage2D; 289 interface->fCopyTexSubImage2D = noOpGLCopyTexSubImage2D;
288 interface->fCreateProgram = nullGLCreateProgram; 290 interface->fCreateProgram = nullGLCreateProgram;
289 interface->fCreateShader = nullGLCreateShader; 291 interface->fCreateShader = nullGLCreateShader;
290 interface->fCullFace = noOpGLCullFace; 292 interface->fCullFace = noOpGLCullFace;
291 interface->fDeleteBuffers = nullGLDeleteBuffers; 293 interface->fDeleteBuffers = nullGLDeleteBuffers;
292 interface->fDeleteProgram = nullGLDelete; 294 interface->fDeleteProgram = nullGLDelete;
293 interface->fDeleteQueries = noOpGLDeleteIds; 295 interface->fDeleteQueries = noOpGLDeleteIds;
294 interface->fDeleteShader = nullGLDelete; 296 interface->fDeleteShader = nullGLDelete;
295 interface->fDeleteTextures = noOpGLDeleteIds; 297 interface->fDeleteTextures = noOpGLDeleteIds;
296 interface->fDeleteVertexArrays = noOpGLDeleteIds; 298 interface->fDeleteVertexArrays = noOpGLDeleteIds;
297 interface->fDepthMask = noOpGLDepthMask; 299 interface->fDepthMask = noOpGLDepthMask;
298 interface->fDisable = noOpGLDisable; 300 interface->fDisable = noOpGLDisable;
301 interface->fDisableClientState = noOpGLDisableClientState;
299 interface->fDisableVertexAttribArray = noOpGLDisableVertexAttribArray; 302 interface->fDisableVertexAttribArray = noOpGLDisableVertexAttribArray;
300 interface->fDrawArrays = noOpGLDrawArrays; 303 interface->fDrawArrays = noOpGLDrawArrays;
301 interface->fDrawBuffer = noOpGLDrawBuffer; 304 interface->fDrawBuffer = noOpGLDrawBuffer;
302 interface->fDrawBuffers = noOpGLDrawBuffers; 305 interface->fDrawBuffers = noOpGLDrawBuffers;
303 interface->fDrawElements = noOpGLDrawElements; 306 interface->fDrawElements = noOpGLDrawElements;
304 interface->fEnable = noOpGLEnable; 307 interface->fEnable = noOpGLEnable;
308 interface->fEnableClientState = noOpGLEnableClientState;
305 interface->fEnableVertexAttribArray = noOpGLEnableVertexAttribArray; 309 interface->fEnableVertexAttribArray = noOpGLEnableVertexAttribArray;
306 interface->fEndQuery = noOpGLEndQuery; 310 interface->fEndQuery = noOpGLEndQuery;
307 interface->fFinish = noOpGLFinish; 311 interface->fFinish = noOpGLFinish;
308 interface->fFlush = noOpGLFlush; 312 interface->fFlush = noOpGLFlush;
309 interface->fFrontFace = noOpGLFrontFace; 313 interface->fFrontFace = noOpGLFrontFace;
310 interface->fGenBuffers = nullGLGenBuffers; 314 interface->fGenBuffers = nullGLGenBuffers;
311 interface->fGenerateMipmap = nullGLGenerateMipmap; 315 interface->fGenerateMipmap = nullGLGenerateMipmap;
312 interface->fGenQueries = noOpGLGenIds; 316 interface->fGenQueries = noOpGLGenIds;
313 interface->fGenTextures = noOpGLGenIds; 317 interface->fGenTextures = noOpGLGenIds;
314 interface->fGenVertexArrays = noOpGLGenIds; 318 interface->fGenVertexArrays = noOpGLGenIds;
315 interface->fGetBufferParameteriv = nullGLGetBufferParameteriv; 319 interface->fGetBufferParameteriv = nullGLGetBufferParameteriv;
316 interface->fGetError = noOpGLGetError; 320 interface->fGetError = noOpGLGetError;
317 interface->fGetIntegerv = noOpGLGetIntegerv; 321 interface->fGetIntegerv = noOpGLGetIntegerv;
318 interface->fGetQueryObjecti64v = noOpGLGetQueryObjecti64v; 322 interface->fGetQueryObjecti64v = noOpGLGetQueryObjecti64v;
319 interface->fGetQueryObjectiv = noOpGLGetQueryObjectiv; 323 interface->fGetQueryObjectiv = noOpGLGetQueryObjectiv;
320 interface->fGetQueryObjectui64v = noOpGLGetQueryObjectui64v; 324 interface->fGetQueryObjectui64v = noOpGLGetQueryObjectui64v;
321 interface->fGetQueryObjectuiv = noOpGLGetQueryObjectuiv; 325 interface->fGetQueryObjectuiv = noOpGLGetQueryObjectuiv;
322 interface->fGetQueryiv = noOpGLGetQueryiv; 326 interface->fGetQueryiv = noOpGLGetQueryiv;
323 interface->fGetProgramInfoLog = noOpGLGetInfoLog; 327 interface->fGetProgramInfoLog = noOpGLGetInfoLog;
324 interface->fGetProgramiv = noOpGLGetShaderOrProgramiv; 328 interface->fGetProgramiv = noOpGLGetShaderOrProgramiv;
325 interface->fGetShaderInfoLog = noOpGLGetInfoLog; 329 interface->fGetShaderInfoLog = noOpGLGetInfoLog;
326 interface->fGetShaderiv = noOpGLGetShaderOrProgramiv; 330 interface->fGetShaderiv = noOpGLGetShaderOrProgramiv;
327 interface->fGetString = noOpGLGetString; 331 interface->fGetString = noOpGLGetString;
328 interface->fGetStringi = noOpGLGetStringi; 332 interface->fGetStringi = noOpGLGetStringi;
329 interface->fGetTexLevelParameteriv = noOpGLGetTexLevelParameteriv; 333 interface->fGetTexLevelParameteriv = noOpGLGetTexLevelParameteriv;
330 interface->fGetUniformLocation = noOpGLGetUniformLocation; 334 interface->fGetUniformLocation = noOpGLGetUniformLocation;
335 interface->fLoadIdentity = noOpGLLoadIdentity;
336 interface->fLoadMatrixf = noOpGLLoadMatrixf;
331 interface->fLineWidth = noOpGLLineWidth; 337 interface->fLineWidth = noOpGLLineWidth;
332 interface->fLinkProgram = noOpGLLinkProgram; 338 interface->fLinkProgram = noOpGLLinkProgram;
339 interface->fMatrixMode = noOpGLMatrixMode;
333 interface->fPixelStorei = nullGLPixelStorei; 340 interface->fPixelStorei = nullGLPixelStorei;
334 interface->fQueryCounter = noOpGLQueryCounter; 341 interface->fQueryCounter = noOpGLQueryCounter;
335 interface->fReadBuffer = noOpGLReadBuffer; 342 interface->fReadBuffer = noOpGLReadBuffer;
336 interface->fReadPixels = nullGLReadPixels; 343 interface->fReadPixels = nullGLReadPixels;
337 interface->fScissor = noOpGLScissor; 344 interface->fScissor = noOpGLScissor;
338 interface->fShaderSource = noOpGLShaderSource; 345 interface->fShaderSource = noOpGLShaderSource;
339 interface->fStencilFunc = noOpGLStencilFunc; 346 interface->fStencilFunc = noOpGLStencilFunc;
340 interface->fStencilFuncSeparate = noOpGLStencilFuncSeparate; 347 interface->fStencilFuncSeparate = noOpGLStencilFuncSeparate;
341 interface->fStencilMask = noOpGLStencilMask; 348 interface->fStencilMask = noOpGLStencilMask;
342 interface->fStencilMaskSeparate = noOpGLStencilMaskSeparate; 349 interface->fStencilMaskSeparate = noOpGLStencilMaskSeparate;
343 interface->fStencilOp = noOpGLStencilOp; 350 interface->fStencilOp = noOpGLStencilOp;
344 interface->fStencilOpSeparate = noOpGLStencilOpSeparate; 351 interface->fStencilOpSeparate = noOpGLStencilOpSeparate;
352 interface->fTexGenf = noOpGLTexGenf;
353 interface->fTexGenfv = noOpGLTexGenfv;
354 interface->fTexGeni = noOpGLTexGeni;
345 interface->fTexImage2D = noOpGLTexImage2D; 355 interface->fTexImage2D = noOpGLTexImage2D;
346 interface->fTexParameteri = noOpGLTexParameteri; 356 interface->fTexParameteri = noOpGLTexParameteri;
347 interface->fTexParameteriv = noOpGLTexParameteriv; 357 interface->fTexParameteriv = noOpGLTexParameteriv;
348 interface->fTexSubImage2D = noOpGLTexSubImage2D; 358 interface->fTexSubImage2D = noOpGLTexSubImage2D;
349 interface->fTexStorage2D = noOpGLTexStorage2D; 359 interface->fTexStorage2D = noOpGLTexStorage2D;
350 interface->fDiscardFramebuffer = noOpGLDiscardFramebuffer; 360 interface->fDiscardFramebuffer = noOpGLDiscardFramebuffer;
351 interface->fUniform1f = noOpGLUniform1f; 361 interface->fUniform1f = noOpGLUniform1f;
352 interface->fUniform1i = noOpGLUniform1i; 362 interface->fUniform1i = noOpGLUniform1i;
353 interface->fUniform1fv = noOpGLUniform1fv; 363 interface->fUniform1fv = noOpGLUniform1fv;
354 interface->fUniform1iv = noOpGLUniform1iv; 364 interface->fUniform1iv = noOpGLUniform1iv;
355 interface->fUniform2f = noOpGLUniform2f; 365 interface->fUniform2f = noOpGLUniform2f;
356 interface->fUniform2i = noOpGLUniform2i; 366 interface->fUniform2i = noOpGLUniform2i;
357 interface->fUniform2fv = noOpGLUniform2fv; 367 interface->fUniform2fv = noOpGLUniform2fv;
358 interface->fUniform2iv = noOpGLUniform2iv; 368 interface->fUniform2iv = noOpGLUniform2iv;
359 interface->fUniform3f = noOpGLUniform3f; 369 interface->fUniform3f = noOpGLUniform3f;
360 interface->fUniform3i = noOpGLUniform3i; 370 interface->fUniform3i = noOpGLUniform3i;
361 interface->fUniform3fv = noOpGLUniform3fv; 371 interface->fUniform3fv = noOpGLUniform3fv;
362 interface->fUniform3iv = noOpGLUniform3iv; 372 interface->fUniform3iv = noOpGLUniform3iv;
363 interface->fUniform4f = noOpGLUniform4f; 373 interface->fUniform4f = noOpGLUniform4f;
364 interface->fUniform4i = noOpGLUniform4i; 374 interface->fUniform4i = noOpGLUniform4i;
365 interface->fUniform4fv = noOpGLUniform4fv; 375 interface->fUniform4fv = noOpGLUniform4fv;
366 interface->fUniform4iv = noOpGLUniform4iv; 376 interface->fUniform4iv = noOpGLUniform4iv;
367 interface->fUniformMatrix2fv = noOpGLUniformMatrix2fv; 377 interface->fUniformMatrix2fv = noOpGLUniformMatrix2fv;
368 interface->fUniformMatrix3fv = noOpGLUniformMatrix3fv; 378 interface->fUniformMatrix3fv = noOpGLUniformMatrix3fv;
369 interface->fUniformMatrix4fv = noOpGLUniformMatrix4fv; 379 interface->fUniformMatrix4fv = noOpGLUniformMatrix4fv;
370 interface->fUseProgram = nullGLUseProgram; 380 interface->fUseProgram = nullGLUseProgram;
371 interface->fVertexAttrib4fv = noOpGLVertexAttrib4fv; 381 interface->fVertexAttrib4fv = noOpGLVertexAttrib4fv;
372 interface->fVertexAttribPointer = noOpGLVertexAttribPointer; 382 interface->fVertexAttribPointer = noOpGLVertexAttribPointer;
383 interface->fVertexPointer = noOpGLVertexPointer;
373 interface->fViewport = nullGLViewport; 384 interface->fViewport = nullGLViewport;
374 interface->fBindFramebuffer = nullGLBindFramebuffer; 385 interface->fBindFramebuffer = nullGLBindFramebuffer;
375 interface->fBindRenderbuffer = nullGLBindRenderbuffer; 386 interface->fBindRenderbuffer = nullGLBindRenderbuffer;
376 interface->fCheckFramebufferStatus = noOpGLCheckFramebufferStatus; 387 interface->fCheckFramebufferStatus = noOpGLCheckFramebufferStatus;
377 interface->fDeleteFramebuffers = nullGLDeleteFramebuffers; 388 interface->fDeleteFramebuffers = nullGLDeleteFramebuffers;
378 interface->fDeleteRenderbuffers = nullGLDeleteRenderbuffers; 389 interface->fDeleteRenderbuffers = nullGLDeleteRenderbuffers;
379 interface->fFramebufferRenderbuffer = nullGLFramebufferRenderbuffer; 390 interface->fFramebufferRenderbuffer = nullGLFramebufferRenderbuffer;
380 interface->fFramebufferTexture2D = nullGLFramebufferTexture2D; 391 interface->fFramebufferTexture2D = nullGLFramebufferTexture2D;
381 interface->fGenFramebuffers = noOpGLGenIds; 392 interface->fGenFramebuffers = noOpGLGenIds;
382 interface->fGenRenderbuffers = noOpGLGenIds; 393 interface->fGenRenderbuffers = noOpGLGenIds;
383 interface->fGetFramebufferAttachmentParameteriv = noOpGLGetFramebufferAt tachmentParameteriv; 394 interface->fGetFramebufferAttachmentParameteriv = noOpGLGetFramebufferAt tachmentParameteriv;
384 interface->fGetRenderbufferParameteriv = noOpGLGetRenderbufferParameteri v; 395 interface->fGetRenderbufferParameteriv = noOpGLGetRenderbufferParameteri v;
385 interface->fRenderbufferStorage = noOpGLRenderbufferStorage; 396 interface->fRenderbufferStorage = noOpGLRenderbufferStorage;
386 interface->fRenderbufferStorageMultisample = noOpGLRenderbufferStorageMu ltisample; 397 interface->fRenderbufferStorageMultisample = noOpGLRenderbufferStorageMu ltisample;
387 interface->fBlitFramebuffer = noOpGLBlitFramebuffer; 398 interface->fBlitFramebuffer = noOpGLBlitFramebuffer;
388 interface->fResolveMultisampleFramebuffer = noOpGLResolveMultisampleFram ebuffer; 399 interface->fResolveMultisampleFramebuffer = noOpGLResolveMultisampleFram ebuffer;
389 interface->fMapBuffer = nullGLMapBuffer; 400 interface->fMapBuffer = nullGLMapBuffer;
390 interface->fUnmapBuffer = nullGLUnmapBuffer; 401 interface->fUnmapBuffer = nullGLUnmapBuffer;
391 interface->fBindFragDataLocationIndexed = noOpGLBindFragDataLocationInde xed; 402 interface->fBindFragDataLocationIndexed = noOpGLBindFragDataLocationInde xed;
392 } 403 }
393 glInterface.get()->ref(); 404 glInterface.get()->ref();
394 return glInterface.get(); 405 return glInterface.get();
395 } 406 }
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | src/gpu/gl/GrGLDefines.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698