| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 822 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 833 enum TexImageByGPUType { | 833 enum TexImageByGPUType { |
| 834 TexImage2DByGPU, | 834 TexImage2DByGPU, |
| 835 TexSubImage2DByGPU, | 835 TexSubImage2DByGPU, |
| 836 TexSubImage3DByGPU | 836 TexSubImage3DByGPU |
| 837 }; | 837 }; |
| 838 // Copy from the canvas element directly to the texture via the GPU, without
a read-back to system memory. | 838 // Copy from the canvas element directly to the texture via the GPU, without
a read-back to system memory. |
| 839 void texImageCanvasByGPU(TexImageByGPUType, WebGLTexture*, GLenum target, GL
int level, | 839 void texImageCanvasByGPU(TexImageByGPUType, WebGLTexture*, GLenum target, GL
int level, |
| 840 GLenum internalformat, GLenum type, GLint xoffset, GLint yoffset, GLint
zoffset, HTMLCanvasElement*); | 840 GLenum internalformat, GLenum type, GLint xoffset, GLint yoffset, GLint
zoffset, HTMLCanvasElement*); |
| 841 bool canUseTexImageCanvasByGPU(GLenum internalformat, GLenum type); | 841 bool canUseTexImageCanvasByGPU(GLenum internalformat, GLenum type); |
| 842 | 842 |
| 843 bool texImage2DVideoByGPU(TexImageFunctionType, WebGLTexture*, GLenum target
, GLint level, | |
| 844 GLenum internalformat, GLenum type, GLint xoffset, GLint yoffset, HTMLVi
deoElement*); | |
| 845 | |
| 846 void handleTextureCompleteness(const char*, bool); | 843 void handleTextureCompleteness(const char*, bool); |
| 847 void createFallbackBlackTextures1x1(); | 844 void createFallbackBlackTextures1x1(); |
| 848 | 845 |
| 849 // Helper function for copyTex{Sub}Image, check whether the internalformat | 846 // Helper function for copyTex{Sub}Image, check whether the internalformat |
| 850 // and the color buffer format of the current bound framebuffer combination | 847 // and the color buffer format of the current bound framebuffer combination |
| 851 // is valid. | 848 // is valid. |
| 852 bool isTexInternalFormatColorBufferCombinationValid(GLenum texInternalFormat
, GLenum colorBufferFormat); | 849 bool isTexInternalFormatColorBufferCombinationValid(GLenum texInternalFormat
, GLenum colorBufferFormat); |
| 853 | 850 |
| 854 // Helper function to get the bound framebuffer's color buffer format. | 851 // Helper function to get the bound framebuffer's color buffer format. |
| 855 virtual GLenum boundFramebufferColorFormat(); | 852 virtual GLenum boundFramebufferColorFormat(); |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1133 static WebGLRenderingContextBase* oldestEvictedContext(); | 1130 static WebGLRenderingContextBase* oldestEvictedContext(); |
| 1134 }; | 1131 }; |
| 1135 | 1132 |
| 1136 DEFINE_TYPE_CASTS(WebGLRenderingContextBase, CanvasRenderingContext, context, co
ntext->is3d(), context.is3d()); | 1133 DEFINE_TYPE_CASTS(WebGLRenderingContextBase, CanvasRenderingContext, context, co
ntext->is3d(), context.is3d()); |
| 1137 | 1134 |
| 1138 } // namespace blink | 1135 } // namespace blink |
| 1139 | 1136 |
| 1140 WTF_ALLOW_MOVE_INIT_AND_COMPARE_WITH_MEM_FUNCTIONS(blink::WebGLRenderingContextB
ase::TextureUnitState); | 1137 WTF_ALLOW_MOVE_INIT_AND_COMPARE_WITH_MEM_FUNCTIONS(blink::WebGLRenderingContextB
ase::TextureUnitState); |
| 1141 | 1138 |
| 1142 #endif // WebGLRenderingContextBase_h | 1139 #endif // WebGLRenderingContextBase_h |
| OLD | NEW |