Reading and drawing textures
-
@marc477 said:
I could load the texture only one time from the Hard Drive using ImageMajik (Thanks Dan), then update the "in memory" buffer directly and display it in the WebDialog. Is it possible to do that ? How do I draw in a web dialog an image loaded with ImageMajik ?
I do not think anyone has ever done it.
The HTML5 Canvas element will not work well on PC yet because SketchUp uses the MSIE WebBrowser control for WebDialogs. Microsoft is lagging behind in their IE support of the specification.
You CAN use the RMagick gem to draw, and save the edits to disk, and MSIE knows how to natively render image file formats, but you'll need to refresh the web dialog, to re-render the imagefile. (or have a html IMG element within a HTML file.)
See the doc: http://studio.imagemagick.org/RMagick/doc/
Also note there IS aRVG
class that is based upon SVG. -
@dan rathbun said:
The HTML5 Canvas element will not work well on PC yet because SketchUp uses the MSIE WebBrowser control for WebDialogs. Microsoft is lagging behind in their IE support of the specification.
You can test by loading the HTML5 Bejeweled game into a WebDialog.
It most likely will not run under XP. But runs fine under Win7 with MSIE v11 installed.
Advertisement