hi,
how can i draw plotly.js based chart onto p5.js based canvas?
for example,
https://editor.p5js.org/ronraisch/sketches/SJbUMtYyM
thank you
hi,
how can i draw plotly.js based chart onto p5.js based canvas?
for example,
https://editor.p5js.org/ronraisch/sketches/SJbUMtYyM
thank you
Plotly appears to use a radically different rendering strategy which is a mix of SVG, DOM elements, and in certain scenarios a WebGL based canvas. There is no obvious way to get them to integrate cleanly. There are two ways that could theoretically work: 1) hide the Plotly div and use the toImage()
function to generate image data that you could then display on a p5.js function, or 2) overlay the p5.js canvas on top of the Plotly div (although depending if you want both Plotly and p5.js to be interactive this may be tricky.
If you could describe what you are actually trying to accomplish it would be easier to give you a recommendation.
hi,
after I read your comment I tried to used the grahp.js library again to solve my problem and I did solve without using plotly.js(though it seems a great library).
thank you