You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • It depends on what exactly the image was encoded as... If it's a base64 image of raw bits then you can just shove it in an object with width, height and buffer fields like http://www.espruino.com/Image+Converter does (http://www.espruino.com/Graphics#images-­bitmaps)

    However if it's a windows bitmap file (which is what asURL does) then you can convert it to a binary form with atob(...) and then feed that into the bitmap loader module which will give you an image which you can draw with graphics as well: http://www.espruino.com/BMPLoader

    If a normal PC application is encoding an image to a URL it may well end up encoding it as a PNG of JPEG image - and I'm afraid there aren't any decoders for those in Espruino though.

About

Avatar for Gordon @Gordon started