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

Side by Side Diff: ui/ozone/platform/drm/gpu/crtc_controller.h

Issue 2623963002: ozone: Allocate scanout buffers according to KMS modifiers. (Closed)
Patch Set: Remove unused modifier_. Created 3 years, 11 months 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 | ui/ozone/platform/drm/gpu/crtc_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_ 5 #ifndef UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_
6 #define UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_ 6 #define UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 #include <xf86drmMode.h> 10 #include <xf86drmMode.h>
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 // Schedule a page flip event and present the overlays in |planes|. 51 // Schedule a page flip event and present the overlays in |planes|.
52 bool SchedulePageFlip(HardwareDisplayPlaneList* plane_list, 52 bool SchedulePageFlip(HardwareDisplayPlaneList* plane_list,
53 const OverlayPlaneList& planes, 53 const OverlayPlaneList& planes,
54 bool test_only, 54 bool test_only,
55 scoped_refptr<PageFlipRequest> page_flip_request); 55 scoped_refptr<PageFlipRequest> page_flip_request);
56 56
57 // Returns true if hardware plane with z_order equal to |z_order| can support 57 // Returns true if hardware plane with z_order equal to |z_order| can support
58 // |fourcc_format| format. 58 // |fourcc_format| format.
59 bool IsFormatSupported(uint32_t fourcc_format, uint32_t z_order) const; 59 bool IsFormatSupported(uint32_t fourcc_format, uint32_t z_order) const;
60 60
61 // Returns a vector of format modifiers for the given fourcc format
62 // on this CRTCs primary plane. A format modifier describes the
63 // actual layout of the buffer, such as whether it's linear, tiled
64 // one way or another or maybe compressed. Except for generic
65 // modifiers such as DRM_FORMAT_MOD_NONE (linear), the modifier
66 // values are 64 bit values that we don't understand at this
67 // level. We pass the modifers to gbm_bo_create_with_modifiers() and
68 // gbm will pick a modifier as it allocates the bo.
69 std::vector<uint64_t> GetFormatModifiers(uint32_t fourcc_format);
70
61 // Called if the page flip event wasn't scheduled (ie: page flip fails). This 71 // Called if the page flip event wasn't scheduled (ie: page flip fails). This
62 // will then signal the request such that the caller doesn't wait for the 72 // will then signal the request such that the caller doesn't wait for the
63 // event forever. 73 // event forever.
64 void SignalPageFlipRequest(gfx::SwapResult result); 74 void SignalPageFlipRequest(gfx::SwapResult result);
65 75
66 // Called when the page flip event occurred. The event is provided by the 76 // Called when the page flip event occurred. The event is provided by the
67 // kernel when a VBlank event finished. This allows the controller to 77 // kernel when a VBlank event finished. This allows the controller to
68 // update internal state and propagate the update to the surface. 78 // update internal state and propagate the update to the surface.
69 // The tuple (seconds, useconds) represents the event timestamp. |seconds| 79 // The tuple (seconds, useconds) represents the event timestamp. |seconds|
70 // represents the number of seconds while |useconds| represents the 80 // represents the number of seconds while |useconds| represents the
(...skipping 30 matching lines...) Expand all
101 111
102 // The time of the last page flip event as reported by the kernel callback. 112 // The time of the last page flip event as reported by the kernel callback.
103 uint64_t time_of_last_flip_ = 0; 113 uint64_t time_of_last_flip_ = 0;
104 114
105 DISALLOW_COPY_AND_ASSIGN(CrtcController); 115 DISALLOW_COPY_AND_ASSIGN(CrtcController);
106 }; 116 };
107 117
108 } // namespace ui 118 } // namespace ui
109 119
110 #endif // UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_ 120 #endif // UI_OZONE_PLATFORM_DRM_GPU_CRTC_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | ui/ozone/platform/drm/gpu/crtc_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698