Age | Commit message (Collapse) | Author |
|
into android12-hostruntime-dev
|
|
The underlying functionality was ifdef'd out, but it compiles fine on
host.
Test: ShadowNativeSurfaceTest in Google3
Bug: 344979295
Change-Id: Ieca45f62a7e0b7c72c8c55213e669f5bd2f26b46
|
|
android12-hostruntime-dev
|
|
into android12-hostruntime-dev
|
|
Attempting to run `m libhwui` causes compile errors in the
android12-hostruntime-dev repo. This is because hwui has been modified
primarily to enhance host graphics, but as a result trying to build it
using the Android toolchain causes compile errors.
Update libhwui to fix various compile errors so it's possible to run `m
libhwui`.
Test: m libhwui
Bug: 344979295
Change-Id: I74a7d09e2f7dd8249c8e6e692e6783cfb70bc6f8
|
|
Summary:
* CanvasContext.cpp - This was not merged correctly when the initial HW
rendering patches were applied from sc-layoutlib-native. This causes
compile errors when `m libhwui` is done, which causes hwui to also be
built using the standard Android toolchain.
* RootRenderNode.cpp/RenderThread.h - Used for RenderNode animation
logic
* android_canvas.cpp - this is needed for Surface.lockCanvas and
Surface.unlockCanvasAndPost
* android_bitmap.cpp - appears to be unused by RNG, but added for
consistency with android_canvas.
* android_graphics_HardwareRenderer - enable RenderNode animation logic.
Test: m libhwui
Bug: 344979295
Change-Id: If52fe2a46839a5231356066e82cc6bd0baa9ee8b
|
|
Q and R" into android12-hostruntime-dev
|
|
and R
Previously, native ImageReader was not used below Android S due to the
non-existence of `ImageReader$ImagePlane`.
Add an API level check to the ImageReader ImageReader binding logic to
support Q and R.
Test: ShadowNativeHardwareRendererTest
Test: ShadowNativeImageReaderTest
Test: HardwareAcceleratedActivityRenderTest
Bug: 344979295
Change-Id: I949382eb17db983d4c486e5c065ed0bdbf5d59eb
|
|
into android12-hostruntime-dev
|
|
kN32_SkColorType is determined at compile-time using a macro that checks
the current architectiure. On Mac, this value is different than Linux or
Windows. As a result, when HW rendering occurs on a Mac, the blue and
red pixels are swapped, which implies one is using
kRGBA_8888_SkColorType and the other is using kBGRA_8888_SkColorType.
When an Android Bitmap object is initialized using
Bitmap.Config.ARGB_8888, it uses kN32_SkColorType
Update SkiaHostPipeline to use kN32_SkColorType so the value is
consistent with what Bitmap uses.
Test: HardwareAcceleratedActivityRenderTest on Mac
Test: ShadowNativeHardwareRendererTest on Mac
Bug: 338399395
Change-Id: Ic037fea16abcbf950d69daafadbf91fb9c6653a6
|
|
android12-hostruntime-dev
|
|
In Android, strtof is used in places such as PathParser to parse floats
in path expressions in drawables, i.e. "C0.2,0 0.1,1 0.5, 1 L 1,1".
In certain locales (e.g. Germany), commas are interpreted as part of
numbers, so this is not parsed correctly.
Use the minimal "C" numeric locale to ensure consistency when doing
strtof and other floating point parsing operations.
This is also done in LayoutlibLoader.
Bug: 334093536
Test: ShadowNativePathParserTest in Google3
Change-Id: I21e7115240045ebf065362a6e28f6af710509a13
|
|
android12-hostruntime-dev
|
|
|
|
This allows AnimatedImageDrawables to be rendered on Mac and Windows.
Also, disable the AnimatedEndListener mechanism on host. It requires
native Looper, which is not available on host.
Bug: 329895268
Bug: 274171734
Test: ShadowNativeAnimatedImageDrawableTest on Windows
Change-Id: I38b67e6f0e4f00bd288469659265bb78eea7001b
|
|
Update logic in CursorWindow.cpp and
android_database_SQLiteConnection.cpp to use libbase's MappedFile, which
is supported on all platforms, including Windows. Also ifdef out the
Parcel support in CursorWindow, since native Parcel is not supported in
RNR.
Bug: 317884162
Test: ctesque SQLiteDatabaseTest on Windows
Change-Id: I138064847f0afcd264c591bd8d04ed4f4b48362c
|
|
android12-hostruntime-dev
|
|
This allows the ICU system properties to be consistent with the latest
version of LayoutLib.
Test: nativegraphics integration tests in Google3
Change-Id: I894b9b794a811a53a14462faf665d871bd423730
|
|
android12-hostruntime-dev
|
|
android12-hostruntime-dev
|
|
This logic was used in Android O through P when copying Bitmaps and then
removed in Q.
Add the logic back for better backwards compatibility with O through P.
Bug: 321811781
Test: m robolectric_native_runtime dist
Change-Id: I6cbc490613cd242deb7b0849c1cb23c33d8cae45
|
|
into android12-hostruntime-dev
|
|
Change the system property from 'robolectric.nativeruntime.languageTag'
to 'icu.locale.default'. The latter is what has been upstreamed to the
LayoutLib main branch.
Bug: 321740537
Test: m robolectric_native_runtime dist
Change-Id: I7c0ffffe9f8deefc3027b8105f0a58501bf01042
|
|
|
|
This results in significant file size reductions:
* librobolectric-nativeruntime.so: 118MiB -> 16MiB
* librobolectric-nativeruntime.dll: 162MiB -> 13MiB
Test: m robolectric_native_runtime dist
Change-Id: Ida323dca4404ed674d706c71c16c393a39191450
|
|
into android12-hostruntime-dev
|
|
The RNG version of Bitmap::allocateHardwareBitmap() is implemented on
top of Bitmap::allocateHeapBitmap(). However, per the class comment
description, this factory method should also copy the content of the
source bitmap into the newly allocated bitmap.
Bug: 310222823,242670053
Test: m -j robolectric_native_runtime dist
Change-Id: Ib657fd33b7862411977832da14ce39ec8b22812e
|
|
android12-hostruntime-dev
|
|
The Windows DuplicateHandle API can be used in place of fcntl with
F_DUPFD_CLOEXEC
Also add Windows variants of isSeekable and AutoFdSeek to hwui JNI
utils.
Test: BitmapFactory decodeFileDescriptor* tests on Windows
Bug: 317994636
Change-Id: Ie6448a22df6c9c300f38af0b4685040787832d5b
|
|
|
|
In a previous CL, the 'libnativehelper_lazy' dependency was switched to
libnativehelper. This caused an apex_available platform error because
'libnativehelper' is not available for the platform apex. Switch it back
to libnativehelper_lazy.
Bug: 317896089
Test: m robolectric_native_runtime dist
Change-Id: I187a065d2c2a9325f45fb3dfd311fca8ef4c4696
|
|
android12-hostruntime-dev
|
|
Currently SQLite JNI is disabled for Windows because both
androidfw/CursorWindow.cpp as well as the SQLite JNI registration logic
requires mmap ashmem. Supporting this is feasible but will be done in a
separate CL.
Note that some functionality still does not work 100% in Windows, such
as BitmapFactory.decodeStream and some font-related methods. These will
be resolved separately.
Test: m robolectric_native_runtime dist
Test: Robolectric ShadowNativeMatrixTest
Change-Id: Ie932ddec1298597bc3f6051574bc9dcc82b38929
|
|
android12-hostruntime-dev
|
|
Original change, author, and description:
Change-Id: I83466bc54bcea0d7a397c24d519bcba620231adb
---
https://android.googlesource.com/platform/frameworks/base/+/33c1ea73e869e68b793ae9a21c2d8ea41e9f1c9a
Chet Haase
Clipping Views to Outlines has existed for several releases,
as has providing a Path for shaping Oulines. However, using
a Path-shaped Outline to clip a View against was specifically
disabled internally, due to historical functionality limitations
(prior to enabling Skia for HWUI rendering) as well as performance
concerns.
On current (even relatively low-end) hardware, path clipping is now
sufficiently performant that we are enabling this functionality.
This functionality will be used by AndroidX APIs that enable easier
shaping via paths.
---
Only the native libs/hwui changes have been backported.
Bug: 315048748
Test: m -j robolectric_native_runtime dist
Change-Id: I4129d0bf7239a0e1e9e82c9f526d052d1102ce17
|
|
android12-hostruntime-dev
|
|
This fixes a build break. It was not added in aosp/2874695.
Test: m robolectric_native_runtime dist
Change-Id: I5602aa4bce64fece66fdcd617573afde56511b4b
|
|
android12-hostruntime-dev
|
|
This method was added in Android T, but it it trivial to backport to
RNG's Android S native code.
Test: ShadowNativeHardwareRendererTest
Change-Id: I9729ee95b4e373abbab59a9a2ec5052c6d485e5e
|
|
android12-hostruntime-dev
|
|
Change the system property from `icu.dir` to `icu.data.path`. This is to
be more consistent with the recent versions of LayoutLib, which uses
`icu.data.path`.
Test: m robolectric_native_runtime dist
Change-Id: I31b57dc911fe3dfdd1ffed9abda5c28f821f9810
|
|
android12-hostruntime-dev
|
|
Test: m -j robolectric_native_runtime dist
Change-Id: I51dfef128fdf4c8362a1f837bf64416a06c1318f
|
|
android12-hostruntime-dev
|
|
android12-hostruntime-dev
|
|
As a first step of deprecating UI fonts, make setElegantTextFlag as true
by default if the target SDK is set to Android 15 or later..
Bug: 308879280
Test: m -j robolectric_native_runtime dist
(cherry picked from https://android-review.googlesource.com/q/commit:cbd21e06413c24fdb8b5457b13e57cc213d9755d)
Merged-In: If8e40c075122cafd2f89ae703bf6a5f07ebc7bd0
Change-Id: If8e40c075122cafd2f89ae703bf6a5f07ebc7bd0
|
|
If the ICU dat file does not exist, there will be obscure crashes in
LineBreaker native methods, which are hard to debug and root cause.
Add an explicit check that the ICU data directory is valid.
Test: m -j robolectric_native_runtime dist
Test: Google3 TAP
Change-Id: Iac738cd7a81cf9fba43c97b06b7e575df52ff949
|
|
There was a lot of complex SDK-specific logic to initialize some
RenderNode Java accessor methods. This logic gets even more complex in
future SDK versions. However, these Java callbacks are never invoked, so
it is unnecessary to set them up. Surround that with ifdef __ANDROID__
to avoid running it on host.
Test: m -j robolectric_native_runtime dist
Change-Id: Ib81b42d0dd547f0534ee5aa7b627f487d729d09a
|
|
|
|
Test: m -j robolectric_native_runtime dist
Change-Id: Ia6f22645902e65045166166c326d8d7c20032a6a
|