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

Side by Side Diff: ui/ozone/platform/drm/common/drm_util.cc

Issue 1671223002: Revert of Give user ability to file a feedback report from the display error notification. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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
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/common/drm_util.h" 5 #include "ui/ozone/platform/drm/common/drm_util.h"
6 6
7 #include <drm_fourcc.h> 7 #include <drm_fourcc.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <stdlib.h> 9 #include <stdlib.h>
10 #include <sys/mman.h> 10 #include <sys/mman.h>
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 params.physical_size = 227 params.physical_size =
228 gfx::Size(info->connector()->mmWidth, info->connector()->mmHeight); 228 gfx::Size(info->connector()->mmWidth, info->connector()->mmHeight);
229 params.type = GetDisplayType(info->connector()); 229 params.type = GetDisplayType(info->connector());
230 params.is_aspect_preserving_scaling = 230 params.is_aspect_preserving_scaling =
231 IsAspectPreserving(fd, info->connector()); 231 IsAspectPreserving(fd, info->connector());
232 232
233 ScopedDrmPropertyBlobPtr edid_blob( 233 ScopedDrmPropertyBlobPtr edid_blob(
234 GetDrmPropertyBlob(fd, info->connector(), "EDID")); 234 GetDrmPropertyBlob(fd, info->connector(), "EDID"));
235 235
236 if (edid_blob) { 236 if (edid_blob) {
237 params.edid.assign( 237 std::vector<uint8_t> edid(
238 static_cast<uint8_t*>(edid_blob->data), 238 static_cast<uint8_t*>(edid_blob->data),
239 static_cast<uint8_t*>(edid_blob->data) + edid_blob->length); 239 static_cast<uint8_t*>(edid_blob->data) + edid_blob->length);
240 240
241 GetDisplayIdFromEDID(params.edid, connector_index, &params.display_id, 241 GetDisplayIdFromEDID(edid, connector_index, &params.display_id,
242 &params.product_id); 242 &params.product_id);
243 243
244 ParseOutputDeviceData(params.edid, nullptr, nullptr, &params.display_name, 244 ParseOutputDeviceData(edid, nullptr, nullptr, &params.display_name, nullptr,
245 nullptr, nullptr); 245 nullptr);
246 ParseOutputOverscanFlag(params.edid, &params.has_overscan); 246 ParseOutputOverscanFlag(edid, &params.has_overscan);
247 } else { 247 } else {
248 VLOG(1) << "Failed to get EDID blob for connector " 248 VLOG(1) << "Failed to get EDID blob for connector "
249 << info->connector()->connector_id; 249 << info->connector()->connector_id;
250 } 250 }
251 251
252 for (int i = 0; i < info->connector()->count_modes; ++i) { 252 for (int i = 0; i < info->connector()->count_modes; ++i) {
253 const drmModeModeInfo& mode = info->connector()->modes[i]; 253 const drmModeModeInfo& mode = info->connector()->modes[i];
254 params.modes.push_back(CreateDisplayModeParams(mode)); 254 params.modes.push_back(CreateDisplayModeParams(mode));
255 255
256 if (info->crtc()->mode_valid && SameMode(info->crtc()->mode, mode)) { 256 if (info->crtc()->mode_valid && SameMode(info->crtc()->mode, mode)) {
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 case gfx::BufferFormat::BGRX_8888: 320 case gfx::BufferFormat::BGRX_8888:
321 return DRM_FORMAT_XRGB8888; 321 return DRM_FORMAT_XRGB8888;
322 case gfx::BufferFormat::UYVY_422: 322 case gfx::BufferFormat::UYVY_422:
323 return DRM_FORMAT_UYVY; 323 return DRM_FORMAT_UYVY;
324 default: 324 default:
325 NOTREACHED(); 325 NOTREACHED();
326 return 0; 326 return 0;
327 } 327 }
328 } 328 }
329 } // namespace ui 329 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/common/gpu/ozone_gpu_messages.h ('k') | ui/views/widget/desktop_aura/desktop_screen_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698