Coffee-Physics
Coffee-Physics copied to clipboard
images in experimental-webgl
Hi, this project looks really interesting. I'm trying to use this in a visualisation. I've managed to set up a working physics world, and now I want render images on the location of certain particles. Have you any idea of how to do this? I've tried drawing with a different context that supports drawImag, but it seems its not possible drawing with two different contexts to the same canvas. Anyone done this?
Did you find a solution? You can always access position with particle.pos.x/y and drawImage should work - something like ctx.drawImage(img,p.pos.x,p.pos.y);