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
2021-02-17Cycles: add utility functions for zero float2/float3/float4/transformBrecht Van Lommel
Ref D8237, T78710
2020-11-04Cycles API: encapsulate Node socket membersKévin Dietrich
This encapsulates Node socket members behind a set of specific methods; as such it is no longer possible to directly access Node class members from exporters and parts of Cycles. The methods are defined via the NODE_SOCKET_API macros in `graph/ node.h`, and are for getting or setting a specific socket's value, as well as querying or modifying the state of its update flag. The setters will check whether the value has changed and tag the socket as modified appropriately. This will let us know how a Node has changed and what to update, which is the first concrete step toward a more granular scene update system. Since the setters will tag the Node sockets as modified when passed different data, this patch also removes the various modified methods on Nodes in favor of Node::is_modified which checks the sockets' update flags status. Reviewed By: brecht Maniphest Tasks: T79174 Differential Revision: https://developer.blender.org/D8544
2020-10-27Revert "Cycles API: encapsulate Node socket members"Brecht Van Lommel
This reverts commit 527f8b32b32187f754e5b176db6377736f9cb8ff. It is causing motion blur test failures and crashes in some renders, reverting until this is fixed.
2020-10-27Cycles API: encapsulate Node socket membersKévin Dietrich
This encapsulates Node socket members behind a set of specific methods; as such it is no longer possible to directly access Node class members from exporters and parts of Cycles. The methods are defined via the NODE_SOCKET_API macros in `graph/ node.h`, and are for getting or setting a specific socket's value, as well as querying or modifying the state of its update flag. The setters will check whether the value has changed and tag the socket as modified appropriately. This will let us know how a Node has changed and what to update, which is the first concrete step toward a more granular scene update system. Since the setters will tag the Node sockets as modified when passed different data, this patch also removes the various `modified` methods on Nodes in favor of `Node::is_modified` which checks the sockets' update flags status. Reviewed By: brecht Maniphest Tasks: T79174 Differential Revision: https://developer.blender.org/D8544
2020-10-13Cycles: fix missing ShaderNode ownership in render_graph_finalize_testKévin Dietrich
2020-09-04Fix build error on macOS after recent changesBrecht Van Lommel
2020-06-22Cleanup: minor refactoring around DeviceTaskBrecht Van Lommel
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2019-12-13Cycles: Fix compilation of the Render Graph testLukas Stockner
2019-12-12Add support for tiled images and the UDIM naming schemeLukas Stockner
This patch contains the work that I did during my week at the Code Quest - adding support for tiled images to Blender. With this patch, images now contain a list of tiles. By default, this just contains one tile, but if the source type is set to Tiled, the user can add additional tiles. When acquiring an ImBuf, the tile to be loaded is specified in the ImageUser. Therefore, code that is not yet aware of tiles will just access the default tile as usual. The filenames of the additional tiles are derived from the original filename according to the UDIM naming scheme - the filename contains an index that is calculated as (1001 + 10*<y coordinate of the tile> + <x coordinate of the tile>), where the x coordinate never goes above 9. Internally, the various tiles are stored in a cache just like sequences. When acquired for the first time, the code will try to load the corresponding file from disk. Alternatively, a new operator can be used to initialize the tile similar to the New Image operator. The following features are supported so far: - Automatic detection and loading of all tiles when opening the first tile (1001) - Saving all tiles - Adding and removing tiles - Filling tiles with generated images - Drawing all tiles in the Image Editor - Viewing a tiled grid even if no image is selected - Rendering tiled images in Eevee - Rendering tiled images in Cycles (in SVM mode) - Automatically skipping loading of unused tiles in Cycles - 2D texture painting (also across tiles) - 3D texture painting (also across tiles, only limitation: individual faces can not cross tile borders) - Assigning custom labels to individual tiles (drawn in the Image Editor instead of the ID) - Different resolutions between tiles There still are some missing features that will be added later (see T72390): - Workbench engine support - Packing/Unpacking support - Baking support - Cycles OSL support - many other Blender features that rely on images Thanks to Brecht for the review and to all who tested the intermediate versions! Differential Revision: https://developer.blender.org/D3509
2019-08-21Shading: Add more operators to Vector Math node.OmarSquircleArt
Add Multiply, Divide, Project, Reflect, Distance, Length, Scale, Snap, Floor, Ceil, Modulo, Fraction, Absolute, Minimum, and Maximum operators to the Vector Math node. The Value output has been removed from operators whose output is a vector, and the other way around. All of those removals has been handled properly in versioning code. The patch doesn't include tests for the new operators. Tests will be added in a later patch. Reviewers: brecht, JacquesLucke Differential Revision: https://developer.blender.org/D5523
2019-08-20Cycles Tests: Fix Math tests when use_clamp is true.OmarSquircleArt
The clamp option is implemented using graph expansion, where a Clamp node named "clamp" is added and connected to the output. So the final result is actually from the node "clamp". Reviewers: brecht Differential Revision: https://developer.blender.org/D5540
2019-08-18Shading: Refactor Math node and use dynamic inputs.OmarSquircleArt
- Implement dynamic inputs. The second input is now unavailable in single operand math operators. - Reimplemenet the clamp option using graph expansion for Cycles. - Clean up code and unify naming between Blender and Cycles. - Remove unused code. Reviewers: brecht Differential Revision: https://developer.blender.org/D5481
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
2018-11-30Fix T58183: crash with CPU + GPU rendering after profiling changes.Brecht Van Lommel
Multi-device was not passing along profiler to the CPU.
2018-11-09Cycles: Cleanup, split array from vectorSergey Sharybin
Those are similar but different types, no reason to keep their definitions in a single file.
2017-10-24Cycles: Fix memory leak in test and simplify codeSergey Sharybin
2017-10-24Cycles: Fix test compilation failure after recent refactorSergey Sharybin
The test will leak CPU devices, but is all passing other than that. Leak will be fixed shortly. P.S. Committing code refactor without running regression tests, tsk ;)
2017-02-03Cycles: Cleanup, order of arguments to EXPECT_EQSergey Sharybin
The order was wrong from the semantic point of view, caused by some legacy workarounds in Libmv. Didn't realize it's was not how things were expected to be used.
2016-10-24Cycles: Cleanup, styleSergey Sharybin
2016-10-01Cycles: implement partial constant folding for exponentiation.Alexander Gavrilov
This is also an important mathematical operation that can be folded if it is known that one argument is a certain constant. For colors the operation is provided as a Gamma node. The SVM Gamma node needs a small fix to make it follow the 0 ^ 0 == 1 rule, same as the Power node, or the Gamma node itself in OSL mode. Reviewers: #cycles Differential Revision: https://developer.blender.org/D2263
2016-08-22Fix T49136: full constant Curves with zero Fac input crashes in assert.Alexander Gavrilov
The if branches were reordered when the original patch was committed, which broke the implicit non-NULL guarantee on link. To prevent re-occurrence, add a couple of unit tests.
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-02Cycles: tweak some folding tests to avoid unnecessary type conversion.Alexander Gavrilov
It's easy to connect a simple value to output without forcing conversion to color by using the Strength socket of Emission.
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-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 :)