-
-
Notifications
You must be signed in to change notification settings - Fork 452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Question] Woscope integration #690
Comments
I'm not familiar with Woscope, but you can always get the canvas element through the const two = new Two({ type: Two.Types.webgl }):
const canvas = two.renderer.domElement; Since, Woscope is using a canvas, you need to set the appropriate type. Alternatively, like Woscope, you could make a const canvas = document.getElementById('my-canvas');
const two = new Two({
type: Two.Types.webgl,
domElement: canvas
}); |
ok, but would I be able to add things managed by Two.js to the canvas? for example, add a frame to the osciloscope and change its size? |
I don't know how Woscope works, so I can't give you an answer to that. If you want to keep Woscope's content and Two.js content, then you'll want to enable Like so: const two = new Two({
type: Two.Types.webgl,
overdraw: true
}); This will disable Two.js from clearing all content on the canvas every frame before it starts its own rendering. |
Describe your question
How can I manage the Woscope library visualization in a Two.js webgl canvas?
by manage I mean like, adding more things in the canvas and the woscope is just one more item in the canvas.
It apparently needs the canvas element.
Your code (either pasted here, or a link to a hosted example)
I tried to create my own XY oscilloscope with just Two.js (SVG canvas) and Tone.js
Screenshots
there's a live demo of the Woscope functionality.
Environment (please select one):
The text was updated successfully, but these errors were encountered: