Commit Graph

23 Commits

Author SHA1 Message Date
Bo Liu
d336f5d95f Deprecate is_layer for vulkan functor
Webview no longer needs this.

Bug: 124123583
Test: comppiles and vulkan webview in layer keeps working
Change-Id: Ib54e33649eb027a03184c5d7588cfd9568c90a6c
2019-03-25 09:34:27 -04:00
Bo Liu
d25d1345a3 Do not call postDrawVk if did not call drawVk
Reland enable vulkan webview functor

Bug: 123877499
Bug: 115613038
Test: Gmail in bug no longer crashing.
Change-Id: I7df761a4691ceaa6c2a02b256d61554e57139409
2019-02-04 20:02:18 -08:00
TreeHugger Robot
30780a26f4 Merge "Revert "Enable vulkan webview draw functor"" 2019-02-05 01:15:34 +00:00
Bo Liu
a2b2535bd7 Revert "Enable vulkan webview draw functor"
This reverts commit dec730fda5.

Reason for revert: b/123877499

Change-Id: I14fc562c81f5ef5dab0f5404402b64858e54e364
2019-02-04 23:05:44 +00:00
TreeHugger Robot
e703b1985f Merge "Enable vulkan webview draw functor" 2019-01-31 03:41:29 +00:00
Greg Daniel
eaf310e1ce Update Vulkan skia creation to use apiVersion instead of instanceVersion
This updates to use Skia's new api which takes the vulkan apiVersion
instead of the instance version. This is technically more correct since
the application apiVersion is really the only client modifiable version
value in vulkan.

This change also updates the webview structs to use the apiVersion as
well.

Test: manual build and testing.
Change-Id: I6ce7c20949eb7242f7bbe69955b54c0785696891
2019-01-29 15:03:10 -05:00
Bo Liu
b6da7f634f Add color space params to webview gl functor
Bug: 111436479
Test: Compiles
Change-Id: I6713afbb871a5c7027bac1e0f52ce2a841f38e25
2019-01-24 14:04:58 -08:00
Bo Liu
dec730fda5 Enable vulkan webview draw functor
Bug: 115613038
Test: Webview with vulkan enabled works
Change-Id: Ia450e93925ea04ff13d6e1731618a16862c66539
2019-01-24 04:22:35 +00:00
Bo Liu
7b8c1eb302 VkFunctorDrawable implementation
Bug: 115613038
Test: Turning on vulkan with appropriate webview apk does not crash and
sort of works.
Change-Id: If1504da7a35e4bd74a994ab2c2a351e6bc415a18
2019-01-15 15:25:04 -08:00
Chris Blume
1a2bdc8c65 Put HWUI & Webview color space in a struct
The color space parameters are currently separate members. This was
making passing color space parameters to functions a bit messy.

This CL puts the color space parameters into their own struct which can
be cleanly passed to functions.

Test: Builds locally
Change-Id: I3709b88dbdedb9616d4905ee973c3099f95b3ca7
2019-01-14 14:48:46 -08:00
TreeHugger Robot
09b1843ca4 Merge "Rename Vulkan functor items to match style" 2019-01-11 01:09:00 +00:00
Chris Blume
237b092884 Rename Vulkan functor items to match style
Several of the first-iteration file/class/member variable names did not
match the style of their surrounding neighbors. This CL fixes that.

Test: Compiles
Change-Id: I9374e6cab79c57413e728d253067306d15011f2c
2019-01-10 13:06:46 -08:00
Bo Liu
30eef074f2 Make sure interop path works with draw_fn
plat_support to pass through the GL functor even if hwui is using vulkan
pipeline, since interop calls the GL functor.

Also remove sGLDrawThread and call functor on render thread, since
onDestroy and onContextDestroy are currently hard coded to run on render
thread as well, and functor expects all calls to be called on a single
thread.

Bug: 115613038
Test: draw_fn functor works with vulkan enabled
Change-Id: Ie3fa643695e95a6cc383f7ffe3eb3ad741792707
2019-01-09 20:41:06 +00:00
Bo Liu
d6668e7c0c Plumb new functor in native/webview
Add plumbing to native/webview for the new functor.
Add a void* data parameter to avoid having to use a thread safe
map for in both the plumbing and in webview.

Test: Compiles and webview runs
Bug: 120997728
Change-Id: I0f9f3acb05688a5afcf95974bc0b3b117f33a8e3
2019-01-03 19:15:18 +00:00
Bo Liu
788d9577bc Add C API for new webview draw functor
Test: Builds successfully.
Change-Id: I684c2a976a92e1f1c6e116a8593e79a95c11bfb5
2018-12-13 11:23:11 -08:00
Chris Blume
4142339381 Add non-interop Vulkan functor
An interop Vulkan functor already exists. It will call the OpenGL
functor and use AHardwareBuffer to translate the OpenGL textures into
something which can be used in Vulkan.

This CL adds the frameworks for a non-interop Vulkan functor. This
functor is not yet complete (and as a result cannot yet be tested). This
is just setting the stage for future work.

Test: This is dead code and cannot yet be tested.
BUG=115613038

Change-Id: I2b87c86cb511abb961c31c17c2fbbc085b07ca4a
2018-12-05 16:26:59 -08:00
Chris Blume
83a9937f18 Add explicit values to ABI enums in libs/hwui
In a separate code review we agreed that at ABI boundaries it feels nice
to explicitly call out enum values rather than rely on the rules of
C/C++ which others may not be comfortable with.

This CL adds explicit values to enums inside draw_gl.h.

Test: I built and tested on a Pixel 2.
Change-Id: I64c03e2684c1ab096a9c0665e4ed3d8b7bb22ac7
2018-11-30 16:20:01 -08:00
TreeHugger Robot
9d03c64c97 Merge "Use "override" keyword instead of "virtual"." 2018-11-27 16:50:34 +00:00
Chris Blume
0fd02aa33d Use "override" keyword instead of "virtual".
"override" provides a compile-time gaurantee that the function is indeed
overriding a virtual function. This prevents the potential mistake of
creating a new virtual function rather than overriding the original.

I happened to notice we could use "override" here instead of "virtual".
Might as well tidy up a bit.

Test: Built locally
BUG=115613038

Change-Id: I7f43f4a466d8ceaa1b863d6a2af054e69618d0c8
2018-11-19 14:25:31 -08:00
Dan Willemsen
d6764f8503 Merge "Convert libwebviewchromium_plat_support to Android.bp" am: 1feeeba433 am: e9db0313a3
am: f1c1db0153

Change-Id: I2aaa83120ea4c50bff44dbcbe976795602fdc89f
2018-11-19 11:22:57 -08:00
Dan Willemsen
f25ac31a60 Convert libwebviewchromium_plat_support to Android.bp
See build/soong/README.md for more information.

Test: m libwebviewchromium_plat_support
Change-Id: Ia999010453d428ddc12d2316436520d866498d78
2018-11-18 19:16:55 -08:00
John Reck
18f442eb2d Remove RenderPipelineType::OpenGL (1/many)
Just removes the define & all things referencing the define.

Test: hwui_unit passes
Change-Id: I3f98c271e23ef696c40addf260abdc0fb149a70d
2018-04-11 13:39:19 -07:00
Torne (Richard Coles)
0f03fbe1ea Move WebView plat_support from frameworks/webview.
Move this code to be in the same repository as the other parts of
WebView's current implementation.

Bug: 62445369
Test: m
Change-Id: I567eac7f3484fa78a948fb84545e578fe18c236d
2018-02-21 12:17:47 -05:00