OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 | 5 |
6 #include "ui/gfx/gl/gl_bindings_skia_in_process.h" | 6 #include "ui/gfx/gl/gl_bindings_skia_in_process.h" |
7 | 7 |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "ui/gfx/gl/gl_bindings.h" | 9 #include "ui/gfx/gl/gl_bindings.h" |
10 #include "ui/gfx/gl/gl_implementation.h" | 10 #include "ui/gfx/gl/gl_implementation.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 | 28 |
29 GLvoid StubGLBindAttribLocation(GLuint program, GLuint index, | 29 GLvoid StubGLBindAttribLocation(GLuint program, GLuint index, |
30 const char* name) { | 30 const char* name) { |
31 glBindAttribLocation(program, index, name); | 31 glBindAttribLocation(program, index, name); |
32 } | 32 } |
33 | 33 |
34 GLvoid StubGLBindBuffer(GLenum target, GLuint buffer) { | 34 GLvoid StubGLBindBuffer(GLenum target, GLuint buffer) { |
35 glBindBuffer(target, buffer); | 35 glBindBuffer(target, buffer); |
36 } | 36 } |
37 | 37 |
38 GLvoid StubBindFragDataLocationIndexedARB(GLuint program, GLuint colorNumber, | 38 GLvoid StubGLBindFragDataLocation(GLuint program, GLuint colorNumber, |
39 GLuint index, const GLchar * name) { | 39 const GLchar * name) { |
| 40 glBindFragDataLocation(program, colorNumber, name); |
| 41 } |
| 42 |
| 43 GLvoid StubGLBindFragDataLocationIndexedARB(GLuint program, GLuint colorNumber, |
| 44 GLuint index, const GLchar * name) { |
40 glBindFragDataLocationIndexedARB(program, colorNumber, index, name); | 45 glBindFragDataLocationIndexedARB(program, colorNumber, index, name); |
41 } | 46 } |
42 | 47 |
43 GLvoid StubGLBindFramebuffer(GLenum target, GLuint framebuffer) { | 48 GLvoid StubGLBindFramebuffer(GLenum target, GLuint framebuffer) { |
44 glBindFramebufferEXT(target, framebuffer); | 49 glBindFramebufferEXT(target, framebuffer); |
45 } | 50 } |
46 | 51 |
47 GLvoid StubGLBindRenderbuffer(GLenum target, GLuint renderbuffer) { | 52 GLvoid StubGLBindRenderbuffer(GLenum target, GLuint renderbuffer) { |
48 glBindRenderbufferEXT(target, renderbuffer); | 53 glBindRenderbufferEXT(target, renderbuffer); |
49 } | 54 } |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 return NULL; | 497 return NULL; |
493 } | 498 } |
494 | 499 |
495 GrGLInterface* interface = new GrGLInterface; | 500 GrGLInterface* interface = new GrGLInterface; |
496 | 501 |
497 interface->fBindingsExported = binding; | 502 interface->fBindingsExported = binding; |
498 interface->fActiveTexture = StubGLActiveTexture; | 503 interface->fActiveTexture = StubGLActiveTexture; |
499 interface->fAttachShader = StubGLAttachShader; | 504 interface->fAttachShader = StubGLAttachShader; |
500 interface->fBindAttribLocation = StubGLBindAttribLocation; | 505 interface->fBindAttribLocation = StubGLBindAttribLocation; |
501 interface->fBindBuffer = StubGLBindBuffer; | 506 interface->fBindBuffer = StubGLBindBuffer; |
| 507 interface->fBindFragDataLocation = StubGLBindFragDataLocation; |
502 interface->fBindTexture = StubGLBindTexture; | 508 interface->fBindTexture = StubGLBindTexture; |
503 interface->fBlendColor = StubGLBlendColor; | 509 interface->fBlendColor = StubGLBlendColor; |
504 interface->fBlendFunc = StubGLBlendFunc; | 510 interface->fBlendFunc = StubGLBlendFunc; |
505 interface->fBufferData = StubGLBufferData; | 511 interface->fBufferData = StubGLBufferData; |
506 interface->fBufferSubData = StubGLBufferSubData; | 512 interface->fBufferSubData = StubGLBufferSubData; |
507 interface->fClear = StubGLClear; | 513 interface->fClear = StubGLClear; |
508 interface->fClearColor = StubGLClearColor; | 514 interface->fClearColor = StubGLClearColor; |
509 interface->fClearStencil = StubGLClearStencil; | 515 interface->fClearStencil = StubGLClearStencil; |
510 interface->fColorMask = StubGLColorMask; | 516 interface->fColorMask = StubGLColorMask; |
511 interface->fCompileShader = StubGLCompileShader; | 517 interface->fCompileShader = StubGLCompileShader; |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
590 interface->fGetFramebufferAttachmentParameteriv = | 596 interface->fGetFramebufferAttachmentParameteriv = |
591 StubGLGetFramebufferAttachmentParameteriv; | 597 StubGLGetFramebufferAttachmentParameteriv; |
592 interface->fGetRenderbufferParameteriv = StubGLGetRenderbufferParameteriv; | 598 interface->fGetRenderbufferParameteriv = StubGLGetRenderbufferParameteriv; |
593 interface->fRenderbufferStorage = StubGLRenderbufferStorage; | 599 interface->fRenderbufferStorage = StubGLRenderbufferStorage; |
594 interface->fRenderbufferStorageMultisample = | 600 interface->fRenderbufferStorageMultisample = |
595 StubGLRenderbufferStorageMultisample; | 601 StubGLRenderbufferStorageMultisample; |
596 interface->fBlitFramebuffer = StubGLBlitFramebuffer; | 602 interface->fBlitFramebuffer = StubGLBlitFramebuffer; |
597 interface->fMapBuffer = StubGLMapBuffer; | 603 interface->fMapBuffer = StubGLMapBuffer; |
598 interface->fUnmapBuffer = StubGLUnmapBuffer; | 604 interface->fUnmapBuffer = StubGLUnmapBuffer; |
599 interface->fBindFragDataLocationIndexed = | 605 interface->fBindFragDataLocationIndexed = |
600 StubBindFragDataLocationIndexedARB; | 606 StubGLBindFragDataLocationIndexedARB; |
601 return interface; | 607 return interface; |
602 } | 608 } |
603 | 609 |
604 } // namespace gfx | 610 } // namespace gfx |
605 | 611 |
OLD | NEW |