It's a fantastic start to a big project. Thank you for all your efforts and hope you keep going strong!
Alternatively, you could try something that pushes the limits of the representation and API, e.g., leveraging OpenEXR as an import/export format and exposing it through exr-pix and pix-exr converters.
Strongly suggest polishing what you have, though. I can probably be more specific if you don't know where to begin.