Skip to content
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

Mixing Two.js with other WebGL libraries in the same gl context. #233

Closed
trusktr opened this issue Jul 14, 2017 · 1 comment
Closed

Mixing Two.js with other WebGL libraries in the same gl context. #233

trusktr opened this issue Jul 14, 2017 · 1 comment

Comments

@trusktr
Copy link
Contributor

trusktr commented Jul 14, 2017

Hello Jono, I'm curious to know if you've tried, or have any thoughts on how, to mix libraries together.

For example, suppose I am use Three.js and Two.js. I would like to have a single canvas, with a single webgl context in my entire application, and to draw using both libraries into the same context.

Are there any utilities in Two.js that allow this to be done? For example, maybe there's a way to modify gl state so Three.js can render, then modify the gl state to render a Two.js inside a framebuffer and use that as a texture inside the main Three.js scene?

In my specific case, I'm doing my own 3D stuff (not using a library like Three.js), and would like to mix it with Two.js. I am thinking I will render either my stuff or Two.js stuff in a framebuffer, and render that framebuffer content in the other. Not sure which direction yet.

@jonobr1
Copy link
Owner

jonobr1 commented Jul 15, 2017

Maybe this thread can help: #226

I don't have much experience mixing gl.programs.., so I'm not really sure what to expect. Also, love the name of your own 3D library :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants