119865 Commits

Author SHA1 Message Date
Clément Foucault
57a20b6d52 DRW: Add missing depth_write to certain shader create info
These are required by the Metal backend.
2022-11-27 22:58:10 +01:00
Richard Antalik
5b4efaeeb3 Merge branch 'blender-v3.4-release' 2022-11-27 21:42:37 +01:00
Richard Antalik
3a65d2f591 Fix T101211: Image jitters when scaling by large values
Issue was caused by imprecise math due to using float numbers.
Use double instead.

No negative performance impact was observed.

Reviewed By: jbakker

Differential Revision: https://developer.blender.org/D16517
2022-11-27 21:33:05 +01:00
Richard Antalik
5a504a0d9d Fix T102663: Meta strips from older versions are broken
Meta strip range was adjusted in versioning because of previous issues
by function `version_fix_seq_meta_range`. After `speed_factor` property
was added, this changed how function works and result was incorrect
function due to uninitialized property value.

Running `version_fix_seq_meta_range` after `seq_speed_factor_set` fixes
this issue.

Reviewed By: sergey

Differential Revision: https://developer.blender.org/D16606
2022-11-27 21:31:38 +01:00
Miguel Pozo
ea384fc096 Merge branch 'blender-v3.4-release' 2022-11-27 14:41:36 +01:00
Miguel Pozo
6cd441fdac Draw: GPU Subdivision: Add missing case in get_shader_code 2022-11-27 14:40:47 +01:00
Miguel Pozo
41733a9c08 Fix T102773 & T102777: Regressions in GPU Subdivision
Introduced in D16420.
SHADER_BUFFER_TRIS and SHADER_BUFFER_TRIS_MULTIPLE_MATERIALS flags were accidentally swapped.
2022-11-27 14:40:00 +01:00
Philipp Oeser
3ccf4a3944 Merge branch 'blender-v3.4-release' 2022-11-27 12:41:42 +01:00
Philipp Oeser
b0bcdcdbef Fix: missing greasepencil hook modifier relationship lines
Overlay relationship lines were missing between the object having the
modifier and the target object.

To make this consistent with other objects types, now draw relationship
lines for greasepencil and hooks now, too.

Spotted while looking into T102741.

Maniphest Tasks: T102741

Differential Revision: https://developer.blender.org/D16609
2022-11-27 12:24:48 +01:00
Philipp Oeser
179008f57a Fix T102685: Grease Pencil brush cursors missing on file open
Brush cursors were missing when opening a file saved in sculpt/vertex-/
weightpaint mode.

Since we dont do a full modeswitch on file load in `ED_editors_init` for
grease pencil since rBde994d6b7b1c, we were missing the brush cursor
toggling [`ED_gpencil_toggle_brush_cursor`] normally done in
`ED_gpencil_setup_modes`.

This is now explicitly added for any greasepencil paintmode (in case
object is active).

Maniphest Tasks: T102685

Differential Revision: https://developer.blender.org/D16603
2022-11-27 12:23:01 +01:00
Philipp Oeser
c935a06edb Cleanup: correct comments in ED_editors_init
These comments were from rBcc7460eaa491 / rBde994d6b7b1c /
rB7037ff920447 but ended up in a confusing state.
Moved into the right places and reworded appropriately.

Spotted while looking into T102685.

Maniphest Tasks: T102685

Differential Revision: https://developer.blender.org/D16601
2022-11-27 12:22:42 +01:00
Philipp Oeser
b0810f788c Fix T102650: Wrong cursor in greasepencil fill operation
Caused by {rBbf8507414889}

Above comit set the wrong cursors (WM_CURSOR_DEFAULT).
When releasing MMB, we need to return to WM_CURSOR_PAINT_BRUSH.
When exiting, we need to return to WM_CURSOR_DOT (since this is the
default cursor for the tool, see `_defs_gpencil_paint` >
`generate_from_brushes`)

Maniphest Tasks: T102650

Differential Revision: https://developer.blender.org/D16591
2022-11-27 12:21:22 +01:00
Philipp Oeser
ee56c46c15 Fix: greasepencil selection mask picking points not working
When in greasepencil sculpt-/vertexpaint mode and using selection
masking, picking points wasnt working correctly.

So regular gpencil.select (without modifier keys) was not enabled for the
keymap. This only really makes sense for RCS (right click select) atm
(and not using RC fallback tools - which I dont think are present in
these modes anyways). With RCS, this can be supported and afaict, this
does not cause conflicts.

NOTE: prior to D16576, one could use the ALT modifier key (this
combination was actually in the keymap) -- but it should select the
entire stroke, which is handled in D16576.

Differential Revision: https://developer.blender.org/D16577
2022-11-27 12:21:02 +01:00
Philipp Oeser
5d481d9e55 Fix: greasepencil selection of entire_strokes not working
Caused by rB85f90ed6fd88.

Above commit made sure whole strokes are selected when the
GP_SELECTMODE_STROKE is used in different modes, but ignored the fact
that this can also already be set by the entire_strokes select operator
property.

This is now corrected.

