Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-01-01Fix deadlock happening when using Save Buffers for renderSergey Sharybin
Summary: Issue was caused by the same tile being written twice to the EXR file. This was happening because of partial update of work-in-progress tiles was merging result to the final render result in order to make color management pipeline happy. We need to avoid such a merges and keep memory usage as low as possible when Save Buffers is enabled. Now render pipeline will allocate special display buffer in render layer which will contain combined pass in the display space. This keeps memory usage as low as we can do at this moment. There's one weak thing which is changing color management settings during rendering would lead to lossy conversion. This is because render result's display buffer uses color space from the time when rendering was invoked. This is actually what was happening in previous release already actually so not a big issue. Reviewers: brecht Reviewed By: brecht Differential Revision: https://developer.blender.org/D162
2013-12-25Use generic task scheduler for threaded image processorSergey Sharybin
It allows to schedule tasks of smaller size without having threads overhead or extra worry about splitting tasks into smaller pieces. This simplifies code in color management which was manually splitting task into smaller chunks to keep memory usage low. Further optimization is possible by avoid malloc called from threads, but that's how it used to work for ages already and would be optimized as a separate patch.
2013-12-22Add ItemDestroyable to the cache limitorSergey Sharybin
This callback is used when cache limiter needs to remove some cached objects when running out of limit. From blender side it's used to keep painted images always in memory. This fixes issue when painted images were removing from the memory after image cache rewrite.
2013-12-18Color management: added utility function to apply processor on a pixelSergey Sharybin
It applies color management on a pixel in a way, based on number of channels of this pixel. Simplifies partial update code a bit.
2013-12-18Color management: get rid of original byte buffer partial updateSergey Sharybin
It was only used by opengl render and in fact it needed just to set DISPLAY_BUFFER_INVALID flag for the image buffer. In theory it wouldn't make any change to opengl render speed (because this change just moved rect_from_float from color management code to image save code). And could not see any speed changes on my laptop.
2013-12-18Fix artifact in partial buffer update after recent changesSergey Sharybin
The issue wasn't new in fact, just partial buffer update function was still broken. Not sure how those issues were not noticed for so long. Perhaps partial_buffer_update_rect() could be simplified, but i've got some more upcoming changes here which might run into conflicts if i'll do simplification now.
2013-12-17Changes to partial update during renderingSergey Sharybin
Summary: Mainly addressed to solve old TODO with color managed fallback to CPU mode when displaying render result during rendering. That fallback was caused by the fact that partial image update was always acquiring image buffer for composite output and was only modifying display buffer directly. This was a big issue for Cycles rendering which renders layers one by one and wanted to display progress of each individual layer. This lead to situations when display buffer was based on what Cycles passes via RenderResult and didn't take layer/pass from image editor header into account. Now made it so image buffer which partial update is operating with always corresponds to what is set in image editor header. To make Cycles displaying progress of all the layers one by one made it so image_rect_update switches image editor user to newly rendering render layer. It happens only once when render engine starts rendering next render layer, so should not be annoying for navigation during rendering. Additional change to render engines was done to make it so they're able to merge composite output to final result without marking tile as done. This is done via do_merge_result argument to end_result() callback. This argument is optional so should not break script compatibility. Additional changes: - Partial display update for Blender Internal now happens from the same thread as tile rendering. This makes it so display conversion (which could be pretty heavy actually) is done in separate threads. Also gives better UI feedback when rendering easy scene with small tiles. - Avoid freeing/allocating byte buffer for render result if it's owned by the image buffer. Only mark it as invalid for color management. Saves loads of buffer re-allocations in cases when having several image editors opened with render result. This change in conjunction with the rest of the patch gave around 50%-100% speedup of render time when displaying non-combined pass during rendering on my laptop. - Partial display buffer update was wrong for buffers with number of channels different from 4. - Remove unused window from RenderJob. - Made image_buffer_rect_update static since it's only used in single file. Reviewers: brecht Reviewed By: brecht CC: dingto Differential Revision: http://developer.blender.org/D98
2013-12-16Better fix for previous commitSergey Sharybin
Cache iterator might return unused keys as well. Now unused keys are being removed before cleanup and iteration.
2013-12-16Fix possible crash when cleaning cache with some ibufs removed by the memory ↵Sergey Sharybin
limit
2013-12-16Color management: use fallback mode if there're no displays/viewsSergey Sharybin
Before this it was a runtime check for number of displays/views which is rather really annoying. This simplifies code a bit and allows to do some more tricks in other patches.
2013-12-16Fix T37826: Opening a new image in the image editorSergey Sharybin
Cast dimensions to size_t before multiplication. Also made add_ibuf_size survive cases when image buffer allocation failed.
2013-12-16Make compression in IMB_allocImBuf match other placesSergey Sharybin
2013-12-13Code cleanup: float<>double promotionCampbell Barton
2013-12-13Image cache rewrite to using generic movie cacheSergey Sharybin
Summary: Behaves very much the same as cache for Movie Clip datablock: - Image now have `MovieCache *cache` field which replaced legacy `ListBase ibufs`. This allows image datablock to easily keep of image buffers which are owned by itself. This field isn't saved to the file and getting restored on undo steps. However, cache limit is global for movies, sequences and image datablocks now. So overall cached image buffers size will not go above cache limit size in user preferences. - Image buffers which are marked as BITMAPDIRTY will never be freed from the cache. - Added utility function to iterate over image buffers saved in movie cache. - Movie cache cleanup check callback now have ImBuf argument which can be used in a condition of cleanup. - Added some utility functions which replaces legacy ibufs iterations with image cache iteration which happens from inside a lock. - Fixed `image_mem_size()` which was only counting one of the buffers if both float and byte buffer present. Additional notes: - `BKE_image_get_first_ibuf()` is rather stupid, but direct access to ibufs->first was also the same stupid idea. Would consider avoid this function is another project. - There are some places which doesn't look threadsafe, but they already were not so much threadsafe anyway before. So think not a big deal with solving this later. Finally solves infinite memory usage by image sequences! :) Reviewers: brecht, campbellbarton Reviewed By: brecht CC: sebastian_k Differential Revision: http://developer.blender.org/D95
2013-12-13Implement GPU-side ditherSergey Sharybin
Summary: Uses some magic pseudo-random which is actually a texture coordinate hashing function. TODOs: - Dither noise is the same for all the frames. - It's different from Floyd's dither we've been using before. - Currently CPU and GPU dithering used different implementation. Ideally we need to use the same dither in CPU. Reviewers: brecht Reviewed By: brecht Differential Revision: http://developer.blender.org/D58
2013-12-08Code cleanup: delete cineon header files that were empty but not deleted.Shane Ambler
Reviewed By: brecht Differential Revision: http://developer.blender.org/D85
2013-12-08Extend system-info with information about OIIO, OCIO and OSLSergey Sharybin
Summary: Version of those libraries might be useful to know. - OIIO and OCIO is exposed via bpy.app.oiio and bpy.app.ocio. There're "supported", "version" and "version_string" defined in those modules. - OSL is available as _cycles.osl_version and _cycles.osl_version_string. Reviewers: campbellbarton Reviewed By: campbellbarton CC: dingto Differential Revision: http://developer.blender.org/D79
2013-12-05Fix T37703: Shadow pass output image is mangled.Sergey Sharybin
Was a mistake in own optimization commit.
2013-12-04Fix for interpolation errors on lower-left borders in compositor imageLukas Tönne
inputs. http://wiki.blender.org/uploads/4/4c/Compo_image_interpolation_borders.png Problem is that all image buffer reader nodes (RenderLayer, Image, MovieClip) were clipping pixel coordinates to 0..N range (N being width or height respectively). Bilinear interpolation works ok then on the upper-right borders (x, N) and (N, y), since the last (N-1) pixel fades out to N (background). But the lower-left (x, 0) and (0, y) borders are not correctly interpolated because the nodes cut off the negative pixels before the interpolation function can calculate their value. To fix this, the interpolation functions are now entirely responsible for handling "out of range" cases, i.e. setting (0,0,0,0) results for invalid pixels, while also handling interpolation for borders. Callers should not do pixel range checks themselves, which also makes the code simpler. Should not have any real performance penalty, the interpolation functions do this check anyway, so is probably even slightly faster.
2013-12-04Code cleanup: remove unused color management functionsSergey Sharybin
2013-12-02Fix T37656: Huge amount of RAM used during start when rendering large imagesSergey Sharybin
Issue was caused by linear float buffer creating for every working thread. This buffer actually duplicated original buffer which doubles amount of required memory. We can not avoid such a duplication, because OCIO needs to work on a float buffer and it modifies this buffer. Alternative for now is to not allocate linear buffer for the whole chunk which needs to be handled by the thread and use further chunk cutting in thread itself. So now every thread will handle the chunk in blocks of 64 scanlines. This reduces memory overhead significantly without speed loss in own tests. Ideally, IMB_processor_apply_threaded need to be switched to generic task scheduler and made it so this function generates tasks with reasonable number of scanlines. This requires much more testing to be sure there're no conflicts with object update and so. Such a change to IMB_processor_apply_threaded would not be noticed by users, so do not consider this is a crucial to do right now.
2013-11-30Woo Hoo. First git commit.Alexandr Kuznetsov
Changes for VC2013 Now, I can build Blender with VC2013 with Cycles, Collada, OpenExr,OpenImageIO disabled. Also, you need VC2008 sp1 installed to make old libs compatible.
2013-11-24Code Cleanup: whitespace / formattingCampbell Barton
2013-11-22Code Cleanup: use NULL for pointer checks and remove joke.Campbell Barton
2013-11-10mistake in last commitCampbell Barton
2013-11-10no need to call isnan() on unsigned ints (causes error on freebsd/clang)Campbell Barton
2013-11-01Fix [#37290] Movie files filtering does not show *.ts files.Bastien Montagne
2013-11-01FIX: [#37199] .ogg file is not recognized as a movie in File BrowserAndrea Weikert
CHANGE: writing an animation in the ogg movie format now defaults to .ogv (ogg/video) which is recommended by Xiph.org for video CHANGE: for .ogg files a check is added whether Blender can read it as a movie (is avi or ffmpeg movie), otherwise assume audio CHANGE: the anim player now filters for the same extensions as the file browser
2013-10-31Add .webm to the list of extensions recognized as videoAndrea Weikert
(Patch by Philipp Oeser, submitted in [#37199], many thanks)
2013-10-23style cleanupCampbell Barton
2013-10-18Add debug prints to the PSD loader in imbuf. The error message can be ↵Irie Shinsuke
obtained from OIIO by geterror().
2013-10-14Fix #37043: bpy.ops.sequencer.rebuild_proxy() don't release memorySergey Sharybin
2013-10-13cmake/openimageio - partially reverting #60692Dalai Felinto
We now have openimageio building when cycles builds or when it's manually set to build. (I reverted the _IMAGE_ in the define name because I think the closer the cmake flags match the defines in the software the better, and there is no reason to rename all the existent WITH_OPENIMAGEIO references in CMakeLists.txt - which would be the alternative)
2013-10-12code cleanup: use const's for vector args.Campbell Barton
2013-10-12Fix build scripts related to PSD support. Both CMake and SCons builds were ↵Irie Shinsuke
broken.
2013-10-12scons: fix WITH_PSD compiling, still i think muddled naming is used here, ↵Jens Verwiebe
todo: cleanup
2013-10-11scons file for OIIO (needed for psd)Dalai Felinto
based on patch by Shinsuke Irie note: scons is not working for me at the moment so I did not test this patch. It should work fine though.
2013-10-11adding WITH_IMAGE_OPENIMAGEIO and removing the PSD build optionDalai Felinto
As per Brecht van Lommel's suggestion.
2013-10-11code cleanup: use const's for static arraysCampbell Barton
2013-10-10style cleanupCampbell Barton
2013-10-09Implementation of curve mapping in GLSLSergey Sharybin
The title says it all, now having curve mapping enabled in color management settings wouldn't force fallback from GLSL to CPU based color space conversion.
2013-10-09style cleanupCampbell Barton
2013-10-09fix for building with OPENJPEG after PSD commitDalai Felinto
reported via email, patch by PerfectionCat
2013-10-09fix building when WITH_PSD is OFF, stub is not needed afterallDalai Felinto
2013-10-09Photoshop PSD supportDalai Felinto
We now support the combined layer of Photoshop files (stored as layer 0 in the file). This way users can keep their files as multilayer PSD and Blender always handle them as flat images. For perfect alpha this requires an OpenImageIO update: https://github.com/OpenImageIO/oiio/commit/342cc2633ff590a3bb278481c61ae798c7148361 Photoshop sample files: https://github.com/OpenImageIO/oiio-images Brecht has some pending fixes to push for OIIO as well, so we may as well wait to update our libraries. What works: =========== * 8bit images (with or without alpha) * 16bits images (alpha discarded) * Photoshop files saved with 'Maximum Compatibility' * Cycles, Blender internal, BGE (and player) Known limitations (due to OIIO dependency): ========================= * Images with less than 4 channels show a wrong thumbnail (bug may be in OIIO) * Packed images are not supported * We do not write PSD files. Note: old Blenders have support for PSD via Quicktime library. But due to license issues this was discontinued. Many thanks for Brecht van Lommel for reviewing the patch, suggesting multiple improvements and to help solving the alpha issue.
2013-10-04Changing dither value will now invalidate cached display bufferSergey Sharybin
2013-09-12code cleanup: headers - doxy comments.Campbell Barton
2013-09-11Revert r60034 and proper fix for #36698 by Sergey Sharybin. NULL pointer ↵Lukas Toenne
checks should never be done in color management. Instead this makes sure the look identifier is always initialized correctly to the default if not defined.
2013-09-11Fix #36698 Cycles MinGW64 Mike Pan scene crashes instantly. Missing pointer ↵Lukas Toenne
check in color management look access from r59945. The look_desc pointer is NULL if the look string is undefined (empty).
2013-09-10Add BLI_utildefines.h for __func__ (necessary for MSVC).Nathan Letwory