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-08-09Cycles: Fix crash in empty scenesJulian Eisel
To recreate, just delete default cube and render. Simple fix, but @maiself or @sergey may want to double-check ;)
2016-08-07Cycles microdisplacement: Move displacement options from mesh to material ↵Mai Lavelle
settings Displacement is now a per material setting, which means old files will have to be updated if they had used displacement. Cool side effect of this change is material previews now show displacement. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2140
2016-08-07Cycles microdisplacement: Support for Catmull-Clark subdivision via OpenSubdivMai Lavelle
Enables Catmull-Clark subdivision meshes with support for creases and attribute subdivision. Still waiting on OpenSubdiv to fully support face varying interpolation for subdividing uv coordinates tho. Also there may be some inconsistencies with Blender's subdivision which will be resolved at a later time. Code for reading patch tables and creating patch maps is borrowed from OpenSubdiv. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2111
2016-08-06Cycles: Add AttributeDescriptorMai Lavelle
Adds a descriptor for attributes that can easily be passed around and extended to contain more data. Will be used for attributes on subdivision meshes. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2110
2016-08-06Fix for Cycles particle motion blur hiding fix.Brecht Van Lommel
My mistake in modifying the patch.
2016-08-05Cycles: hide particles with broken motion blur traces.Alexander Gavrilov
Currently cycles cannot correctly render motion blur for objects that appear or disappear during the shutter window. Until that can be fixed properly, it may be better to hide such particles rather than let them render as if they were stationary for half of the frame. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2125
2016-08-04Cycles: copy shader node names over in the blender sync code.Alexander Gavrilov
This makes constant folding logs with --debug-cycles more meaningful. A tiny fix is needed in OSL generator to match recent node refactoring.
2016-08-03Fix T49010: Portals don't work in recent Blender versionsSergey Sharybin
2016-08-02Cycles: log how many nodes were deduplicated for use in tests.Alexander Gavrilov
To make the number more meaningful, also skip deduplicating obviously unused nodes with no outgoing links.
2016-08-02Cycles: add folding for redundant A to B to A conversions.Alexander Gavrilov
As a result of other folding simplifications it may happen that two type conversion nodes end up directly connected. In some cases it may be possible to then remove both. A realistic case might be an optimized out Mix RGB node used to blend vectors. It seems it's safe to optimize when B is a float3 type (color, vector), and A is float3 or float. Reviewers: #cycles, sergey Reviewed By: #cycles, sergey Subscribers: sergey Differential Revision: https://developer.blender.org/D2134
2016-08-01Cycles: add unit tests for supported constant folding rules.Alexander Gavrilov
Code coverage of different combinations of secondary conditions is obviously not complete because there are so many of them, but all main rules should be there. The reason for CORRECT vs INVALID is that both words have the same number of characters so calls line up, but look quite different. Reviewers: #cycles, sergey Reviewed By: #cycles, sergey Subscribers: dingto, sergey, brecht Differential Revision: https://developer.blender.org/D2130
2016-07-31Fix mistake in Cycles mix node multiply constant folding.Brecht Van Lommel
2016-07-31Cycles: refactor kernel closure storage to use structs per closure type.Brecht Van Lommel
Reviewed By: dingto, sergey Differential Revision: https://developer.blender.org/D2127
2016-07-31Cycles: constant fold add/mul type nodes with known 0 and 1 arguments.Alexander Gavrilov
These values often either turn the node into a no-op, or even make it evaluate to 0 no matter what the other input value is, thus allowing deletion of a branch of the node graph that otherwise is not constant. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2085
2016-07-31Cycles: constant folding for RGB/Vector Curves and Color Ramp.Alexander Gavrilov
These are complex nodes, and it's conceivable they may end up constant in some circumstances within node groups, so folding support is useful. Reviewed By: brecht Differential Revision: https://developer.blender.org/D2084
2016-07-31Fix Cycles OpenCL not always allocating enough space for closures.Brecht Van Lommel
2016-07-29Cycles: Add fundamentals to test constant foldingSergey Sharybin
This commit adds some easy to use way to check whether the graph was properly optimized. The idea is based on using mock glog sync which keeps track on all messages and expects specific log message to appear in the logging. This means each optimization step should report that it optimized something (specifying what exactly was optimized) and what was used for optimization. There's also some ease-ish way to define shader networks which we might want to make a bit more global and available for all tests in the future. For now only RGBToBW node is covered as an example, really hope to get help from active guys in the community to finish covering all existing optimization cases. Ready to fix any possible issues with builder when needed tho :)
2016-07-29Cycles: remove narrowing conversion from recent commitMai Lavelle
2016-07-29Cycles microdisplacement: move subdivision options to subsurf modifierMai Lavelle
Subdivision options can now be found in the subsurf modifier. The modifier must be the last in the stack or the options will be unavailable. Catmull-Clark subdivision is still unavailable and will fallback to linear subdivision instead Reviewed By: brecht Differential Revision: https://developer.blender.org/D2109
2016-07-29Cycles microdisplacement: ngons and attributes for subdivision meshesMai Lavelle
This adds support for ngons and attributes on subdivision meshes. Ngons are needed for proper attribute interpolation as well as correct Catmull-Clark subdivision. Several changes are made to achieve this: - new primitive `SubdFace` added to `Mesh` - 3 more textures are used to store info on patches from subd meshes - Blender export uses loop interface instead of tessface for subd meshes - `Attribute` class is updated with a simplified way to pass primitive counts around and to support ngons. - extra points for ngons are generated for O(1) attribute interpolation - curves are temporally disabled on subd meshes to avoid various bugs with implementation - old unneeded code is removed from `subd/` - various fixes and improvements Reviewed By: brecht Differential Revision: https://developer.blender.org/D2108
2016-07-29Fix use of uninitialized variable in Cycles, mostly harmless.Brecht Van Lommel
2016-07-28Cycles: Fix missing mesh flags update when tweaking shadersSergey Sharybin
This is a bit weak, but better than tagging whole mesh manager for update. Maybe we'll solve such dual-look up in the future. This commit finally solves T48963: Noise when changing Diffuse node to Emission node
2016-07-28Cycles: Fix wrong order of light manager update tagSergey Sharybin
Shader's has_surface_emission will only be known for sure after compilation.
2016-07-28Cycles: De-duplicate more checks around light emisive meshesSergey Sharybin
Once again, should be no functional changes.
2016-07-28Cycles: De-duplicate check for MIS shaders in meshesSergey Sharybin
Should be no functional changes.
2016-07-28Cycles: Add some extra logging for light debuggingSergey Sharybin
2016-07-28Fix T48790: Cycles render bug with zero strength lights.Brecht Van Lommel
2016-07-27Cycles: Style, placement of asteric in pointersSergey Sharybin
Seems we are using `void *` much much more often in Cycles.
2016-07-27Cycles: Some minor tweaks to emission sharderSergey Sharybin
- Nodification of shader nodes changed default strength from 10 to 1. If that was intentional, IMO should happen as a separate commit. - Fixed indentation.
2016-07-21Fix another Cycles OSL script node issue with shaders using bump.Brecht Van Lommel
2016-07-21Fix Cycles OSL script node not working in shader using bump, after node type ↵Brecht Van Lommel
refactoring.
2016-07-18Cycles: add ConstantFolder class for constant folding boilerplate.Alexander Gavrilov
Reviewed By: brecht, sergey Differential Revision: https://developer.blender.org/D2089
2016-07-18Cycles: add support for motion blurring of fluid meshes.Kévin Dietrich
Reviewed By: brecht Differential Revision: https://developer.blender.org/D2063
2016-07-15Cycles: Add option to disable new Hair BVHSergey Sharybin
While it's an extra option added to the interface which might not be fully obvious for artists, it allows to save up to 20% of memory in hairy scenes. This is high enough memory saver in my opinion which might become handy for some production files where it's more important to make scene to fit into memory rather than trying to use more optimal BVH structure but go into swap or crash. Reviewers: dingto, brecht Reviewed By: dingto, brecht Differential Revision: https://developer.blender.org/D2090
2016-07-14Code cleanup: show unused arguments names for ShaderNode::constant_fold.Brecht Van Lommel
2016-07-14Cleanup: comment blocksCampbell Barton
2016-07-14Cycles: Fix wrong size of sobol textureSergey Sharybin
After reformulation of SSS indirect rays it became possible to try accessing dimension higher than was pre-calculated on scene preparation. This is because we're traversing rays backwards, which means we are using higher dimensions first now.
2016-07-07Cycles: Enable unaligned BVH builder for scenes with hairSergey Sharybin
This commit enables new unaligned BVH builder and traversal for scenes with hair. This happens automatically, no need of manual control over this. There are some possible optimization still to happen here and there, but overall there's already nice speedup: Master Hair BVH bunny.blend 8:06.54 5:57.14 victor.blend 16:07.44 15:37.35 Unfortunately, such more complexity is not really coming for free, so there's some downsides, but those are within acceptable range: Master Hair BVH classroom.blend 5:31.79 5:35.11 barcelona.blend 4:38.58 4:44.51 Memory usage is also somewhat bigger for hairy scenes, but speed benefit pays well for that. Additionally as was mentioned in one of previous commits we can add an option to disable hair BVH and have similar render time but have memory saving. Reviewers: brecht, dingto, lukasstockner97, juicyfruit, maiself Differential Revision: https://developer.blender.org/D2086
2016-07-07Cycles: Implement unaligned nodes BVH builderSergey Sharybin
This is a special builder type which is allowed to orient nodes to strands direction, hence minimizing their surface area in comparison with axis-aligned nodes. Such nodes are much more efficient for hair rendering. Implementation of BVH builder is based on Embree, and generally idea there is to calculate axis-aligned SAH and oriented SAH and if SAH of oriented node is smaller than axis-aligned SAH we create unaligned node. We store both aligned and unaligned nodes in the same tree (which seems to be different from what Embree is doing) so we don't have any any extra calculations needed to set up hair ray for BVH traversal, hence avoiding any possible negative effect of this new BVH nodes type. This new builder is currently not in use, still need to make BVH traversal code aware of unaligned nodes.
2016-07-07Cycles: Reduce memory usage by de-duplicating triangle storageSergey Sharybin
There are several internal changes for this: First idea is to make __tri_verts to behave similar to __tri_storage, meaning, __tri_verts array now contains all vertices of all triangles instead of just mesh vertices. This saves some lookup when reading triangle coordinates in functions like triangle_normal(). In order to make it efficient needed to store global triangle offset somewhere. So no __tri_vindex.w contains a global triangle index which can be used to read triangle vertices. Additionally, the order of vertices in that array is aligned with primitives from BVH. This is needed to keep cache as much coherent as possible for BVH traversal. This causes some extra tricks needed to fill the array in and deal with True Displacement but those trickery is fully required to prevent noticeable slowdown. Next idea was to use this __tri_verts instead of __tri_storage in intersection code. Unfortunately, this is quite tricky to do without noticeable speed loss. Mainly this loss is caused by extra lookup happening to access vertex coordinate. Fortunately, tricks here and there (i,e, some types changes to avoid casts which are not really coming for free) reduces those losses to an acceptable level. So now they are within couple of percent only, On a positive site we've achieved: - Few percent of memory save with triangle-only scenes. Actual save in this case is close to size of all vertices. On a more fine-subdivided scenes this benefit might become more obvious. - Huge memory save of hairy scenes. For example, on koro.blend there is about 20% memory save. Similar figure for bunny.blend. This memory save was the main goal of this commit to move forward with Hair BVH which required more memory per BVH node. So while this sounds exciting, this memory optimization will become invisible by upcoming Hair BVH work. But again on a positive side, we can add an option to NOT use Hair BVH and then we'll have same-ish render times as we've got currently but will have this 20% memory benefit on hairy scenes.
2016-07-03Fix T48783: OSL render errors after recent refactoring.Brecht Van Lommel
2016-07-02Fix use of uninitialized variable in Cycles OpenCL image textures.Brecht Van Lommel
2016-07-02Cleanup: comment blocksCampbell Barton
2016-07-02Fix Cycles OpenCL not taking Extend and Clip extension types into account.Thomas Dinges
(See T48720).
2016-06-23Cycles: Add multi-scattering, energy-conserving GGX as an option to the ↵Lukas Stockner
Glossy, Anisotropic and Glass BSDFs This commit adds a new distribution to the Glossy, Anisotropic and Glass BSDFs that implements the multiple-scattering microfacet model described in the paper "Multiple-Scattering Microfacet BSDFs with the Smith Model". Essentially, the improvement is that unlike classical GGX, which only models single scattering and assumes the contribution of multiple bounces to be zero, this new model performs a random walk on the microsurface until the ray leaves it again, which ensures perfect energy conservation. In practise, this means that the "darkening problem" - GGX materials becoming darker with increasing roughness - is solved in a physically correct and efficient way. The downside of this model is that it has no (known) analytic expression for evalation. However, it can be evaluated stochastically, and although the correct PDF isn't known either, the properties of MIS and the balance heuristic guarantee an unbiased result at the cost of slightly higher noise. Reviewers: dingto, #cycles, brecht Reviewed By: dingto, #cycles, brecht Subscribers: bliblubli, ace_dragon, gregzaal, brecht, harvester, dingto, marcog, swerner, jtheninja, Blendify, nutel Differential Revision: https://developer.blender.org/D2002
2016-06-22Cycles: Fix crash with Environment Texture and OSLLukas Stockner
In the OSL node compilation code for the Environment Texture, is_linear was used as a socket. However, there was no socket for it, which caused Blender to crash. Adding a socket doesn't really make sense since it's an internal value and not a parameter of the node, so it now just uses the variable directly.
2016-06-21Cycles: Deduplicate Vector and RGB Curve nodesLukas Stockner
Since most of the code for these two nodes was identical, this commit now instead uses a common base class that implements all the functionality.
2016-06-19Cleanup: Remove todo comment, this is fine as is.Thomas Dinges
2016-06-19Cycles: add constant folding for more color operation nodes.Alexander Gavrilov
Invert, brightness & constrast, separate/combine and Mix RGB blend modes and clamping.
2016-06-19Fix issues with node deduplication in Cycles shader graph.Alexander Gavrilov
It is not possible to use a set split by name as valid input to check_node_input_traversed - it needs a complete set of all nodes visited so far. On the other hand, the merge comparison loop should only check nodes that were not just visited, but found unique. This means that there should really be two separate data structures. Without the fix, check_node_input_traversed actually never returns true, so only nodes without any inputs are processed.