| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <stdint.h> | 6 #include <stdint.h> |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 #include <string.h> | 8 #include <string.h> |
| 9 #include <cmath> | 9 #include <cmath> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 attributes.sample_buffers = 1; | 66 attributes.sample_buffers = 1; |
| 67 attributes.bind_generates_resource = false; | 67 attributes.bind_generates_resource = false; |
| 68 | 68 |
| 69 context_.reset(gpu::GLInProcessContext::Create( | 69 context_.reset(gpu::GLInProcessContext::Create( |
| 70 nullptr, /* service */ | 70 nullptr, /* service */ |
| 71 nullptr, /* surface */ | 71 nullptr, /* surface */ |
| 72 true, /* offscreen */ | 72 true, /* offscreen */ |
| 73 gfx::kNullAcceleratedWidget, /* window */ | 73 gfx::kNullAcceleratedWidget, /* window */ |
| 74 gfx::Size(1, 1), /* size */ | 74 gfx::Size(1, 1), /* size */ |
| 75 nullptr, /* share_context */ | 75 nullptr, /* share_context */ |
| 76 true, /* use_global_share_group */ | |
| 77 attributes, gfx::PreferDiscreteGpu, | 76 attributes, gfx::PreferDiscreteGpu, |
| 78 ::gpu::GLInProcessContextSharedMemoryLimits(), | 77 ::gpu::GLInProcessContextSharedMemoryLimits(), |
| 79 nullptr, /* gpu_memory_buffer_manager */ | 78 nullptr, /* gpu_memory_buffer_manager */ |
| 80 nullptr /* image_factory */)); | 79 nullptr /* image_factory */)); |
| 81 gl_ = context_->GetImplementation(); | 80 gl_ = context_->GetImplementation(); |
| 82 gpu::ContextSupport* support = context_->GetImplementation(); | 81 gpu::ContextSupport* support = context_->GetImplementation(); |
| 83 | 82 |
| 84 helper_.reset(new content::GLHelper(gl_, support)); | 83 helper_.reset(new content::GLHelper(gl_, support)); |
| 85 helper_scaling_.reset(new content::GLHelperScaling(gl_, helper_.get())); | 84 helper_scaling_.reset(new content::GLHelperScaling(gl_, helper_.get())); |
| 86 } | 85 } |
| (...skipping 1733 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1820 } | 1819 } |
| 1821 } | 1820 } |
| 1822 } | 1821 } |
| 1823 | 1822 |
| 1824 TEST_F(GLHelperTest, CheckOptimizations) { | 1823 TEST_F(GLHelperTest, CheckOptimizations) { |
| 1825 // Test in baseclass since it is friends with GLHelperScaling | 1824 // Test in baseclass since it is friends with GLHelperScaling |
| 1826 CheckOptimizationsTest(); | 1825 CheckOptimizationsTest(); |
| 1827 } | 1826 } |
| 1828 | 1827 |
| 1829 } // namespace content | 1828 } // namespace content |
| OLD | NEW |