AWS Thinkbox Discussion Forums

Error Writing jpg from exr

Hi,
I’m getting an error I don’t know how to fix when writing an image.
I’m reading a multichannel exr that was rendered from VRay, then writing a jpg.
The simplified version of the code is:

thumbnail = Draft.Image.ReadFromFile(inFile) thumbnail.Resize(width, height, 'fill') thumbnail.WriteToFile(outFile)

The error is:

I don’t know how to fix this error. I’d appreciate any help I can get.

Would it be possible for you to please send us a copy of the multichannel EXR file? You can send us your file by posting it on this forum, or by using our ticket system. You’ll may need to ZIP your file to get it through our ticket system.

I sent you a private message with the ticket number. Thanks for looking into it.

Got it, thanks! This seems like a bug. We’ll look into a fix. In the meantime, you could work around this problem by adding a line to your script:

thumbnail = Draft.Image.ReadFromFile(inFile) thumbnail.Resize(width, height, 'fill') thumbnail.SetFileChannelMap({k : thumbnail.GetFileChannelMap()[k] for k in thumbnail.GetChannelNames()}) thumbnail.WriteToFile(outFile)

Privacy | Site terms | Cookie preferences