jupyter-widgets / pythreejs

A Jupyter - Three.js bridge
https://pythreejs.readthedocs.io
Other
936 stars 187 forks source link

Using pythreejs output in a Jupyter kernel? #239

Open nickc92 opened 5 years ago

nickc92 commented 5 years ago

Hi, I am interested in writing a Jupyter kernel which, upon execution of some code, will generate a pythreejs rendering. But it is unclear to me how I would do that. Is that a simple thing to do?

vidartf commented 5 years ago

I don't have a lot of experience writing kernels, so I'm maybe not your best bet for an answer here, but it would very much depend on what kind of kernel you are writing (which language / run-time?). The first milestone would be to have support for jupyter-widgets (equivalent of ipywidget's nbextension). Maybe @SylvainCorlay can be more helpful here?

boustrephon commented 5 years ago

Hi @nickc92: you can get this effect by opening up a python kernel and then run some pythreejs commands in python. Jupyter will then display the rendering in the notebook. Any reason why this would not meet your needs?