Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: ui/ozone/platform/drm/gpu/drm_thread.cc

Issue 2568243004: ozone: Remove USE_LINEAR when allocating modeset buffers. (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "ui/ozone/platform/drm/gpu/drm_thread.h" 5 #include "ui/ozone/platform/drm/gpu/drm_thread.h"
6 6
7 #include <gbm.h> 7 #include <gbm.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 22 matching lines...) Expand all
33 class GbmBufferGenerator : public ScanoutBufferGenerator { 33 class GbmBufferGenerator : public ScanoutBufferGenerator {
34 public: 34 public:
35 GbmBufferGenerator() {} 35 GbmBufferGenerator() {}
36 ~GbmBufferGenerator() override {} 36 ~GbmBufferGenerator() override {}
37 37
38 // ScanoutBufferGenerator: 38 // ScanoutBufferGenerator:
39 scoped_refptr<ScanoutBuffer> Create(const scoped_refptr<DrmDevice>& drm, 39 scoped_refptr<ScanoutBuffer> Create(const scoped_refptr<DrmDevice>& drm,
40 uint32_t format, 40 uint32_t format,
41 const gfx::Size& size) override { 41 const gfx::Size& size) override {
42 scoped_refptr<GbmDevice> gbm(static_cast<GbmDevice*>(drm.get())); 42 scoped_refptr<GbmDevice> gbm(static_cast<GbmDevice*>(drm.get()));
43 return GbmBuffer::CreateBuffer(gbm, format, size, 43 // TODO(dcastagna): Use GBM_BO_USE_MAP modifier once minigbm exposes it.
44 GBM_BO_USE_SCANOUT | GBM_BO_USE_LINEAR); 44 return GbmBuffer::CreateBuffer(gbm, format, size, GBM_BO_USE_SCANOUT);
45 } 45 }
46 46
47 protected: 47 protected:
48 DISALLOW_COPY_AND_ASSIGN(GbmBufferGenerator); 48 DISALLOW_COPY_AND_ASSIGN(GbmBufferGenerator);
49 }; 49 };
50 50
51 class GbmDeviceGenerator : public DrmDeviceGenerator { 51 class GbmDeviceGenerator : public DrmDeviceGenerator {
52 public: 52 public:
53 GbmDeviceGenerator(bool use_atomic) : use_atomic_(use_atomic) {} 53 GbmDeviceGenerator(bool use_atomic) : use_atomic_(use_atomic) {}
54 ~GbmDeviceGenerator() override {} 54 ~GbmDeviceGenerator() override {}
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 correction_matrix); 273 correction_matrix);
274 } 274 }
275 275
276 // DrmThread requires a BindingSet instead of a simple Binding because it will 276 // DrmThread requires a BindingSet instead of a simple Binding because it will
277 // be used from multiple threads in multiple processes. 277 // be used from multiple threads in multiple processes.
278 void DrmThread::AddBinding(ozone::mojom::DeviceCursorRequest request) { 278 void DrmThread::AddBinding(ozone::mojom::DeviceCursorRequest request) {
279 bindings_.AddBinding(this, std::move(request)); 279 bindings_.AddBinding(this, std::move(request));
280 } 280 }
281 281
282 } // namespace ui 282 } // namespace ui
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698