Differential Revision: https://developer.blender.org/D16576
2022-11-27 12:20:06 +01:00
Iliya Katueshenock
9fa4ceb340 Geometry Nodes: Change Collection Info output socket name to Instances
As described in T101948, this commit changes socket name to be more
consistent with other nodes that generate instances output.

Differential Revision: https://developer.blender.org/D16394
2022-11-26 18:11:01 -06:00
Iliya Katueshenock
42485b01d2 Geometry Nodes: Rename Transform node to Transform Geometry
Change name to make navigation easier for beginner users. This should
more clearly hint at the use of this node to change the full geometry,
and not work with fields, and makes the name more consistent.

Differential Revision: https://developer.blender.org/D16396
2022-11-26 18:05:41 -06:00
Iliya Katueshenock
beeeb6da30 Cleanup: Integer types, references in geometry node image texture node
While implementing T102289, I noticed that this node has
several solutions that are different from other, newer nodes.
 - Explicitly set default values
 - Use references
 - Reduce the size of the node settings structure

Differential Revision: https://developer.blender.org/D16548
2022-11-26 18:00:47 -06:00
Hans Goudey
3f5dfbf681 Geometry Nodes: Modify existing mesh in split edges node
Instead of creating a new mesh from scratch, modify an existing mesh.
This allows us to keep derived caches for triangulation and bounds
alive more easily, and allows keeping materials and non-generic
attributes like vertex groups alive on the mesh.

It also has other performance benefits, since face and face corner
attributes aren't affected at all, and because of reduced overhead
from not allocating a new mesh.

Updating edge attributes is a bit more complicated now, since we
have to completely replace the arrays but keep the existing attribute
IDs around. The new mesh update tag is also slightly too specific IMO.
But I think both of those things will improve in the future because
of existing plans for further refactoring these areas:
- New attribute storage that gives pointer stability
- Further use and granularity of mesh update tagging that will
  make the correct API more clear

Fixes T102711

Differential Revision: https://developer.blender.org/D16615
2022-11-26 17:54:05 -06:00
Hans Goudey
3a41e0f611 Tests: Automated geometry nodes benchmark
Add a script for a very simple object evaluation benchmark.
There could be more advanced ways of measuring the time
per-node or per modifier, but this just loads the file, tags
the active object for a reevaluation, and times how long
that takes.

Differential Revision: https://developer.blender.org/D16604
2022-11-26 17:15:55 -06:00
Ray Molenkamp
828525b268 Fix: MSVC build error without TBB
windows.h once more providing min/max macro's when you least want them.
2022-11-26 11:44:08 -07:00
Hans Goudey
4ecc7cf14a Cleanup: Move interface_intern.hh
The entire interface directory is now compiled as C++ files.
2022-11-26 10:12:58 -06:00
Hans Goudey
e47c75aa6e Cleanup: Move interface eyedroppers directory to C++ 2022-11-26 10:12:58 -06:00
Hans Goudey
136ea84d9a Cleanup: Move interface_handlers.c to C++ 2022-11-26 10:12:58 -06:00
Hans Goudey
162f0dcb2f Cleanup: Move six more interface files to C++ 2022-11-26 10:12:58 -06:00
Antonio Vazquez
1aff91b1a7 GPencil: Add Vertex Opacity Overlay parameter in Sculpt
This option was missing in overlay panel.
2022-11-26 15:39:59 +01:00
Jacques Lucke
b43bdd8ba2 Fix T102751: missing tree update with muted nodes
This was accidentally caused by removing too much code in
{rBb4c3ea264439158df70e837e20f8dd9ec548de2d}.
2022-11-26 13:46:39 +01:00
Jacques Lucke
86ade3df56 Nodes: move node registration to nodes module
The main goal here is to move towards more self contained node
definitions. Previously, one would have to change `blenkernel` to
add a new node which is not necessary anymore. There is no need
for all these register functions to "leak out" of the nodes module.

