Hi all,
I’m in WEBGL mode which doesn’t support image()
(in 0.5.16 anyway) - how can I load a graphics into a an html div?
Thanks,
Charles
Hi all,
I’m in WEBGL mode which doesn’t support image()
(in 0.5.16 anyway) - how can I load a graphics into a an html div?
Thanks,
Charles
I guess you could do:
document.getElementById("my-image").innerHTML = '<img src="myimage.jpg">'
or just add that into the html itself.
Did you read the question or did I misunderstand your answer? - The image isn’t saved locally
If I am not mistaken you can use a link in src, so that is not a problem
document.getElementById("my-image").innerHTML = '<img src="http://i.imgur.com/jiItp64.png">'
<h1>
3D with WebGL
</h1>
<div id="my-image">
<img src="http://i.imgur.com/jiItp64.png">
</div>
I’m creating my Graphics on the “fly” therefore I don’t have src link
There are many examples here that you can use then.
Needs to be done with P5…
I can’t help you then. Sorry.
You may try out show() and/or parent() methods: