OSDN Git Service

Prevent buggy display orientation when exiting vr
authorStephen Kiazyk <skiazyk@google.com>
Fri, 14 Apr 2017 20:43:29 +0000 (13:43 -0700)
committerStephen Kiazyk <skiazyk@google.com>
Fri, 14 Apr 2017 20:43:29 +0000 (13:43 -0700)
commit82386cd4eb194a9bf4b8688cb02317909ba346e0
tree8dd37743b3ea49b362108d1d8bd73fa5d0ec96eb
parent7d3dcb9235ec149af2f5139a8a9c6eac859d92e2
Prevent buggy display orientation when exiting vr

The underlying issue is that the viewport settings were being re-set to
(0,0,-1,-1) on every transition to VR. I've instead extracted the vsync
period updates, and only apply those, as that was really all we wanted
out of it.

Bug: 37093920
Test: Compile and run Vr application. The 2d scene is now no longer in
the weird landscape viewport with portrait orientation if the phone is
in landscape when exiting VR mode.

Change-Id: I2bab6e4d834e15f477d1b56991375d1a18a77b8c
services/surfaceflinger/SurfaceFlinger.cpp