Differential Revision: https://developer.blender.org/D16612
2022-11-26 13:20:18 +01:00
Aaron Carlisle
8d269a2488 PyDocs: Fix incorrect data type of bmesh.types.BMFaceSeq.new
The API documentation of [[ https://docs.blender.org/api/current/bmesh.types.html?highlight=faces#bmesh.types.BMFaceSeq.new | bmesh.types.BMFaceSeq.new ]] indicates that the argument is only `BMVert`.
But the correct one is sequence of `BMVert`.
This patch fixes this mismatch.

Contributed by @Nutti

Differential Revision: https://developer.blender.org/D15668
2022-11-25 19:55:04 -05:00
Hans Goudey
ed6e1381dc Cleanup: Avoid using macros to refer to theme global variables
Prefer slightly more verbose code to the use of macros where
they aren't really necessary and just add indirection.
2022-11-25 17:11:44 -06:00
Hans Goudey
248ee6270b Cleanup: Remove unnecessary includes 2022-11-25 17:10:28 -06:00
Hans Goudey
afd16c487d Cleanup: Move four interface files to C++ 2022-11-25 17:09:47 -06:00
Hans Goudey
4029cdee7b Merge branch 'blender-v3.4-release' 2022-11-25 15:28:48 -06:00
Hans Goudey
680a0fb23b Fix T102752: Missing default radius when joining point clouds
Point clouds are meant to use a default radius of 0.01 when there is no
radius attribute. The curve to points node can create curves without a
radius attribute. This affects joining and the realize instances node.

Similar to 30f244d96f16142d4.
2022-11-25 15:25:37 -06:00
Hans Goudey
ed8fee16ac Fix: Hide "Squeeze Value" node from node search
Based on discussion in D10891, this node isn't meant to be exposed and
may be removed in the future. The fact that it was exposed in search
menus was a mistake from the implementation of link-drag-search
and bdb57541475f20ccc4.

I explicitly removed the link drag search implementation, and added
(Legacy) to the node name which hides it from the add node search.
2022-11-25 14:59:27 -06:00
Hans Goudey
4a0e19e608 Cleanup: Group deprecated mesh DNA fields, improve comments 2022-11-25 12:54:22 -06:00
Brecht Van Lommel
5ca6965273 Merge branch 'blender-v3.4-release' 2022-11-25 18:54:49 +01:00
Brecht Van Lommel
0147e09e0b Python Module: add project description for pypi 2022-11-25 18:54:00 +01:00
Nikita Sirgienko
f07b09da27 Cycles: Improve oneAPI backend support for non-Intel platforms 2022-11-25 17:46:59 +01:00
Sergey Sharybin
f83aa1ae08 Fix T102764: Slow change of active material slot
The issue is caused by the combination of the following factors:

- There is a driver from custom property to the subdivision surface
  modifier.
- Active material index tags the ID for the copy-on-write update.

Dependency graph currently does not fully distinguish between
copy-on-write tag and properties-update tag, so the copy-on-write tag
makes the dependency graph believe that it is property which actually
affects evaluation has been changed.

The simple solution is to treat the active material slot index as an
interface data which does not need to trigger copy-on-write tag.

The possible downside of this solution is that if someone has a driver
from this property the driver will stop working. Whether there is such
a real-life setup or not is not clear. Is not something advisable to do
anyway.

Possible alternative would be to introduce more granularity into the
way how property tagging is done. This is something that would be nice
to implement eventually, but it is a much bigger refactor.

Differential Revision: https://developer.blender.org/D16613
2022-11-25 17:44:54 +01:00
Yiming Wu
d1c21d5673 Fix T102470: Make material LineArt properties animatable.
MaterialLineArt didn't have a path func, now corrected.
2022-11-25 23:18:41 +08:00
Yiming Wu
b5ca43b2a0 Fix T102470: Make material LineArt properties animatable.
MaterialLineArt didn't have a path func, now corrected.
2022-11-25 23:15:39 +08:00
Sergey Sharybin
994e3c6ac5 Clarify depsgraph API usage in the libraries code
Basically copy the information from the commit message of the
03e2f11d48dc directly to the code.

This makes the information easier to find when working on the
code.
2022-11-25 15:25:55 +01:00
Yiming Wu
dad0f37c1e Fix T101824: Line art flickers when light object has scaling.
Line art doesn't expect light or camera objects to have scaling.
2022-11-25 22:21:26 +08:00
Yiming Wu
118afe1de3 Fix T101824: Line art flickers when light object has scaling.
Line art doesn't expect light or camera objects to have scaling.
2022-11-25 22:00:21 +08:00
Sergey Sharybin
ae6e35279f Clarify comment about ID_RECALC_COPY_ON_WRITE
The copy-on-write is really an implementation detail of the
dependency graph. While there are still cases where there is
no better tag to be used, the ID_RECALC_COPY_ON_WRITE should
not be used in combination with a dedicated tag.

For example if location of object changes the proper tag is
`ID_RECALC_TRANSFORM`. Tagging with `ID_RECALC_TRANSFORM |
ID_RECALC_COPY_ON_WRITE` will seemingly work, but this is
not an intended usage.
2022-11-25 14:55:50 +01:00
Kévin Dietrich
043673ca70 Cleanup: Alembic, deduplicate CacheObjectPath creation
No functionnal changes.
2022-11-25 14:37:48 +01:00
Kévin Dietrich
3cf803cf3c Cleanup: Alembic, use MEM_cnew
Avoids extra cast. No functionnal change.
2022-11-25 14:27:18 +01:00
Miguel Pozo
6422f75088 Merge branch 'blender-v3.4-release' 2022-11-25 12:44:05 +01:00
Miguel Pozo
b918c079da Fix T101402: EEVEE: Wrong Volume transforms
Ensure VolumeUniformPool uses is always incremented when retrieving a buffer in alloc().
Otherwise the same buffer will be retrieved for more than one object when incrementing the pool size.

Reviewed By: fclem

Maniphest Tasks: T101402

Differential Revision: https://developer.blender.org/D16607
2022-11-25 12:43:30 +01:00
Omar Emara
6bc3311410 Fix: Missing node warning when compositor is enabled
If the compositor is enabled or disabled, the node warnings for
unsupported nodes is not updated because of a missing redraw. This patch
adds that missing redraw in order to make the change immediate.
2022-11-25 13:19:13 +02:00