Commit Graph

60 Commits

Author SHA1 Message Date
c58a0c5eb8 catch exception and report an error when failing to write exr files - was crashing with debug builds. 2011-08-30 23:08:38 +00:00
2164847928 fix for openexr include path, for both cmake and scons a custom openexr install wouldn't work since it expected BF_OPENEXR/include and BF_OPENEXR/include/OpenEXR to be in the search path. 2011-06-15 11:50:45 +00:00
Nathan Letwory
192ab99b5c doxygen: blender/imbuf tagged. 2011-02-27 20:23:21 +00:00
Nathan Letwory
5b607701a7 doxygen: prevent GPL license block from being parsed as doxygen comment. 2011-02-23 10:52:22 +00:00
6a2e5ad599 [#25815] Patch gcc 4.6
with minor edits, made sure it works in CMake too.
2011-01-27 00:02:25 +00:00
263830f000 Enabled GCC -Wwrite-strings warning for CMake and replaced many 'char's for 'const char's,.
Only one functional change where Transform orientations passed "" to BIF_createTransformOrientation() which could then have the value written into.
2010-12-03 17:05:21 +00:00
f973be9fe4 Bugfix #21385
Blender MultiLayer openEXR files now save with correct scanline order.
Code also provides backward compatibility. Also thanks to Troy Sobotka!
2010-11-27 19:33:40 +00:00
5a09368957 use 'const char *' for imbuf and file ops. 2010-11-19 02:14:18 +00:00
1e245cc589 option to write images to a files on single frame renders, this isn't accessed by the UI at the moment, but could eventually be used for saving test-renders.
The main reason to have this is so renders can be scripted to write to a specific file without having to do annoying tricks like set a dummy start/end frame range, render an animation and work out the current frame image will be written to, then rename after rendering.

Also made some 'char *' args into 'const char *'
2010-11-16 14:40:46 +00:00
8268a4be71 most unused arg warnings corrected.
- removed deprecated bitmap arg from IMB_allocImBuf (plugins will need updating).
- mostly tagged UNUSED() since some of these functions look like they may need to have the arguments used later.
2010-10-16 14:32:17 +00:00
a8db76f00e fix for error in last commit. 2010-09-15 08:00:19 +00:00
f5957e6237 own recent commit which added support for writing srgb float buffers broke writing char buffers as half EXR's. 2010-07-15 13:32:20 +00:00
731824c464 support for colorspace conversion when saving srgb float buffers (from the sequencer) as openexr. 2010-07-12 14:54:05 +00:00
9e57892b90 dont add a rect buffer for EXR's, the sequencer discards them immediately and functions that need a rect should create one on the fly.
this shows a problem with Imbuf where there is no way to ask to only load the native type byte/float.
2010-07-12 13:35:00 +00:00
b9e241d3e3 error in last commit 2010-07-12 12:07:32 +00:00
51d8c5d93f [#22824] OpenEXR Save from byte buffer bug
- Saving a typical byte buffer as an exr wasnt converting into linear colorspace.
- Remove checks for 1 and 2 channel images, these will write as RGB anyway and are very rare.
- 3 Channel images were having the alpha channel written from the red color channel, write 1.0 instead.
2010-07-12 11:28:16 +00:00
7f575ddf89 revert 28807, fix for [#21385] Multilayer OpenEXR files import into other compositors upside down
looks like a threading problem:
 Easy to redo, 1024x436, FSA, 4 threads.

With 1 thread it runs ok, need to look into this further but no time now so reverting.
2010-05-19 16:23:09 +00:00
9c3c7f970f no functional changes, simplify some exr api code. 2010-05-17 16:42:53 +00:00
d5f74baa17 [#21385] Multilayer OpenEXR files import into other compositors upside down
famous upside down EXR bugfix from Xavier Thomas

- Files from blender 2.4x will be flipped on load.
- New files will be saved correctly

tracker has detailed info for further reference.
2010-05-17 15:54:57 +00:00
5774e61f4a shouldnt have committed this, was local hack to workaround float buffer bug. 2010-05-07 15:52:16 +00:00
d972b8488e fix for segfault when reading bad multilayer EXR's 2010-05-07 15:49:21 +00:00
008863daec Merge image related changes from the render branch. This includes the image
tile cache code in imbuf, but it is not hooked up to the render engine.


Imbuf module: some small refactoring and removing a lot of unused or old code
(about 6.5k lines).

* Added a ImFileType struct with callbacks to make adding an file format type,
  or making changes to the API easier.
* Move imbuf init/exit code into IMB_init()/IMB_exit() functions.
* Increased mipmap levels from 10 to 20, you run into this limit already with
  a 2k image.
* Removed hamx, amiga, anim5 format support.
* Removed colormap saving, only simple colormap code now for reading tga.
* Removed gen_dynlibtiff.py, editing this is almost as much work as just
  editing the code directly.
* Functions removed that were only used for sequencer plugin API:
  IMB_anim_nextpic, IMB_clever_double, IMB_antialias, IMB_gamwarp,
  IMB_scalefieldImBuf, IMB_scalefastfieldImBuf, IMB_onethird, IMB_halflace,
  IMB_dit0, IMB_dit2, IMB_cspace
* Write metadata info into OpenEXR images. Can be viewed with the command
  line utility 'exrheader'

For the image tile cache code, see this page:
http://wiki.blender.org/index.php/Dev:2.5/Source/Imaging/ImageTileCache
2010-05-07 15:18:04 +00:00
081c1205a3 correct fsf address 2010-02-12 13:34:04 +00:00
04dec46c6a Color management fixes
Now it's a bit more robust, tagging images with profiles when they're loaded, 
which then get interpreted later on by conversion functions. Just Linear RGB 
and sRGB profiles at the moment, same as before.

This commit fixes Martin's problem with EXRs and Multilayer images loading/
saving too dark, and it also makes the sequence editor work correctly with it too.

Also fixes:
[#19647] gamma correction with color management is reset when resetting Curve
[#19454] 2.5: Dither does not work when Color management is enabled
2010-01-09 00:16:35 +00:00
b39f73431a [#19232] (2.5) Correction of cmake for windows about audio (jack and openal)
from Guillaume Lecocq (lguillaume) 

[#19247] (2.5) useless WITH_OPENEXR redefinition
from Mauro Toffanin (equilibrium)
2009-08-24 10:07:49 +00:00
c8b4cf9206 2.50:
svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r19820:HEAD

Notes:
* Game and sequencer RNA, and sequencer header are now out of date
  a bit after changes in trunk.
* I didn't know how to port these bugfixes, most likely they are
  not needed anymore.
  * Fix "duplicate strip" always increase the user count for ipo.
  * IPO pinning on sequencer strips was lost during Undo.
2009-06-08 20:08:19 +00:00
aeb2225a28 2.50: some warning fixes. 2009-03-17 22:27:15 +00:00
0c23d0c2ad Bugfix #17327
Small one: changed the string attribute in multilayer exr files to be:

"2.43 and newer"

To indicate that it's about compatibility of the exr file, not the version
Blender saved it in.
2008-07-14 10:26:11 +00:00
d0d179dce6 Buhh... and now I left in testing print in exr code. 2008-07-09 15:25:34 +00:00
180a7d1f62 Replaced strcasecmp with BLI_strcasecmp, to make msvc happy! 2008-07-09 13:12:58 +00:00
bad6b003db Fix for reported openexr file reading failures.
For simple RGB(A) files, the channel names in openexr were supposed
to be simply "R" "G" "B" and "A" too.
Other programs like other names... like lower case, or like "ambient.r"

Tested with file from renderman.
2008-07-09 10:51:03 +00:00
391bd70d42 Fix for bug #9014: crash saving the depth pass with openexr or hdr,
both file formats crashed on saving images with less than 4 channels.
2008-04-29 16:57:39 +00:00
03402b8419 - Removed the Save Buffers/FSA restriction that the width and height
must be divisible by the number of parts.
- OpenEXR code also has some changes to allow writing mipmapped images,
  but that is unused at the moment.
2008-02-06 13:45:07 +00:00
Ken Hughes
0a27a31970 Clean-up for various gcc warnings under linux. 2008-02-03 01:33:35 +00:00
70c413d4ad Fixes in reading back rendered temp files ("Save buffers" and "FSA" options).
Press Rkey in compositor for reading back render results and invoke a compo.
This now correctly reads AO (skipped it sometimes) and it makes a correct
composite.

FSA todo:
- hotkey + button for reading all samples back + composite
- solve black border around image
2008-01-30 21:14:36 +00:00
9b0c2efeed Handle OpenEXR exception and print it, for writeTile. It's sometimes
crashing there now with FSA, if it crashes again this should give
more info.
2008-01-28 21:28:32 +00:00
Nathan Letwory
e3ff98fc6b === OpenEXR ===
* fix [ #6105 ] Blender crashes when opening multilayer with node in compositor
  - Mem_IStream membuf was allocated on the stack, so it caused major troubles when
 out of the function scope. Now allocate it on the heap and let OpenEXR deal with
 freeing it.
  - moved + added delete file;'s for completeness
2007-03-27 10:13:57 +00:00
d1b17f8c30 ==== MSVC 7.1 project files ====
- fix for 3DPlugin compile
- cleanup of bullet path
- removed PHY_ODE project from 3D plugin too, not used anymore

Now all configurations should build again, let me know of any problems!

Not been able to test if the 3DPlugin is actually working,is job for another day ;)
Also the 3DPlugin is compiled without OpenExr, this needs to be looked into once too.
2007-03-03 11:28:15 +00:00
06826d27d4 Bugfix #5818
OpenEXR MultiLayer: line order DECREASING_Y (openexr spec) crashes newer
openexr libs in windows... ???
Removed it, since tests reveiled the line order is still bottom-top
2007-01-24 15:03:20 +00:00
3228b58a38 Added flag in MultiChannel exr file to denote line order. Blender has the
Y coordinate 0 in left-bottom of screen :)

Fun news: cinepaint now reads such files too:
http://www.blender.org/bf/cornelius.exr_sc1.jpg
2007-01-09 13:58:51 +00:00
ac37a15675 "Save Buffers" fix: when you ESC from rendering, it now saves empty
tiles in the file, that read back fast as black. This also solves
crashes on partial written files, when trying to read them.
2006-12-21 19:37:53 +00:00
b12927ecb8 MultiLayer images: added support for choosing compression type.
Without setting anything, it uses ZIP now as default, which gives the best
lossless compression and works nice fast.
2006-12-21 10:41:43 +00:00
ed853e00da Function returned no '1', causing multilayer files to not read, except
for me of course :)
2006-12-20 21:34:20 +00:00
253432bfc7 The Big Image refactor!
Please read:
http://www.blender3d.org/cms/Imaging.834.0.html

Or in short:

- adding MultiLayer Image support
- recoded entire Image API
- better integration of movie/sequence Images

Was a whole load of work... went down for a week to do this. So, will need
a lot of testing! Will be in irc all evening.
2006-12-20 17:57:56 +00:00
2a0fc46266 CMake: Fix FFMPeg/OpenEXR issues in CMake system and possibly the others. OpenEXR can be linked in DEBUG mode on Windows using the libraries in CVS and stub. 2006-11-18 02:48:18 +00:00
148bc0a2e8 Tsk! A 'new' for filehandle wasn't combined with a 'delete', which is
probably causing the leakage issues we have exr in linux.
2006-03-18 14:45:15 +00:00
ea9866a75f Memory saving for large renders:
New option "Save Buffers", in first Output panel of renderbuttons, will not
allocate all render buffers, but instead save the rendered tiles to exr.
For each scene rendered, a single exr file then is created.
After rendering, the files get read, and only then the memory allocation is
done.

The exr files are saved in the temp dir (from user settings), and have
names derived from the filename+scene name. That way these buffers remain
relatively unique, and can be re-used later too.

Saving all render-layers and passes in a single file (as F3 command) will
be done later. Also reading back the current muli-layer exr files is not
supported yet (will read black). The purpose is that these files then can
be used as input for the Compositor.

One fun thing I added; after rendering once with this option, close
Blender, and restart it. If you have a Composite set up press 'R' on an
active RenderResult node. This will refresh the node(s) and load the exr,
so you can composite again without a re-render.
2006-03-14 21:29:42 +00:00
fe3506f6d4 WIP commit on getting the 'render result layers' saved in a single
file. Previous fix accidentally committed parts of that... :)

Note: it is currently disabled still... will commit the real version
soon.
2006-03-14 17:48:40 +00:00
a8afa6dc20 Proper syntax for freeing an allocated array in silly c++ :) 2006-03-01 21:18:31 +00:00
21df108cb9 Saving OpenEXR half didn't free allocated half buffer... silly c++ memory
management!
2006-02-28 16:45:52 +00:00