Stream Optimization
Last updated
Last updated
When optimizing for YOM, it's crucial to understand the distinct performance considerations for the stream, game, and server components:
Stream: Focus on minimizing latency and optimizing video compression for smooth playback across devices.
Game: Concentrate on frame rate, visual quality, and efficient resource usage within Unreal Engine.
Server: Prioritize network performance, concurrent user capacity, and efficient data processing for multiplayer experiences.
Each component requires specific benchmarking and optimization techniques to ensure optimal overall performance.
To assess your stream's performance, click the "information" icon in the modal. This reveals a UI displaying:
QP (Quantization Parameter): Indicates the level of video compression applied.
Latency: Measures the delay between the browser and the game.
FPS (Frames Per Second): Shows how quickly the game renders.
Ping: Represents the distance between the game and server (relevant for multiplayer games).
For optimizing the performance of your game, we have a comprehensive guide available: Download the YOM Optimzation Guide. It provides valuable insights, tips, and best practices to ensure optimal performance.
Profiling is crucial for analyzing performance issues and determining necessary optimizations. Here are key points to remember:
Profile early and often
Test on target hardware as soon as possible
Ensure your development team understands profiling basics
Optimize after profiling shows problems
Minimize interference:
Turn off unnecessary features (e.g., TAA, V-Sync)
Disable Framerate Smoothing in Project Settings
Profile in a build:
Use a test build when possible
Testing in a dev build can inflate draw thread with noise/interference
If profiling in the editor:
Use standalone mode
Set the editor to NOT update in realtime
Minimize the editor window
Identify bottlenecks:
Game Thread
Render Thread (GPU/CPU)
Use r.ScreenPercentage 10
to quickly check if you're GPU bound
Use profiling commands:
stat unit
: Shows largest numbers indicating likely bottlenecks
stat unitGraph
: Displays line graph playback; heartbeats/spikes show repeating hitches
Other useful commands: stat fps
, stat scenerendering
, stat gpu
, stat engine
, stat streaming
, stat lighting
, stat RHI
Analyze results:
Frame time
CPU Game Thread (Code or Blueprint)
CPU Draw (Object count, draw calls, culling)
GPU Render (Shader complexity, shader calls, overdraw, lights/lighting)
Use these view modes to identify specific issues:
Shader Complexity: Shows shader cost and overdraw
Quad Overdraw: Reveals overdraw for simplification
Light Complexity: Displays the complexity of light
Lightmap Density: Shows texel density for lightmapping
Stationary Light Overlap: Highlights areas where more than 4 stationary lights affect objects
Lighting:
Directional Lighting should NOT be stationary
Limit light actors per level area and keep light radii small
Disable shadow casting on unimportant assets
Meshes and LODs:
Review meshes for polycount
Use LODs and Nanite
Use (Hierarchical) Instanced Static Meshes
Textures:
Clamp max texture size of objects
Pack/compress greyscale textures in RGB channels
Use texture atlases for meshes
Keep Lightmap resolution as low as possible
Materials and Shaders:
Use switch parameters in pixel shaders to turn off unneeded nodes
Check Material Instruction Counts (e.g., 350 for characters, 150-200 for environment)
Use trimsheets and shaders applicable to multiple assets
Performance:
Disable Motion Blur
Avoid temporal effects like TAA
Remove as many transparent pixels as possible
Asset Management:
Use Window > Developer Tools to merge actors into 1 asset
When texture pool is over budget, use r.Streaming.PoolSize value in MiB
Use a slush/dummy project to review marketplace content
Create a custom template as a clean slate for projects with tailored default settings
By following these optimization techniques and best practices, you can significantly improve the performance of your metaverse experiences. Remember to profile regularly and focus your optimization efforts on the areas that show the most significant impact on performance.