I am using NodeWebkit and want to save snapshot of the game into a .png file. I could write CanvasSnapshot into a file with NodeWebkit's write function, but the file is invalid.
I took a peek at the data of CanvasSnapshot expression, and it does not look like usual png file format at all. I believe this data has to be converted into the usual png file format first before it could be written with NodeWebkit's write function.
The question is... ...is there a way in C2? Or is there a better way?