Sorry for the double reply guys. For some reason your email @larry got
caught by my SPAM filter.


On Tue, May 15, 2018 at 9:17 AM, Daniel Flehner Heen <
[email protected]> wrote:

> Hi, Matthew!
>
> When you say half sizing, do you mean half resolution or half file size?
> For half resolution you could do as follows:
>
> ####################BEGIN######################
> import OpenImageIO as oiio
>
> buf = oiio.ImageBuf('/path/to/fullsize.exr')
>
> # Get the specs for original image to use in the resizes one
> spec = buf.spec()
>
> # Create a buffer set to half resolution
> scaled = oiio.ImageBuf(oiio.ImageSpec(spec.full_width // 2,
> spec.full_width // 2, spec.nchannels, spec.format))
>
> #Slower, but higher quality resize
> oiio.ImageBufAlgo.resize(scaled, buf)
>
> # Faster, but not as good resize
> #oiio.ImageBufAlgo.resample(scaled, buf)
>
> # Write out your resized image
> scaled.write('/path/to/resized.exr')
>
> #####################END#####################
>
> OIIO is well documented. There's a pdf in the doc folder of the source
> code that covers pretty much everything. The image manipulation is mostly
> done in the ImageBufAlgo functions.
>
> Hope this helps,
>
> On Tue, May 15, 2018 at 7:20 AM, Matthew.Alexander - The Empire Post <
> [email protected]> wrote:
>
>> Hi,
>>
>>
>> My name is Matthew and i've been looking into using OIIO for half sizing
>> EXR sequences, however I cannot seem to find much documentation on how to
>> do that.
>> I use python quite often but it appears OIIO is in C++, which I can
>> certainly learn, however there does not appear to be much documentation on
>> this.
>>
>>
>> Regards,
>> Matthew.
>>
>> *Matthew Alexander: IT & IO*
>> The Empire Post
>>
>> 36 Agnes St, Fortitude Valley 4006, Qld
>> Em: [email protected]
>> <[email protected]>
>> Mb: 0499 004 747 <http://0499004747>
>> Ph: 07 3180 1902
>>
>> This email and any attachments are confidential. If received in error,
>> please inform us by return email and then delete both messages. You should
>> not read, copy, use or disclose them without authorisation. We do not
>> accept liability in connection with computer virus, data corruption, delay,
>> interruption, unauthorised access or unauthorised amendment. The views
>> or opinions expressed are the author's own and may not reflect the views or
>> opinions of The Empire Post Pty Ltd.
>>
>>
>>
>> _______________________________________________
>> Oiio-dev mailing list
>> [email protected]
>> http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org
>>
>>
>
>
> --
> -Daniel
>



-- 
-Daniel
_______________________________________________
Oiio-dev mailing list
[email protected]
http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org

Reply via email to