[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [Openexr-devel] Multi-layer multi-pass files
From: |
Chris Cox |
Subject: |
RE: [Openexr-devel] Multi-layer multi-pass files |
Date: |
Tue, 19 Dec 2006 13:46:06 -0800 |
If we're going to support layers in OpenEXR files, I would much rather see
something more concrete that isn't based on parsing comments and channel names.
Where are you going to put the user assigned names for layers and channels? In
another comment?
Where are you putting the compositing modes and other attributes of each layer?
Do you have any way to represent layer data that isn't pixels (ie: "this should
be solid 1.0,0,0", or "this is a reference to another node in the graph").
And how does this map to other applications that support layers and extra
channels, such as Photoshop?
Chris
--------------------
> Currently there is no standard naming scheme for layers. Would you
> like
> to suggest one?
While working on multilayer files I decided it would be very hard to
get a generic parser for a multilayer formatted exr file. There are too
many dependencies also with our internal conventions for reading and
saving, so I've tied it more to what is possible now in Blender (i.e.
the separation in "Layers", "Passes" and "Channels").
In short the parsing goes as follows;
- check for a comment in the file with string "Blender MultiChannel"
- read all channels from the file, and it put it in a list
- split up channel names, with the following assumptions:
(reading string from right to left)
- channel type identifier is the last character, preceded with a "."
- search back to another "." to get the pass name
- the remainder is the layer name.
- create a list of Layers, each with a list of Passes, with an array of
Channels,
and read everything.
This allows any "random" name, for as long it has three dots to
separate :)
Examples:
Front Shot 21.01.Diffuse.R
Light.Group.Blue.Spec.R
Character John Hair.Speed.X
(Note that these names get close to the 32 character limit! I've
hardcoded Layer names to a maximum of 19 chars now. Pass names are max
10).
As for a standard; our image system will show any named layer/pass
combo. But for the Blender compositor UI I had to standardize pass
names. Available now in Blender are:
"Combined" : RGBA (the default combined result of Passes in a Layer)
"Depth": Z.
"Vector": XYZW
"Normal": XYZ
"UV": UVA (we store alpha for UV pass, to allow antialising)
"Color": RGBA
"Diffuse": RGB
"Spec": RGB
"Shadow": RGB
"AO": Ambient occlusion, RGB
"Reflect": RGB
"Refract": RGB
"Radio": RGB
"IndexOB": X
That list is easy to extend of course.
-Ton-