• Home
  • History
  • Annotate
  • only in /frameworks/native/libs/vr/libvrflinger/
History log of /frameworks/native/libs/vr/libvrflinger/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
cd43683371f158b77e934e7cb71a9fdc65a122ed 12-May-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Remove QCom specific flags" into oc-dev
fac407407e30c70da44a7a8ae1b13bf1ef9c05b7 09-May-2017 Hendrik Wagenaar <hendrikw@google.com> DO NOT MERGE Remove graphics.cpp and friends

* Delete a bunch of code that isn't used in the O2 path

Bug: 36776792
Test: Compiled
Change-Id: I4adf6ec5678a53e0850229f9dda60e8687793376
Merged-In: I4adf6ec5678a53e0850229f9dda60e8687793376
ndroid.bp
isplay_surface.h
ardware_composer.cpp
ardware_composer.h
4720c9db1fd7777af57fd25e375cd8a3e72ea305 11-May-2017 Hendrik Wagenaar <hendrikw@google.com> Remove QCom specific flags

* We can't have any device specific code on Android

Bug: 38207381
Test: Compiled
Change-Id: I0cab52d71c65ff401985b01140452c7901eef855
isplay_surface.cpp
c6c0c9c730cd11e9f55737a5b30d3f162cc76bd2 09-May-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Remove framebuffer_target" into oc-dev
a9d668acaa888acc04705b73d6e4fe3c0069d06f 08-May-2017 Hendrik Wagenaar <hendrikw@google.com> Remove framebuffer_target

* Remove unused variable

Bug: 38132845
Test: Compiled
Change-Id: I08afba75b72c3d27aca042755bf36584979c7f0c
ardware_composer.cpp
ardware_composer.h
a4aeae5ef39aa6a379a503e1e4cfffba06d48594 07-May-2017 Hendrik Wagenaar <hendrikw@google.com> remove vr/libeds

* libeds is no longer needed

Bug: 38075841
Test: compiled
Change-Id: I61b7edb284633ab8e960387c0479b1a924d68222
ndroid.bp
2251d822dac2a96aad4184a6fdc2690f0a58af7c 21-Apr-2017 Corey Tabaka <eieio@google.com> Remove the VR compositor from the framework.

Remove the VR compositor framework and enable out-of-process VR composition
in VrCore.

This CL seems large due to the ripple effect of changing the VrFlinger
API and protocol types. There are three major modules that require
concurrent changes:
1. Protocol definitions and low-level VrFlinger API in libdisplay.
* Additional changes needed to keep old interfaces working for
a short time while replacing the dependent code (dvrGraphics*).
2. VrFlinger service implementation changes to support VrCore compositor
and the removal of the internal compositor.
3. Changes to libdvr platform library API due to changes in #1 and #2.

Because of the nature of the interdependence of types and other defs it is
difficult to break this CL into smaller chunks. However, review of the three
major modules (libdisplay, libdvr, and libvrflinger) may be done separately
to ease the mental burden on reviewers.

Change Summary:
- Remove obsolete screenshot service. VR screenshots will be implemented
by VrCore.
- Update display protocol definitions for changes in VrFlinger service
requirements. The majority of the changes in libdisplay are a
consequence of these protocol and service changes.
- Update VrFlinger to support two kinds of surfaces:
1. Application - use by VR apps.
2. Direct - used by VrCore (protected by permission check).
- Remove VrFlinger internal compositor and GL context.
- Remove obsolete debug console.
- Update VrFlinger hardware composer interface to handle direct
surfaces only, removing the concept of GPU (compositor) layers.
- Update display manager to expose access to application surface info
to VrCore (protected by permission check).
- Update libdvr platform library interfaces for changes to VrFlinger
API / protocol.
- Clean up libdvr API struct setup using a common include.
- Add C++ header-only helpers for DVR platform library opaque types.

