The dynamic wallpaper in MacOS Mojave is a single 114 MB .heic
file that seems to contain 16 embedded images.
It also contains the following binary plist data in its metadata under the key "Solar". It's an array of 16 items, each with four keys:
i
(integer). This seems to be the image index.o
(integer). This is always 1 or 0. Stephen Radford thinks it indicates dark mode (0) vs. light mode (1).a
(decimal). I’m pretty sure this is the angle of the sun over the horizon. 0º = sunset/sunrise. 90º = sun directly overhead. Negative values = sun below horizon.z
(decimal). This seems to be the cardinal position of the sun relative to the camera. 0º = sun is directly in front of the camera. 90º = sun is directly to the right of the camera. 180º = sun is directly behind the camera.
@tim-hilt Paste the following code into an Xcode playground or turn it into a command-line script, this should get your started. Note that the code will not work on Linux since it uses Apple-proprietary APIs to parse the image's metadata. If you want to use another library for this, look for the
apple_desktop:solar
key in the image's XMP metadata.