The problem is that set_write_tiles() just remembers what tile sizes (or none) you want, and uses that when subsequent calls to ImageBuf.write() need to call open(). (The spec passed to open is what determines the tile size of the file.)
But you are calling open() and passing the open file to IB.write(), instead of letting it open a file on its own (which you need to do in this case because you are writing multiple subimages). So the set_write_tiles has no effect. This ought to work: out = ImageOutput.create(out_filepath) spec = matte_buf.spec().copy() spec.tile_width = 0 spec.tile_height = 0 open1 = out.open(out_filepath, (comp.spec(), spec) comp.write(out) ... > On Apr 12, 2022, at 8:06 AM, Jerome Raim <[email protected]> wrote: > > Hello, > I am combining multiple channels from various EXRs into a single multi-image > EXR. > > I am using set_write_tiles (0, 0) but the resulting EXR is still being read > as tiled. > > Code looks something like this: > > out = ImageOutput.create(out_filepath) > > open1 = out.open(out_filepath, (comp.spec(), matte_buf.spec())) > comp.set_write_tiles (0, 0) > comp.write(out) > > open2 = out.open(out_filepath, matte_buf.spec(), "AppendSubimage") > matte_buf.set_write_tiles (0, 0) > matte_buf.write(out) > > out.close() > > As always, thank you so much for a great library and knowledgeable help. > > Best, > Jerome > _______________________________________________ > Oiio-dev mailing list > [email protected] > http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org -- Larry Gritz [email protected]
_______________________________________________ Oiio-dev mailing list [email protected] http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org
