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
2022-02-10Rebase on mastertemp-license-header-spdxCampbell Barton
2022-01-21Fix: Node link drag search doesn't list shader socketsHans Goudey
Shader sockets were only available when dragging from inputs.
2021-12-15Node Editor: Link Drag Search MenuHans Goudey
This commit adds a search menu when links are dragged above empty space. When releasing the drag, a menu displays all compatible sockets with the source link. The "main" sockets (usually the first) are weighted above other sockets in the search, so they appear first when you type the name of the node. A few special operators for creating a reroute or a group input node are also added to the search. Translation is started after choosing a node so it can be placed quickly, since users would likely adjust the position after anyway. A small "+" is displayed next to the cursor to give a hint about this. Further improvements are possible after this first iteration: - Support custom node trees. - Better drawing of items in the search menu. - Potential tweaks to filtering of items, depending on user feedback. Thanks to Juanfran Matheu for developing an initial patch. Differential Revision: https://developer.blender.org/D8286
2021-12-08Nodes: Add Shader Socket to new decleration APIAaron Carlisle
This commit adds the shader socket type to the new socket builder api. Re commits part of rB0bd3cad04edf4bf9b9d3b1353f955534aa5e6740
2021-12-07Revert moving all shader nodes to c++Jacques Lucke
This reverts to following commits: * rB5cad004d716da02f511bd34983ac7da820308676 * rB97e3a2d935ba9b21b127eda7ca104d4bcf4e48bd * rBf60b95b5320f8d6abe6a629fe8fc4f1b94d0d91c * rB0bd3cad04edf4bf9b9d3b1353f955534aa5e6740 * rBf72cc47d8edf849af98e196f721022bacf86a5e7 * rB3f7014ecc9d523997062eadd62888af5fc70a2b6 * rB0578921063fbb081239439062215f2538a31af4b * rBc20098e6ec6adee874a12e510aa4a56d89f92838 * rBd5efda72f501ad95679d7ac554086a1fb18c1ac0 The original move to c++ that the other commits depended upon had some issues that should be fixed before committing it again. The issues were reported in T93797, T93809 and T93798. We should also find a better rule for not using c-style casts going forward, although that wouldn't have been reason enough to revert the commits. Introducing something like a `MEM_new<T>` and `MEM_delete<T>` function might help with the the most common case of casting the return type of `MEM_malloc`. Going forward, I recommend first committing the changes that don't require converting files to c++. Then convert the shading node files in smaller chunks. Especially don't mix fairly low risk changes like moving some simple nodes, with higher risk changes.
2021-12-06Nodes: Add Shader Socket to new decleration APIAaron Carlisle
This commit adds the shader socket type to the new socket builder api. As a test, this commit also converts the Add Shader node to the new API Reviewed By: JacquesLucke Differential Revision: https://developer.blender.org/D13485
2021-10-26Geometry Nodes: geometry component type warning systemJacques Lucke
Previously, every node had to create warnings for unsupported input geometry manually. Now this is automated. Nodes just have to specify the geometry types they support in the node declaration. Differential Revision: https://developer.blender.org/D12899
2021-10-18Nodes: add default value to string socket declarationErik Abrahamsson
Differential Revision: https://developer.blender.org/D12758
2021-10-05Cleanup: use doxygen sectionsCampbell Barton
2021-09-15Nodes: refactor socket declarationsJacques Lucke
This commits adds a few common flags to `SocketDeclaration` so that they are available for all socket types (hide label, hide value, is multi input). This allows porting over the remaining geometry nodes to the new declaration system. Furthermore, this commit separates the concepts of the socket declaration and corresponding builders. The builders are used by nodes to declare which sockets they have (e.g. `FloatBuilder`). The ready build socket declarations can then be consumed by other systems such as the versioning code. Both use cases need different APIs and those will change for independent reasons, so it makes sense to separate the classes.
2021-09-11Nodes: Add vector min/max support to new socket builder APIHans Goudey
Also use it to fix an incorrect min and max in the cube mesh primitive node.
2021-09-08Fix T91241: wrong labels and identifiers for id socketsJacques Lucke
`nodeAddSocket` expects the name and identifier in a different order.
2021-08-30Nodes: add more flexible method to declare sockets of a nodeJacques Lucke
Previously, built-in nodes had to implement "socket templates" (`bNodeSocketTemplate`) to tell Blender which sockets they have. It was nice that this was declarative, but this approach was way too rigid and was cumbersome to use in many cases. This commit starts to move us away from this rigid structure by letting nodes implement a function that declares the sockets the node has. Right now this is used as a direct replacement of the "socket template" approach to keep the refactor smaller. It's just a bit easier to read and write. In the future we want to support more complex features like dynamic numbers of sockets and type inferencing. Those features will be easier to build on this new approach. This new approach can live side by side with `bNodeSocketTemplate` for a while. That makes it easier to update nodes one by one. Note: In `bNodeSocketTemplate` socket identifiers were made unique automatically. In this new approach, one has to specify unique identifiers manually (unless the name is unique already). Differential Revision: https://developer.blender.org/D12335