Bug: 36401174
Test: Build; run VrFlinger display test tool.
Change-Id: I15abfde5f72dbb3725a3f58621486afba6b64902
ndroid.bp
cquired_buffer.cpp
cquired_buffer.h
ompositor.cpp
ompositor.h
ebug_hud_data.cpp
ebug_hud_data.h
ebug_hud_view.cpp
ebug_hud_view.h
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
isplay_surface.cpp
isplay_surface.h
poll_event_dispatcher.cpp
poll_event_dispatcher.h
ardware_composer.cpp
ardware_composer.h
wc_types.h
creenshot_service.cpp
creenshot_service.h
urface_channel.cpp
urface_channel.h
ideo_compositor.cpp
ideo_compositor.h
ideo_mesh_surface.cpp
ideo_mesh_surface.h
r_flinger.cpp
sync_service.cpp
sync_service.h
3f82d31341f66d0c58e1ec3360ea5f528ffe0ea4 20-Apr-2017 Corey Tabaka <eieio@google.com> Remove unnecessary clients and rename files.

- Remove clients for obsolete services.
- Rename display protocol defs file to match purpose.
- Rename display manager client file. "impl" does not match naming
conventions used by DVR libraries.
- Remove video mesh surface interface. This will be replaced by more
general surface support in the unified O compositor.

Bug: 36401174
Test: Build; run cube sea.
Change-Id: Idb782623319329f6fa1b0aa45005d9fee3b9957d
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
isplay_surface.h
urface_channel.h
ideo_compositor.cpp
ideo_mesh_surface.cpp
sync_service.cpp
0057fddc71d1c3c3de8f9d0bd45a51bb293bfa3c 02-May-2017 Jiwen 'Steve' Cai <jwcai@google.com> Deprecate producer/consumer usage: Step 2

Clean up bufferhub_rpc, display_rpc and service side producer/consumer
usage reference.

Next (final) step is to remove all remaining client side reference to
producer/consumer usage and update dvr_xxx API.

This also fixes a minor typo in dvr_named_buffer-test

Bug: 37881101
Test: Build, flash, ran particles.apk and buffer_hub_queue-test
Change-Id: Ibae4376c1fd1ed964843d8b2ad2fb27204fe5e28
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
044963e1dd0479035b6e5f2c6bd618bde7143710 02-May-2017 Jiwen 'Steve' Cai <jwcai@google.com> Deprecate producer/consumer usage: Step 1

Clean up producer/consumer usage from IonBuffer.

Bug: 37881101
Test: Build, flash, ran particles.apk
Change-Id: I66a8c4db2348b014a7b458b69157ed7c150112e1
isplay_service.cpp
949c9ce51adbcbdb25d78ee700fd731aa941d577 01-May-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Call validateDisplay() when skipping frames" into oc-dev
0af4b9f88a48a6ecc705b4a8cec3d3ba24c53ead 26-Apr-2017 Steven Thomas <steventhomas@google.com> Call validateDisplay() when skipping frames

Layer management was getting screwed up in vr flinger in the following
scenario:

1. In frame X, post a new buffer to layer L.

2. Decide to skip frame X (e.g. because we're behind our target
schedule).

3. In frame X+1, delete layer L.

When we skip the frame in step 2, we weren't calling validateDisplay()
or presentDisplay() on the hardware composer, so the composer's internal
command queue wasn't being flushed. When we called validateDisplay() for
frame X+1 the update buffer call from frame X would be run, referencing
the deleted layer L, causing a crash.

Now we always call validateDisplay() when we change the layer state,
even if we decide to skip the frame.

I also added code to explicitly clear the Composer object's internal
command buffer when we transfer control from surface flinger to vr
flinger and back. There were certain cases where there could be commands
left in the command buffer after the display handoff.

Bug: 37159844

