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