Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2,349 changes: 877 additions & 1,472 deletions dist/aframe-master.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/aframe-master.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/aframe-master.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/aframe-master.min.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/aframe-master.module.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/aframe-master.module.min.js.map

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion docs/components/renderer.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ It also configures presentation attributes when entering WebVR/WebXR.
| maxCanvasWidth | Maximum canvas width. Uses the size multiplied by device pixel ratio. Does not limit canvas width if set to -1. | -1 |
| maxCanvasHeight | Maximum canvas height. Behaves the same as maxCanvasWidth. | -1 |
| multiviewStereo | Enables the use of the OCULUS_multiview extension. | false |
| spaceWarp | Enables SpaceWarp motion vector rendering when supported. | false |
| logarithmicDepthBuffer | Whether to use a logarithmic depth buffer. | auto |
| precision | Fragment shader [precision][precision] : low, medium or high. | high |
| alpha | Whether the canvas should contain an alpha buffer. | true |
Expand All @@ -43,7 +44,7 @@ It also configures presentation attributes when entering WebVR/WebXR.
| exposure | When any toneMapping other than "no" is used this can be used to make the overall scene brighter or darker | 1 |
| anisotropy | Default anisotropic filtering sample rate to use for textures | 1 |

> **NOTE:** Once the scene is initialized, none of these properties may no longer be changed apart from "exposure", "toneMapping", "sortTransparentObjects" and "foveationLevel" which can be set dynamically.
> **NOTE:** Once the scene is initialized, none of these properties may no longer be changed apart from "exposure", "toneMapping", "sortTransparentObjects", "foveationLevel", and "spaceWarp" which can be set dynamically.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While it was already the case, there's a double negation here "none of these properties may no longer".


### antialias

Expand Down Expand Up @@ -111,3 +112,7 @@ Whether the canvas should contain an alpha buffer. If this is true the renderer
### multiviewStereo

Performance improvement for applications that are CPU limited and draw count bound. Most experiences will get a free perf gain from this extension at not visual cost but there are limitations to consider. multiview builds on the multisampled render to texture extension that discards the frame buffer if there are other texture operations during rendering. Problem outlined in https://github.com/KhronosGroup/WebGL/issues/2912. Until browsers and drivers allow more control of when multisample is resolved we have a workaround with some drawbacks. As a temporary solution when enabling multiview the upload of texture data is deferred until the rendering of the main scene has ended, adding one extra frame of latency to texture uploads. Scenarios affected are for example skeletal meshes that upload bone textures with TexImage. With the workadound in place all bone animations will lag by one frame. Another issue is rendering mirror reflexions or rendering another view in the middle of the scene. The logic would have to move to the beginning of the frame to make sure it's not interrupted by the multiview frame. Because of the limitations this flag is disabled by default so developers can address any issues before enabling.

### spaceWarp

Enables SpaceWarp motion vector rendering when supported by the device and browser. This requires `multiviewStereo: true` and requesting the `space-warp` WebXR feature (see the [`webxr` system](./webxr.md)). This flag can be toggled at runtime to pause or resume the motion vector pass.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be a good idea to link to the WebXR space warp spec or the WebXR Space Warp documentation page by Meta.

Additionally a note can be added to indicate that this features is limited to the Meta Quest browser (at least for now)

2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ if (utils.device.isBrowserEnvironment) {
require('./style/aframe.css');
}

console.log('A-Frame Version: 1.7.1 (Date 2026-02-21, Commit #d2e94756)');
console.log('A-Frame Version: 1.7.1 (Date 2026-03-24, Commit #a7ef140e)');
console.log('THREE Version (https://github.com/supermedium/three.js):',
THREE.REVISION);

Expand Down
5 changes: 5 additions & 0 deletions src/systems/renderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export var System = registerSystem('renderer', {
maxCanvasWidth: {default: -1},
maxCanvasHeight: {default: -1},
multiviewStereo: {default: false},
spaceWarp: {default: false},
exposure: {default: 1, if: {toneMapping: ['ACESFilmic', 'linear', 'reinhard', 'cineon', 'AgX', 'neutral']}},
toneMapping: {default: 'no', oneOf: ['no', 'ACESFilmic', 'linear', 'reinhard', 'cineon', 'AgX', 'neutral']},
precision: {default: 'high', oneOf: ['high', 'medium', 'low']},
Expand Down Expand Up @@ -60,6 +61,10 @@ export var System = registerSystem('renderer', {
var toneMappingName = this.data.toneMapping.charAt(0).toUpperCase() + this.data.toneMapping.slice(1);
renderer.toneMapping = THREE[toneMappingName + 'ToneMapping'];
renderer.toneMappingExposure = data.exposure;
renderer.spaceWarp = data.spaceWarp;
if (renderer.xr) {
renderer.xr.isSpaceWarp = data.spaceWarp && renderer.xr.isMultiview;
}
Comment on lines +64 to +67
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally there'd be a single flag to toggle space warp. Having to set isSpaceWarp feels wrong, since it's already being set initially in WebXRManager itself. Perhaps it would be better to:

  • Move renderer.spaceWarp to renderer.xr.spaceWarp as space warp is strictly tied to WebXR.
  • Replace isSpaceWarp with a getter that determines the value based on both spaceWarp and isMultiview

Copy link
Author

@KooIaIa KooIaIa Mar 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks these are all great changes. When I started I was making it like multiview but if it is just enabled with the optional feature then it could be toggled with renderer.xr.spaceWarp like that. I think I was imagining being able to set it to false by default in the a-scene while still having it enabled in the renderer so it could be set to true later during runtime.

renderer.xr.setFoveation(data.foveationLevel);

if (data.sortObjects) {
Expand Down
1 change: 1 addition & 0 deletions src/systems/webxr.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export var System = registerSystem('webxr', {

update: function () {
var data = this.data;

this.sessionConfiguration = {
requiredFeatures: data.requiredFeatures,
optionalFeatures: data.optionalFeatures
Expand Down