| OLD | NEW |
| 1 // Copyright 2010 The Chromium Authors. All rights reserved. | 1 // Copyright 2010 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 #ifndef CC_GL_RENDERER_H_ | 5 #ifndef CC_GL_RENDERER_H_ |
| 6 #define CC_GL_RENDERER_H_ | 6 #define CC_GL_RENDERER_H_ |
| 7 | 7 |
| 8 #include "cc/cc_export.h" | 8 #include "cc/cc_export.h" |
| 9 #include "cc/checkerboard_draw_quad.h" | 9 #include "cc/checkerboard_draw_quad.h" |
| 10 #include "cc/debug_border_draw_quad.h" | 10 #include "cc/debug_border_draw_quad.h" |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 // Texture shaders. | 161 // Texture shaders. |
| 162 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexVar
yingAlpha> TextureProgram; | 162 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexVar
yingAlpha> TextureProgram; |
| 163 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexFli
pVaryingAlpha> TextureProgramFlip; | 163 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexFli
pVaryingAlpha> TextureProgramFlip; |
| 164 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexRec
tVaryingAlpha> TextureIOSurfaceProgram; | 164 typedef ProgramBinding<VertexShaderPosTexTransform, FragmentShaderRGBATexRec
tVaryingAlpha> TextureIOSurfaceProgram; |
| 165 | 165 |
| 166 // Video shaders. | 166 // Video shaders. |
| 167 typedef ProgramBinding<VertexShaderVideoTransform, FragmentShaderOESImageExt
ernal> VideoStreamTextureProgram; | 167 typedef ProgramBinding<VertexShaderVideoTransform, FragmentShaderOESImageExt
ernal> VideoStreamTextureProgram; |
| 168 typedef ProgramBinding<VertexShaderPosTexYUVStretch, FragmentShaderYUVVideo>
VideoYUVProgram; | 168 typedef ProgramBinding<VertexShaderPosTexYUVStretch, FragmentShaderYUVVideo>
VideoYUVProgram; |
| 169 | 169 |
| 170 // Special purpose / effects shaders. | 170 // Special purpose / effects shaders. |
| 171 typedef ProgramBinding<VertexShaderPos, FragmentShaderColor> SolidColorProgr
am; | 171 typedef ProgramBinding<VertexShaderQuad, FragmentShaderColor> SolidColorProg
ram; |
| 172 typedef ProgramBinding<VertexShaderQuad, FragmentShaderColorAA> SolidColorPr
ogramAA; |
| 172 | 173 |
| 173 const TileProgram* tileProgram(); | 174 const TileProgram* tileProgram(); |
| 174 const TileProgramOpaque* tileProgramOpaque(); | 175 const TileProgramOpaque* tileProgramOpaque(); |
| 175 const TileProgramAA* tileProgramAA(); | 176 const TileProgramAA* tileProgramAA(); |
| 176 const TileProgramSwizzle* tileProgramSwizzle(); | 177 const TileProgramSwizzle* tileProgramSwizzle(); |
| 177 const TileProgramSwizzleOpaque* tileProgramSwizzleOpaque(); | 178 const TileProgramSwizzleOpaque* tileProgramSwizzleOpaque(); |
| 178 const TileProgramSwizzleAA* tileProgramSwizzleAA(); | 179 const TileProgramSwizzleAA* tileProgramSwizzleAA(); |
| 179 const TileCheckerboardProgram* tileCheckerboardProgram(); | 180 const TileCheckerboardProgram* tileCheckerboardProgram(); |
| 180 | 181 |
| 181 const RenderPassProgram* renderPassProgram(); | 182 const RenderPassProgram* renderPassProgram(); |
| 182 const RenderPassProgramAA* renderPassProgramAA(); | 183 const RenderPassProgramAA* renderPassProgramAA(); |
| 183 const RenderPassMaskProgram* renderPassMaskProgram(); | 184 const RenderPassMaskProgram* renderPassMaskProgram(); |
| 184 const RenderPassMaskProgramAA* renderPassMaskProgramAA(); | 185 const RenderPassMaskProgramAA* renderPassMaskProgramAA(); |
| 185 | 186 |
| 186 const TextureProgram* textureProgram(); | 187 const TextureProgram* textureProgram(); |
| 187 const TextureProgramFlip* textureProgramFlip(); | 188 const TextureProgramFlip* textureProgramFlip(); |
| 188 const TextureIOSurfaceProgram* textureIOSurfaceProgram(); | 189 const TextureIOSurfaceProgram* textureIOSurfaceProgram(); |
| 189 | 190 |
| 190 const VideoYUVProgram* videoYUVProgram(); | 191 const VideoYUVProgram* videoYUVProgram(); |
| 191 const VideoStreamTextureProgram* videoStreamTextureProgram(); | 192 const VideoStreamTextureProgram* videoStreamTextureProgram(); |
| 192 | 193 |
| 193 const SolidColorProgram* solidColorProgram(); | 194 const SolidColorProgram* solidColorProgram(); |
| 195 const SolidColorProgramAA* solidColorProgramAA(); |
| 194 | 196 |
| 195 scoped_ptr<TileProgram> m_tileProgram; | 197 scoped_ptr<TileProgram> m_tileProgram; |
| 196 scoped_ptr<TileProgramOpaque> m_tileProgramOpaque; | 198 scoped_ptr<TileProgramOpaque> m_tileProgramOpaque; |
| 197 scoped_ptr<TileProgramAA> m_tileProgramAA; | 199 scoped_ptr<TileProgramAA> m_tileProgramAA; |
| 198 scoped_ptr<TileProgramSwizzle> m_tileProgramSwizzle; | 200 scoped_ptr<TileProgramSwizzle> m_tileProgramSwizzle; |
| 199 scoped_ptr<TileProgramSwizzleOpaque> m_tileProgramSwizzleOpaque; | 201 scoped_ptr<TileProgramSwizzleOpaque> m_tileProgramSwizzleOpaque; |
| 200 scoped_ptr<TileProgramSwizzleAA> m_tileProgramSwizzleAA; | 202 scoped_ptr<TileProgramSwizzleAA> m_tileProgramSwizzleAA; |
| 201 scoped_ptr<TileCheckerboardProgram> m_tileCheckerboardProgram; | 203 scoped_ptr<TileCheckerboardProgram> m_tileCheckerboardProgram; |
| 202 | 204 |
| 203 scoped_ptr<RenderPassProgram> m_renderPassProgram; | 205 scoped_ptr<RenderPassProgram> m_renderPassProgram; |
| 204 scoped_ptr<RenderPassProgramAA> m_renderPassProgramAA; | 206 scoped_ptr<RenderPassProgramAA> m_renderPassProgramAA; |
| 205 scoped_ptr<RenderPassMaskProgram> m_renderPassMaskProgram; | 207 scoped_ptr<RenderPassMaskProgram> m_renderPassMaskProgram; |
| 206 scoped_ptr<RenderPassMaskProgramAA> m_renderPassMaskProgramAA; | 208 scoped_ptr<RenderPassMaskProgramAA> m_renderPassMaskProgramAA; |
| 207 | 209 |
| 208 scoped_ptr<TextureProgram> m_textureProgram; | 210 scoped_ptr<TextureProgram> m_textureProgram; |
| 209 scoped_ptr<TextureProgramFlip> m_textureProgramFlip; | 211 scoped_ptr<TextureProgramFlip> m_textureProgramFlip; |
| 210 scoped_ptr<TextureIOSurfaceProgram> m_textureIOSurfaceProgram; | 212 scoped_ptr<TextureIOSurfaceProgram> m_textureIOSurfaceProgram; |
| 211 | 213 |
| 212 scoped_ptr<VideoYUVProgram> m_videoYUVProgram; | 214 scoped_ptr<VideoYUVProgram> m_videoYUVProgram; |
| 213 scoped_ptr<VideoStreamTextureProgram> m_videoStreamTextureProgram; | 215 scoped_ptr<VideoStreamTextureProgram> m_videoStreamTextureProgram; |
| 214 | 216 |
| 215 scoped_ptr<SolidColorProgram> m_solidColorProgram; | 217 scoped_ptr<SolidColorProgram> m_solidColorProgram; |
| 218 scoped_ptr<SolidColorProgramAA> m_solidColorProgramAA; |
| 216 | 219 |
| 217 OutputSurface* m_outputSurface; | 220 OutputSurface* m_outputSurface; |
| 218 WebKit::WebGraphicsContext3D* m_context; | 221 WebKit::WebGraphicsContext3D* m_context; |
| 219 | 222 |
| 220 gfx::Rect m_swapBufferRect; | 223 gfx::Rect m_swapBufferRect; |
| 221 gfx::Rect m_scissorRect; | 224 gfx::Rect m_scissorRect; |
| 222 bool m_isViewportChanged; | 225 bool m_isViewportChanged; |
| 223 bool m_isBackbufferDiscarded; | 226 bool m_isBackbufferDiscarded; |
| 224 bool m_discardBackbufferWhenNotVisible; | 227 bool m_discardBackbufferWhenNotVisible; |
| 225 bool m_isUsingBindUniform; | 228 bool m_isUsingBindUniform; |
| (...skipping 17 matching lines...) Expand all Loading... |
| 243 #if DEBUG_GL_CALLS && !defined(NDEBUG) | 246 #if DEBUG_GL_CALLS && !defined(NDEBUG) |
| 244 #define GLC(context, x) (x, GLRenderer::debugGLCall(&*context, #x, __FILE__, __L
INE__)) | 247 #define GLC(context, x) (x, GLRenderer::debugGLCall(&*context, #x, __FILE__, __L
INE__)) |
| 245 #else | 248 #else |
| 246 #define GLC(context, x) (x) | 249 #define GLC(context, x) (x) |
| 247 #endif | 250 #endif |
| 248 | 251 |
| 249 | 252 |
| 250 } | 253 } |
| 251 | 254 |
| 252 #endif // CC_GL_RENDERER_H_ | 255 #endif // CC_GL_RENDERER_H_ |
| OLD | NEW |