Repository navigation
Open
Labels
bugSomething isn't working
Description
Describe the bug 📝
Both render the snapshot with renderer.three.render(scene, camera) directly. That skips the renderer's own update(), which PostproductionRenderer overrides, so with postproduction on, the snapshot is the plain scene, not what the user saw when they saved the viewpoint.
Left: the live view (PostproductionRenderer, PEN style). In the panel: the frame read after renderer.update(), and the updateCamera(true) snapshot below it, shaded and without the pen lines.
Expected: both call renderer.update() and read the canvas in the same task.
Where in the code
updateCamera(true): viewpoint.ts#L485;takeSnapshot(): #L519SimpleRenderer.update(): simple-renderer.ts#L310-L329, overridden in PostproductionRenderer/index.ts#L922
Reproduction ▶️
Steps to reproduce 🔢
- In the repro:
npm install,npm run dev, openissue-5/example.html. - It draws a box with a
PostproductionRenderer(postproduction on,COMPOSERmode,PENstyle), callsupdateCamera(true), and shows in the panel the frame read afterrenderer.update()and the snapshot. Take a snapshot repeats it. - The panel's Result (a 961 × 528 canvas, so 507336 of its 507408 pixels):
BUG pixels that differ between the snapshot and the frame: got 507336, expected 0
System Info 💻
System:
OS: Windows 11 10.0.26200
CPU: (16) x64 Intel(R) Core(TM) i9-10885H CPU @ 2.40GHz
Memory: 33.34 GB / 63.76 GB
Binaries:
Node: 22.22.1 - C:\nvm4w\nodejs\node.EXE
npm: 11.12.0 - C:\nvm4w\nodejs\npm.CMD
Browsers:
Chrome: 156.0.8078.48
Edge: Chromium (152.0.4191.53)
npmPackages:
@thatopen/components: 3.6.0 => 3.6.0
@thatopen/components-front: 3.6.0 => 3.6.0
@thatopen/fragments: 3.6.0 => 3.6.0
@thatopen/ui: 3.4.17 => 3.4.17
camera-controls: 3.1.2 => 3.1.2
three: 0.184.0 => 0.184.0
web-ifc: 0.0.77 => 0.0.77Used Package Manager 📦
npm
Error Trace/Logs 📃
No response
Validations ✅
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a repository issue and not a framework-specific issue. For example, if it's a THREE.js related bug, it should likely be reported to mrdoob/threejs instead.
- Check that this is a concrete bug. For Q&A join our Community.
- The provided reproduction is a minimal reproducible example of the bug.
Metadata
Metadata
Assignees
Labels
bugSomething isn't working
Activity