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

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

Issue 1438343002: Remove deprecated ScopedVector usage from ui/ozone and ui/events/ozone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove HDCI stuff Created 5 years, 1 month 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
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 #include "ui/ozone/platform/drm/gpu/drm_window.h" 5 #include "ui/ozone/platform/drm/gpu/drm_window.h"
6 6
7 #include <drm_fourcc.h> 7 #include <drm_fourcc.h>
8 8
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "base/trace_event/trace_event.h" 10 #include "base/trace_event/trace_event.h"
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 return OverlayPlane::GetPrimaryPlane(last_submitted_planes_); 207 return OverlayPlane::GetPrimaryPlane(last_submitted_planes_);
208 } 208 }
209 209
210 void DrmWindow::GetVSyncParameters( 210 void DrmWindow::GetVSyncParameters(
211 const gfx::VSyncProvider::UpdateVSyncCallback& callback) const { 211 const gfx::VSyncProvider::UpdateVSyncCallback& callback) const {
212 if (!controller_) 212 if (!controller_)
213 return; 213 return;
214 214
215 // If we're in mirror mode the 2 CRTCs should have similar modes with the same 215 // If we're in mirror mode the 2 CRTCs should have similar modes with the same
216 // refresh rates. 216 // refresh rates.
217 CrtcController* crtc = controller_->crtc_controllers()[0]; 217 CrtcController* crtc = controller_->crtc_controllers()[0].get();
218 // The value is invalid, so we can't update the parameters. 218 // The value is invalid, so we can't update the parameters.
219 if (controller_->GetTimeOfLastFlip() == 0 || crtc->mode().vrefresh == 0) 219 if (controller_->GetTimeOfLastFlip() == 0 || crtc->mode().vrefresh == 0)
220 return; 220 return;
221 221
222 // Stores the time of the last refresh. 222 // Stores the time of the last refresh.
223 base::TimeTicks timebase = 223 base::TimeTicks timebase =
224 base::TimeTicks::FromInternalValue(controller_->GetTimeOfLastFlip()); 224 base::TimeTicks::FromInternalValue(controller_->GetTimeOfLastFlip());
225 // Stores the refresh rate. 225 // Stores the refresh rate.
226 base::TimeDelta interval = 226 base::TimeDelta interval =
227 base::TimeDelta::FromSeconds(1) / crtc->mode().vrefresh; 227 base::TimeDelta::FromSeconds(1) / crtc->mode().vrefresh;
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 if (!cursor_buffers_[i]->Initialize( 297 if (!cursor_buffers_[i]->Initialize(
298 info, false /* should_register_framebuffer */)) { 298 info, false /* should_register_framebuffer */)) {
299 LOG(FATAL) << "Failed to initialize cursor buffer"; 299 LOG(FATAL) << "Failed to initialize cursor buffer";
300 return; 300 return;
301 } 301 }
302 } 302 }
303 } 303 }
304 } 304 }
305 305
306 } // namespace ui 306 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/gpu/drm_gpu_display_manager.cc ('k') | ui/ozone/platform/drm/gpu/hardware_display_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698