orbitControl() ignored on layer / createGraphics() WEBGL offscreen buffer
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 24k
- Forks
- 3.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 25
Description
Most appropriate sub-area of p5.js?
- Core/Environment/Rendering
- WebGL
Details about the bug:
- p5.js version: 1.0.0
- Web browser and version: Chrome 80.0.3987.149
- Operating System: MacOS 10.13.6
- Steps to reproduce this:
Have always wished there was an opacity option on background() when using WEBGL render (sneaky request in this bug issue) – so as a work around, I draw the WEBGL content to a layer using createGraphics(width, height, WEBGL) - then display this layer on a 2d canvas, allowing use of translucent/fading background(0, 15). Whil playing with a sketch, just realized that orbitControl() is ignored when applied to this offscreen buffer. Intended behavior or a bug?
Here's an example with both behaviors– toggle useLayer at top to see each:
https://editor.p5js.org/ffd8/sketches/n2rIHPPv3
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked p5.js editor sketch and reproduce the difference between direct WEBGL rendering and createGraphics(width, height, WEBGL) when orbitControl() is used. Trace the rendering and camera-control paths for offscreen WEBGL buffers, then confirm the intended behavior and add coverage showing whether orbitControl() should affect the buffer.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100