Hey Deke,

I don't have the exact code handy, but I've managed to do this a few times.
If memory serves you just need to create imagespecs for each part with the
proper metadata you want per-part and use the oiio.AppendSubimage with
ImageOutput after calling open().


outFile = foo.exr
specs = tuple(...all your image specs with metadata...)
output = ImageOutput.open(outFile, specsTuple)
for part in range(1,len(parts)):
    output.open(outFile, outSpecs[part]. oiio.AppendSubimage)
   ....write image/scanlines with your data and the correct index to the
image spec not sure if you ahve to do a full re-read from the source
image....

Hope that helps get you started, if someone else doesn't have exact code.

~Andrew

On Thu, Nov 16, 2017 at 10:02 AM, Deke Kincaid <[email protected]>
wrote:

> Hi Folks
>
> Does anyone have an example of how to inject metadata with the oiio python
> bindings into a specific part of a multipart EXR?(part 0 for example)  We
> keep trying to do this but the output is that all my parts disappear and I
> only have a part 0 in my output image.
>
> _______________________________________________
> Oiio-dev mailing list
> [email protected]
> http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org
>
>
_______________________________________________
Oiio-dev mailing list
[email protected]
http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org

Reply via email to