Test: I used an app switcher script that quickly switches vr apps, which
would consistently trigger the setLayerBuffer crash. I confirmed with
this CL applied I can run the app switcher until surface flinger runs
out of file descriptors (that's a separate bug), and I never see the
setLayerBuffer crash. I also confirmed from the log output there are no
additional hardware composer errors.

Change-Id: I85832b87f393754dc6b034eb38f2937d7b58ed74
ardware_composer.cpp
cb4751c52a5625a22b6a11b4de537ff026d9bfe3 15-Apr-2017 Jiwen 'Steve' Cai <jwcai@google.com> Fix minor corner cases in BufferHubQueueProducer

1/ Set reasonable return value BufferHubQueueProducer::query.
2/ Don't error out for setSharedBufferMode(false),
setAutoRefresh(false), as they are just setting default values again.
3/ Supports addition buffer metadata: transformt, crop,
data_format (a.k.a. color_format).
4/ This also changes BufferHubQueueProducer to be based of
BnInterface<IGraphicBufferProducer> so that itself can be passed via Binder.

Bug: 37342387
Bug: 36907193
Test: exoplayer_demo
Change-Id: Ie00bb79f6a249e09905ae52f85a85a67744cc90d
ideo_compositor.cpp
ideo_mesh_surface.cpp
4b78832d7fc3cdd13a20587dfee96d1505916213 24-Mar-2017 Luke Song <songwalker@google.com> Remove/Cleanup Obselete References

Bug: 36039686
Bug: 36040117
Bug: 36039685
Bug: 36040550
Test: Build
Change-Id: Ifd5ae90138e39d0a14c6a5a8198a9145f74ec8f6
(cherry picked from commit 8126b9df8987fd9959eab1ae76620c343c32f4fc)
cquired_buffer.h
ompositor.cpp
ardware_composer.cpp
f8b1ef4fd9cd4e0bd750b07f502add63ddf43166 19-Apr-2017 Hendrik Wagenaar <hendrikw@google.com> Fix default optics

* Prior cl caused an infinite loop with the defaults
* Removed linear approximation - it caused issues with
inverse distortion

Bug: 37443861
Test: Manually ran on a few phones
Test: Wrote a program that compared the distortion and
undistortion values with the old and new path
Change-Id: I7221679585dd7f0fe966ff11170e9d3ec74a51df
isplay_service.cpp
e602082190a70f7f4ab1636b5cc21afa0edcf6cc 20-Apr-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Hold onto FileHandles for glBindSharedBufferQCOM calls" into oc-dev
511544f212a9e675c10928b29551746374fb1637 19-Apr-2017 Steven Thomas <steventhomas@google.com> Merge "Fix query management in GpuProfiler" into oc-dev
28f85d6a602cccbf288e236da704729e61c9ed7f 17-Apr-2017 Steven Thomas <steventhomas@google.com> Fix query management in GpuProfiler

GL query objects were being used incorrectly in GpuProfiler across GL
context resets, which could cause endless creation of additional GL
query objects.

Have the compositor notify the GpuProfiler when the GL context is
created and destroyed, so it can reset its state appropriately.

Also impose a limit of 32 outstanding queries to help prevent endless
query object creation in the future. If we hit the limit we print a log,
reset everything, and start over.

Bug: 34256609

Test: Manually tested that: (a) we no longer get GL errors after
glGetQueryObjectiv() calls after a context destroy/create cycle, and (b)
the queue overflow handling works as expected.

Change-Id: I64905b766a3ea7cb62d543b776ac975d0762868e
ompositor.cpp
093516f6d3327be7a098738ecf0d9a75ecc5d765 17-Apr-2017 John Bates <jbates@google.com> Hold onto FileHandles for glBindSharedBufferQCOM calls

The internal implementation of glBindSharedBuffer does not dup
the file descriptor, so to be pedantic about fd lifetime we
need to hold onto the fd until the gl buffer is deleted.

Bug: b/34256609
Test: manually switched between apps
Change-Id: I35bfbfe6a6b793bc3bdf38d7ddca31699ee0f4ff
ompositor.cpp
db5763834df1b6a1a3aef9442982451f7505f402 18-Apr-2017 Hendrik Wagenaar <hendrikw@google.com> Dvr api usages should follow AHardwareBuffer

* Since vrcore doesn't have access to gralloc1 usages
* Since gralloc1 may be replaced in the future

Bug: 37435415
Test: TestNamedBufferUsage
Change-Id: Iaa47396aca26460541d1b9031dce0b971b630555
isplay_service.cpp
302b74ffc656243d91ee6ddd8743239ef2dfbdba 04-Apr-2017 Hendrik Wagenaar <hendrikw@google.com> Update optics

* Specify optics via system properties

Bug: 36039976
Test: Ran on device

Change-Id: I7a38e5a9eb3b8a861f1997d5011ec109f5e79cca
ompositor.cpp
isplay_service.cpp
ee7cb1b5b86d54e98875ca5b714b98be6d01b824 12-Apr-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Convert the pose buffer into a more generic named buffer" into oc-dev
eaa5522feac452703a0836310047d4b15702487d 06-Apr-2017 Hendrik Wagenaar <hendrikw@google.com> Convert the pose buffer into a more generic named buffer

* It's likely that we'll have more than one pose buffer
* It's cleaner to separate the vsync info into a separate buffer

Bug: 37001881
Bug: 37240552
Test: Added and manually ran TestNamedBuffersSetup
Change-Id: I76621d3cfa8c21c9d5d1e6e648854067673be9ab
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
1f42e3a02c4f9a1ba1916a2f0e47082bedb73e41 10-Apr-2017 Daniel Nicoara <dnicoara@google.com> VR: Update VR HWC to use buffer metadata passed by SurfaceFlinger

Without gralloc1 support, need to pass buffer metadata in order to
import native buffers and used them as graphic buffers.

Bug: 36481301
Test: Compiled and ran on device; Verified VR Window Manager properly
displays SurfaceFlinger buffers.

Change-Id: I8426be1d79dcc2fbd631c399427ae03cb2afc21d
ndroid.bp
ardware_composer.cpp
3fdeae8b2df1c72f7bf1b7e53a0d94f9f01d106d 06-Apr-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Check if a visible layer exists instead of an invisible layer exists" into oc-dev
b324457171474f02e793d3a669b14c8c24e23008 06-Apr-2017 Daniel Nicoara <dnicoara@google.com> Merge "VR: Remove HIDL VR Composer from service/vr/vr_window_manager" into oc-dev
356bc37719bb748346a79935e1979e264c81c296 06-Apr-2017 Albert Chaulk <achaulk@google.com> Check if a visible layer exists instead of an invisible layer exists

Multiple layers may exist at index 0 and what we really want to know
is if any of them are active, not if any aren't.

Bug: 36867186, 36036583
Test: Launch ithaca then youtube
Change-Id: I5881a838c7df8670fa42eece558717140d4cb021
isplay_service.cpp
95a99a1d3cdbd19343d0d27271098c9c01a63e78 21-Mar-2017 Daniel Nicoara <dnicoara@google.com> VR: Remove HIDL VR Composer from service/vr/vr_window_manager

Moved into frameworks/hardware/interfaces

Bug: 35570958
Test: Compiled and ran on device
Change-Id: I735096935a06e4dd6a8fc1d719c73ad11e9c1583
ndroid.bp
f0a7bd033941e26e380232a0515e903cf8e678e5 01-Apr-2017 Alex Vakulenko <avakulenko@google.com> pdx: Rework error reporting when transfering file and channel handles

There is a lot of confusion about reporting errors when passing file
and channel handles over PDX transport between client and service.

Methods like Message::PushFileHandle return an integer which means
both a file handle reference value (if positive) and a possible error
code (if negative). But file handles could contain negative values too
(when they are empty). This is used frequently when passing buffer
fences around (when a fence is not being used, its fd is set to -1).

This results in a special case of when PushFileHandle is called with
a file handle with value of -1, the return value is actually "-errno"
which becomes dependent on a global state (errno is not set by
PushFileHandle itself in case file handle value is negative) and results
in unpredicted behavior (sometimes errno is 0, sometimes its >0).

Cleaned this all up by using Status<T> everywhere we used an int to
pass value payload along with possible error code.

Now the semantics of the calls are more clear.

Bug: 36866492
Test: `m -j32` for sailfish-eng succeeds
Ran unit tests on device (pdx_tests, libpdx_uds_tests, bufferhub_tests,
buffer_hub_queue-test, buffer_hub_queue_producer-test), all pass
Ran CubeSea, NativeTreasureHunt and Ithaca on Sailfish with vrflinger
enabled, was able to use controller and screen rendered correctly.

Change-Id: I0f40c3f356fcba8bc217d5219a0ddf9685e57fd7
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
isplay_surface.cpp
isplay_surface.h
creenshot_service.cpp
creenshot_service.h
urface_channel.cpp
urface_channel.h
ideo_mesh_surface.cpp
ideo_mesh_surface.h
sync_service.cpp
sync_service.h
3078ed9ad08e40690281b432ccb5e97c16de2d12 24-Mar-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Implement an API for vrwm to query if the current vr app is active"
b7c8a4bd8131ce18fb4ab4ee986c3b6b1ed27ad5 20-Mar-2017 Albert Chaulk <achaulk@google.com> Implement an API for vrwm to query if the current vr app is active

The API returns if the client_order 0 layer is visible or not. This
aids in 2D app detection

Bug: None
Test: Manual with permissionsgen & calculator

Change-Id: Id988e61a9f93885e93c28ed83ffaffd84f3bdf15
isplay_service.cpp
isplay_service.h
ed72e3eea40bbaa1b7b5040b5f02cc047de4fe39 23-Mar-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Fix BlockUntilVSync() to actually block"
66747c180e456cc762821c61a75a17bee03a4cf9 23-Mar-2017 Steven Thomas <steventhomas@google.com> Fix BlockUntilVSync() to actually block

In my refactoring in ag/2008740 I introduced a regression where blocking
until the next vsync would busy loop instead of actually blocking on an
event on the vsync fd. The problem was I changed the poll() call to
listen for POLLIN in addition to POLLPRI. While waiting for vsync events
we only want to listen for POLLPRI.

Bug: 36495351

Test: Confirmed with debug logs the busy loop bug and that we correctly
block with this patch applied.

Change-Id: Iec4951e014575a5d0ed3cfe3fc20ea91c67edf1b
ardware_composer.cpp
ardware_composer.h
c13ee942359a0bc5278ff0eddd509ab484df41a0 22-Mar-2017 Jiwen Cai <jiwen@google.com> Merge "Fix janky pose"
1455342db3009c21a5c167ba23089505ee8f04c3 21-Mar-2017 Jiwen 'Steve' Cai <jwcai@google.com> Fix janky pose

It's introduced through ag/1980993, where render_buffer_index_ was not
managed after the refactor.

Bug: 36194745
Test: Build and flash, pose is no longer janky.
Change-Id: I6ef86625dbc1c1afd2725614062f5e40e1b7f60a
isplay_surface.cpp
isplay_surface.h
050b2c83304bd16ec3a838da08b6ba6acf6a3af4 06-Mar-2017 Steven Thomas <steventhomas@google.com> Revert "Revert "Tie vr flinger to persistent vr mode""

This reverts commit 7480c060cb3466d97ec3125d61bbace153f534c8.

Transfer display control to vr flinger when persistent vr mode is
entered, rather than when vr mode is entered. This allows cardboard
apps, which will invoke vr mode but not persistent vr mode, to work as
in N.

This activates vr flinger at device boot for Daydream ready devices,
which fixes an issue where an app would attempt to create a surface
before vr flinger was running, which would hang indefinitely.

The VrManager listener for persistent vr mode is put in vr flinger
instead of surface flinger. This is cleaner since the vr interaction
with the rest of the device is now consolidated in vr flinger.

While testing I encountered a problem where vr flinger was given control
of the display but vsync was turned off, causing vr flinger's post
thread to hang. I changed the vr flinger logic to give control over
vsync and other display settings to the post thread, and took the
opportunity to further simplify and improve vr flinger's thread
interactions.

Bug: 35885165

Test: Manually confirmed that when persistent vr mode is not invoked we
get the N-based render implementation, and when persistent vr mode is
invoked we get vr flinger.

Change-Id: I3b5ad599cc0748e38b861c714c4cc3118f854acf
isplay_service.cpp
isplay_service.h
ardware_composer.cpp
ardware_composer.h
nclude/dvr/vr_flinger.h
r_flinger.cpp
10e68eb8aa4db8b6f8cfbf2c3754e2677d7bf848 15-Mar-2017 Hendrik Wagenaar <hendrikw@google.com> Add dvr_buffer apis

Test: None
Bug: None
Change-Id: I234d7ef4dabb4453cdbc67d3112adf2ffbbadaf4
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
7480c060cb3466d97ec3125d61bbace153f534c8 21-Mar-2017 Jin Qian <jinqian@google.com> Revert "Tie vr flinger to persistent vr mode"

This reverts commit f43d13e4e35ae7d3cdafc4b97c819669d42cef78.

Change-Id: Ib67db8e51b7ea2dbbe6faccce36962bf5b44a6e2
isplay_service.cpp
isplay_service.h
ardware_composer.cpp
ardware_composer.h
nclude/dvr/vr_flinger.h
r_flinger.cpp
f43d13e4e35ae7d3cdafc4b97c819669d42cef78 06-Mar-2017 Steven Thomas <steventhomas@google.com> Tie vr flinger to persistent vr mode

Transfer display control to vr flinger when persistent vr mode is
entered, rather than when vr mode is entered. This allows cardboard
apps, which will invoke vr mode but not persistent vr mode, to work as
in N.

This activates vr flinger at device boot for Daydream ready devices,
which fixes an issue where an app would attempt to create a surface
before vr flinger was running, which would hang indefinitely.

The VrManager listener for persistent vr mode is put in vr flinger
instead of surface flinger. This is cleaner since the vr interaction
with the rest of the device is now consolidated in vr flinger.

While testing I encountered a problem where vr flinger was given control
of the display but vsync was turned off, causing vr flinger's post
thread to hang. I changed the vr flinger logic to give control over
vsync and other display settings to the post thread, and took the
opportunity to further simplify and improve vr flinger's thread
interactions.

Bug: 35885165

Test: Manually confirmed that when persistent vr mode is not invoked we
get the N-based render implementation, and when persistent vr mode is
invoked we get vr flinger.

Change-Id: Ieeb8dabc19e799e3179e52971f3b63f5a8f54b3b
isplay_service.cpp
isplay_service.h
ardware_composer.cpp
ardware_composer.h
nclude/dvr/vr_flinger.h
r_flinger.cpp
a3613612a1142c3134045f08c30a861ea43288ed 09-Mar-2017 Jiwen 'Steve' Cai <jwcai@google.com> Refactor VrFlinger to use BufferHubQueue

1/ Remove DisplayRPC::AllocateBuffer, as individual buffer allocation
is now handled by BufferHubQueue.
2/ Reimplement native_buffer_queue using bufferhubqueue.
3/ Hook up consumer queue in DisplaySurface.
4/ Remove epoll_event_dispatcher as its no longer being used.

Bug: 36033302
Test: Built and ran particles.apk
Change-Id: I38ee1c57195888ede935ebc50119bcb7e4ab4e36
ndroid.bp
isplay_service.cpp
isplay_service.h
isplay_surface.cpp
isplay_surface.h
poll_event_dispatcher.cpp
poll_event_dispatcher.h
ardware_composer.cpp
ed6543224138fd753eeea909918bb8d1d2efb1e6 14-Mar-2017 Jiwen 'Steve' Cai <jwcai@google.com> Expose acquire_fence though ConsumerQueue::Dequeue

The current compositor implementation will be refactored to use
BufferHubQueue instead of ad-hoc BufferHub operations. We need this to
expose release_fence to compositor so that it can wait for buffers
to become avaiable by checking fence properly.

Bug: 36033302
Bug: 36148608
Test: Built and ran buffer_hub_queue-test
Change-Id: I75cfcb02e06a4b9e7e89b89690ca2d92ee09a678
ideo_compositor.cpp
e77dce28e5e9a7f078cb324a7b9320802fca8469 14-Mar-2017 Stephen Kiazyk <skiazyk@google.com> Force vrhwc/wm to report the native resolution

Due to some Yak-shaving, this also involved a partial conversion of our
libraries to soong.

Notes:
* I also changed the name of libsensor to libvrsensor to avoid a naming
clash with an existing library
* The remaining libraries will be soongified in a separate CL

Bug: 36139334
Test: Build and run vr apps.
Change-Id: Ib39687bd01e3d2e1c30adc54e18f362a85954ab9
ndroid.bp
ndroid.mk
5c46fc496a2e9537f318efef9a08d1e76f5e7a5f 10-Mar-2017 Jiwen 'Steve' Cai <jwcai@google.com> Remove dvrDisplayManagerClientGetSurfaceBuffers

This should be replaced with BufferHubQueue

Bug: 36033302
Test: Build device targets
Change-Id: I658514e1b56b0bdbd523d3fa322f0f2b6a1fc7e8

Signed-off-by: Jiwen 'Steve' Cai <jwcai@google.com>
isplay_manager_service.cpp
isplay_manager_service.h
isplay_surface.cpp
isplay_surface.h
89ed4c8cfd8ad64269dfcff9742e16bdd705b926 10-Feb-2017 Mathias Agopian <mathias@google.com> split libandroid.so

- ANativeWindow (native_window.h) and
AHardwareBuffer (hardware_buffer.h) now live
in libnativewindow.so, which is a vodka library.

- libandroid.so still provide those symbols
via a static library version (libnativewindow.a)

- removed libbinder dependency as well

Test: compiled & booted
Bug: 35164655
Change-Id: Ib4bc8e8fc9ec1891bcbee63c28fd0131d82edf29
ndroid.mk
016e5e3ca751de7e86731349985d1eaf7c072515 22-Feb-2017 Stephen Kiazyk <skiazyk@google.com> Ensure display metrics on display service creation

This fixes a potential race condition where a VR app could request the
display metrics from the VR display service before it actually queries
them from the HWC.

Bug: None
Test: Compiled and ran Vr app.
Change-Id: Ie95b7f5a8ef2e286c7b2994ca94fd87214567e24
isplay_service.cpp
isplay_service.h
ardware_composer.cpp
ardware_composer.h
03436e9c60607ec80c3f5eea873091b2907a3e3d 14-Feb-2017 Steven Thomas <steventhomas@google.com> Merge "Ignore callbacks from the non-active hardware composer"
6e0e9479177677bfbf7a70deef31ab8b1e92061f 14-Feb-2017 Jiyong Park <jiyong@google.com> Merge "Remove TARGET_USES_QCOM_BSP from libvrflinger"
3cfac28462910d3f976aebac54ac7301aca7e434 06-Feb-2017 Steven Thomas <steventhomas@google.com> Ignore callbacks from the non-active hardware composer

Ignore callbacks from the non-active hardware composer so we don't get
e.g. duplicate vsync callbacks, one from each composer.

Bug: None

Test: Manually confirmed with logs we're now ignoring callbacks on the
non-active composer.

Change-Id: I8b475d6283d86c64ff96b41e78528bce8c6ff1d3
isplay_service.cpp
isplay_service.h
ardware_composer.cpp
ardware_composer.h
nclude/dvr/vr_flinger.h
r_flinger.cpp
3c8d4581488de9b49f09e2b98cf83aa3bf2d703a 11-Feb-2017 Jiyong Park <jiyong@google.com> Remove TARGET_USES_QCOM_BSP from libvrflinger

Removing TARGET_USES_QCOM_BSP because 1) it is broken:
hardware/qcom/display/libgralloc,libqdutils do not exist and 2)
conditional compilation must be eliminated from the framework-side code
so that we can build a generic system.img.

