| OLD | NEW |
| 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 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 GLES2DecoderPassthroughImpl class. | 5 // This file contains the GLES2DecoderPassthroughImpl class. |
| 6 | 6 |
| 7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
| 8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
| 9 | 9 |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 242 | 242 |
| 243 // Returns true if the context was lost specifically by GL_ARB_robustness. | 243 // Returns true if the context was lost specifically by GL_ARB_robustness. |
| 244 bool WasContextLostByRobustnessExtension() const override; | 244 bool WasContextLostByRobustnessExtension() const override; |
| 245 | 245 |
| 246 // Lose this context. | 246 // Lose this context. |
| 247 void MarkContextLost(error::ContextLostReason reason) override; | 247 void MarkContextLost(error::ContextLostReason reason) override; |
| 248 | 248 |
| 249 Logger* GetLogger() override; | 249 Logger* GetLogger() override; |
| 250 | 250 |
| 251 const ContextState* GetContextState() override; | 251 const ContextState* GetContextState() override; |
| 252 scoped_refptr<ShaderTranslatorInterface> GetTranslator( | 252 scoped_refptr<ShaderTranslatorInterface> GetTranslator(GLenum type) override; |
| 253 GLenum type) const override; | |
| 254 | 253 |
| 255 private: | 254 private: |
| 256 void* GetScratchMemory(size_t size); | 255 void* GetScratchMemory(size_t size); |
| 257 | 256 |
| 258 template <typename T> | 257 template <typename T> |
| 259 T* GetTypedScratchMemory(size_t count) { | 258 T* GetTypedScratchMemory(size_t count) { |
| 260 return reinterpret_cast<T*>(GetScratchMemory(count * sizeof(T))); | 259 return reinterpret_cast<T*>(GetScratchMemory(count * sizeof(T))); |
| 261 } | 260 } |
| 262 | 261 |
| 263 template <typename T, typename GLGetFunction> | 262 template <typename T, typename GLGetFunction> |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 400 | 399 |
| 401 // Include the prototypes of all the doer functions from a separate header to | 400 // Include the prototypes of all the doer functions from a separate header to |
| 402 // keep this file clean. | 401 // keep this file clean. |
| 403 #include "gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototyp
es.h" | 402 #include "gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototyp
es.h" |
| 404 }; | 403 }; |
| 405 | 404 |
| 406 } // namespace gles2 | 405 } // namespace gles2 |
| 407 } // namespace gpu | 406 } // namespace gpu |
| 408 | 407 |
| 409 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 408 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
| OLD | NEW |