Repository navigation
WebGPURenderer: Introduce CanvasTarget - #31919
Conversation
π¦ Bundle sizeFull ESM build, minified and gzipped.
π³ Bundle size after tree-shakingMinimal build including a renderer, camera, empty scene, and dependencies.
|
|
After seeing the shape and properties of // -- setup --
const canvas = document.querySelector( '#mycanvas' );
const output = new THREE.RenderOutput( canvas );
// -- loop --
renderer.setRenderOutput( output );
renderer.render( scene, camera );Regarding this:
How would the |
I think And if so, should |
|
After more testing on I can confirm reverting this PR fixes |
| descriptionElement.innerText = 'Scene ' + ( i + 1 ); | ||
| element.appendChild( descriptionElement ); | ||
|
|
||
| const canvasTarget = new THREE.CanvasTarget( sceneCanvas, { antialias: true } ); |
There was a problem hiding this comment.
Looks like the antialias parameter was removed in #31928. Not sure what the alternative is, or if this should just be removed?
Related issue: #31730
Description
Instead of using
RenderTargets, the current implementation considersCanvasTargetthe currentcanvas, always having one as default, and it cannot be null.The main motivation, besides bringing these new WebGPU features, is to inspect the nodes individually through the new inspector.
The API follows @mrdoob βs suggestion. #31730 (comment)