Bug: 34115514
Test: build & run

Change-Id: I1fd643003426c52353b608bc6053a4ad80c1676a
ndroid.mk
4766e2a776386489667e792f9c7d8c71131b78c1 28-Jan-2017 Leandro Gracia Gil <leandrogracia@google.com> Introduce an API to verify trusted caller apps by UID.

This CL introduces a new function to make sure only trusted packages
like VrCore can make use of APIs that are not intended for app use.

As a first example, this CL introduces a caller check for taking screenshots,
although any sensitive APIs should implement similar checks.

Package trust is defined by having the RESTRICTED_VR_ACCESS permission.

Bug: 34474022
Change-Id: Ib5a242d1a4e17f59b178fb1465064043613ac369
ndroid.mk
creenshot_service.cpp
06d63de03cb2a551ca99608f5aa0c4f3e200b0fc 04-Jan-2017 Chia-I Wu <olv@google.com> surfaceflinger: cache HWC client targets and buffers

Remember HWC client targets and buffers, and make sure we send each
unique slot/handle pair only once. This allows the composer to
clone/register/retain each buffer only once.

Test: builds and boots
Change-Id: Ib485189043a9c132031e82d4d7380ace3bf9453d
ardware_composer.cpp
c8da5b356ee215f4c8cc53a5728aa303478772b5 08-Feb-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Fix vr flinger deadlock and race condition"
282a5ed48f64e4010f97ca4077e3bd4b54ba3268 08-Feb-2017 Steven Thomas <steventhomas@google.com> Fix vr flinger deadlock and race condition

