circle-loader
0
by
0/ 1481/ /4

1) GPU Skinning does not take effect

2) Check the warning question of the convex hull report

3) Unity 2019 image compression format selection

4) The impact of Android Export packaging on compression

5) The Unknown part of Android memory leaks


Rendering

Q: Unity Version: 2019.3.0f6

Shader: GPUSkinningUnlitSkin2

Test Scene: Adam_Player_Crowd

Test Device: Samsung S5

I used GPU Skinning on Git to test on the PC, finding that the number of DrawCalls decreased, and there is no consumption of Animator.update and the Instancing happened. When I built it on Samaung S5, there is no overhead of Animator.update in Unity Profiler, but the DrawCall didn’t decrease, and there is no Instancing. Is there any part that is not set?

In addition, is GPU Skinning limited to OpenGL ES 3.0 if I want to use Instancing? Or can I use it on OpenGL ES 2.0?

PC

Samsung S5

A: Refer to the official website document, as described below, GPU Instancing is not available on OpenGL ES 2.0.

 


Mesh

Q: There is a warning about a complicated model:
Couldn
’t create a Convex Mesh from source mesh “**” within the maximum polygons limit (256). The partial hull will be used. Consider simplifying your mesh.

After I used SimpleLod to reduce the meshes, I didn’t reach 256, but this warning is no longer reported. What is going on with this warning? How to avoid it when modeling?

A: The generated Convex Mesh can only have up to 255 triangles. Your original model is too complicated, and 255 triangles are not enough to represent the outline.


Texture

Q: Regarding the choice of image compression format, I read the previous blog saying that Android chooses ETC2 and Apple chooses PVRTC. Now the project has been upgraded to Unity 2019.2.21f1, more formats are available, so I would like to ask the following questions: (Unity version: 2019.2.21f1)

  1. In the new version of Unity 2019, how to choose the Format for Android and Apple?
  2. Is the ASTC format available for Android now, and what is the market share?
  3. What does Resize Algorithm and Override ETC2 fallback mean and how to choose?
  4. How to choose among HDR, 6X6, 10X10?

Could anyone share some insights? Thank you

A1: Personally speaking, for Question 1, It is better to choose ASTC for iOS and ETC2 for Android;

For questions 3&4, you can look at the official documentation of Texture. After reading this, you can basically understand it. Then, according to the needs of the project, I believe there will be a good choice.

 

A2: Now the newly launched projects of tx have begun to popularize the use of ASTC, so ASTC can be fully selected in your case. In 2019, ASTC can be selected by default when importing, especially for lightmaps and normals. Unity now defaults to use 6×6, but other sizes can be selected according to the project.


AssetBundle

Q: The settings of build.gradle in an Android Gradle product are as follows:

aaptOptions
{
noCompress ‘.unity3d’, ‘.ress’, ‘.resource’, ‘.obb’
}

In the current test, if the AssetBundle is not configured to be uncompressed, the package body will be reduced a bit, which has almost the same the effect as LZMA compression on the AssetBundle. If the compressed package is compressed twice in this way, what is the decompression process then? Does it have any impact on runtime performance?

Based on my personal experience, the Android APK package is decompressed during installation. In other words, after the installation is complete, it will look the same in the hard disk regardless of whether it is compressed twice. Could anyone with relevant experience make an explanation on this?

A: The Android APK is not decompressed after installation, so in theory, obtaining the “secondary compressed” Bundle in it during runtime requires a further decompression step. There is feedback from other developers that if it is changed to “secondary compression”, the time-consuming of loading AssetBundle and loading resources from AssetBundle will be significantly greater.

Therefore, before modification, it is recommended to use the AssetBundle resources of your own project to do a test to see if the time-consuming difference between the two parts is obvious.


Memory

Q: What is the Unknown part of Android memory in general? After repeatedly entering and exiting a scene, Unity’s resources were released normally without leakage, but this Unknown has been growing.

A: This is the anonymous memory allocated through mmap using LuaJIT. Lua memory is here. Regular Lua memory is allocated through malloc and will appear in Native Heap; the other big part is Mono memory, and Boehm GC is also allocated through mmap on Android; then it also contains the memory allocation of the third-party so library.


That’s all for today’s sharing. Of course, life may have its limit but knowledge knows no bounds. In the long development cycle, these problems you see maybe just the tip of the iceberg. We have already prepared many technical topics on the UWA blog, waiting for you to explore and share them together. You are welcome to join in, who loves progress. Perhaps your method can solve the urgent needs of others, and the “stone” of other mountains can also attack your “jade”.

YOU MAY ALSO LIKE!!!

UWA Website: https://en.uwa4d.com

UWA Blogs: https://blog.en.uwa4d.com

LinkedIn: https://www.linkedin.com/company/uwahub

Facebook: https://www.facebook.com/uwa4d

Twitter: https://twitter.com/uwa4d

Related Topics

Post a Reply

Your email address will not be published.