[Openexr] Re: [Bf-committers] OpenEXR plugin for Blender :-) (fwd)

Gernot Ziegler gz at lysator.liu.se
Wed Aug 10 00:01:42 CEST 2005


Historical information ;)
---------- Forwarded message ----------
Date: Wed, 9 Mar 2005 13:33:39 +0100
From: Ton Roosendaal <ton at blender.org>
Reply-To: bf-blender developers <bf-committers at projects.blender.org>
To: bf-blender developers <bf-committers at projects.blender.org>
Subject: Re: [Bf-committers] OpenEXR plugin for Blender :-)

Hi,

Great, thanks!
I have no time to check on this patch now, but like to mention that
another developer has been working on the feature as well (Alfredo de
Greef). Afaik this wasn't finished yet.

Kent Mein is also working on 64/128 bits images support in our ImBuf
(image) library, something to keep synced as well!

> Restrictions are:
> .) It is C++-code, so openexr.cc is using g++ to compile

Check on how for example the Freetype/FTGL library was linked in
Blender. This is C++ code as well, nicely wrapped to a C API. The local
Blender component for it (C++ too) is in the directory
source/blender/ftfont/, the FTGL library in extern/, the freetype
library belongs either in lib/<platform>/ or defined to use a link path
in makefiles/scons.

OpenEXR should be done in a similar way. The library itself doesn't
belong in our source tree, but precompiled as static lib (with
headers).
Make a nice C Api for it in source/blender/openxr/ or so

> .) I only integrated the necessary includes and ldadds to SConstruct,
> and
> only for the Linux platform.

There are devs here who will help with makefiles and project files.

> .) There is no auto-detection of OpenEXR, it is assumed to lie in
> /usr/include/OpenEXR

See above. Since we use many different OSs to compile on, using the
lib/ dir for Blender will be simplest for everyone to use.

> Bonus features of OpenEXR:
> .) Support for OpenEXR Z-data writing (that's why I wrote the
> plugin ;) )
> .) Prepared for float data output (will be the first one, right ? :-) )
> .) Prepared for extra data channels (like normals, geometry images,
> etc.)
> .) Interchange format with Cinepaint

Yep, openEXR was on our roadmap. :)

> I will need help with:
> .) Licensing ... what shall I write in the header ? I gladly donate the
> code to the Blender foundation for dual licensing, but I would like to
> have my name in the code .

Just copy the full header from another C file, and change the (c)
statement into "Blender Foundation" and add your name as contributor.

> .) 16 bit-short-output: Is there example code for that ?

I doubt we'll support that in the short term.

> .) Float out: I heard the renderer is being rebuilt to support float
> output. How can the OpenEXR plugin register as a float output format to
> the renderer ?

Check on the code for other image saving... warning, this is a very
antique abused dutch named routine "schrijfplaatje()" in toets.c. Could
use major cleanup, but will work for you.
The 4xfloat buffer is simply accessible as the global R.rectftot (float
pointer, RGBA). Check the RE_floatbuffer_to_output() code in render
module.

> .) GUI: It would be great to be able to provide settings for OpenEXR
> output (see the OpenEXR plugin on www.splutterfish.com ). Although I
> dont
> know if I have time to do it myself, I could sit together with some
> Blender GUI expert to define the knobs and whistles the user could set,
> and export this settings API from the OpenEXR plugin.

There's space for 1 or 2 buttons... not much. :)
Output choices could be limited to 4 x float, with/without Z
Optional is 4 x short, with/without Z. Dunno...

> .) Z data channel: How is the Z data defined ? Is it relative to the
> camera, starting with Z=0 at the image plane ? Where is Z=1.0 ?

The zbuffer is the actial Z buffer as used for rendering. It isn't even
'correct' since it misses transparency and halos or particles. The
values are signed integers, ranging from -max to +max for clipping
planes (between near and far).

-Ton-

>
> It would be cool to meet devs who could help me in this, maybe this or
> next evening on IRC. Just drop me a mail to gz at lysator.liu.se
> (important,
> since the list is in digest mode for me) and I will do my best to be
> there :-)
>
> Servus,
>   Gernot
>
> --
> T----------------------------W-E-L-C-O-M-
> E------------------------------T
> O  The Austria <=> Sweden <=> Germany <=> Netherlands connection.....
>  H
> |  http://www.mpi-sb.mpg.de/~gziegler | http://lysator.liu.se/~gz
>  E
> \-----------------------------F-U-T-U-R-
> E-------------------------------/
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at projects.blender.org
> http://projects.blender.org/mailman/listinfo/bf-committers
>
>
------------------------------------------------------------------------
--
Ton Roosendaal  Blender Foundation ton at blender.org
http://www.blender.org

_______________________________________________
Bf-committers mailing list
Bf-committers at projects.blender.org
http://projects.blender.org/mailman/listinfo/bf-committers


More information about the Openexr mailing list