While investigating hangs when transitioning from 2d --> vr and back I
found a deadlock and race condition in the vr flinger pause/resume
handling. This CL should fix both issues.

Unfortunately there's still another deadlock related to multiple threads
trying to suspend/resume vr flinger, but considering how vr flinger is
currently used by surface flinger we shouldn't ever hit that scenario in
practice.

Bug: None

Test: I was able to reliably get a hang when starting/stopping vr
launcher a few times, but with this CL applied and another CL to remove
calls to SetPowerMode() applied (that CL will be submitted separately),
I no longer see any hangs.

Change-Id: Ie842bf9fb00e4e2937769ed7e1e2ec9cc47861f7
(cherry picked from commit cf921a3919d68d8c8d1b8be39e03a372f6346f57)
ardware_composer.cpp
ardware_composer.h
105036fa54ad282611d355ecea00c470abbfa4a0 08-Feb-2017 Jiwen 'Steve' Cai <jwcai@google.com> Stop calling setPowerMode in VrFlinger

Seems that SetPowerMode from VrFlinger is causing the HIDL HWC service
(android.hardware.graphics.composer@2.1-service) to hang.

Bug: None
Test: Start particles, stop particles, start CubeSea; stop CubeSea
Change-Id: I074568fa0b04041d94dd76768ff27d467e699682
(cherry picked from commit 7fba71a24630bdf757bd4e8a28193a3995c133aa)
ardware_composer.cpp
ardware_composer.h
cd11bd5909e50a3f69937f73a0b5871ad402d85f 07-Feb-2017 Hendrik Wagenaar <hendrikw@google.com> Discard invisible surfaces

