Blender Git Commits

Blender Git "master" branch commits.

Page: 13 / 5574

December 15, 2021, 12:43 (GMT)
Cleanup: unused variable warning
December 15, 2021, 12:40 (GMT)
MetaBall: optimize memory allocation for meta-ball tessellation

Double the allocation size when the limit is reached instead of
increasing by a fixed number.

Also re-allocate to the exact size once complete instead of over
allocating. This gives a minor speedup in my tests ~19% faster
tessellation for ~1million faces.
December 15, 2021, 12:40 (GMT)
Fix meta-ball bound-box calculation reading past buffer bounds

This broke "test_undo.view3d_multi_mode_select" test in
"lib/tests/ui_simulate" and is likely exposed by recent changes to
bounding box calculation.

The missing check for DL_INDEX4 dates back to code from 2002 which
intended to check this but was checking for DL_INDEX3 twice
which got removed as part of a cleaned up.

This could be hidden from memory checking tools as meta-balls
over-allocate vertex arrays.
December 15, 2021, 10:51 (GMT)
Fix compile errors on windows.
December 15, 2021, 10:19 (GMT)
Cleanup: Use pixel in stead of texels in naming.
December 15, 2021, 10:09 (GMT)
Images: 1,2,3 channel support for transform function.

Added support for 1, 2, 3 float channel source images. Destination
images must still be 4 channels.
Revision 67b657f by Hans Goudey
December 15, 2021, 00:57 (GMT)
Fix T94082: Curve to point empty evaluated NURBS crash

This is basically the same as rBee4ed99866fbb7ab04, the fix is
simply to check if the spline has evaluated points when deciding
the offsets into the result points array.
December 14, 2021, 21:50 (GMT)
Fix T93949: Preview Image Error When No Screen

Fix an error if "File Preview Type" is "Auto" and there is no screen.

See D13574 for details.

Differential Revision: https://developer.blender.org/D13574

Reviewed by Julian Eisel
Revision 40aee0b by Julian Eisel
December 14, 2021, 19:57 (GMT)
Fix possible use-after-free on error handling during VR view drawing

Whenever an exception happens in VR session code, we cancel the entire
session. Alongside that, we removed the "surface" item used to draw into
an offscreen context. This would mess up the iterator of the surface
draw loop.
Similar to 7afd84df409a.
Revision 4cfa21f by Julian Eisel
December 14, 2021, 19:44 (GMT)
Fix null-pointer dereference on error handling during VR view drawing
Revision 7afd84d by Julian Eisel
December 14, 2021, 19:13 (GMT)
Fix possible use-after-free on error handling during VR view drawing

Whenever an exception happens in VR session code, we cancel the entire
session. Alongside that, we removed the "surface" item used to draw into
an offscreen context. But this may still be stored as active surface,
leading to a use-after-free when deactivating this active surface, for
example.
December 14, 2021, 19:01 (GMT)
Fix Cycles compilation with CUDA / Optix after recent Map Range additions.
December 14, 2021, 18:27 (GMT)
Nodes: Add vector support to Map Range node

This replaces lost functionality from the old GN Attribute Map Range node.
This also adds vector support to the shader version of the node.

Notes:
This breaks forward compatibility as this node now uses data storage.

Reviewed By: HooglyBoogly, brecht

Differential Revision: https://developer.blender.org/D12760
Revision 44232a2 by Hans Goudey
December 14, 2021, 18:16 (GMT)
Cleanup: Remove unused arguments
Revision d56bbfe by Hans Goudey
December 14, 2021, 17:19 (GMT)
Cleanup: Remove runtime uiBlock pointer from nodes

Code is simpler when the uiBlocks used during drawing are simply
stored in an array. Additionally, looping can be simpler when we use
an vector to hold a temporary copy of the tree's linked list of nodes.

This patch also slightly changes how uiBlocks are "named" in
`node_uiblocks_init`. Now it uses the node name instead of the
pointer, which is helpful so we rely less on the node's address.

Differential Revision: https://developer.blender.org/D13540
Revision fdd41ac by Hans Goudey
December 14, 2021, 16:56 (GMT)
Cleanup: Simplify node group input and output socket verification

This commit refactors the way the socket lists for group nodes,
and group input/output nodes are verified to match the group's
interface.

Previously the `bNodeSocket.new_sock` pointer was used to
temporarily mark the new sockets. This made the code confusing
and more complicated than necessary.

Now the old socket list is saved, and sockets are moved directly from
the old list to a new list if they match, or a new socket is created
directly in the new list.

This change is split from D13518, which aims to remove the `new_node`
and `new_sock` pointers. In the future this code might be removed
entirely in favor of using node socket declarations.

Differential Revision: https://developer.blender.org/D13543
December 14, 2021, 14:57 (GMT)
Geometry Nodes: support instance attributes when realizing instances

This patch refactors the instance-realization code and adds new functionality.
* Named and anonymous attributes are propagated from instances to the
realized geometry. If the same attribute exists on the geometry and on an
instance, the attribute on the geometry has precedence.
* The id attribute has special handling to avoid creating the same id on many
output points. This is necessary to make e.g. the Random Value node work
as expected afterwards.

Realizing instance attributes has an effect on existing files, especially due to the
id attribute. To avoid breaking existing files, the Realize Instances node now has
a legacy option that is enabled for all already existing Realize Instances nodes.
Removing this legacy behavior does affect some existing files (although not many).
We can decide whether it's worth to remove the old behavior as a separate step.

This refactor also improves performance when realizing instances. That is mainly
due to multi-threading. See D13446 to get the file used for benchmarking. The
curve code is not as optimized as it could be yet. That's mainly because the storage
for these attributes might change soonish and it wasn't worth optimizing for the
current storage format right now.

```
1,000,000 x mesh vertex: 530 ms -> 130 ms
1,000,000 x simple cube: 1290 ms -> 190 ms
1,000,000 x point: 1000 ms -> 150 ms
1,000,000 x curve spiral: 1740 ms -> 330 ms
1,000,000 x curve line: 1110 ms -> 210 ms
10,000 x subdivided cylinder: 170 ms -> 40 ms
10 x subdivided spiral: 180 ms -> 180 ms
```

Differential Revision: https://developer.blender.org/D13446
December 14, 2021, 14:40 (GMT)
Geometry Nodes: simplify using selection when evaluating fields

We often had to use two `FieldEvaluator` instances to first evaluate
the selection and then the remaining fields. Now both can be done
with a single `FieldEvaluator`. This results in less boilerplate code in
many cases.

Performance is not affected by this change. In a separate patch we
could improve performance by reusing evaluated sub-fields that are
used by the selection and the other fields.

Differential Revision: https://developer.blender.org/D13571
Revision b44a500 by Hans Goudey
December 14, 2021, 14:30 (GMT)
Fix T93920: Wrong field inferencing state with unavailable socket

This commit ignores unavailable sockets in one more place, to fix the
case in T93920.

Differential Revision: https://developer.blender.org/D13562
Revision b5c1828 by Julian Eisel
December 14, 2021, 14:23 (GMT)
Fix T93649: Blender freezes when saving with active VR session

Dead-lock when VR viewport drawing and depsgraph updates would fight for
the draw-manager GL lock. This didn't usually cause issues because the
depsgraph would be evaluated at this point already, except in rare
exceptions like after file writing.

Fix this by ensuring the XR surface gets its depsgraph updated after
handling notifiers, which is where regular windows also do the depsgraph
updating.
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021