Introduction

Pixel Streaming allows Unreal games to run on remote architecture, removing the rendering burden from the user's machine. To provide the best 3D experience to your users, we assembled several suggestions for optimization. Not all of these will be applicable or appropriate for your project.

Optimizing Textures & Materials

Use instanced materials

If possible, instance your materials and add parameters to customize them. This can reduce the total number of unique materials in your project. Fewer materials in the project will result in lower compilation time for your shaders.

Reduce texture file sizes to under 2k

Large, high resolution textures provide a level of detail that is often unnecessary, and unnoticed, in a pixel streaming situation...particularly for textures used in materials that will not be viewed up close. As a general rule, textures over 2k greatly increase the load time for levels, without increasing the visual detail enough to offset that load time.

You can also substantially reduce the size of individual texture files by converting them to JPG, rather than using uncompressed formats such as PNG.

Use Channel Packing

Channel packing is done by using different grayscale images in each of a texture's channels. This means you can further reduce the total number of texture files in your project, as well as the complexity of your shaders, but does require a bit of extra work to achieve.

Shader Complexity View Mode

Use the "Shader Complexity" View Mode to 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.

Optimizing Ray Tracing

Ray Tracing Quality Switch Replace Node

Use the "Ray Tracing Quality Switch Replace" node to replace entire parts of your Material logic to lower the cost of features like RTGI, RT Reflections, and RT Translucency with less complex logic. This is a global change that affects all ray tracing effects.

Deactivate Cast Ray Traced Shadows

In the Materials editor, enable or disable the "Cast Ray Traced Shadows" checkbox to control if that Material should, or should not cast ray traced shadows. This can be helpful reducing calculation costs for shadows in your scenes.

Post Process Volume

In a Ray Tracing enabled project, restrict the "Samples Per Pixel" value to 2 or lower. This value sets the number of samples to use per pixel for Ray Traced Reflections. Although additional samples increase reflection quality, they are offset by a decrease in performance.

Optimizing Geometry

Levels of Detail

Creating custom LODs, or using engine-generated ones, can reduce the amount of polys being drawn on-screen.

Defeaturing

For meshes that can't be removed from the scene or hidden from view, defeaturing is a method of simplifying a mesh by removing protrusions and holes. This can increase rendering performance by decreasing the number of vertices and triangles the mesh contains.

You could also consider creating your LODs from Defeatured geometry to optimize even further!

Jacketing

Any objects that are occluded — that is, blocked from the camera's current view by other objects — can safely be skipped during rendering to improve performance without changing the final image.

The Unreal Editor offers a tool, through the right-click menu on a static mesh, that scans it to determine which if any meshes are fully occluded. Once identified, you can isolate them on their own Layer, remove them from the Level entirely, or simplify their geometry to remove internal details.

Cull Distance Volumes

To further reduce the number of polygons drawn in frame, you can use "Cull Distance Volume" to manually define the distance at which certain geometry sets are no longer drawn in the frame.

Optimizing Physics & Foliage

For any objects that won't be needed for physics-based interaction, disable "Simulate Physics."

Use the Player Collision view mode to check for any objects with unnecessary collision enabled and disable it to improve game performance.

Similar to the Cull Distance Volumes on geometry, experiment with setting a distance for your foliage in the Foliage Tool to obtain a nice balance that produces good looking foliage without massive amounts of compute, or consider using Imposter Sprites / Billboards as a replacement for heavy foliage meshes.

When painting foliage in your level, select the “No Collision” preset for all instances that will not interact with other scene objects.

Optimizing Lighting

If your project uses baked lighting, disable dynamic shadow casting on static meshes, and disable shadow casting entirely on objects with translucent materials.

Disable "Affect Global Illumination" on all the lights in your level that you can, and reduce the attenuation radius on each light, where possible, so that only the desired objects are lit with them.

Consider using an HDRI map rather than Sky Atmosphere, disable Real Time Capture for your SkyLight actor, or even consider using a cubemap for your environment!

Consider using the "Light Complexity" View Mode to help focus your lighting optimization efforts. Light Complexity shows the number of non-static lights affecting your geometry. This is useful for tracking lighting cost - the more lights affecting a surface, the more expensive it will be to shade.

Further Reading

The official Unreal documentation provides much greater depth on these (and many other) tools. Here are just a few links to delve into!

GPU Profiling
How to optimize the GPU demands of your game.
Pixel Streaming
Run your Unreal Engine application on a server in the cloud, and stream its rendered frames and audio to browsers and mobile devices over WebRTC.
Working with Content
Information on using art created in external applications, importing it into Unreal Engine 4, and setting it up for use in visualization and interactive applications.
View Modes
Explanations for the available View Modes within the viewports.
Cubemaps
The landing page for cubemaps: creation, export, import, and usage within Unreal Engine 4.