Why is this incredibly basic material showing up as red in “viewmode shadercomplexity” when doing a mobile preview? On PC, it is bright green like the black void you see in the screenshot. I did this test because I’m trying to optimize a scene of mine for mobile in which every single object was either red, pink, or white. Even the most basic materials such as this.
I have created a test project with what you have displayed in your screenshot.
I do not receive the same thing you are.
There are a couple of steps I would like for you to take.
1.) Recreate a new project and recreate your first.
2.) Send me a list of steps that are the exact steps you have done.
3.) If you have changed any world settings or project settings let me know.
I tested on two new projects with exactly the same results.
Mobile/Tablet
Scalable 2D/3D
No Starter Content
Desktop/Console
Maximum Quality
No Starter Content
Once created, I selected Mobile Preview and typed ‘viewmode shadercomplexity’. Everything is red.
I then deleted everything in the scene except the floor, created a new material with a simple uniform color of ‘0.5’ to diffuse, compiled and applied the new material to the floor, rebuilt level, and played game via mobile preview. Same result as my first post.
I didn’t change any project or world settings. Everything is default.
So there are different modes for viewing inside of UE4. These are for development purposes and are meant to troubleshoot/view different aspects of your project.
Shader Complexity Mode is used to visualize the number of shader instructions being used to calculate each pixel of your scene. It is generally a good indication of how performance-friendly your scene will be. In general, it is used to test overall performance for your base scene, as well as to optimize particle effects, which tend to cause performance spikes with a large amount of overdraw for a short period of time.
Only instruction count is used to calculate shader complexity, which may not always be accurate. For example, a shader with 16 instructions, all texture lookups, will be much slower on all platforms than a shader with 16 math instructions. Also shaders which contain loops that are not unrolled will not be represented accurately by the instruction count, this is mainly an issue for vertex shaders. Overall the instruction count is a good metric in the vast majority of cases.
The view mode uses a color spectrum to indicate how expensive the scene is. Green through red represent a linear relationship of “very inexpensive” to “expensive”, while pink and white indicate a large jump to “very expensive” pixels. Small areas of white can be tolerated, but if the majority of your screen is covered in bright red or white, the performance will be poor.
Here is also a link to our wiki with explanations on different view modes:
I haven’t heard from you in a couple of days. I am checking in to see if you are still experiencing some confusion on this matter or of this answer was helpful to you.
Hello i am getting a bug like the one said before and i dont know how to swich the grayscale mode to a Green-Red one…
I dont care if i actually cant do this. In fact, the only thing i need to know is: in case of grayscaled shader, black means cheap and white means expensive?
Hello, How did you make the shader complexity mode useful when run the game. If I click play the scene will turn to normal nor the shader complexity mode.