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 #ifndef UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 5 #ifndef UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
6 #define UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 6 #define UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
267 | 267 |
268 // Checks the available color profiles for |display_id| and fills the result | 268 // Checks the available color profiles for |display_id| and fills the result |
269 // into |profiles|. | 269 // into |profiles|. |
270 std::vector<ui::ColorCalibrationProfile> GetAvailableColorCalibrationProfiles( | 270 std::vector<ui::ColorCalibrationProfile> GetAvailableColorCalibrationProfiles( |
271 int64_t display_id); | 271 int64_t display_id); |
272 | 272 |
273 // Updates the color calibration to |new_profile|. | 273 // Updates the color calibration to |new_profile|. |
274 bool SetColorCalibrationProfile(int64_t display_id, | 274 bool SetColorCalibrationProfile(int64_t display_id, |
275 ui::ColorCalibrationProfile new_profile); | 275 ui::ColorCalibrationProfile new_profile); |
276 | 276 |
277 // Sets the gamma ramp for |display_id| to the values in |lut|. | |
278 bool SetGammaRamp(int64_t display_id, | |
279 const std::vector<GammaRampRGBEntry>& lut); | |
280 | |
281 // Enables/disables virtual display. | 277 // Enables/disables virtual display. |
282 int64_t AddVirtualDisplay(gfx::Size display_size); | 278 int64_t AddVirtualDisplay(gfx::Size display_size); |
283 bool RemoveVirtualDisplay(int64_t display_id); | 279 bool RemoveVirtualDisplay(int64_t display_id); |
284 | 280 |
285 // Returns true if there is at least one display on. | 281 // Returns true if there is at least one display on. |
286 bool IsDisplayOn() const; | 282 bool IsDisplayOn() const; |
287 | 283 |
288 void set_configure_display(bool configure_display) { | 284 void set_configure_display(bool configure_display) { |
289 configure_display_ = configure_display; | 285 configure_display_ = configure_display; |
290 } | 286 } |
291 | 287 |
| 288 // Sets the gamma, degamma and correction matrix for |display_id| to the |
| 289 // values in |degamma_lut|, |gamma_lut| and |correction_matrix|. |
| 290 bool SetColorCorrection(int64_t display_id, |
| 291 const std::vector<GammaRampRGBEntry>& degamma_lut, |
| 292 const std::vector<GammaRampRGBEntry>& gamma_lut, |
| 293 const std::vector<float>& correction_matrix); |
| 294 |
292 private: | 295 private: |
293 class DisplayLayoutManagerImpl; | 296 class DisplayLayoutManagerImpl; |
294 | 297 |
295 // Mapping a client to its protection request. | 298 // Mapping a client to its protection request. |
296 typedef std::map<ContentProtectionClientId, ContentProtections> | 299 typedef std::map<ContentProtectionClientId, ContentProtections> |
297 ProtectionRequests; | 300 ProtectionRequests; |
298 | 301 |
299 // Performs platform specific delegate initialization. | 302 // Performs platform specific delegate initialization. |
300 scoped_ptr<NativeDisplayDelegate> CreatePlatformNativeDisplayDelegate(); | 303 scoped_ptr<NativeDisplayDelegate> CreatePlatformNativeDisplayDelegate(); |
301 | 304 |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
457 | 460 |
458 // This must be the last variable. | 461 // This must be the last variable. |
459 base::WeakPtrFactory<DisplayConfigurator> weak_ptr_factory_; | 462 base::WeakPtrFactory<DisplayConfigurator> weak_ptr_factory_; |
460 | 463 |
461 DISALLOW_COPY_AND_ASSIGN(DisplayConfigurator); | 464 DISALLOW_COPY_AND_ASSIGN(DisplayConfigurator); |
462 }; | 465 }; |
463 | 466 |
464 } // namespace ui | 467 } // namespace ui |
465 | 468 |
466 #endif // UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 469 #endif // UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
OLD | NEW |