Performance Guide#
This performance reference covers CloudXR.js and WebXR tuning controls for balancing visual quality and frame stability.
Quick Reference#
Setting |
Set in |
Balanced |
Performance-focused |
|---|---|---|---|
|
|
|
|
|
|
|
|
|
CloudXR.js + WebXR |
|
|
|
WebGL context |
|
|
|
CloudXR.js |
|
|
|
CloudXR.js |
|
|
Primary Tuning Controls#
framebufferScaleFactor(WebXR): client render resolution scalingfixedFoveation(WebXR): peripheral quality reduction for performancedeviceFrameRate(CloudXR.js + WebXR): target refresh and stream timing alignmentperEyeWidth/perEyeHeight(CloudXR.js): stream resolution per eyemaxStreamingBitrateKbps(CloudXR.js): stream bitrate ceilingantialias(WebGL): multisampling cost/quality tradeoff
Framebuffer Scale Factor#
framebufferScaleFactor controls XR framebuffer resolution scaling and strongly affects image clarity and frame time.
Higher values improve clarity but increase GPU cost.
On Quest-class devices,
1.4-1.5is a practical high-quality range.
Fixed Foveation#
fixedFoveation reduces peripheral shading cost to improve performance.
0.666(medium) is a good default balance.1.0(high) prioritizes performance with more peripheral degradation.
WebGL Antialiasing#
Set WebGL antialias to false by default for headset workloads. The quality gain is typically small relative to frame-time cost.
Stream Resolution and Bitrate#
perEyeWidth / perEyeHeight and maxStreamingBitrateKbps must be tuned together:
Resolution controls source detail and encode/decode workload.
Bitrate controls compression quality under available network bandwidth.
Per-eye width must be a multiple of 16.
Per-eye height must be a multiple of 64.
Device Frame Rate#
Set frame rate in both layers:
CloudXR.js
deviceFrameRatefor stream timing behavior.WebXR
updateTargetFrameRate(when supported) for device refresh target.
Keeping these two frame rate settings the same improves pose-to-photon stability.
Recommended Baseline (Meta Quest 3)#
Note
Quest 2 and Quest 3S devices have less powerful hardware than Quest 3.
Start with slightly reduced settings on these devices (e.g., lower framebufferScaleFactor and resolution) and profile performance before increasing quality. Monitor frame rate and adjust parameters as needed.
Start with this balanced baseline and tune from measured results:
framebufferScaleFactoraround1.4to1.5fixedFoveationaround0.666(medium)deviceFrameRateset to90when supportedperEyeWidth: 2048andperEyeHeight: 1792maxStreamingBitrateKbps: 150000WebGL
antialias: false
Pico 4 Ultra and HTTPS#
Pico 4 Ultra requires HTTPS web hosting for immersive WebXR workflows. Ensure your deployment uses wss:// signaling through a secure proxy where applicable.
Profiling Workflow#
Use remote debugging tools (for example, Chromium DevTools via chrome://inspect) to record:
frame pacing and long JavaScript tasks
network stalls and bandwidth pressure
stream startup and reconnect behaviors
Tune one parameter at a time and validate across representative network conditions.
Troubleshooting Performance Issues#
Frame rate drops below target#
Reduce
framebufferScaleFactor.Increase foveation level.
Reduce resolution and/or bitrate for constrained networks.
Visual quality issues#
Increase bitrate when network allows.
Increase per-eye resolution when server/client performance allows.
Reduce foveation level if peripheral quality is too low.
Stuttering or judder#
Check frame pacing in devtools.
Look for network jitter and packet loss.
Lower bitrate/resolution to restore stable frame timing.