Archive for September 2015
This is trivial, but was awfully hard to find via Google Search. Eventually had to give up and actually think about it. :-)
So, a data-URI looks something like the following:
data:image/png;base64,[and a stream of base64 characters here]
The part after the comma is literally the contents of the file (image or whatever), encoded in base64, so all you need to do is run base64 --decode on that part.
For example, with the whole data URL copied to the clipboard, I can do:
pbpaste | sed -e 's#data:image/png;base64,##' | base64 --decode > out.png
to get it into a png file.
(I don’t have a solution yet.)
I just wanted to show what the sky looks like over the course of a week.
On a Mac with Stellarium installed, I ran the following
/Applications/Stellarium.app/Contents/MacOS/stellarium --startup-script stellarium.ssc
with the following
It took a while (some 10–15 minutes) and created those 336 images in
~/Pictures/Stellarium/uj*, occupying a total size of about 550 MB. This seems a start, but Imagemagick etc. seem to choke on creating a GIF from such large data.
Giving up for now; would like to come back in future and figure out something better, that results in a smaller GIF.