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
2015-03-13Initial compilation support with C++11 featureset enabledSergey Sharybin
This commit makes some preliminary fixes and tweaks aimed to make blender compilable with C++11 feature set. This includes: - Build system attribute to enable C++11 featureset. It's for sure default OFF, but easy to enable to have a play around with it and make sure all the stuff is compilable before we go C++11 for real. - Changes in Compositor to use non-named cl_int structure fields. This is because __STRICT_ANSI__ is defined by default by GCC and OpenCL does not use named fields in this case. - Changes to TYPE_CHECK() related on lack of typeof() in C++11 This uses decltype() instead with some trickery to make sure returned type is not a reference. - Changes for auto_ptr in Freestyle This actually conditionally switches between auto_ptr and unique_ptr since auto_ptr is deprecated in C++11. Seems to be not strictly needed but still nice to be ready for such an update anyway/ This all based on changes form depsgraph_refactor branch apart from the weird changes which were made in order to support MinGW compilation. Those parts of change would need to be carefully reviewed again after official move to gcc49 in MinGW. Tested on Linux with GCC-4.7 and Clang-3.5, other platforms are not tested and likely needs some more tweaks. Reviewers: campbellbarton, juicyfruit, mont29, lukastoenne, psy-fi, kjym3 Differential Revision: https://developer.blender.org/D1089
2014-12-25Cleanup: Fix Cycles Apache header.Thomas Dinges
This was already mixed a bit, but the dot belongs there.
2014-12-25Cycles: Add some utility functions and structuresSergey Sharybin
Most of them are not currently used but are essential for the further work. - CPU kernels with SSE2 support will now have sse3b, sse3f and sse3i - Added templatedversions of min4, max4 which are handy to use with register variables. - Added util_swap function which gets arguments by pointers. So hopefully it'll be a portable version of std::swap.
2014-11-15Cycles: Revert changes to inline flags enabled for release onlySergey Sharybin
It appears it's not really needed for convenient debugging when using proper flags passed to the compiler. Basically, it is -g3 and set breakpoint to a function as if it's not in the namespace. Not as if a code was any wrong, just it's possible to have more clear solution for the issue i've tried to solve in the past.
2014-09-26Cycles: Keep ccl_always_inline always inlining the stuffSergey Sharybin
It works around strange shading bug when building with MSVC. If such weirdeness continues, we perhaps would need to use proper inline flags all the time. Anyway, lets see how things will behave now.
2014-09-25Cycles: Accidentally inverted the logic of NDEBUG macroSergey Sharybin
2014-09-25Cycles: Don't inline functions for debug CPU kernelSergey Sharybin
Nobody will use debug mode for benchmarks anyway and this way it's much easier to set breakpoints on inlined functions to catch all their usages.
2014-08-02Make CHECK_TYPE_NONCONST macro portableCampbell Barton
also replace __typeof -> typeof
2014-06-13Cycles Refactor: Add SSE Utility code from Embree for cleaner SSE code.Thomas Dinges
This makes the code a bit easier to understand, and might come in handy if we want to reuse more Embree code. Differential Revision: https://developer.blender.org/D482 Code by Brecht, with fixes by Lockal, Sergey and myself.
2014-05-19Move ShadingSystem enum to shader.hNathan Letwory
Add SHADINGSYSTEM_ to enum member names, so it is clear where they are from. Revert BVHType enum changes, as there's no need for code dedup here.
2014-05-19Move BVHType and shadingsystem enums to top-level of Cycles namespace.Nathan Letwory
Easier access of BVHType and deduplication for ShadingSystem. Reviewers: dingto, brecht Differential Revision: https://developer.blender.org/D534
2014-05-11Code cleanup: comment typosCampbell Barton
2014-05-05Add check for LIKELY/UNLIKELY is CPU onlyCampbell Barton
2014-05-04Cycles: use LIKELY/UNLIKELY macrosCampbell Barton
Gives overall ~3% speedup in own tests for BMW scene.
2014-05-04Style cleanup: indentation, bracesCampbell Barton
2014-03-08Add support for multiple interpolation modes on cycles image texturesMartijn Berger
All textures are sampled bi-linear currently with the exception of OSL there texture sampling is fixed and set to smart bi-cubic. This patch adds user control to this setting. Added: - bits to DNA / RNA in the form of an enum for supporting multiple interpolations types - changes to the image texture node drawing code ( add enum) - to ImageManager (this needs to know to allocate second texture when interpolation type is different) - to node compiler (pass on interpolation type) - to device tex_alloc this also needs to get the concept of multiple interpolation types - implementation for doing non interpolated lookup for cuda and cpu - implementation where we pass this along to osl ( this makes OSL also do linear untill I add smartcubic to the interface / DNA/ RNA) Reviewers: brecht, dingto Reviewed By: brecht CC: dingto, venomgfx Differential Revision: https://developer.blender.org/D317
2014-03-02Cycles: remove ccl_align macro for GPU as unused and unsupported in OpenCLSv. Lockal
2014-02-27Cycles: fix crash in SSE hair and half-floats on x86+vc2008Sv. Lockal
MSVC 2008 ignores alignement attribute when assigning from unaligned float4 vector, returned from other function. Now Cycles uses unaligned loads instead of casts for win32 in x86 mode.
2014-02-04Cycles: bvh_cardinal_curve_intersect intro SSE optimizationSv. Lockal
Gives 5% speedup for koro_final.blend, 10-15% for hair.blend Reviewed By: brecht Differential Revision: https://developer.blender.org/D225
2014-02-04Fix cycles crash with float image textures on CPU without AVX support.Brecht Van Lommel
The AVX kernel functions for reading image textures could be get used from non-AVX kernels. These are C++ class methods and need to be marked for inlining, all other functions are static so they don't leak into other kernels.
2014-01-15Code cleanup: move half float functions to separate header file.Brecht Van Lommel
2014-01-15Code cleanup: some reshuffling of SIMD defines moving more code to ↵Brecht Van Lommel
util_optimization.h.
2014-01-11Fix T38129: cycles viewport render display with very bright colors turning ↵Brecht Van Lommel
black. This happened when exceeding the maximum value representable by half floats.
2013-12-28Cycles: Move SIMD utility functions into its own file.Thomas Dinges
Recently added SSE macros for noise texture can be moved here as well, but I leave this for later.
2013-11-23Fix cycles build error with visual studio, apparently the windows ABI does notBrecht Van Lommel
like 16 bit alignment on 32 bit.
2013-11-22Cycles: test code for sse 4.1 kernel and alignment for some vector types.Martijn Berger
This is mostly work towards enabling the __KERNEL_SSE__ option to start using SIMD operations for vector math operations. This 4.1 kernel performes about 8% faster with that option but overall is still slower than without the option. WITH_CYCLES_OPTIMIZED_KERNEL_SSE41 is the cmake flag for testing this kernel. Alignment of int3, int4, float3, float4 to 16 bytes seems to give a slight 1-2% speedup on tested systems with the current kernel already, so is enabled now.
2013-11-18Cycles: change __device and similar qualifiers to ccl_device in kernel code.Brecht Van Lommel
This to avoids build conflicts with libc++ on FreeBSD, these __ prefixed values are reserved for compilers. I apologize to anyone who has patches or branches and has to go through the pain of merging this change, it may be easiest to do these same replacements in your code and then apply/merge the patch. Ref T37477.
2013-10-02Fix cycles OpenCL compile error on AMD, and fix assert in debug builds.Brecht Van Lommel
2013-08-31Cycles: viewport render now takes scene color management settings into account,Brecht Van Lommel
except for curves, that's still missing from the OpenColorIO GLSL shader. The pixels are stored in a half float texture, converterd from full float with native GPU instructions and SIMD on the CPU, so it should be pretty quick. Using a GLSL shader is useful for GPU render because it avoids a copy through CPU memory.
2013-08-18Cycles: relicense GNU GPL source code to Apache version 2.0.Brecht Van Lommel
More information in this post: http://code.blender.org/ Thanks to all contributes for giving their permission!
2013-06-27Code cleanup: cyclesBrecht Van Lommel
* Reshuffle SSE #ifdefs to try to avoid compilation errors enabling SSE on 32 bit. * Remove CUDA kernel launch size exception on Mac, is not needed. * Make OSL file compilation quiet like c/cpp files.
2013-06-27Cycles / SSE2:Thomas Dinges
* kernel_sse2 was built without actual SSE2 intrinsics on x86 systems.
2013-06-22Cycles: ensure any SSE data is allocated 16 byte aligned, happens automaticallyBrecht Van Lommel
on many platforms but is not assured everywhere.
2013-06-20Cycles: update build configurations to include CUDA sm_35 architecture. When ↵Brecht Van Lommel
using a compiler older than CUDA 5.0 it will give a warning and skip this architecture.
2013-06-19Cycles: optimized SSE BVH traversal now also works with SSE2 CPUs, so all theBrecht Van Lommel
way back to Pentium 4, using a slightly less efficient instruction. Also ensure /Ox is used for Visual Studio for RelWithDebInfo builds.
2013-06-18Fix cycles crash on some processors. We actually need S-SSE3 support for thisBrecht Van Lommel
new BVH traversal code, not just SSE3.
2013-06-18Cycles: attempt to fix internal compile error with some visual studio buildsBrecht Van Lommel
2013-06-18Cycles BVH Build fix for MSVC 2012.Jürgen Herrmann
needs to include intrin.h for _BitScanForward and _BitScanReverse.
2013-06-18Cycles: optimization for BVH traveral on CPU's with SSE3, using code from ↵Brecht Van Lommel
Embree. On the BMW scene, this gives roughly a 10% speedup overall with clang/gcc, and 30% speedup with visual studio (2008). It turns out visual studio was optimizing the existing code quite poorly compared to pretty good autovectorization by clang/gcc, but hand written SSE code also gives a smaller speed boost there. This code isn't enabled when using the hair minimum width feature yet, need to make that work with the SSE code still.
2013-06-09Fix compilation of cycles for MinGW-w64 after recent commits. MinGW-w64 has ↵Antony Riakiotakis
conflicting redefinitions of the SSE functions in windows.h, so we will be using this header instead, since we can't always avoid including it instead of the sse headers.
2013-06-07Cycles: experimental correlated multi-jittered sampling pattern that can be usedBrecht Van Lommel
instead of sobol. So far one doesn't seem to be consistently better or worse than the other for the same number of samples but more testing is needed. The random number generator itself is slower than sobol for most number of samples, except 16, 64, 256, .. because they can be computed faster. This can probably be optimized, but we can do that when/if this actually turns out to be useful. Paper this implementation is based on: http://graphics.pixar.com/library/MultiJitteredSampling/ Also includes some refactoring of RNG code, fixing a Sobol correlation issue with the first BSDF and < 16 samples, skipping some unneeded RNG calls and using a simpler unit square to unit disk function.
2013-06-07Code cleanup: avoid some warnings due to implicit uint/int/float/double ↵Brecht Van Lommel
conversion.
2013-01-03Cycles Hair: refactoring to support generic attributes for hair curves. ThereBrecht Van Lommel
should be no functional changes yet. UV, tangent and intercept are now stored as attributes, with the intention to add more like multiple uv's, vertex colors, generated coordinates and motion vectors later. Things got a bit messy due to having both triangle and curve data in the same mesh data structure, which also gives us two sets of attributes. This will get cleaned up when we split the mesh class.
2012-12-21Fix cycles aliasing warnings caused by motion blur transforms.Brecht Van Lommel
2012-12-03get rid of annoying redefinition warning on cycles compilation for mingw64Antony Riakiotakis
2012-11-06Cycles: 4 new nodes.Brecht Van Lommel
* Tangent: generate a tangent direction for anisotropic shading. Can be either radial around X/Y/Z axis, or from a UV map. The default tangent for the anisotropic BSDF and geometry node is now always radial Z, for UV tangent use this node now. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/More#Tangent * Normal Map: generate a perturbed normal from an RGB normal map image. This is usually chained with an Image Texture node in the color input, to specify the normal map image. For tangent space normal maps, the UV coordinates for the image must match, and the image texture should be set to Non-Color mode to give correct results. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/More#Normal_Map * Refraction BSDF: for best results this node should be considered as a building block and not be used on its own, but rather mixed with a glossy node using a fresnel type factor. Otherwise it will give quite dark results at the edges for glossy refraction. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/Shaders#Refraction * Ambient Occlusion: controls the amount of AO a surface receives, rather than having just a global factor in the world. Note that this outputs a shader and not a color, that's for another time. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/Shaders#Ambient_Occlusion
2012-10-10Cycles: Anisotropic BSDF enabled, with tangents now computed from the active ↵Brecht Van Lommel
UV map. It's using the Ward BSDF currently, which has some energy loss so might be a bit dark. More/better BSDF options can be implemented later. Patch by Mike Farnsworth, some modifications by me. Currently it's not possible yet to set a custom tangent, that will follow as part of per-bsdf normals patch.
2012-09-07Fix for Cycles (CUDA) compilation (again ...). Moved the AttributeStandard ↵Lukas Toenne
enum typedef and the attribute_standard_name mapping function to util_attribute/util_types headers, so they can properly be used by kernel and render files alike. This should avoid any std C includes which are not available in CUDA. Thanks to Sergey for help!
2012-04-29mingw32 compiles againJoshua Leung
"__force_inline" keyword used in Cycles header is not defined
2012-04-28Cycles: merging features from tomato branch.Brecht Van Lommel
=== BVH build time optimizations === * BVH building was multithreaded. Not all building is multithreaded, packing and the initial bounding/splitting is still single threaded, but recursive splitting is, which was the main bottleneck. * Object splitting now uses binning rather than sorting of all elements, using code from the Embree raytracer from Intel. http://software.intel.com/en-us/articles/embree-photo-realistic-ray-tracing-kernels/ * Other small changes to avoid allocations, pack memory more tightly, avoid some unnecessary operations, ... These optimizations do not work yet when Spatial Splits are enabled, for that more work is needed. There's also other optimizations still needed, in particular for the case of many low poly objects, the packing step and node memory allocation. BVH raytracing time should remain about the same, but BVH build time should be significantly reduced, test here show speedup of about 5x to 10x on a dual core and 5x to 25x on an 8-core machine, depending on the scene. === Threads === Centralized task scheduler for multithreading, which is basically the CPU device threading code wrapped into something reusable. Basic idea is that there is a single TaskScheduler that keeps a pool of threads, one for each core. Other places in the code can then create a TaskPool that they can drop Tasks in to be executed by the scheduler, and wait for them to complete or cancel them early. === Normal ==== Added a Normal output to the texture coordinate node. This currently gives the object space normal, which is the same under object animation. In the future this might become a "generated" normal so it's also stable for deforming objects, but for now it's already useful for non-deforming objects. === Render Layers === Per render layer Samples control, leaving it to 0 will use the common scene setting. Environment pass will now render environment even if film is set to transparent. Exclude Layers" added. Scene layers (all object that influence the render, directly or indirectly) are shared between all render layers. However sometimes it's useful to leave out some object influence for a particular render layer. That's what this option allows you to do. === Filter Glossy === When using a value higher than 0.0, this will blur glossy reflections after blurry bounces, to reduce noise at the cost of accuracy. 1.0 is a good starting value to tweak. Some light paths have a low probability of being found while contributing much light to the pixel. As a result these light paths will be found in some pixels and not in others, causing fireflies. An example of such a difficult path might be a small light that is causing a small specular highlight on a sharp glossy material, which we are seeing through a rough glossy material. With path tracing it is difficult to find the specular highlight, but if we increase the roughness on the material the highlight gets bigger and softer, and so easier to find. Often this blurring will be hardly noticeable, because we are seeing it through a blurry material anyway, but there are also cases where this will lead to a loss of detail in lighting.