我在运行 Flutter 默认的初始计数器应用程序时在控制台上得到了这个。我该如何解决这个问题?

亚历克斯

这是我在运行 flutter 附带的初始 Flutter 应用程序时在调试控制台中获得的大部分内容。这看起来不正常。我该怎么做才能解决这个问题?

 Built build/app/outputs/apk/debug/app-debug.apk.
D/FlutterActivity(12595): Using the launch theme as normal theme.
D/FlutterActivityAndFragmentDelegate(12595): Setting up FlutterEngine.
D/FlutterActivityAndFragmentDelegate(12595): No preferred FlutterEngine was provided. Creating a new FlutterEngine for this FlutterFragment.
D/FlutterActivityAndFragmentDelegate(12595): Attaching FlutterEngine to the Activity that owns this Fragment.
D/FlutterView(12595): Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ad2d938
D/FlutterActivityAndFragmentDelegate(12595): Executing Dart entrypoint: main, and sending initial route: /
D/HostConnection(12595): HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_native_sync_v3 ANDROID_EMU_native_sync_v4 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_YUV420_888_to_NV21 ANDROID_EMU_YUV_Cache ANDROID_EMU_async_unmap_buffer GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_gles_max_version_3_0
I/Choreographer(12595): Skipped 913 frames!  The application may be doing too much work on its main thread.
D/EGL_emulation(12595): eglMakeCurrent: 0xe02eec60: ver 3 0 (tinfo 0xe030ba70)
D/EGL_emulation(12595): eglMakeCurrent: 0xeb57f3a0: ver 3 0 (tinfo 0xe038db30)
D/EGL_emulation(12595): eglMakeCurrent: 0xe02eede0: ver 3 0 (tinfo 0xe030ba70)
D/EGL_emulation(12595): eglMakeCurrent: 0xeb57f3a0: ver 3 0 (tinfo 0xe038db30)
D/FlutterView(12595): Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ad2d938
D/FlutterView(12595): Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ad2d938
D/EGL_emulation(12595): eglMakeCurrent: 0xeb57f3a0: ver 3 0 (tinfo 0xe038db30)
D/FlutterView(12595): Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ad2d938
D/EGL_emulation(12595): eglCreateContext: 0xe02eede0: maj 3 min 0 rcv 3
D/EGL_emulation(12595): eglMakeCurrent: 0xe02eede0: ver 3 0 (tinfo 0xe030ba70)
I/Choreographer(12595): Skipped 176 frames!  The application may be doing too much work on its main thread.
D/EGL_emulation(12595): eglMakeCurrent: 0xeb57f3a0: ver 3 0 (tinfo 0xe038db30)
D/FlutterView(12595): Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@ad2d938
D/EGL_emulation(12595): eglCreateContext: 0xd4b696e0: maj 3 min 0 rcv 3
D/EGL_emulation(12595): eglMakeCurrent: 0xd4b696e0: ver 3 0 (tinfo 0xe030ba70)
I/Choreographer(12595): Skipped 66 frames!  The application may be doing too much work on its main thread.
D/EGL_emulation(12595): eglMakeCurrent: 0xd4b696e0: ver 3 0 (tinfo 0xe030ba70)
Reloaded 1 of 478 libraries in 2,280ms.
杰西·劳森

假设您没有接触过启动代码,跳过的帧在您运行时下降这一事实告诉我,这是在您的机器上运行模拟器的自然副产品。通常,可以安全地忽略这些消息中 < 100 个跳过的帧——这意味着您的计算机很难实时运行模拟器。

将您的物理 Android 设备置于调试模式,然后使用电缆连接它,然后选择该设备作为您的构建目标。如果您在手机上运行该应用程序,您是否仍然会出现跳帧?如果您正在运行任何类型的现代 Android 手机,您通常不会。

Android 模拟器需要大量的处理能力才能运行。大多数人普遍认为,在物理设备上进行调试比通过仿真器进行调试要快几倍。

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章