Hi,
this plugin saves the whole c2-canvas, a base64-string or a sprite via ajax(= a short php-script) to an image in png-format on a webserver.
Because the images get saved on a webserver with php the plugin doesn't work in preview mode.
History:
1.1) Since version 1.1 it's possible to create PNG-files out of Base64-strings. Together with Pode's behavior "Extract Sprite to base64 string" it's possible to save sprites to images.
1.2) Since version 1.2 customizable screenshots are possible.
1.3) code cleaning
1.4) supports WebGL
1.5) works on Android via fallback-script
- - - - Android bugfix release - - - -
[Update5] c2i - v <font color="red">1.5</font>:
[Add]Fallback for Android-Devices (ie 2.1,2.2,2.3,..?)
The Plugin uses a fallback script when 'toDataURL()' has no native support from the browser - c2i2dataURL.js.
<font size="1">On Android-devices only Opera works as expected and understands toDataURL() (-no fallbackscript used). The webkit-browsers on Android need the fallback-script.. </font>
HowTo convince Android: Copy the file c2i2dataURL.js next to index.html
Demo - canvas/sprite/screenshot + Plugin(v 1.5)-- demoproject (capx,exported project) + php-script + fallback bugfix-script
<img src="http://dl.dropbox.com/u/31151399/Construct2/Plugins/joe7_c2i/howTo/1.5.png" border="0">
____________
[Update4] c2i - v 1.4:
Plugin is completely rewritten.
[Changed] WebGL-support - It should work now with both renderers - currently on desktop browsers (+ on Android - only with Opera).
[Changed] Plugin is now a "world-plugin". If you don't want to see a "black canvas" in C2, give it an image-texture - transparent image should be possible.
Demo - canvas/sprite/screenshot + Plugin(v 1.4)+capx
changed php-file (filename)
__________________________________________
Property:
<img src="http://dl.dropbox.com/u/31151399/Construct2/Plugins/joe7_c2i/howTo/properties.png" border="0">
Actions:
<img src="http://dl.dropbox.com/u/31151399/Construct2/Plugins/joe7_c2i/howTo/action.png" border="0">
Condition:
<img src="http://dl.dropbox.com/u/31151399/Construct2/Plugins/joe7_c2i/howTo/condition.png" border="0">
short overview how2use:
<img src="http://dl.dropbox.com/u/31151399/Construct2/Plugins/joe7_c2i/howTo/overview.png" border="0">
Have fun and all suggestions are welcome <img src="smileys/smiley17.gif" border="0" align="middle"> ,
Joe7