| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // This file contains the GLES2Decoder class. | 5 // This file contains the GLES2Decoder class. |
| 6 | 6 |
| 7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ | 7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ |
| 8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ | 8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ |
| 9 | 9 |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 namespace gpu { | 27 namespace gpu { |
| 28 | 28 |
| 29 class AsyncPixelTransferDelegate; | 29 class AsyncPixelTransferDelegate; |
| 30 class AsyncPixelTransferManager; | 30 class AsyncPixelTransferManager; |
| 31 class StreamTextureManager; | 31 class StreamTextureManager; |
| 32 struct Mailbox; | 32 struct Mailbox; |
| 33 | 33 |
| 34 namespace gles2 { | 34 namespace gles2 { |
| 35 | 35 |
| 36 class ContextGroup; | 36 class ContextGroup; |
| 37 class ContextState; |
| 37 class ErrorState; | 38 class ErrorState; |
| 38 class GLES2Util; | 39 class GLES2Util; |
| 39 class Logger; | 40 class Logger; |
| 40 class QueryManager; | 41 class QueryManager; |
| 41 class VertexArrayManager; | 42 class VertexArrayManager; |
| 42 | 43 |
| 43 struct DisallowedFeatures { | 44 struct DisallowedFeatures { |
| 44 DisallowedFeatures() | 45 DisallowedFeatures() |
| 45 : multisampling(false), | 46 : multisampling(false), |
| 46 gpu_memory_manager(false) { | 47 gpu_memory_manager(false) { |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 | 134 |
| 134 // Gets the associated GLContext. | 135 // Gets the associated GLContext. |
| 135 virtual gfx::GLContext* GetGLContext() = 0; | 136 virtual gfx::GLContext* GetGLContext() = 0; |
| 136 | 137 |
| 137 // Gets the associated ContextGroup | 138 // Gets the associated ContextGroup |
| 138 virtual ContextGroup* GetContextGroup() = 0; | 139 virtual ContextGroup* GetContextGroup() = 0; |
| 139 | 140 |
| 140 virtual Capabilities GetCapabilities() = 0; | 141 virtual Capabilities GetCapabilities() = 0; |
| 141 | 142 |
| 142 // Restores all of the decoder GL state. | 143 // Restores all of the decoder GL state. |
| 143 virtual void RestoreState() const = 0; | 144 virtual void RestoreState(const ContextState* prev_state) const = 0; |
| 144 | 145 |
| 145 // Restore States. | 146 // Restore States. |
| 146 virtual void RestoreActiveTexture() const = 0; | 147 virtual void RestoreActiveTexture() const = 0; |
| 147 virtual void RestoreAllTextureUnitBindings() const = 0; | 148 virtual void RestoreAllTextureUnitBindings() const = 0; |
| 148 virtual void RestoreAttribute(unsigned index) const = 0; | 149 virtual void RestoreAttribute(unsigned index) const = 0; |
| 149 virtual void RestoreBufferBindings() const = 0; | 150 virtual void RestoreBufferBindings() const = 0; |
| 150 virtual void RestoreFramebufferBindings() const = 0; | 151 virtual void RestoreFramebufferBindings() const = 0; |
| 151 virtual void RestoreGlobalState() const = 0; | 152 virtual void RestoreGlobalState() const = 0; |
| 152 virtual void RestoreProgramBindings() const = 0; | 153 virtual void RestoreProgramBindings() const = 0; |
| 153 virtual void RestoreRenderbufferBindings() const = 0; | 154 virtual void RestoreRenderbufferBindings() const = 0; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 221 virtual bool WasContextLost() = 0; | 222 virtual bool WasContextLost() = 0; |
| 222 | 223 |
| 223 // Returns true if the context was lost specifically by GL_ARB_robustness. | 224 // Returns true if the context was lost specifically by GL_ARB_robustness. |
| 224 virtual bool WasContextLostByRobustnessExtension() = 0; | 225 virtual bool WasContextLostByRobustnessExtension() = 0; |
| 225 | 226 |
| 226 // Lose this context. | 227 // Lose this context. |
| 227 virtual void LoseContext(uint32 reset_status) = 0; | 228 virtual void LoseContext(uint32 reset_status) = 0; |
| 228 | 229 |
| 229 virtual Logger* GetLogger() = 0; | 230 virtual Logger* GetLogger() = 0; |
| 230 | 231 |
| 232 virtual const ContextState* GetContextState() = 0; |
| 233 |
| 231 protected: | 234 protected: |
| 232 GLES2Decoder(); | 235 GLES2Decoder(); |
| 233 | 236 |
| 234 private: | 237 private: |
| 235 bool initialized_; | 238 bool initialized_; |
| 236 bool debug_; | 239 bool debug_; |
| 237 bool log_commands_; | 240 bool log_commands_; |
| 238 | 241 |
| 239 DISALLOW_COPY_AND_ASSIGN(GLES2Decoder); | 242 DISALLOW_COPY_AND_ASSIGN(GLES2Decoder); |
| 240 }; | 243 }; |
| 241 | 244 |
| 242 } // namespace gles2 | 245 } // namespace gles2 |
| 243 } // namespace gpu | 246 } // namespace gpu |
| 247 |
| 244 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ | 248 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_H_ |
| OLD | NEW |