diff options
author | oshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-13 19:34:28 +0000 |
---|---|---|
committer | oshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-13 19:34:28 +0000 |
commit | d9fc55bfc2c805b703f1c8cfd1f736489438c0f8 (patch) | |
tree | e76b0f6164aa837a2a144249d41923923b9bd2f5 /chromeos | |
parent | 1885f753954bbe2765e7feab3dd67ce1093c6071 (diff) | |
download | chromium_src-d9fc55bfc2c805b703f1c8cfd1f736489438c0f8.zip chromium_src-d9fc55bfc2c805b703f1c8cfd1f736489438c0f8.tar.gz chromium_src-d9fc55bfc2c805b703f1c8cfd1f736489438c0f8.tar.bz2 |
Merge 186231 "Matching modes for mirroring should preserve inter..."
> Matching modes for mirroring should preserve interlacing.
>
> Add a condition when searching for modes for mirroring -
> both modes must either be interlaced or progressive scan.
>
> Also, as internal panels don't support interlacing,
> do not attempt to panel fit interlaced modes on them.
>
> BUG=179207
> TEST=Manually disabled modes, making interlaced one the preferred,
> then verified that this mode is not picked for mirroring,
> but the next one. Steps in the bug should also work,
> but I don't have the necessary hardware.
>
> Review URL: https://chromiumcodereview.appspot.com/12388090
TBR=ynovikov@chromium.org
Review URL: https://codereview.chromium.org/12607010
git-svn-id: svn://svn.chromium.org/chrome/branches/1410/src@187919 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos')
-rw-r--r-- | chromeos/display/output_configurator.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/chromeos/display/output_configurator.cc b/chromeos/display/output_configurator.cc index 6f9ce47c..50fddd2 100644 --- a/chromeos/display/output_configurator.cc +++ b/chromeos/display/output_configurator.cc @@ -1059,8 +1059,11 @@ bool OutputConfigurator::FindOrCreateMirrorMode(Display* display, for (int j = 0; j < internal_info->nmode; j++) { internal_mode_id = internal_info->modes[j]; XRRModeInfo* internal_mode = ModeInfoForID(screen, internal_mode_id); + bool is_internal_interlaced = internal_mode->modeFlags & RR_Interlace; + bool is_external_interlaced = external_mode->modeFlags & RR_Interlace; if (internal_mode->width == external_mode->width && - internal_mode->height == external_mode->height) { + internal_mode->height == external_mode->height && + is_internal_interlaced == is_external_interlaced) { *internal_mirror_mode = internal_mode_id; *external_mirror_mode = external_mode_id; return true; // Mirror mode found @@ -1071,9 +1074,11 @@ bool OutputConfigurator::FindOrCreateMirrorMode(Display* display, if (try_creating) { // We can downscale by 1.125, and upscale indefinitely // Downscaling looks ugly, so, can fit == can upscale + // Also, internal panels don't support fitting interlaced modes bool can_fit = internal_native_mode->width >= external_mode->width && - internal_native_mode->height >= external_mode->height; + internal_native_mode->height >= external_mode->height && + !(external_mode->modeFlags & RR_Interlace); if (can_fit) { XRRAddOutputMode(display, internal_output_id, external_mode_id); *internal_mirror_mode = *external_mirror_mode = external_mode_id; |