Blender Git Commits

Blender Git "master" branch commits.

Page: 23 / 5574

Revision c3c69fe by Hans Goudey
December 6, 2021, 18:49 (GMT)
Cleanup: Fix warnings about copied Map loop variables

The `Map::items()` iterator does not return references.
Revision 86d520f by Hans Goudey
December 6, 2021, 18:47 (GMT)
Fix: Attempt to fix build error on macOS
December 6, 2021, 18:40 (GMT)
Nodes: Add function to set compact socket flag for vectors

This flag is currently only used for vector sockets
so the function is limited to the vector builder.

The flag is only used by two shader nodes at the moment
and this is needed to port them over to the new socket declaration API.

Reviewed By: JacquesLucke

Differential Revision: https://developer.blender.org/D13490
December 6, 2021, 18:13 (GMT)
Geometry Nodes: reduce code duplication with new GeometyrFieldInput

Most of our field inputs are currently specific to geometry. This patch introduces
a new `GeometryFieldInput` that reduces the overhead of adding new geometry
field input.

Differential Revision: https://developer.blender.org/D13489
December 6, 2021, 17:58 (GMT)
Geometry Nodes: 4 Field Inputs for Mesh Topology Data

Creates 4 new nodes which provide topology information
for the mesh. Values are interpolated from the primary
domain in each case using basic attribute interpolation.

Vertex Neighbors
- Vertex Count
- Face Count
Face Neighbors
- Vertex Count
- Neighboring Face Count
Edge Vertices
- Vertex Index 1
- Vertex Index 2
- Position 1
- Position 2
Face Area
- Face Area

Differential Revision: https://developer.blender.org/D13343
Revision ee4ed99 by Hans Goudey
December 6, 2021, 17:19 (GMT)
Fix T93521: Single point NURBS crash in resample node

The resample node didn't handle the case of when a spline didn't have
any evaluated points. For poly and Bezier splines we should never hit
this case, but it is expected when the number of NURBS control points
is smaller than its order, so we have to handle the case here.

It's not that obvious what to do in this case, there are a few options:
- Remove the bad splines from the result
- Generate empty splines for those inputs
- Skip resampling the bad splines, copy them to the result
- Arbitrarily generate single point splines

I chose option three, just skipping the "bad" splines. Since the node
already has a selection input, this can be described by just extending
that. "Splines with no evaluated points are implicitly deselected."
The first option would probably be valid too though.

Differential Revision: https://developer.blender.org/D13434
December 6, 2021, 16:59 (GMT)
Nodes: Add Shader Socket to new decleration API

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
December 6, 2021, 16:47 (GMT)
Shader Nodes: Unity Build

- Create a new `bf_nodes_shader` library
- Enable unity builds for `bf_nodes_shader`, gives abount a 2.7x speed up for compile times

Reviewed By: JacquesLucke

Differential Revision: https://developer.blender.org/D13484
December 6, 2021, 16:42 (GMT)
Asset Indexer: use fixed-length string for ID code

Use fixed-length string to convert `char[2]` to `std::string`. Otherwise
`strlen()` is called, which is problematic as the `char[2]` is not
zero-terminated.
December 6, 2021, 16:42 (GMT)
Disable asset indexing in the Asset List

Asset indexing should be disabled, but this was overlooked in the
asset list (used for the pose library in the 3D View).
December 6, 2021, 16:31 (GMT)
Cleanup: remove unnecessary extern template implementations

This technique isn't really necessary anymore, because unity builds
avoid instantiating the same template too many times already.
December 6, 2021, 16:01 (GMT)
VSE: Fix strip with mask modifier not blending

Set `ibuf->planes` to `R_IMF_PLANES_RGBA` because mask modifier adds
transparent areas to image.
December 6, 2021, 16:01 (GMT)
Fix T93314: Thumbnails not drawn with default scale

Decrease threshold for drawing thumbnails.

This was unintended change in daaa43232d34 that was overlooked.
December 6, 2021, 15:46 (GMT)
cmake: fix linking with WITH_X11_XF86VMODE and bfd

Fix typos in the variables of the Xxf86vm libray to fix link failure
with bfd. These variables are defined in platform_unix.cmake.

Reviewed By: zeddb

Differential Revision: https://developer.blender.org/D12911
December 6, 2021, 14:50 (GMT)
Fix T93707: Dragging the tweaked NLA strip causes crash

Earlier code assumed that the active strip was on the active track. This
commit detects when this assumption doesn't hold, and adds a more thorough
search of the active strip.
December 6, 2021, 14:20 (GMT)
Fix T93611: Curve modifier crash in editmode in certain situations

Caused by {rB3b6ee8cee708}

Above commit was trying to get the vertexgroup from the mesh that is
passed into `deformVertsEM` (but that can be NULL).
When can it be NULL, when is is non-NULL?
`editbmesh_calc_modifiers` only passes in a non-NULL mesh to
`deformVertsEM` under certain conditions:
- a non-deform-only modifier is handled currently
- a non-deform-only modifier preceeds the current modifier
- a deform-only modifier preceeds the current modifier (and the current
one depends on normals)

So the passed-in mesh cannot be relied on, now get the vertex group from
the context object data (like it was before the culprit commit).

Related commit: rB8f22feefbc20

Maniphest Tasks: T93611

Differential Revision: https://developer.blender.org/D13487
December 6, 2021, 10:29 (GMT)
Cleanup: remove some temp dev asserts in new link/append code.

No longer needed now that all code uses that new
BKE_blendfile_link_append module, and that instantiation code in
BLO_readfile has been removed.
December 6, 2021, 02:40 (GMT)
Fix T93732: Snap Cursor not working after changing Add Object settings

`g_data_intern.state_default.gzgrp_type` is a very specific member and
cannot be set to default.
December 6, 2021, 02:40 (GMT)
Fix T93388: dropping object on grid in orthogonal view misses the floor plane

`ED_view3d_win_to_3d_on_plane` does not use the `clip_start` and
`clip_end` values of the scene, so the `do_clip` option can be misleading
especially in the orthographic view where the `clip_start` is negative.

For now, don't use the `do_clip` option in orthographic view.
December 5, 2021, 22:47 (GMT)
Shader Nodes: Declare nodes in their own namespace

Follow up on rB1df8abff257030ba79bc23dc321f35494f4d91c5

This puts all static functions in geometry node files into a new
namespace. This allows using unity build which can improve
compile times significantly

- The namespace name is derived from the file name.
That makes it possible to write some tooling that checks the names later on.
The filename extension (cc) is added to the namespace name as well.
This also possibly simplifies tooling but also makes it more obvious that this namespace is specific to a file.
- In the register function of every node, I added a namespace alias namespace `file_ns = blender::nodes::node_shader_*_cc`;.
This avoids some duplication of the file name and may also simplify tooling, because this line is easy to detect.
The name `file_ns` stands for "file namespace" and also indicates that this namespace corresponds to the current file.

In the future some nodes will be split up to separate files and given their own namespace
This will allow function names to be simplified similar to rBfab39440e94

Reviewed By: HooglyBoogly

Differential Revision: https://developer.blender.org/D13480
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021