* Jiwen found that we would try to post invisible layers, and this
would cause a hang.
* Check to see if the surface is invisible, and if so, discard it

Test: Manually tested with particles
Change-Id: Id4a0813cb30bd48c3cfa4d13dcee59fcb5f58a8d
isplay_surface.cpp
ae2d58b16a231e6afe5867d312e6811c7b710b4c 06-Feb-2017 Hendrik Wagenaar <hendrikw@google.com> Add param null-check + error return

* Fail gracefully when no hidl is passed

Test: Manually ran with nullptr

Change-Id: I2726c5ad512c7115f4c6e99d1e41e0fe267e6ff2
r_flinger.cpp
ea572425ac5438d6d27eca83104b795100ca87af 02-Feb-2017 Hendrik Wagenaar <hendrikw@google.com> Remove access to the backlight brightness

* We don't need to set the display brightness at the moment, and
access to the brightness fd requires an SELinux policy change
that we'd like to avoid, so ifdef out the code for now.

Bug: None
Test: To be tested along with Nick's SELinux policy cl
Change-Id: Ic6de9a1bd15d0eab2780bda31ec67fab94f8d6da
ardware_composer.cpp
3079cb7c32421099a73e1a774b228635eeb3f189 20-Jan-2017 Corey Tabaka <eieio@google.com> Use generic libpdx event bits facility in libvrflinger and bufferhubd.

