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
2016-04-16Cycles: Refactor Image Texture limits.Thomas Dinges
Instead of treating Fermi GPU limits as default, and overriding them for other devices, we now nicely set them for each platform. * Due to setting values for all platforms, we don't have to offset the slot id for OpenCL anymore, as the image manager wont add float images for OpenCL now. * Bugfix: TEX_NUM_FLOAT_IMAGES was always 5, even for CPU, so the code in svm_image.h clamped float textures with alpha on CPU after the 5th slot. Reviewers: #cycles, brecht Reviewed By: #cycles, brecht Subscribers: brecht Differential Revision: https://developer.blender.org/D1925
2016-04-15Fix T48139: Checker texture strange behavior in cyclesSergey Sharybin
Seems particular CUDA implementations has some precision issues, which made integer coordinate (which was expected to always be positive) to go negative.
2016-04-13Cycles: Minor cleanup, whitespace around keyword and preprocessor indentSergey Sharybin
2016-04-05Revert "Cycles: Remove the Preetham Sky model."Thomas Dinges
This reverts commit d91316dc672dc1ee69fbd24d2f00124a24b75c6b.
2016-04-03Cycles: Remove the Preetham Sky model.Thomas Dinges
The improved Hosek / Wilkie model was added during my GSoC 2013 and the default since then. The older model was kinda kept for compatibility, but after more than 2 years it's time to remove it. The Hosek / Wilkie model is more realistic anyway, and people who really want a day / night transition can mix the Sky Shader with another one (e.g. color) and fade between the two.
2016-03-27Fix T47668: Cycles OpenCL glass not rendering correctly on AMD.Brecht Van Lommel
Work around what appears to be a compiler bug.
2016-03-25Cycles: Cleanup, indent nested preprocessor directivesSergey Sharybin
Quite straightforward, main trick is happening in path_source_replace_includes(). Reviewers: brecht, dingto, lukasstockner97, juicyfruit Differential Revision: https://developer.blender.org/D1794
2016-02-18Fix T47461: Different results on CPU and GPU when using Branched Path TracingLukas Stockner
The issue here was actually somewhere else - the attached scene from the report used a light falloff node in a sunlamp (aka distant light). However, since distant lamps set the ray length to FLT_MAX and the light falloff node squares this value, it overflows and produces a NaN weight, which propagates and leads to a NaN intensity, which is then clamped to zero and produces the black pixels. To fix that issue, the smoothing part of the light falloff is just ignored if the smoothing term isn't finite (which makes sense since the term should converge to 1 as the distance increases). The reason for the different results on CPUs and GPUs is not perfectly clear, but probably can be explained with different handling of Inf/NaN edge cases. Also, to notice issues like these faster in the future, kernel_asserts were added that evaluate as false as soon as a non-finite intensity is produced.
2016-02-17Fix OpenCL kernel build errors after recent 3D texture changes.Brecht Van Lommel
2016-02-15Cycles: Initial support of 3D textures for CUDA renderingSergey Sharybin
Supports both smoke/fire and point density textures now. Reduces number of textures available for sm_20 and sm_21, but you have to compromise somewhere on such a limited hardware. Currently limited to linear interpolation only, and decoupled ray marching is not supported yet. Think those could be considered just a further improvement. Some quick example: https://developer.blender.org/F282934 Code is minimal and we can fully consider it a fix for missing support of 3D textures with CUDA. Reviewers: lukasstockner97, brecht, juicyfruit, dingto Reviewed By: brecht, juicyfruit, dingto Subscribers: mib2berlin Differential Revision: https://developer.blender.org/D1806
2016-02-04Cycles: Implement approximate reflectance profilesSergey Sharybin
Using this paper: http://graphics.pixar.com/library/ApproxBSSRDF/paper.pdf This model gives less blurry results than the Cubic and Gaussian we had implemented: - Cubic: https://developer.blender.org/F279670 - Burley: https://developer.blender.org/F279671 The model is called "Christensen-Burley" in the interface, which actually should be read as "Physically based" or "Realistic". Reviewers: juicyfruit, dingto, lukasstockner97, brecht Reviewed By: brecht, dingto Subscribers: robocyte Differential Revision: https://developer.blender.org/D1759
2016-02-03Cycles: Cleanup, indentation and bracesSergey Sharybin
2016-01-14Cycles: Cleanup, spelling and indentationSergey Sharybin
2016-01-14Cycles: Tweak inline policy for some functionsSergey Sharybin
The goal is to make Experimental kernel closer in performance to the official kernel, avoiding spills and such. There should not be big impact on official kernel, own tests showed few percent performance drop on laptop's GPU. CPU was always the same speed on AVX, AVX2 and SSE4.1 CPUs i've been testing here. This seems to be the last essential step before we can get rid of Experimental kernel and enable SSS officially on GPU without causing some major performance issues. Surely some more tweaks are possibly required, but that we can do for until cows go home anyway.
2016-01-07Cycles: Refactor how we pass bounce info to light path node.Thomas Dinges
This commit changes the way how we pass bounce information to the Light Path node. Instead of manualy copying the bounces into ShaderData, we now directly pass PathState. This reduces the arguments that we need to pass around and also makes it easier to extend the feature. This commit also exposes the Transmission Bounce Depth to the Light Path node. It works similar to the Transparent Depth Output: Replace a Transmission lightpath after X bounces with another shader, e.g a Diffuse one. This can be used to avoid black surfaces, due to low amount of max bounces. Reviewed by Sergey and Brecht, thanks for some hlp with this. I tested compilation and usage on CPU (SVM and OSL), CUDA, OpenCL Split and Mega kernel. Hopefully this covers all devices. :)
2016-01-02Cycles: Add Saw option to the wave textureLukas Stockner
This commit adds "Bands Saw" and "Rings Saw" to the options for the Wave texture node in Cycles, behaving similar to the Saw option in BI textures. Requested by @cekuhnen on BA. Reviewers: dingto, sergey Subscribers: cekuhnen Differential Revision: https://developer.blender.org/D1699
2015-12-31Fix T46915: Non-intuitive behavior of Vector Curve Mapping nodeSergey Sharybin
Vector mapping node was doing some weird mapping of both original and mapped coordinates. Mapping of original coordinates was caused by the clamping nature of the LUT generated from the node. Mapping of the mapped value again was quite totally obscure -- one needed to constantly keep in mind that actual value will be scaled up and moved down. This commit makes it so values in the vector curve mapping are always absolute. In fact, it is now behaving quite the same as RGB curve mapping node and the code could be de-duplicated. Keeping the code duplicated for a bit so it's more clear what exact parts of the node changed. Reviewers: brecht Subscribers: bassamk Differential Revision: https://developer.blender.org/D1672
2015-12-22Cycles: Constant fold for the Gamma Node.Thomas Dinges
2015-12-05Cycles: Implement extrapolation for RGB curvesSergey Sharybin
Previously RGB Curves node will clamp input to 0..1 which is rather useless when one wants to use HDR image textures and do bit of correction on them. Now kernel code supports extrapolation of baked LUT based on first/last two table points and performs linear extrapolation. The only tricky part is to guess the range to bake the LUT for. Currently it's using simple approach -- minmax of the input curves. While this behaves ok for the simple cases it's easy to trick the system up causing incorrect results. Not sure we can solve those issues in a general case and since the new code is giving more expected results it's not that bad actually. In the worst case artist migh always create explicit point to make sure LUT is created for the needed HDR range. Reviewers: brecht, juicyfruit Subscribers: sebastian_k Differential Revision: https://developer.blender.org/D1658
2015-10-11Fix T45058: Cycles hair shader reflects incorrectly for meshesSergey Sharybin
The issue was caused by non-continuous tangent space calculated for triangles. This commit adds a Tangent input to Hair BSDF node which can be used to hook up Tangent calculated form UV as an input to the node in order to make sure the tangent space is continuous. Doing this as an input instead of using default tangent layer from UV because of several reasons: - This way it's really easy to preserve compatibility with existing setups. - Default UV map is not necessarily giving continuous space, one might want to use other tangent space sources or distort the space for some artistic decision. Reviewers: juicyfruit, dingto Reviewed By: dingto Differential Revision: https://developer.blender.org/D1428
2015-10-05Fix T46352: Cycles fails to render when material contains UV mapped texture ↵Sergey Sharybin
as volume input
2015-10-05Cycles: Remove redundant coordinate clipping in voxel SVM nodeSergey Sharybin
It is now handled via texture extension type.
2015-09-18Fix T46030: Strange behavior of Cycles Brick TextureSergey Sharybin
Added some extra seed to the hash, so it's now less likely to give repetitive patters at values around zero. This will change distribution of bricks for existing files. but it's something inevitable.
2015-09-03Cycles: Fix for uninitialized closure dataSergey Sharybin
This might confuse closure merger. Spotted by Campbell Barton, thanks!
2015-08-23Cleanup: spelling/styleCampbell Barton
2015-07-29Cycles: Fix issue in closure merge function.Lukas Stockner
* Did not check data2, this partially fixes T45583. * Initialize data2 in some closures to avoid potential problems. Differential Revision: https://developer.blender.org/D1436
2015-07-21Cycles: Workaround for sm_50 on 32bit platformSergey Sharybin
Basically this commit totally disables new SVN Voxel node, which solves some of the compiler's issues.
2015-07-19Cycles: Fix compilation of OpenCL kernel after point density commitSergey Sharybin
2015-07-18Cycles: Add voxel texture sampler shader nodeSergey Sharybin
The idea of this node is to sampling of 3D voxels at a given coordinate supporting different mapping strategies (world space mapping, object local space etc). Currently not in use, it's a preparation step for supporting point density textures.
2015-06-13Cycles: Solve possible buffer overrun when using too much closuresSergey Sharybin
Glass BSDF was doing some magic with copying weigths from initial closure onto refraction one and the code was not checking properly for the number of closures.
2015-06-01Cycles: Assert in the cases when SVM node was not handledSergey Sharybin
This will help figuring out cases when node was not properly handled by the SVM by aborting execution on CPU, where all the nodes are expected to be supported.
2015-06-01Cycles: Implement selective nodes compilationSergey Sharybin
This commits finishes initial selective nodes compilation into kernel, which helps a lot performance-wise for AMD OpenCL kernels. Split by node groups is based on statistics from simple scenes like BMW and more complex scenes like mango and gooseberry production files. Further tweaks are always possible, but it should be a good starting point. TODO: Still need to ignore unused nodes when calculating requested shader features.
2015-06-01Cycles: Fix some typos in the selective modes compilationSergey Sharybin
2015-06-01Cycles: Add bump feature for selective nodes compilationSergey Sharybin
For now it is unused in the kernel, actual usage will come with the next commits.
2015-05-28Cleanup: Remove unused Noise Basis texture code.Thomas Dinges
Same as last commit, code is unused and this one actually would have required some fixes, as these variants output values outside the 0-1 value range, which doesn't fit Cycles shader design.
2015-05-28Cleanup: Remove unused Voronoi texture code.Thomas Dinges
Let's finally delete this code, after 4 years of being unused, there really is no excuse anymore. If we decide to extend the procedural textures in SVM, we can do this anytime in the future.
2015-05-09Cycles: OpenCL kernel splitGeorge Kyriazis
This commit contains all the work related on the AMD megakernel split work which was mainly done by Varun Sundar, George Kyriazis and Lenny Wang, plus some help from Sergey Sharybin, Martijn Berger, Thomas Dinges and likely someone else which we're forgetting to mention. Currently only AMD cards are enabled for the new split kernel, but it is possible to force split opencl kernel to be used by setting the following environment variable: CYCLES_OPENCL_SPLIT_KERNEL_TEST=1. Not all the features are supported yet, and that being said no motion blur, camera blur, SSS and volumetrics for now. Also transparent shadows are disabled on AMD device because of some compiler bug. This kernel is also only implements regular path tracing and supporting branched one will take a bit. Branched path tracing is exposed to the interface still, which is a bit misleading and will be hidden there soon. More feature will be enabled once they're ported to the split kernel and tested. Neither regular CPU nor CUDA has any difference, they're generating the same exact code, which means no regressions/improvements there. Based on the research paper: https://research.nvidia.com/sites/default/files/publications/laine2013hpg_paper.pdf Here's the documentation: https://docs.google.com/document/d/1LuXW-CV-sVJkQaEGZlMJ86jZ8FmoPfecaMdR-oiWbUY/edit Design discussion of the patch: https://developer.blender.org/T44197 Differential Revision: https://developer.blender.org/D1200
2015-05-09Cycles: Initial work towards selective nodes support compilationSergey Sharybin
The goal is to be able to compile kernel with nodes which are actually needed to render current scene, hence improving performance of the kernel, The idea is: - Have few node groups, starting with a group which contains nodes are used really often, and then couple of groups which will be extension of this one. - Have feature-based nodes disabling, so it's possible to disable nodes related to features which are not used with the currently used nodes group. This commit only lays down needed routines for this approach, actual split will happen later after gathering statistics from bunch of production scenes.
2015-05-09Cycles: Add utility function to graph to query number of closures used in itSergey Sharybin
Currently unused but will be needed soon for the split kernel work.
2015-05-07Cycles: Cleanup, make it more clear what endif closes what ifdefSergey Sharybin
2015-05-05Cycles: Use curve approximation for blackbody instead of lookup tableSv. Lockal
Now we calculate color in range 800..12000 using an approximation a/x+bx+c for R and G and ((at + b)t + c)t + d) for B. Max absolute error for RGB for non-lut function is less than 0.0001, which is enough to get the same 8 bit/channel color as for OSL with a noticeable performance difference. However there is a slight visible difference between previous non-OSL implementation because of lookup table interpolation and offset-by-one mistake. The previous implementation gave black color outside of soft range (t > 12000), now it gives the same color as for 12000. Also blackbody node without input connected is being converted to value input at shader compile time. Reviewers: dingto, sergey Reviewed By: dingto Subscribers: nutel, brecht, juicyfruit Differential Revision: https://developer.blender.org/D1280
2015-04-27Cycles: Use native saturate function for CUDASergey Sharybin
This more a workaround for CUDA optimizer which can't optimize clamp(x, 0, 1) into a single instruction and uses 4 instructions instead. Original patch by @lockal with own modification: Don't make changes outside of the kernel. They don't make any difference anyway and term saturate() has a bit different meaning outside of kernel. This gives around 2% of speedup in Barcelona file, but in more complex shader setups with lots of math nodes with clamping speedup could be much nicer. Subscribers: dingto Projects: #cycles Differential Revision: https://developer.blender.org/D1224
2015-04-20Cycles: Split BVH nodes storage into inner and leaf nodesSergey Sharybin
This way we can get rid of inefficient memory usage caused by BVH boundbox part being unused by leaf nodes but still being allocated for them. Doing such split allows to save 6 of float4 values for QBVH per leaf node and 3 of float4 values for regular BVH per leaf node. This translates into following memory save using 01.01.01.G rendered without hair: Device memory size Device memory peak Global memory peak Before the patch: 4957 5051 7668 With the patch: 4467 4562 7332 The measurements are done against current master. Still need to run speed tests and it's hard to predict if it's faster or not: on the one hand leaf nodes are now much more coherent in cache, on the other hand they're not so much coherent with regular nodes anymore. Reviewers: brecht, juicyfruit Subscribers: venomgfx, eyecandy Differential Revision: https://developer.blender.org/D1236
2015-04-04Cleanup: Typo fix in HSV code.Thomas Dinges
2015-03-31Cycles: Avoid float/int conversion in few placesSergey Sharybin
2015-03-27Cycles: Code cleanup, spaces around keywordsSergey Sharybin
This inconsistency drove me totally crazy, it's really confusing when it's inconsistent especially when you work on both Cycles and Blender sides. Shouldn;t cause merge PITA, it's whitespace changes only, Git should be able to merge it nicely.
2015-03-25Fix T44123: Cycles SSS renders black in recent buildsSergey Sharybin
Issue was introduced in 01ee21f where i didn't notice *_setup() function only doing partial initialization, and some of parameters are expected to be initialized by callee function. This was hitting only some setups, so tests with benchmark scenes didn't unleash issues. Now it should all be fine. This is to go to the 2.74 branch and we actually might re-AHOY.
2015-02-23Cleanup: Simplify brick texture code a bit.Thomas Dinges
2015-02-21Fix T43755: Wireframe attribute doesn't work with displaceSergey Sharybin
This attribute missed derivatives calculation. Not totally sure what's the proper approach for algebraic derivative calculation, so calculating them by definition. This isn't fastest way to do it in this case and could be replaced with some smarter magic in the wireframe calculation loop. At least currently implemented approach is better than nothing.
2015-02-19Cycles: Make sphere and tube image mapping friendly with OpenCLSergey Sharybin
OpenCL doesn't let you to get address of vector components, which is kinda annoying. On the other hand, maybe now compiler will have more chances to optimize something out.