Skip to content

Bad PlatformView performance on Android #53532

@t-artikov

Description

@t-artikov

I'm trying to integrate native OpenGL rendering by exposing GLSurfaceView as PlatformView.
On my Nexus 6P (Android 8.1) the performance is quite bad, rendering is not smooth.

Here is a complete example:
https://github.com/t-artikov/flutter_platform_view_test

flutter doctor -v
[✓] Flutter (Channel master, v1.16.4-pre.18, on Linux, locale en_US.UTF-8)
    • Flutter version 1.16.4-pre.18 at /home/timur/flutter
    • Framework revision c8efcb632b (2 days ago), 2020-03-27 22:31:01 -0700
    • Engine revision 3ee9e3d378
    • Dart version 2.8.0 (build 2.8.0-dev.18.0 1402e8e1a4)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /home/timur/Android/Sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.2
    • ANDROID_HOME = /home/timur/Android/Sdk
    • Java binary at: /snap/android-studio/84/android-studio/jre/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)
    • All Android licenses accepted.

[✓] Linux toolchain - develop for Linux desktop
    • clang++ 9.0.0
    • GNU Make 4.1

[✓] Android Studio (version 3.6)
    • Android Studio at /snap/android-studio/84/android-studio
    • Flutter plugin version 44.0.2
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)

[✓] VS Code (version 1.43.0)
    • VS Code at /usr/share/code
    • Flutter extension version 3.8.1

[✓] Connected device (2 available)
    • Nexus 6P • ENU7N15B06000345 • android-arm64 • Android 8.1.0 (API 27)
    • Linux    • Linux            • linux-x64     • Linux

• No issues found!  

Observatory timeline

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: platform-viewsEmbedding Android/iOS views in Flutter appsc: performanceRelates to speed or footprint issues (see "perf:" labels)c: renderingUI glitches reported at the engine/skia or impeller rendering levelengineflutter/engine related. See also e: labels.perf: speedPerformance issues related to (mostly rendering) speedplatform-androidAndroid applications specificallyteam-androidOwned by Android platform teamtriaged-androidTriaged by Android platform team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions