Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by coreysnyder

In my recent quest of re-creating my HTML Overlays & Menus I found that there is a way to draw HTML to the canvas via the methods found here:
Drawing DOM objects into a canvas

I'd imagine it would make my life easier if I were able to copy over the HTML for the menus and drop them into JavaScript variables and draw them directly to the canvas. It looks like CSS Styles are supported as well.

Can anyone confirm or deny if this is supported by Ejecta?

Tonight when I get out of work I'm going to attempt this method. Please save me some time if you know already that its not going to work.

1 decade ago by dominic

The process described by Mozilla doc is pretty hack-ish: it creates an SVG element, puts all the DOM elements into it and then renders the SVG into an image.

This will not work in Ejecta. It neither supports SVG, nor the DOM.

1 decade ago by coreysnyder

Ok thanks Dominic! I figured as much but it was worth at try :). Luckily I'm having pretty good luck re-creating the HTML menu's in canvas using the button.js plugin. My game should be in the iOS App Store review by the weekend.
Page 1 of 1
« first « previous next › last »