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
2019-05-19Cleanup: refactor image texture node code for coming changesBrecht Van Lommel
2019-05-03Cycles: support loading images from arbitrary OpenColorIO color spaceLukas Stockner
These are the internal changes to Cycles, for Blender integration there are no functional changes in this commit. Images are converted to scene linear color space on file load, and on reading from the OpenImageIO texture cache. 8-bit images are compressed with the sRGB transfer function to avoid precision loss while keeping memory usages low. This also means that for common cases of 8-bit sRGB images no conversion happens at all on image loading. Initial patch by Lukas, completed by Brecht. Differential Revision: https://developer.blender.org/D3491
2019-05-01Cleanup: comments (long lines) in cyclesCampbell Barton
2019-04-24Cycles: remove hair minimum width support.Brecht Van Lommel
This never really worked as it was supposed to. The main goal of this is to turn noise from sampling tiny hairs into multiple layers of transparency that do not need to be sampled stochastically. However the implementation of this worked by randomly discarding hair intersections in BVH traversal, which defeats the purpose. If it ever comes back, it's best implemented outside the kernel as a preprocess that changes hair radius before BVH building. This would also make it work with Embree, where it's not supported now. But it's not so clear anymore that with many AA samples and GPU rendering this feature is as helpful as it once was for CPU raytracers with few AA samples. The benefit of removing this feature is improved hair ray tracing performance, tested on NVIDIA Titan Xp: bmw27: +0.37% classroom: +0.26% fishy_cat: -7.36% koro: -12.98% pabellon: -0.12% Differential Revision: https://developer.blender.org/D4532
2019-04-17ClangFormat: apply to source, most of internCampbell Barton
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
2019-03-11Fix T61103: Cycles bevel wrong on objects with negative scale.Brecht Van Lommel
2019-03-05Cycles: Added Float2 attribute type.Brecht Van Lommel
Float2 are now a new type for attributes in Cycles. Before, the choices for attribute storage were float and float3, the latter padded to float4. This meant that UV maps were inflated to twice the size necessary. Reviewers: brecht, sergey Reviewed By: brecht Subscribers: #cycles Tags: #cycles Differential Revision: https://developer.blender.org/D4409
2019-02-19T61513: Refactored Cycles Attribute RetrievalJeroen Bakker
There is a generic function to retrieve float and float3 attributes `primitive_attribute_float` and primitive_attribute_float3`. Inside these functions an prioritised if-else construction checked where the attribute is stored and then retrieved from that location. Actually the calling function most of the time already knows where the data is stored. So we could simplify this by splitting these functions and remove the check logic. This patch splits the `primitive_attribute_float?` functions into `primitive_surface_attribute_float?` and `primitive_volume_attribute_float?`. What leads to less branching and more optimum kernels. The original function is still being used by OSL and `svm_node_attr`. This will reduce the compilation time and render time for kernels. Especially in production scenes there is a lot of benefit. Impact in compilation times job | scene_name | previous | new | percentage -------+-----------------+----------+-------+------------ t61513 | empty | 10.63 | 10.66 | 0% t61513 | bmw | 17.91 | 17.65 | 1% t61513 | fishycat | 19.57 | 17.68 | 10% t61513 | barbershop | 54.10 | 24.41 | 55% t61513 | classroom | 17.55 | 16.29 | 7% t61513 | koro | 18.92 | 18.05 | 5% t61513 | pavillion | 17.43 | 16.52 | 5% t61513 | splash279 | 16.48 | 14.91 | 10% t61513 | volume_emission | 36.22 | 21.60 | 40% Impact in render times job | scene_name | previous | new | percentage -------+-----------------+----------+--------+------------ 61513 | empty | 21.06 | 20.35 | 3% 61513 | bmw | 198.44 | 190.05 | 4% 61513 | fishycat | 394.20 | 401.25 | -2% 61513 | barbershop | 1188.16 | 912.39 | 23% 61513 | classroom | 341.08 | 340.38 | 0% 61513 | koro | 472.43 | 471.80 | 0% 61513 | pavillion | 905.77 | 899.80 | 1% 61513 | splash279 | 55.26 | 54.86 | 1% 61513 | volume_emission | 62.59 | 61.70 | 1% There is also a possitive impact when using CPU and CUDA, but they are small. I didn't split the hair logic from the surface logic due to: * Hair and surface use same attribute types. It was not clear if it could be splitted when looking at the code only. * Hair and surface are quick to compile and to read. So the benefit is quite small. Differential Revision: https://developer.blender.org/D4375
2019-02-14Cleanup: fix compiler warnings.Brecht Van Lommel
2019-02-14Fix T61470: incorrect saturation clamping in recent bugfix.Brecht Van Lommel
We should clamp the result after multiplication.
2019-02-13Fix T61470: inconsistent HSV node results with saturation > 1.0.Brecht Van Lommel
Values outside the 0..1 range produce negative colors, so now clamp to that range everywhere. Also fixes improper handling of hue > 2.0 in some places.
2018-12-06Fix T57963: Cycles crash using AO for displacement.Brecht Van Lommel
Note this is not supported, there exists no geometry at this point, but it should not crash at least.
2018-11-15Cycles: Cleanup, code styleSergey Sharybin
2018-11-09Cycles: Cleanup, spacing after preprocessorSergey Sharybin
It is supposed to be two spaces before comment stating which if else/endif statements corresponds to. Was mainly violated in the header guards.
2018-09-12Cycles: Don't allocate Extra if BSDF allocation failedSergey Sharybin
Failed as in did not allocate due to possibly weight cutoff. Tryign to allocated Extra storage for closure in such situation will consfuse Cycles and cause crashes later one due to obscure values in ShaderData.
2018-09-10Fix Cycles principled BSDF black with transmission and IOR 1.0.Brecht Van Lommel
2018-08-24Cycles: Cleanup, styleSergey Sharybin
I wouldn't mind changing style to have space after keyword, but there was no official code style change proposed.
2018-08-24Cycles: Fix wrong looking voronoi of second 2nd closestSergey Sharybin
Was only happening for release builds made with GCC-8. Probably some optimization strtegy was confused by uninitialized variable.
2018-07-26Cycles: Add reflection fix to Bump and Normal Map nodesLukas Stockner
While changing the shading normal is a great way to add additional detail to a model, there are some problems with it. One of them is that at grazing angles and/or strong changes to the normal, the reflected ray can end up pointing into the actual geometry, which results in a black spot. This patch helps avoid this by automatically reducing the strength of the bump/normal map if the reflected direction would end up too shallow or inside the geometry. Differential Revision: https://developer.blender.org/D2574
2018-07-20Fix T54455, T56053, T55564: Cycles OpenCL build error after recent changes.Brecht Van Lommel
2018-07-18Cycles: add Principled Hair BSDF.L. E. Segovia
This is a physically-based, easy-to-use shader for rendering hair and fur, with controls for melanin, roughness and randomization. Based on the paper "A Practical and Controllable Hair and Fur Model for Production Path Tracing". Implemented by Leonardo E. Segovia and Lukas Stockner, part of Google Summer of Code 2018.
2018-07-15Cycles: add voronoi features and distance settings from Blender.charlie
Features to get the 2nd, 3rd, 4th closest point instead of the closest, and various distance metrics. No viewport/Eevee support yet. Patch by Michel Anders, Charlie Jolly and Brecht Van Lommel. Differential Revision: https://developer.blender.org/D3503
2018-07-15Cleanup: use float3 SSE instead of ssef for voronoi texture.Brecht Van Lommel
2018-07-13Nodes: add sqrt, ceil, floor and fract to math nodes.Charlie Jolly
This works for Cycles, Eevee, texture nodes and compositing. It helps to reduce the number of math nodes required in various node setups. Differential Revision: https://developer.blender.org/D3537
2018-07-06Cleanup: strip trailing space for cyclesCampbell Barton
2018-06-21Fix T55564: Cycles OpenCL build error on some scenes.Brecht Van Lommel
2018-06-19Fix T55528: Cycles AO node should default to 1 if radius is 0.Brecht Van Lommel
2018-06-15Cycles: change Ambient Occlusion shader to output colors.Lukas Stockner
This means the shader can now be used for procedural texturing. New settings on the node are Samples, Inside, Local Only and Distance. Original patch by Lukas with further changes by Brecht. Differential Revision: https://developer.blender.org/D3479
2018-06-14Cycles: Query XYZ to/from Scene Linear conversion from OCIO instead of ↵Lukas Stockner
assuming sRGB I've limited it to just the RGB<->XYZ stuff for now, correct image handling is the next step. Reviewers: brecht, sergey Differential Revision: https://developer.blender.org/D3478
2018-05-27Cycles: Add Support for IES files as textures for light strengthLukas Stockner
This patch adds support for IES files, a file format that is commonly used to store the directional intensity distribution of light sources. The new IES node is supposed to be plugged into the Strength input of the Emission node of the lamp. Since people generating IES files do not really seem to care about the standard, the parser is flexible enough to accept all test files I have tried. Some common weirdnesses are distributing values over multiple lines that should go into one line, using commas instead of spaces as delimiters and adding various useless stuff at the end of the file. The user interface of the node is similar to the script node, the user can either select an internal Text or load a file. Internally, IES files are handled similar to Image textures: They are stored in slots by the LightManager and each unique IES is assigned to one slot. The local coordinate system of the lamp is used, so that the direction of the light can be changed. For UI reasons, it's usually best to add an area light, rotate it and then change its type, since especially the point light does not immediately show its local coordinate system in the viewport. Reviewers: #cycles, dingto, sergey, brecht Reviewed By: #cycles, dingto, brecht Subscribers: OgDEV, crazyrobinhood, secundar, cardboard, pisuke, intrah, swerner, micah_denn, harvester, gottfried, disnel, campbellbarton, duarteframos, Lapineige, brecht, juicyfruit, dingto, marek, rickyblender, bliblubli, lockal, sergey Differential Revision: https://developer.blender.org/D1543
2018-05-24Cycles/Compositor: Add arctan2 operation to the Math nodeLukas Stockner
The Math node currently has the normal atan() function, but for actual angles this is fairly useless without additional nodes to handle the signs. Since the node has two inputs anyways, it only makes sense to add an arctan2 option. Reviewers: sergey, brecht Differential Revision: https://developer.blender.org/D3430
2018-04-29Cycles: Cleanup: Remove double semicolonsLukas Stockner
2018-03-10Cycles: switch to squared roughness convention for all nodes.Brecht Van Lommel
This was already done for the Principled BSDF to be compatible with typical baked roughness maps in PBR workflows.
2018-03-10Code refactor: make Transform always affine, dropping last row.Brecht Van Lommel
This save a little memory and copying in the kernel by storing only a 4x3 matrix instead of a 4x4 matrix. We already did this in a few places, and those don't need to be special exceptions anymore now.
2018-02-28Cycles: principled absorption color now has more effect at lower values.Brecht Van Lommel
2018-02-23Cycles: add Principled Volume shader.Brecht Van Lommel
Similar to the Principled BSDF, this should make it easier to set up volume materials. Smoke and fire can be rendererd with just a single principled volume node, the appropriate attributes will be used when available. The node also works for simpler homogeneous volumes like water or mist. Differential Revision: https://developer.blender.org/D3033
2018-02-22Cycles: better path termination for transparency.Brecht Van Lommel
We now continue transparent paths after diffuse/glossy/transmission/volume bounces are exceeded. This avoids unexpected boundaries in volumes with transparent boundaries. It is also required for MIS to work correctly with transparent surfaces, as we also continue through these in shadow rays. The main visible changes is that volumes will now be lit by the background even at volume bounces 0, same as surfaces. Fixes T53914 and T54103.
2018-02-21Fix T54107: bevel shader + normal map gives wrong result.Brecht Van Lommel
2018-02-18Code cleanup: remove some more unused code after recent CUDA changes.Brecht Van Lommel
2018-02-14Cycles: restore Particle Info Index for now, keep it next to Random.Brecht Van Lommel
It seems to be useful still in cases where the particle are distributed in a particular order or pattern, to colorize them along with that. This isn't really well defined, but might as well avoid breaking backwards compatibility for now.
2018-02-14Cycles: change Index output of Hair and Particle Info to Random, in 0..1 range.Brecht Van Lommel
These are used for randomization, so it's convenient if the index is already hashed and consistent with the Object Info node.
2018-02-13Cycles: Implement index output for hair nodeSergey Sharybin
This is like the only way to add variety to hair which is created using simple children. Used here for the hair. Maybe not ideal, but the time will show.
2018-02-12Fix random walk SSS issues with different base and subsurface color.Brecht Van Lommel
Burley SSS uses a bit of strange thing where the albedo and closure weight are different, which makes the subsurface color act a bit like a subsurface radius indirectly by the way the Burley SSS profile works. This can't work for random walk SSS though, and it's not clear to me that this is actually a good idea since it's really the subsurface radius that is supposed to control this. For now I'll leave Burley SSS working the same to not break backwards compatibility.
2018-02-09Cycles: add random walk subsurface scattering to Principled BSDF.Brecht Van Lommel
Differential Revision: https://developer.blender.org/D3054
2018-02-09Cycles: random walk subsurface scattering.Brecht Van Lommel
It is basically brute force volume scattering within the mesh, but part of the SSS code for faster performance. The main difference with actual volume scattering is that we assume the boundaries are diffuse and that all lighting is coming through this boundary from outside the volume. This gives much more accurate results for thin features and low density. Some challenges remain however: * Significantly more noisy than BSSRDF. Adding Dwivedi sampling may help here, but it's unclear still how much it helps in real world cases. * Due to this being a volumetric method, geometry like eyes or mouth can darken the skin on the outside. We may be able to reduce this effect, or users can compensate for it by reducing the scattering radius in such areas. * Sharp corners are quite bright. This matches actual volume rendering and results in some other renderers, but maybe not so much real world objects. Differential Revision: https://developer.blender.org/D3054
2018-02-03Fix more Cycles incorrect principled BSDF mixing due to missing initialization.Brecht Van Lommel
Spotted by Ha Hyung-jin, thanks!
2018-02-03Cycles: add Vector Displacement node and extend Displacement node.Brecht Van Lommel
This adds midlevel and object/world space for displacement, and a vector displacement node with tangent/object/world space, midlevel and scale. Note that tangent space vector displacement still is not exactly compatible with maps created by other software, this will require changes to the tangent computation. Differential Revision: https://developer.blender.org/D1734
2018-01-30Fix Cycles incorrect principled BSDF mixing with some parameter variatons.Brecht Van Lommel
Spotted by Ha Hyung-jin, thanks!
2018-01-27Code refactor: make mixed small/large BSSRDF radii more robust.Brecht Van Lommel
2018-01-26Code refactor: store RGB BSSRDF in a single closure.Brecht Van Lommel
Previously we stored each color channel in a single closure, which was convenient for sampling a closure and channel together. But this doesn't work so well for algorithms where we want to render multiple color channels together.