| 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 #include "gpu/blink/webgraphicscontext3d_impl.h" | 5 #include "gpu/blink/webgraphicscontext3d_impl.h" |
| 6 | 6 |
| 7 #include "base/atomicops.h" | 7 #include "base/atomicops.h" |
| 8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "gpu/GLES2/gl2extchromium.h" | 10 #include "gpu/GLES2/gl2extchromium.h" |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 } // namespace anonymous | 34 } // namespace anonymous |
| 35 | 35 |
| 36 class WebGraphicsContext3DErrorMessageCallback | 36 class WebGraphicsContext3DErrorMessageCallback |
| 37 : public ::gpu::gles2::GLES2ImplementationErrorMessageCallback { | 37 : public ::gpu::gles2::GLES2ImplementationErrorMessageCallback { |
| 38 public: | 38 public: |
| 39 WebGraphicsContext3DErrorMessageCallback( | 39 WebGraphicsContext3DErrorMessageCallback( |
| 40 WebGraphicsContext3DImpl* context) | 40 WebGraphicsContext3DImpl* context) |
| 41 : graphics_context_(context) { | 41 : graphics_context_(context) { |
| 42 } | 42 } |
| 43 | 43 |
| 44 virtual void OnErrorMessage(const char* msg, int id) override; | 44 void OnErrorMessage(const char* msg, int id) override; |
| 45 | 45 |
| 46 private: | 46 private: |
| 47 WebGraphicsContext3DImpl* graphics_context_; | 47 WebGraphicsContext3DImpl* graphics_context_; |
| 48 | 48 |
| 49 DISALLOW_COPY_AND_ASSIGN(WebGraphicsContext3DErrorMessageCallback); | 49 DISALLOW_COPY_AND_ASSIGN(WebGraphicsContext3DErrorMessageCallback); |
| 50 }; | 50 }; |
| 51 | 51 |
| 52 void WebGraphicsContext3DErrorMessageCallback::OnErrorMessage( | 52 void WebGraphicsContext3DErrorMessageCallback::OnErrorMessage( |
| 53 const char* msg, int id) { | 53 const char* msg, int id) { |
| 54 graphics_context_->OnErrorMessage(msg, id); | 54 graphics_context_->OnErrorMessage(msg, id); |
| (...skipping 966 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1021 output_attribs->depth_size = attributes.depth ? 24 : 0; | 1021 output_attribs->depth_size = attributes.depth ? 24 : 0; |
| 1022 output_attribs->stencil_size = attributes.stencil ? 8 : 0; | 1022 output_attribs->stencil_size = attributes.stencil ? 8 : 0; |
| 1023 output_attribs->samples = attributes.antialias ? 4 : 0; | 1023 output_attribs->samples = attributes.antialias ? 4 : 0; |
| 1024 output_attribs->sample_buffers = attributes.antialias ? 1 : 0; | 1024 output_attribs->sample_buffers = attributes.antialias ? 1 : 0; |
| 1025 output_attribs->fail_if_major_perf_caveat = | 1025 output_attribs->fail_if_major_perf_caveat = |
| 1026 attributes.failIfMajorPerformanceCaveat; | 1026 attributes.failIfMajorPerformanceCaveat; |
| 1027 output_attribs->bind_generates_resource = false; | 1027 output_attribs->bind_generates_resource = false; |
| 1028 } | 1028 } |
| 1029 | 1029 |
| 1030 } // namespace gpu_blink | 1030 } // namespace gpu_blink |
| OLD | NEW |