Use the generic event bits abstraction to support UDS and ServiceFS
backends properly.

Bug: 34466748
Test: start/stop basicvr repeatedly; observe stable bufferhub counts.
Change-Id: I9f2ea67c25860ad7fb931938991a29a37f3391fc
isplay_surface.cpp
a8a92784bc5f6a50ce00311c6161fbcfc0898c5a 27-Jan-2017 Alex Vakulenko <avakulenko@google.com> Add libvrflinger for use in SurfaceFlinger

A separate CL uses this code from SurfaceFlinger.

Bug: None
Test: Manually ran modified SurfaceFlinger
Change-Id: I34588df1365588c0a0265e1e2325e3dd5516206a
ndroid.mk
cquired_buffer.cpp
cquired_buffer.h
ompositor.cpp
ompositor.h
ebug_hud_data.cpp
ebug_hud_data.h
ebug_hud_view.cpp
ebug_hud_view.h
isplay_manager_service.cpp
isplay_manager_service.h
isplay_service.cpp
isplay_service.h
isplay_surface.cpp
isplay_surface.h
poll_event_dispatcher.cpp
poll_event_dispatcher.h
ardware_composer.cpp
ardware_composer.h
nclude/dvr/vr_flinger.h
creenshot_service.cpp
creenshot_service.h
urface_channel.cpp
urface_channel.h
ideo_compositor.cpp
ideo_compositor.h
ideo_mesh_surface.cpp
ideo_mesh_surface.h
r_flinger.cpp
sync_service.cpp
sync_service.h