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-11-09Merge branch 'blender-v3.4-release'Hans Goudey
2022-11-09Geometry Nodes: Trim curve node selection input and correctionsMattias Fredriksson
Correct trim for cyclical curves mentioned in T101379, splitting the curves if the start/endpoint is at the 'loop point'. Correct implementation based on comments in D14481, request was made to use 'foreach_curve_by_type' to computing the point lookups. Included corrections from D16066 as it may not be a adopted solution. Exposed selection input by adding it as input to the node. Note: This is disabled for 3.4 to avoid making UI changes in Bcon3. Differential Revision: https://developer.blender.org/D16161
2022-11-09Cleanup: formatChris Blackbourn
2022-11-08Merge branch 'blender-v3.4-release'Hans Goudey
2022-11-08Geometry Nodes: Add preferred domain to many field inputsHans Goudey
The preferred domain is used to decide which domain the viewer node should use when set to "Auto" domain. This commit adds it to some curve input nodes and the curve and mesh topology nodes. This makes debugging node setups with these nodes a bit faster and less frustrating.
2022-11-08Fix T102358: Sample curve node all curves factor mode incorrectHans Goudey
The "all curve" sampling is implemented as two functions internally. The first finds which curve each "global" sample should be on. Then the second is the regular evaluation and sampling in that curve. The first operations creates lengths, but they were processed as factors when passed to the second function.
2022-11-08Cleanup: formatChris Blackbourn
2022-11-08Merge branch 'blender-v3.4-release'Hans Goudey
2022-11-08Fix T102003: Spline parameter length wrong for NURBSHans Goudey
The node has always be a bit confusing for the NURBS case, since it uses the distance between control points since the evaluated/control point mapping isn't obvious, but it also went above 1, which wasn't correct. Instead, retrieve the total length from the point lengths calculated in the previous step. The results should be the same for other curve types.
2022-11-08Merge branch 'blender-v3.4-release'Sergey Sharybin
2022-11-08Fix deprecation warnings about printf() on macOSSergey Sharybin
The new Xcode 14.1 brings the new Apple Clang compiler which considers sprintf unsafe and geenrates deprecation warnings suggesting to sue snprintf instead. This only happens for C++ code by default, and C code can still use sprintf without any warning. This changes does the following: - Whenever is trivial replace sprintf() with BLI_snprintf. - For all other cases use the newly introduced BLI_sprintf which is a wrapper around sprintf() but without warning. There is a discouragement note in the BLI_sprintf comment to suggest use of BLI_snprintf when the size is known. Differential Revision: https://developer.blender.org/D16410
2022-11-07Merge branch 'blender-v3.4-release'Miguel Pozo
2022-11-07Fix T102324: reverse curve node breaks crazy space editingJacques Lucke
2022-11-06Merge branch 'blender-v3.4-release'Jacques Lucke
2022-11-06Fix T102144: missing validation of spline resolutionJacques Lucke
2022-11-06Geometry Nodes: fix missing curve cacheJacques Lucke
2022-11-06Cleanup: Nodes: Use const arguments, avoid recursive iterationHans Goudey
Use the node topology cache and avoid modifying the node tree in a non-threadsafe way to improve the predictability of using the helper function. Replaces the implementation from e0d40471364aafca967b6ebd52.
2022-11-05Cleanup: Remove unused node functionHans Goudey
2022-11-05Cleanup: Use Vector in group input/output node update functionsHans Goudey
Also reduce the scope of variables and use ListBase macros
2022-11-05Cleanup: Remove unnecessary node type registraction functionsHans Goudey
These functions provided little benefit compared to simply setting the function pointers directly.
2022-11-04Cleanup: Mesh: Remove redundant edge render flagHans Goudey
Currently there are both "EDGERENDER" and "EDGEDRAW" flags, which are almost always used together. Both are runtime data and not exposed to RNA, used to skip drawing some edges after the subdivision surface modifier. The render flag is a relic of the Blender internal renderer. This commit removes the render flag and replaces its uses with the draw flag.
2022-11-04Realtime Compositor: Implement static cache managerOmar Emara
This patch introduces the concept of a Cached Resource that can be cached across compositor evaluations as well as used by multiple operations in the same evaluation. Additionally, this patch implements a new structure for the realtime compositor, the Static Cache Manager, that manages all the cached resources and deletes them when they are no longer needed. This improves responsiveness while adjusting compositor node trees and also conserves memory usage. Differential Revision: https://developer.blender.org/D16357 Reviewed By: Clement Foucault
2022-11-02Refactor: Rename Object->imat to Object->world_to_objectSergey Sharybin
The goal is to improve clarity and readability, without introducing big design changes. Follows the recent obmat to object_to_world refactor: the similar naming is used, and it is a run-time only rename, meaning, there is no affect on .blend files. This patch does not touch the redundant inversions. Those can be removed in almost (if not all) cases, but it would be the best to do it as a separate change. Differential Revision: https://developer.blender.org/D16367
2022-11-02Geometry Nodes: Add index and value inputs to sample curve nodeHans Goudey
As described in T92474 and T91650, this patch adds two features to the sample curve node. First is an index input, to allow choosing the curve to sample for each point. Second is a custom field input, which is evaluated on the control points of the curve and then sampled like the other outputs. There is an "All Curves" option for the old behavior which takes the length of all curves into account. For invalid curve indices, the node outputs zeros (default values). Invalid lengths and factors are clamped. There have been various discussions about splitting the node up more, but this is an intuitive combination of options and will work well enough for current use cases. The node could still be generalized more in the future. Keep in mind that the source field is evaluated on curve control points, not the evaluated points used for sampling. This is necessary so that fields like "Index" work as expected. Differential Revision: https://developer.blender.org/D16147
2022-11-01Refactor: Rename Object->obmat to Object->object_to_worldSergey Sharybin
Motivation is to disambiguate on the naming level what the matrix actually means. It is very easy to understand the meaning backwards, especially since in Python the name goes the opposite way (it is called `world_matrix` in the Python API). It is important to disambiguate the naming without making developers to look into the comment in the header file (which is also not super clear either). Additionally, more clear naming facilitates the unit verification (or, in this case, space validation) when reading an expression. This patch calls the matrix `object_to_world` which makes it clear from the local code what is it exactly going on. This is only done on DNA level, and a lot of local variables still follow the old naming. A DNA rename is setup in a way that there is no change on the file level, so there should be no regressions at all. The possibility is to add `_matrix` or `_mat` suffix to the name to make it explicit that it is a matrix. Although, not sure if it really helps the readability, or is it something redundant. Differential Revision: https://developer.blender.org/D16328
2022-11-01Cleanup: spelling in commentsCampbell Barton
2022-10-31Geometry Nodes: Use attribute API in deform curves on surface nodeHans Goudey
Retrieve the surface UV coordinates with the attribute API instead of the helper function. This allows more flexibility of data types (and domains), which is helpful especially because geometry nodes can't write 2D vectors yet.
2022-10-20Buildfix for 078e034 missing includeJens Verwiebe
2022-10-20Fix T101215: Distribute Points in Volume node does not refresh on frame changeJacques Lucke
2022-10-20Realtime Compositor: Implement normalize nodeOmar Emara
This patch implements the normalize node for the realtime compositor. Differential Revision: https://developer.blender.org/D16279 Reviewed By: Clement Foucault
2022-10-20Realtime Compositor: Implement Tone Map nodeOmar Emara
This patch implements the tone map node for the realtime compositor based on the two papers: Reinhard, Erik, et al. "Photographic tone reproduction for digital images." Proceedings of the 29th annual conference on Computer graphics and interactive techniques. 2002. Reinhard, Erik, and Kate Devlin. "Dynamic range reduction inspired by photoreceptor physiology." IEEE transactions on visualization and computer graphics 11.1 (2005): 13-24. The original implementation should be revisited later due to apparent incompatibilities with the reference papers, which makes the operation less useful. Differential Revision: https://developer.blender.org/D16306 Reviewed By: Clement Foucault
2022-10-19Geometry Nodes: Use common utility for copying attribute dataHans Goudey
Attribute copying often uses identical logic for copying selected elements or copying with an index map. Instead of reimplementing this in each file, use the common implementation in the array_utils namespace. This makes the commonality more obvious, gives improved performance (this implementation is multithreaded), reduces binary size (I observed a 173KB reduction), and probably reduces compile time.
2022-10-19Cleanup: CMake include pathsCampbell Barton
Remove redundant separators & redundant references to parent paths.
2022-10-18Fix T101660: crash when trying to propagate string attributes in some nodesJacques Lucke
String attributes are intentionally not fully supported in geometry nodes yet because more design work is necessary to decide how they should behave. For now just disable handling string attributes to avoid crashes.
2022-10-18Fix: Sample nearest surface node crash with empty meshHans Goudey
2022-10-18Fix T101642: crash when deleting group output inside node groupJacques Lucke
2022-10-18Fix T101872: Curves sculpt deform node crash with changed curve countHans Goudey
There might be more or fewer curves in the input to the deform curves on surface node than the original, so the curve's surface UV coordinates need to be retrieved from the original curves.
2022-10-18Fix T101882: Division by zero in mesh topology nodesHans Goudey
A vertex might be connected to no edges or no faces. Most of these nodes worked fine in that case, but we might as well make that explicit and skip the sorting anyway.
2022-10-17Fix T101705: crash when connecting reroute to multi-input socketIliya Katueshenock
Differential Revision: https://developer.blender.org/D16203
2022-10-17Geometry Nodes: separate Instances from InstancesComponentJacques Lucke
This makes instance handling more consistent with all the other geometry component types. For example, `MeshComponent` contains a `Mesh *` and now `InstancesComponent` has a `Instances *`. Differential Revision: https://developer.blender.org/D16137
2022-10-14Fix: Muted curves connect to the Fac socketCharlie Jolly
Resolve by setting no_muted_links() on Factor sockets. Same issue as T101613 Reviewed By: HooglyBoogly Differential Revision: https://developer.blender.org/D16153
2022-10-13Realtime Compositor: Keep interpolation in Scale nodeOmar Emara
Currently, the scale node always changes the interpolation of its result to bilinear. This was done because the scale node does not have an interpolation option, unlike the Transform node, so a default of bilinear was assumed. This turned out to be problematic, because in the pixelation use cases, a nearest interpolation is typically preferred by the user. This patch changes the default interpolation of input nodes to bilinear, makes the scale node keep the interpolation of the input it receives, and makes the pixelate node changes the interpolation to nearest. In effect, for non-pixelation use cases, the default bilinear interpolation will be used, and for pixelation use cases, the nearest interpolation will be used unless explicitly specified using a node that sets the interpolation.
2022-10-13Cleanup: Use correct blenkernel namespace for mesh functionsHans Goudey
2022-10-12Nodes: Add "Legacy" to legacy node UI names, skip in searchHans Goudey
Currently there is no way to tell that these node types are deprecated in the UI. This commit adds "(Legacy)" to the end of the names. It also makes it simple to skip these in the various node searches more automatically than before. Fixes T101700 Differential Revision: https://developer.blender.org/D16223
2022-10-12Cleanup: use commented arguments for unused args in C++Campbell Barton
2022-10-12Cleanup: Convert two nodes files to C++Hans Goudey
2022-10-12Cleanup: Remove link drag search operations for socket templatesHans Goudey
Besides texture nodes, which aren't supported anyway, we don't have any builtin nodes that still use the socket template system, so this can be removed.
2022-10-12Nodes: Change Mix node link drag weightingCharlie Jolly
This lowers the search weight for color-specific mix functions on non-color sockets. Reported in blender.chat by simonthommes Differential Revision: https://developer.blender.org/D16228
2022-10-11Realtime Compositor: Implement variable size bokeh blurOmar Emara
This patch implements the variable size blur option in the Bokeh Blur node. The implementation is different from the CPU one in that it also takes the Bounding Box input into account, which is ignored for some reason for the CPU. Additionally, this implementation does not do the optimization where the search radius is limited relative to the maximum value in the size texture. That's because the cost of computing the maximum is not worth it for most use cases. The reference implementation does three unexpected things that are replicated here nonetheless. First, the center bokeh weight is always ignored and assumed to be 1. Second the size of the center pixel is taken into account. Third, a unidimensional distance is used instead of a 2D euclidean one. Those need to be considered independently. Differential Revision: https://developer.blender.org/D16185 Reviewed By: Clement Foucault
2022-10-11Realtime Compositor: Implement parallel reductionOmar Emara
This patch implements generic parallel reduction for the realtime compositor and implements the Levels operation as an example. This patch also introduces the notion of a "Compositor Algorithm", which is a reusable operation that can be used to construct other operations. Differential Revision: https://developer.blender.org/D16184 Reviewed By: Clement Foucault