For compatibility with the upcoming OpenEXR code, img.depth is now an int.
Like OpenEXR's code, it will now also return metadata as ^Info instead of Info.
The example was updated to retrieve the metadata this way.
It regrettably does not fix: #1018. That seems to be a codegen issue in the test runner or elsewhere.
I would've used `os.stream_from_handle`, but:
- Parts of it seem to be implemented for Windows only at the moment.
- PNG's `peek_data` using that stream didn't manage to rewind and thus tried to parse the data after the header as the header.
Two things must happen:
- The `os.stream_from_handle` implementation needs to be fixed.
- PNG and GZIP's parsers need to be able to handle streams that can't rewind or seek (backward).
Those fixes are on my TODO list but are exceed the scope of this patch.