[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Openexr-devel] Saving EXR file one channel at time
From: |
Pavel Hradský |
Subject: |
[Openexr-devel] Saving EXR file one channel at time |
Date: |
Thu, 19 Aug 2010 14:23:19 +0200 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.8) Gecko/20100802 Thunderbird/3.1.2 |
Hi!
I need to save an EXR file with several channels (for example
RGBA+Depth+AmbientOcclusion) in a kind of strange way. I'd like to save
the RGBA channels first and then, after some time, add a Depth channel
and then the other channel (layer, whatever) into the same file. I tried
this by first setting the header to have all necessary channel (names)
and then filling a framebuffer first with RGBA channels only, writing
pixels, then creating another framebuffer with depth channel (and same
header), writing pixels and so on. This is obviously not the right
approach, since I ended up with a file containing only the last channel
:-) (I first tried R, then GBA for example).
The reason for wanting to create the single file in several passes is
memory constraints (the images will be rather big, generated in Direct3D
and I don't want to hold all of them in memory at once). Is it even
possible?
I'm using Imf::OutputFile (scan-lines).
Many thanks! (my first post, hopefully correctly sent)
--
Pavel Hradsky
Faculty of Electrical Engineering, Czech Technical University in Prague
- [Openexr-devel] Saving EXR file one channel at time,
Pavel Hradský <=