WIP: Pass on color_attribute metadata through instancing, only for mesh #107066

Draft
Martijn Versteegh wants to merge 5 commits from Baardaap/blender:pass_active_color_to_instances into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.

Since color attributes don't use the CustomData active/render/clone index system
anymore the active status is no longer embedded in the CustomData itself.
In 3.4 and earlier if you use an Instance on Points node to instance mesh data
on the vertices of a base mesh and then realize the instances the first color attribute
in the resulting mesh (which can be inherited from the base mesh or the instances)
gets set as the active color attribute. This is useful because it allows rendering
pointcloud data in a fast way in solid mode (see #106563).

However with the named system this no longer works and the resulting mesh after realize
does not have an active color attribute (even though the attribute data itself is inherited just fine)

Since color attributes don't use the CustomData active/render/clone index system anymore the active status is no longer embedded in the CustomData itself. In 3.4 and earlier if you use an `Instance on Points` node to instance mesh data on the vertices of a base mesh and then realize the instances the first color attribute in the resulting mesh (which can be inherited from the base mesh or the instances) gets set as the *active* color attribute. This is useful because it allows rendering pointcloud data in a fast way in solid mode (see https://projects.blender.org/blender/blender/issues/106563). However with the named system this no longer works and the resulting mesh after realize does not have an *active* color attribute (even though the attribute data itself is inherited just fine)
Author
Member

This patch shows one approach.

It stores the active/default color attribute from the instancer mesh on the Instances level and then uses that to set the active/default in the resulting mesh. If the instancer mesh does not have an active/default color attribute it uses the first one it encounters in the list of instanced meshes.

Questions/doubts I have:

  • I used std::string, but maybe this is overkill? Could probably just be a char * referencing the base mesh? I guess the base mesh will always stay alive at least up till the 'realize instances' node?
  • I now have to include "DNA_mesh_types.h" in node_geo_instance_on_points.cc just to get at those strings. I don't really like it.

Other possibilities:

Another approach would be to just check if there are color attributes present on the resulting mesh after a realize instances just make the first one active+default. Slightly less control, but maybe easier to implement and probably more or less equivalent to what happened in 3.4.

Yet another approach would be to build a full system of priorities and collect all this metadata in the gather phase and then use the priorities to pick the best option. I'd imagine the instancer mesh to have the highest priority. Direct mesh instances a lower one and instances in instances an even lower one. That might be slightly better than what I do in this patch (just pick the first I encounter in the list of instanced meshes) at the cost of considreably more complexity.

edit:
Another approach would be to leave the strings alone completely and if a mesh has no active/default set just always use the first one as active/default. That would have the added benefit of fixing #107206

  • It might be nice to also have this active/default metadata on other objects (PointCloud? Curves?)
  • Eventually we want to get rid of the active/render/clone layer indices in CustomData I guess. Because that would make CD layers implicitly shareable between meshes with different active layers. Having these be name based is (I think) more robust than the constant jugging of indices anyway.

With these 2 possible future developments in mind it might be better to eventually store this metadata in some sort of easier to handle container then as bare char * on the object data. Maybe a key-value based system?

This patch shows one approach. It stores the active/default color attribute from the instancer mesh on the Instances level and then uses that to set the active/default in the resulting mesh. If the instancer mesh does not have an active/default color attribute it uses the first one it encounters in the list of instanced meshes. Questions/doubts I have: - I used std::string, but maybe this is overkill? Could probably just be a char * referencing the base mesh? I guess the base mesh will always stay alive at least up till the 'realize instances' node? - I now have to include "DNA_mesh_types.h" in node_geo_instance_on_points.cc just to get at those strings. I don't really like it. Other possibilities: --------------------------------- Another approach would be to just check if there are color attributes present on the resulting mesh after a realize instances just make the first one active+default. Slightly less control, but maybe easier to implement and probably more or less equivalent to what happened in 3.4. Yet another approach would be to build a full system of priorities and collect all this metadata in the gather phase and then use the priorities to pick the best option. I'd imagine the instancer mesh to have the highest priority. Direct mesh instances a lower one and instances in instances an even lower one. That might be slightly better than what I do in this patch (just pick the first I encounter in the list of instanced meshes) at the cost of considreably more complexity. edit: Another approach would be to leave the strings alone completely and if a mesh has no active/default set just always use the first one as active/default. That would have the added benefit of fixing #107206 Related thoughts ---------------------------- - It might be nice to also have this active/default metadata on other objects (PointCloud? Curves?) - Eventually we want to get rid of the active/render/clone layer indices in CustomData I guess. Because that would make CD layers implicitly shareable between meshes with different active layers. Having these be name based is (I think) more robust than the constant jugging of indices anyway. With these 2 possible future developments in mind it might be better to eventually store this metadata in some sort of easier to handle container then as bare `char *` on the object data. Maybe a key-value based system?
Martijn Versteegh requested review from Hans Goudey 2023-04-18 12:16:58 +02:00
Hans Goudey reviewed 2023-04-18 20:12:10 +02:00
@ -215,2 +217,4 @@
params,
attributes_to_propagate);
if (type == GEO_COMPONENT_TYPE_MESH) {
const Mesh *src_mesh = ((MeshComponent *)geometry_set.get_component_for_read(type))->get_for_read();
Member

geometry_set.get_mesh_for_read() is a simpler way of writing this.

`geometry_set.get_mesh_for_read()` is a simpler way of writing this.
Iliya Katushenock added this to the Nodes & Physics project 2023-05-15 12:11:48 +02:00
Iliya Katushenock added the
Interest
Geometry Nodes
Interest
Modeling
labels 2023-05-15 12:11:56 +02:00
Martijn Versteegh changed target branch from main to blender-v3.6-release 2023-05-27 00:16:47 +02:00
Martijn Versteegh added 294 commits 2023-05-29 11:28:35 +02:00
Release cycle: Bcon1 for Blender 4.0, alpha.
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
7be3a0a727
Revert "Release cycle: 3.6 enters beta, Bcon3."
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
feaeb7e6ad
This reverts commit 2dd0a08aff.
Fix warning in USD curves exporter
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
df48490db2
Use timecode.GetValue() to fix warning about passing correct 'double' type to 'WM_reportf'

Co-authored-by: DESKTOP-ON14TH5\Sonny Campbell <sonny.campbell@unity3d.com>
Pull Request: #108008
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
aa2eb422a7
Cleanup: Add enum type for drag data type definitions
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ac6af0be7b
Adds type safety and enables compiler features like warnings on missing
enumerator in switches.
The usage of the lib pointer was cryptic to say the least, it was
essentialy used to allow or not local IDs results in the mapping
old_id_pointer -> new_id_pointer lookup result.

Now:
- Explicitely pass a boolean to allow or not local ID as result in
  lower-level code.
- Pass the 'self ID' pointer instead of its library to the whole
  liblinking code (that was already the case in a few places).

Note that naming of the 'self id' pointer is currently very inconsistent
throughout the readfile liblink code, this will have to be cleaned up in
a separate step later. For now, `self_id` has been chosen for new code
as it matches the terminology in lib_query code.

The later change can also allow finer handling of lookup on undo, based
on how it was re-read (or not), should the need for this arise.
Fix/Update the 'search previous startup data' versioning logic.
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
086dada878
`PREFERENCES_OT_copy_prev` handling of versionning was for older release
cycles type (pre-3.0), now that we are in 4.0, we can use a simpler
logic: Just look for startup data from this major release cycle (i.e.
4.x currently) and the previous one (i.e. all 3.x releases).

Fixes the 're-use previous settings' option not showing when first
starting 4.0 build.
Workbench Next: Volumes: Don't draw on top of "in front" objects
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
430b2716c8
The UI list and asset view preview size calculations were out of sync,
so the UI list made more space than the preview actually used. Making
them match made the previews quite large though, so compensate that by
scaling the layout down.
Remove the related TODO comment, since this uses a common function for
getting the preview size now.

Before/after:
![Screenshot from 2023-05-17 17-33-19.png](/attachments/0ac713a3-12d9-41b6-ab50-85790da765a9) ![Screenshot from 2023-05-17 17-42-15.png](/attachments/0def65b5-6b16-4431-9a9e-592ed3d9675f)

Pull Request: #108017
The highlighting of preview tiles would be too strong in asset view
templates and grid views (only used in branches so far). This is because
two buttons are overlayed on top of each other, and both would
highlight. Ensure the overlayed preview tile button doesn't use any
highlighting.
The text under previews would be quite close to the preview, so that
there was more space below it than above. Center it vertically in the
available space now. Also, the horizontal padding was only applied to
the right side of the text rectangle, meaning horizontally centered text
would be too far left. Apply the padding equally, this doesn't affect
available space for the text too much.

See #108018 for before/after pictures.

Pull Request: #108018
UI: Use fixed width for grid view items, don't stretch to full width
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
39a5025032
No user visible changes expected (since grid-views are only used in
branches right now).

This just makes grid view UIs feel more "stable" while scaling areas,
since things don't move around as much anymore. The tradeoff is that
there may be some empty space on the right, if there's not enough space
for a full column. This is how the file browser already behaves, and can
be mitigated by a smaller preview size.
Core: Write mesh and movieclip with new format
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1b63a290c6
Finish the transition from #95966 and fe38715600 by
writing files with the new format for meshes and some movie clip fields.
This removes overhead when saving files, and makes meshes saved in
files smaller (a file with a 1 million face grid changed from 32 to 28 MB).

3.6 can still read files saved with this format, but older versions will
crash. Older files are automatically converted by versioning code when
opened.

This also allows removing all the code that converts from the new
format to the legacy format, previously used when saving files.

Pull Request: #108015
Mesh: Remove sculpt vertex colors from RNA API
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
6805657a39
Added in f7bbc7cdbb, these were never exposed in an
official release, and were eventually replaced by the attribute system.

Ref #100153
Mesh: Remove deprecated face/vert custom data API
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d41021a7d4
Remove six collection properties from Mesh that are redundant
with the attribute API which has a nicer API and more features.
- `vertex_layers_float`
- `vertex_layers_int`
- `vertex_layers_string`
- `polygon_layers_float`
- `polygon_layers_int`
- `polygon_layers_string`
Cleanup: Remove redundant writing of old face set type
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9bdfb15e98
Face sets are now always saved with the generic float type
Cleanup: Add function to check if named custom data layer exists
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f106579a9a
This simplifies #108014 and is consistent with the existing function
for face corners, `sample_corner_normals`.
Cleanup: Add version after linking function for 4.0 series
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
180c72a708
Merge branch 'blender-v3.6-release' into main
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
4368b0e296
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9fbadc98cd
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
07058765b9
Refactor ImBuf buffer access
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
406cfd214a
The goal is to make it more explicit and centralized operation to
assign and steal buffer data, with proper ownership tracking.

The buffers and ownership flags are wrapped into their dedicated
structures now.

There should be no functional changes currently, it is a preparation
for allowing implicit sharing of the ImBuf buffers. Additionally, in
the future it is possible to more buffer-specific information (such
as color space) next to the buffer data itself. It is also possible
to clean up the allocation flags (IB_rect, ...) to give them more
clear naming and not have stored in the ImBuf->flags as they are only
needed for allocation.

The most dangerous part of this change is the change of byte buffer
data from `int*` to `uint8_t*`. In a lot of cases the byte buffer was
cast to `uchar*`, so those casts are now gone. But some code is
operating on `int*` so now there are casts in there. In practice this
should be fine, since we only support 64bit platforms, so allocations
are aligned. The real things to watch out for here is the fact that
allocation and offsetting from the byte buffer now need an explicit 4
channel multiplier.

Once everything is C++ it will be possible to simplify public
functions even further.

Pull Request: #107609
Before 9f78530d80, the -1 coarse_edge_index values in the
foreach_edge calls would return false in BLI_BITMAP_TEST_BOOL,
which made them look like loose edges. BitSpan doesn't have this
problem, so the return for negative indices must be explicit.
Nodes: Remove deprecated useless width_hidden property
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
30a20b4def
See 7b82d8f029
Geometry Nodes: Only use realized geometry in mesh boolean node
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
fc06a471f1
Since 44e4f077a9 and related commits, geometry nodes doesn't
try to hide the difference between real geometry data and instances from
the user. Other nodes were updated to only support real geometry, but
the "Mesh Boolean" node was never updated and still implicitly gathered
all the instances. This commit removes the special instance behavior in the
boolean node and adds realize instances nodes to keep existing behavior
in most cases. Typically this doesn't make a difference in the result,
though it could in the union mode for instance inputs. Shifting more of
the work to realizing instances should generally be better for
performance, since it's much faster.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
3a839cc52b
Cycles: Merge Anisotropic BSDF node into Glossy BSDF node
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8cde7d8f8a
Used to be https://archive.blender.org/developer/D17123.

Internally these are already using the same code path anyways, there's no point in maintaining two distinct nodes.

The obvious approach would be to add Anisotropy controls to the Glossy BSDF node and remove the Anisotropic BSDF node. However, that would break forward compability, since older Blender versions don't know how to handle the Anisotropy input on the Glossy BSDF node.

Therefore, this commit technically removes the Glossy BSDF node, uses versioning to replace them with an Anisotropic BSDF node, and renames that node to "Glossy BSDF".

That way, when you open a new file in an older version, all the nodes show up as Anisotropic BSDF nodes and render correctly.

This is a bit ugly internally since we need to preserve the old `idname` which now no longer matches the UI name, but that's not too bad.

Also removes the "Sharp" distribution option and replaces it with GGX, sets Roughness to zero and disconnects any input to the Roughness socket.

Pull Request: #104445
Fix #106484: Show all rotations with same precision
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
b34ece48f8
Increase precision of some rotational inputs so that they all show the
same precision.  And have the arrows change in full degrees.

Pull Request: #106515
VSE: Add go to current frame operator to view menu
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
40ccc37fc6
Fix #102574: Don't Show "Rename" for Volume and & System lists
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
dad9e8e621
For File Browser "System" and "Volumes" lists, the item names cannot be
changed by users yet the tooltip says "Double click to rename". This PR
just removes that text for these non-editable lists.

Pull Request: #106873
Cleanup: function style C++ casts, use printing & ELEM macros
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8ad2ee7f12
Also remove redundant CTX_wm_space_text(C) calls.
If there are no loose vertices or edges, it's basically free to
propagate that information to the result and save calculating
it later in case it's necessary. I observed a peformance increase
from 3.6 to 4.1 FPS when extruding a 1 million face grid.
Cleanup: Rename mesh loose edges tag function
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
71d22331b1
To match the more recently added `tag_loose_verts_none`.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ec8a4cfcb7
While strcpy is safe in this case, it's use requires extra scrutiny
and can cause problems if the strings are later translated.

Also move the ID code assignment into material_init_data
as the ID-code is more of an internal detail.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
3db0bde21d
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9af19822f0
Fix motion tracking not tracking at all
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9e5e06136a
A mistake in the recent ImBuf API refactor: the Libmv image accessor
was copying destination to destination (possibly using the wrong
number of channels as well).

Pull Request: #108070
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
e620ae054f
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
3a286a735f
Cycles: implement faster #make_orthonormals()
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
51923c09e2
Pull Request: #106053
Mesh: Move bevel weight to generic attribute
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
2a56403cb0
Store bevel weights in two new named float attributes:
- `bevel_weight_vert`
- `bevel_weight_edge`

These attributes are naming conventions. Blender doesn't enforce
their data type or domain at all, but some editing features and
modifiers use the hard-coded name. Eventually those tools should
become more generic, but this is a simple change to allow more
flexibility in the meantime.

The largest user-visible changes are that the attributes populate the
attribute list, and are propagated by geometry nodes. The method of
removing this data is now the attribute list as well.

This is a breaking change. Forward compatibility is not preserved, and
the vertex and edge `bevel_weight` properties are removed. Python API
users are expected to use the attribute API to get and set the values.

Fixes #106949

Pull Request: #108023
Cleanup: deduplicate code to obtain the object for the transform space
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
e0e182d5e9
Workaround Cycles regression test failures
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8cc22d2809
The failure happens since the recent changes in the make_orthonormals.

The only difference is the underwater caustics test file, and the
difference seems to be a noise floor.

There seems to be nothing wrong with the math in the function itself:
the return values are all without quite small epsilon when comparing
Linux with M2 macOS. The thing is: the very first input is already a
bit different on different platforms. So the difference is already
somewhere else.

For now increase the threshold to avoid confusion of the rest of the
team, and to allow builds to be deployed.

Pull Request: #108080
UI: Edit Mode Options panel cleanup
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
560e9c654b
AutoMerge is a property of transform operations, so it seems more
convenient to have this option bundled with transform settings.

Another thing is that the 'Live Unwrap' option has no real relation to
Transform.

Therefore, remove the 'AutoMerge' sub-panel and create two sub-panels
for the Options Panel:
- Transform
- UVs

Merge the 'AutoMerge' settings into the 'Transform' sub-panel.

Move 'Live Unwrap' to the 'UVs' sub-panel.

Pull Request: #108056
This forces the max thread count to be inlined with what
blender expects. While this will make some shaders less
eficient it avoid crashes / assert on shaders that
could not compile. The performance impacts can be fixed
by tackling the individual cases.
Cleanup: Format python after recent changes
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8bca0e1075
Pull Request: #108086
Metal: Always add GPU_TEXTURE_USAGE_ATTACHMENT flag
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c435d2f856
Texture clearing is done using framebuffer clear.
To avoid adding the flag everywhere we add it as part
of the texture creation process.

This should have no performance impact.
Geometry Nodes: Remove realize instances legacy behavior
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f17ea1f2a7
The option was added f5ce243a56 when the node was
rewritten to add support for propagating instance attributes.
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
552c262cee
View 3D: new utility to provide navigation in operators
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
2ce365efc7
Implements a new API consisting of:
- `ED_view3d_navigation_init`,
- `ED_view3d_navigation_do` and
- `ED_view3d_navigation_free`,

With these functions, any operator can create their own navigation
context and navigate in the 3D View without having to use
`PASS_THROUGH`.
Transform: support navigation while transforming in 3D view
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
33c13ae6e3
Implements a new option in keymap settings:
- "Navigate during Transform"

Note that with the option enabled, the keymap changes as follows:

|Modal Map (Blender):| Conflict: | Current: | New:
|---|---|---|---
| Increase Proportional Influence | VIEW3D_OT_zoom | Wheel Down | Alt Wheel Down
| Decrease Proportional Influence | VIEW3D_OT_zoom | Wheel Up | Alt Wheel Up
| Adjust Proportional Influence | VIEW3D_OT_rotate | Mouse/Trackpad Pan | Alt Mouse/Trackpad Pan
| Increase Max AutoIK Chain Length | VIEW3D_OT_zoom | Wheel Down | Alt Wheel Down
| Decrease Max AutoIK Chain Length | VIEW3D_OT_zoom | Wheel Up | Alt Wheel Up
| Automatic Constraint | VIEW3D_OT_rotate | Middle Mouse | Alt Middle Mouse
| Automatic Constraint Plane | VIEW3D_OT_move | Shift Middle Mouse | Shift Alt Middle Mouse

Design Task: #106008
Pull Request: #105764
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8783a51583
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8925ea1890
Cleanup: spelling in comments, colon after doxy parameters
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ab294b4ebb
UI: Rename Copy Vertex Group to Duplicate Vertex Group
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f637b8c095
Change display name of OBJECT_OT_vertex_group_copy to "Duplicate Vertex
Group" from "Copy Vertex Group". The word "duplicate" is a better
unambiguous descriptor of this operation.

Pull Request: #107691
Cleanup: Fix copyright date in new bke header
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
43d66f6760
Pull Request: #108112
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
57f593b7ca
BLI: move tbb part of parallel_for to implementation file
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f6d824bca6
Previously, `tbb::parallel_for` was instantiated every time `threading::parallel_for`
is used. However, when actual parallelism is used, the overhead of a function
call is negilible. Therefor it is possible to move that part out of the header
without causing noticable performance regressions.

This reduces the size of the Blender binary from 308.2 to 303.5 MB, which is
a reduction of about 1.5%.
BLI: improve IndexRange
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
b58cfde48a
Defining `operator-` for the iterator allows it to be used in more generic
iterator code. The `index_range` method is the same that exists on many
other containers like `Vector`.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8c6908eba5
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
737f582329
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
fd887bcb15
BLI: fix overload resolution with FunctionRef parameters
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
153e1c0492
This is useful when debugging how much memory a particular function
allocates from this allocator. The change also reduces the size of
`LinearAllocator`.
This can be useful when e.g. each thread has its own `LinearAllocator`,
but in the end they are combined into one.
Alignment here means that the size of the range passed into callback
is a multiple of the alignment value (which has to be a power of two).
This can help with performance when loops in the callback are are
unrolled and/or vectorized. Otherwise, it can potentially reduce
performance by splitting work into more unequally sized chunks.
For example, chunk sizes might be 4 and 8 instead of 6 and 6 when
alignment is 4.
Cleanup: add missing inline
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
64c33871bd
This is necessary for correctness of the code to avoid duplicate symbols.
In practice, this wasn't necessary yet, because usually we pass lambdas
into these functions which cause every instantiation to have a different
signature.
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
7f4aa0b553
Fix #108136: Regression : Texture paint is broken
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
eb3e32b653
Mistake in the 406cfd214a which was calculating the offset wrongly.

Pull Request: #108138
Pull Request: #108042
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
a440386654
I18n: Add translation contexts to properties declared from Python
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
2decfe4f00
Some property labels need a context to disambiguate them from others
which have the same name.

The only way to show the proper text currently for such properties is
to override it in the UI code with a translation context, like:

```python
    layout.prop(obj, "area", text="Area",
                context=i18n_contexts.amount)
```

Python properties already store a translation context though, but this
context cannot be chosen from a Python script.

For instance, typing:

```python
bpy.types.Scene.test_area = bpy.props.BoolProperty(name="Area")
print(bpy.context.scene.bl_rna.properties['test_area'].translation_context)
```

will print `*`, the default context for Python props.

This commit allows specifying a context in this manner:

```python
from bpy.app.translations import contexts as i18n_contexts
bpy.types.Scene.test_number_area = bpy.props.BoolProperty(
    name="Area", translation_context=i18n_contexts.amount
)
print(bpy.context.scene.bl_rna.properties['test_number_area'].translation_context)
```

will now print `Amount` and can be translated differently from other
labels. In this instance, the word for a surface area measurement,
instead of a UI area.

-----

This is what translated properties look like using the existing ("Area", "") and ("Area", "Amount") messages:
![python_prop_contexts_test.png](/attachments/b0d9737e-4b31-4c91-a08e-b347db31225f)

The panel can be generated with this script:
[python_prop_contexts_test.py](/attachments/ab613cdc-8eba-46bc-8f3c-ad0a97e7a6e5)

Pull Request: #107150
After 22f641e7f8, translation macros were removed and thus in many
files inclusion of the translation header is no longer needed.

Pull Request: #107986
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1ab265f535
DrawManager: Fix Incorrect Resource Binding Hair/Curves
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
2164515fab
In the DrawManager a dummy texture was attached to the a, au, c, ac
binding points. In the shader those binding points are actual texture
buffers.

The reason for the dummy texture was to work around some OpenGL driver
bugs. In Vulkan (and expected also in Metal) it is not allowed to attach
a texture as a texel buffer. Fixing this would require copying buffers into a
buffer during binding.

This patch will remove the binding of the textures and use the vbos
instead. Also it fixes an issue where a platform does support compute
shaders, but don't support transform feedback. This is currently the
case for the Vulkan backend.

Pull Request: #108139
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
e70051ae3d
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
6cce149144
Pull Request: #107782
Cleanup: fix compiler warnings
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
7d416ece82
Avoid two GHash lookups when deleting an override property by its RNA
path.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
5eab240f7f
Metal: Stencil texture view support
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ae405639e7
Adds stencil texture view support for Metal, allowing reading of
stencil component during texture sample/read.

Stencil view creation refactored to use additional parameter in
textureview creation function, due to deferred stencil parameter
causing double texture view creation in Metal, when this should
ideally be provided upfront.

Authored by Apple: Michael Parkin-White

Pull Request: #107971
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
f85fb56a4a
UI: Shapekey pin tooltip change
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
6609ca4593
Use correct terminology "value" vs strength
UI: Change tooltip for edit mode display shapekey
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c06e8f6549
Change terminology from Apply to Display.
Apply suggests a destructive change to
the base mesh.

Display is also used in modifiers.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
2c1338f67b
Fix invalid buffer size used in ED_asset_handle_get_full_library_path
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c440efb23a
Relatively harmless as the length was shorter, however all callers
used the larger size.
Rename `r_dir` to `dirpath` as this isn't a return only argument.
Also add the maximum size in the argument as a hint for the maximum size.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
63074dddb1
Remove the guimode argument which used to set the cursor back in v2.4x.
PyAPI: remove deprecated blf.size() dpi argument
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9357f7b606
Scripts can be updated by scaling the font size, e.g.

blf.size(id, size, dpi) -> blf.size(id, size * (dpi / 72.0))
Also remove redundant call to snprintf.
PyAPI: remove deprecated Mesh.calc_normals
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ab5fc46872
Remove deprecated context override argument to operator execution and
poll() method in favor of context.temp_override().
PyAPI: use faster argument parsing for internal bpy.ops call & poll
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d1cc16913d
No functional changes.
Prefer BLI_strncpy as it ensures the string is null terminated.
PyAPI: remove deprecated bpy.app.version_char
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
345fc2b1f6
This hard-coded assumption meant that operators would behave as if
bl_property = "type" was assigned in the operator - when the variable
wasn't found.

Remove the hard coded name. Operators that depended on this now need
to assign bl_property = "type" in the operator class explicitly.

Remove this because it wasn't documented as means operator behavior
could change unexpectedly when renaming a property.
Missed from recent removal of the argument.
PyAPI: remove deprecated 2D_/3D_ prefix for built-in shader names
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9a8fd2f1dd
Names passed to gpu.shader.from_builtin()
no longer skip the 2D_/3D_ prefix.
PyAPI: remove deprecated 2D_/3D_ prefix (update docs)
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
495e4f2d0e
Allows to share buffer data between the render result and image buffers.

The storage of the passes and buffers in the render result have been
wrapped into utility structures, with functions to operate on them.

Currently only image buffers which are sharing buffers with the render
results are using the implicit sharing. This allows proper decoupling of
the image buffers from the lifetime of the underlying render result.

Fixes #107248: Compositor ACCESS VIOLATION when updating datablocks from handlers

Additionally, this lowers the memory usage of multi-layer EXR sequences
by avoiding having two copies of render passes in memory.

It is possible to use implicit sharing in more places, but needs
some API to ensure the render result is the only owner of data before
writing to its pixels.

Pull Request: #108045
BLI: Replace some macros with inlined functions for C++
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
793446cbdc
Covers the macro ARRAY_SIZE() and STRNCPY.

The problem this change is aimed to solve it to provide cross-platform
compiler-independent safe way pf ensuring that the functions are used
correctly.

The type safety was only ensured for GCC and only for C. The C++
language and Clang compiler would not have detected issues of passing
bare pointer to neither of those macros.

Now the STRNCPY() will only accept a bounded array as the destination
argument, on any compiler.

The ARRAY_SIZE as well, but there are a bit more complications to it
in terms of transparency of the change.

In one place the ARRAY_SIZE was used on float3 type. This worked in the
old code because the type implements subscript operator, and the type
consists of 3 floats. One would argue this is somewhat hidden/implicit
behavior, which better be avoided. So an in-lined value of 3 is used now
there.

Another place is the ARRAY_SIZE used to define a bounded array of the
size which matches bounded array which is a member of a struct. While
the ARRAY_SIZE provides proper size in this case, the compiler does not
believe that the value is known at compile time and errors out with a
message that construction of variable-size arrays is not supported.

Solved by converting the field to std::array<> and adding dedicated
utility to get size of std::array at compile time. There might be a
better way of achieving the same result, or maybe the approach is
fine and just need to find a better place for such utility.

Surely, more macro from the BLI_string.h can be covered with the C++
inlined functions, but need to start somewhere.

There are also quite some changes to ensure the C linkage is not
enforced by code which includes the headers.

Pull Request: #108041
Vulkan: Select Compatible Render Surface
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
4997748e5e
In previous implementation the first available render surface was
selected. For NVIDIA platform this was the correct one, but for
AMD and Intel GPUs this was incorrect. This PR goes over all the
available render surfaces and selects a compatible one.

For now when no compatible render surface is found it will still select
the first available one. With the expectation that the screen is drawn
incorrectly and users would report a bug so we can investigate.

Pull Request: #108169
MSL require to use packed_int3 for compatibility
with GLSL memory layout.
Cleanup: Remove unused collection pointer from depsgraph builder
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
e54a20b2a2
Pull Request: #108177
Cycles: bumping OpenPGL minimum version to 0.5 and removing version checks
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
493856427d
Move the instancing related code to a dedicated function, leaving
the generic `build_collection()` dedicated to the building of the
collection itself.

Should be no functional changes: the code paths should effectively
still be the same. This is because non-instancing cases were passing
object as a null pointer, disabling the non-generic code path.
Depsgraph: Add explicit object collection hierarchy tracking
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
61ed5b3d24
The practical problem this change addresses is ability to have base
flag dependent functionality in Cycles without re-setting the render
on selection. This problem initially arose during the Cycles light
linking project.

The original review happened there:

    #105837

Pull Request: #108182
I found the small dent on the log to be bothersome and unnecessary. Although modifying the Blender output may cause some parsing issues, they can be quickly resolved.

Before:
```
22-05 16:26:02 (debug) Fra:96 Mem:3130.54M (Peak 11196.17M) | Time:11:58.38 | Remaining:00:09.02 | Mem:2890.45M, Peak:9039.80M | Scene | ViewLayer | Finishing
22-05 16:26:34 (debug) Saved: 'd:\sheep_gpu\sheepit\208726392_0096.png'
22-05 16:26:34 (debug)  Time: 12:30.28 (Saving: 00:31.08)
```
After:
```
22-05 16:26:02 (debug) Fra:96 Mem:3130.54M (Peak 11196.17M) | Time:11:58.38 | Remaining:00:09.02 | Mem:2890.45M, Peak:9039.80M | Scene | ViewLayer | Finishing
22-05 16:26:34 (debug) Saved: 'd:\sheep_gpu\sheepit\208726392_0096.png'
22-05 16:26:34 (debug) Time: 12:30.28 (Saving: 00:31.08)
```

Pull Request: #108187
This contains the basis of the new overlay engine.
Only a few overlays are ported for proof of concept of the new design.

This new design unifies the selection drawing with the overlay-next engine.
It now becomes responsible of selection in object mode.
For this we create a dedicated shader module that patches the shaders
for selection.

Note that the gizmo selection still uses the occlusion queries and edit-mode
the current selection engine (select_engine.c).

Related task #102179
Related task #102177

Co-authored-by: Clément Foucault <foucault.clem@gmail.com>
Pull Request: #107734
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
683f7d3f74
Method didn't modified the ShaderInterface but wasn't usable when trying
to debug a const reference to the ShaderInterface. This PR just adds the
const to the method.

Pull Request: #108190
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1d9aaf7a4d
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
5142d8c831
Depsgraph: add generic way for modifiers to check user-edited flags
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0d13b0e50d
This implements the design described in #108174.

Pull Request: #108181
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ec1349c62d
fc06a471f1 was missing a file subversion bump.
Cleanup: Use C++ BitVector in subdiv code instead of Bitmap
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9fd8fe134d
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
574a9a9c8f
Cleanup: Remove #pragma once in .cc files
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
14e6a5c44c
See 75ad8da1ea
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
abdb2bd6e9
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0f87bdfd8f
Replace a template with a FunctionRef, reducing Blender's
binary size by 63 KB, with a negligible performance impact.
Cleanup: Remove unnecessary template in curve subdivide node
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
e704ebaba4
The Catmull Rom curve subdivision arguments use runtime-typed spans,
so the template doesn't help anyway. Makes Blender 27 KB smaller.
Cleanup: Fix build error on Windows
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
37b6ba7616
Docs: expand on why a restart when changing script directories is needed
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
6a9c78d059
- Don't use the source string length +1 as the size of the destination
  (USD export & IMB_exr_get_handle_name).
- Correct undersized buffer being passed into imb_exr_insert_view_name.
Cleanup: misleading/incorrect argument to BLI_path_to_display_name
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
f5ea30985e
The strlen() was passed in as a size argument, in this case it
couldn't have caused an overflow because the source & destination
happened to be the same size.

Also reduce the destination buffer size as this is used for an ID name.
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
44d9a5eb72
Fix: Windows build error in template code
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
a6eae61b52
`using namespace blender` didn't make it into the lambda,
likely because of a compiler bug.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8be8960738
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
a4217d8a71
While these uses seemed safe, strcat is error prone enough that other
functions are preferable.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9e8cfabb8a
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
57501d899d
Cleanup: spelling in comments, replace slang/informal terms
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
129f6b7b84
Mesh: Reimplement and unify topology maps
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
4d841e1b35
Combine the newer less efficient C++ implementations and the older
less convenient C functions. The maps now contain one large array of
indices, split into groups by a separate array of offset indices.
Though performance of creating the maps is relatively unchanged, the
new implementation uses 4 bytes less per source element than the C
maps, and 20 bytes less than the newer C++ functions (which also
had more overhead with larger N-gons). The usage syntax is simpler
than the C functions as well.

The reduced memory usage is helpful for when these maps are cached
in the near future. It will also allow sharing the offsets between
maps for different domains like vertex to corner and vertex to face.

A simple `GroupedSpan` class is introduced to make accessing the
topology maps much simpler. It combines offset indices and a separate
span, splitting it into chunks in an efficient way.

Pull Request: #107861
Cleanup: remove unused function #light_sample_new_position
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d1dca2d15c
Fix man-page generation when ASAN_OPTIONS included strict_init_order
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
60d97fb5fa
The install target would fail when ASAN_OPTIONS was set for the
environment that launched the build.

Resolve by explicitly overriding these settings.
Cycles: light and shadow linking
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ba3f26fac5
With light linking, lights can be set to affect only specific objects in the
scene. Shadow linking additionally gives control over which objects acts a
shadow blockers for a light.

Usage:
https://wiki.blender.org/wiki/Reference/Release_Notes/4.0/Cycles

Implementation:
https://wiki.blender.org/wiki/Source/Render/Cycles/LightLinking

Ref #104972
Co-authored-by: Brecht Van Lommel <brecht@blender.org>
BLI: Add utility to find true/false mix in boolean array
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c9dac7e77c
This is useful for #108014, when determining whether there
are any sharp faces and edges in a mesh.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9acff4edab
Goals of this refactor:
* Reduce memory consumption of `IndexMask`. The old `IndexMask` uses an
  `int64_t` for each index which is more than necessary in pretty much all
  practical cases currently. Using `int32_t` might still become limiting
  in the future in case we use this to index e.g. byte buffers larger than
  a few gigabytes. We also don't want to template `IndexMask`, because
  that would cause a split in the "ecosystem", or everything would have to
  be implemented twice or templated.
* Allow for more multi-threading. The old `IndexMask` contains a single
  array. This is generally good but has the problem that it is hard to fill
  from multiple-threads when the final size is not known from the beginning.
  This is commonly the case when e.g. converting an array of bool to an
  index mask. Currently, this kind of code only runs on a single thread.
* Allow for efficient set operations like join, intersect and difference.
  It should be possible to multi-thread those operations.
* It should be possible to iterate over an `IndexMask` very efficiently.
  The most important part of that is to avoid all memory access when iterating
  over continuous ranges. For some core nodes (e.g. math nodes), we generate
  optimized code for the cases of irregular index masks and simple index ranges.

To achieve these goals, a few compromises had to made:
* Slicing of the mask (at specific indices) and random element access is
  `O(log #indices)` now, but with a low constant factor. It should be possible
  to split a mask into n approximately equally sized parts in `O(n)` though,
  making the time per split `O(1)`.
* Using range-based for loops does not work well when iterating over a nested
  data structure like the new `IndexMask`. Therefor, `foreach_*` functions with
  callbacks have to be used. To avoid extra code complexity at the call site,
  the `foreach_*` methods support multi-threading out of the box.

The new data structure splits an `IndexMask` into an arbitrary number of ordered
`IndexMaskSegment`. Each segment can contain at most `2^14 = 16384` indices. The
indices within a segment are stored as `int16_t`. Each segment has an additional
`int64_t` offset which allows storing arbitrary `int64_t` indices. This approach
has the main benefits that segments can be processed/constructed individually on
multiple threads without a serial bottleneck. Also it reduces the memory
requirements significantly.

For more details see comments in `BLI_index_mask.hh`.

I did a few tests to verify that the data structure generally improves
performance and does not cause regressions:
* Our field evaluation benchmarks take about as much as before. This is to be
  expected because we already made sure that e.g. add node evaluation is
  vectorized. The important thing here is to check that changes to the way we
  iterate over the indices still allows for auto-vectorization.
* Memory usage by a mask is about 1/4 of what it was before in the average case.
  That's mainly caused by the switch from `int64_t` to `int16_t` for indices.
  In the worst case, the memory requirements can be larger when there are many
  indices that are very far away. However, when they are far away from each other,
  that indicates that there aren't many indices in total. In common cases, memory
  usage can be way lower than 1/4 of before, because sub-ranges use static memory.
* For some more specific numbers I benchmarked `IndexMask::from_bools` in
  `index_mask_from_selection` on 10.000.000 elements at various probabilities for
  `true` at every index:
  ```
  Probability      Old        New
  0              4.6 ms     0.8 ms
  0.001          5.1 ms     1.3 ms
  0.2            8.4 ms     1.8 ms
  0.5           15.3 ms     3.0 ms
  0.8           20.1 ms     3.0 ms
  0.999         25.1 ms     1.7 ms
  1             13.5 ms     1.1 ms
  ```

Pull Request: #104629
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
adb87dd080
Refactor: group multiple floats to float2 or float3
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
41e49d7ece
Multiple random numbers were passed around separately, making some
argument lists unnecessarily long.
No functional changes expected.

Pull Request: #108236
Fix: Crash with "use sharp" turned off in weighted normal modifier
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d168df7c23
UI: Updated Windows File Registration
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9cf77efaa0
Windows file associations using ProgID, needed because of the launcher.
This fixes "pin to taskbar" and Recent Documents lists, allow per-
version jump lists and an "Open with" list with multiple versions.

Pull Request: #107013
UI: Text cursor behavior for Apple Devices
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0e8419246d
MacOS-specific behavior for arrow keys, delete, and backspace. Alt/Opt
modifier to jump by word, CMD modifier to jump to beginning/end.

Pull Request: #107522
UI: Updated Windows File Registration Correction
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f37f60937a
Removal of thumbnail via regsvr32 requires /s argument to be silent
to not show any messageboxes during WIX uninstallation

Pull Request: #107013
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
b567b249d4
Curves edit mode does select the selection filter feature.
Also use "values" and "indices" instead of elements, since they're
more specific terms.
The mask was sliced, but the original mask was used from before the
slicing, causing an unsliced mask to be used with the new offsets.
This caused a crash in the hair styles demo file.
- Handle multithreading in caller, consistent with other multi-functions
- Simplify IndexMask iteration (avoid logarithmic lookup)
Unify the handling of masks for affected curves in a few of the sculpt
brushes. In the grow shrink brush, replace a more custom "influences
per thread" solution. In the puff brush, use a full array of weights,
and build the mask earlier. In the snake hook brush, use the selection
properly (I observed a 2-3x improvement with a small selection).
Use the weird but at least consistent "from_groups" method in the sample
curves node, and avoid one logarithmic lookups when merging points.
"ledge" and "lvert" sound very word, and "ledge" is also a word. It's
clearer to use the full word and abbeviate the obvious part, "index."
Cleanup: quiet RNA warnings from a trailing '.'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
23862ec60e
Clenup: remove strcat use
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
6eebc06c36
Cleanup: replace strcat with BLI_strncat
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9182ebdfde
Fix off by 1 error in BLI_uniquename* clipping an extra character
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
21b2393eb2
When the new name was clipped to make room for the number,
the string was clipped by the number size (including the null byte).

Store the length in `numlen` instead of the size (including null byte).
Metal: Fix MSL compilation warning
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0e7b81dd32
Fix #108243: Crash when save before close with modified image
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f669f6cd8c
A mistake in the recent API refactor for the buffer sharing.

Pull Request: #108259
Vulkan: Extract Vendor/Driver/Device Information
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
f5d159b2a4
Extract vendor, driver and device information from the physical device
properties.

Note that driver version is implementation dependent and might fail as
it is unclear which driver is being used. An open source driver could
store the driver version in a different way than a closed source driver.
But as it is not clear which driver version is being used it might
extract the incorrect version.

To solve this issue we check if the extracted version makes sense
depending on the version schema of the driver and if they don't match we
use another approach.

Pull Request: #107872
A user-counter mistake caused by shallow-copy of the render result
during its duplication.

Pull Request: #108265
The original names were `...update_position()`, but no update in
position is performed in these functions, rather, the entries in
`LightSample` are updated. Also make clear that the functions are used
by MNEE.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
01595ee807
Fix #108250: Cycles: Light Linking disabled after modifying object
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1c3e0f3585
The runtime backup/restore logic was slightly wrong: it is possible that
an object requires light linking runtime but does not need light linking
itself. This is typical configuration for the receivers/blockers.

Modified the logic so that the evaluated object light linking is allocated
if there was a runtime field needed.

This required to make it so light linking evaluation takes care of feeing
the light_linking if it is empty. The downside of this approach is a
redundant allocation from the object backup when removing light linking
collection from emitter. But this is not a typical evaluation flow, and
the more typical flows are cheap with this approach.

Pull Request: #108261
The recent light linking commit changed some includes order,
making compilation to fail on platforms where certain features
are disabled.

Pull Request: #108264
Fix: Crash entering vertex paint mode
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1c88721442
SculptSession now contains non-trivial types that must be initialized.
Cleanup: remove unnecessary eval_fac == 0 checks for point lights
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
bbe5b1e8cf
Fix #108258: Sculpt mode crash after remesh
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
de2c8416a0
4d841e1b35 incorrectly removed the clearing
of mesh topology maps when the object is reevaluated.
Build: fix OpenBSD error in guardedalloc
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
a50768616f
Pull Request: #108252
After 2cfcb8b0b8 this was only used in one place that
was easily replaced. In practice this avoids creating a statically
allocated array after the split edges code is called.

Pull Request: #108249
Cleanup: Fix warnings in Overlay Next
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
a31875dab6
The goal here is to get us closer to using C++ in RNA code.

Pull Request: #108277
The intersection already has proper object assigned.

Pull Request: #108275
Transform: remove precision modification upon starting navigation
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
fc854fc252
In order to execute the navigation of type "VIEW3D_OT_move," the user
is required to press both the `Shift` and `MMB` keys.

However, pressing `Shift` also activates the precision modifier for the
transform.

Consequently, while the `MMB` is unpressed, the transform operation
unintentionally remains in precision mode, altering the mouse position.

To address this issue, the solution was to eliminate the precision
changes immediately after the navigation is initiated.

Unfortunately, we have no way of knowing whether the user actually
unintentionally enabled precision, so this solution serves as a
workaround. Ideally, keymap conflicts should be avoided.
Add Material::blend_flags to Shaderkey,
to ensure Materials with different settings but the same shader
don't end up using the same pass.

Pull Request: #108283
Workbench Next: Add missing texture usage flags
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
55b20cef43
Fix recent change in transform code
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c89461a2bc
fc854fc252 caused the precision modification to be removed after
navigation was complete.

The ideal is when starting navigation.

This is because the precision button can be released during navigation,
thus confirming the precision change.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c18cafe748
Mesh: Avoid position copying in corrective smooth modifier
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
72309be398
This is a place where copying mesh position is not needed. See #103789.

Pull Request: #108291
Audaspace: porting changes from upstream.
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
e98c26dece
Fix #108098: GPencil: Prevent overwriting mvalo
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
99df159ce0
There are other events besides `MOUSEMOVE` that's passed in during modal
handling, causes the `tgpi->mvalo` variable to be overwritten without
moving the stroke in the first place, this results in inaccurate offsets
during mouse/pen grabbing in primitive gizmo `IN_MOVE` mode. Now fixed.

Also fixed the operator hint to include the grab functionality.

Pull Request: #108172
Cleanup: refactor cursor jump type check into a function
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
ac74f3b396
Cleanup: duplicate words in comments
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
393d4a6e14
Also use doxygen-comments in files where this is already the convention.
Cleanup: deduplicate code to create menu for flip region
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
cd09c91f69
Ref !108302.
BLF: use BLI_path_cmp when comparing path names
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ad6fa96041
There is no reason to use case-sensitive path lookups on MS-Windows.

Also replace BLI_str_endswith with BLI_path_basename since ends-with
checks don't ensure a preceding path separator.
We have been chatting in the Animation&Rigging module meeting that the collection hotkeys (1, 2, 3 etc.) in Pose Mode are unwanted and could be replaced with something more useful.
This patch only removes the hotkeys, we can later decide what should be in their place.

Pull Request: #105120
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
dfb3e0d262
Fix assert in light linking when making an asset
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
786c599404
Simple steps to reproduce: mark the default cube as an asset.

Pull Request: #108306
Slightly increase threshold to avoid division by zero.
Fix hiding receiver disabling light/shadow linking
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
5e971e8d7f
Turns out it is not enough to check for the receiver/blocker set,
as the object might be hidden. This should not change the light
behavior.

Pull Request: #108307
Cycles: Store light name
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d6db9e4193
Similar to objects, store the name of Blender's side light name
on the Cycles side. This allows to have readable logs where a
name and property is logged (while previously in the logs all
lights will be called lamp).

There is no user-measurable change.

Pull Request: #108310
Fix specialized light tree building for distant lights
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
4ca39297ab
On a user level this fixes configuration when a spot light is
linked to an object, and a sun light is not linked to anything.
It used to be making non-linked receivers to be very noisy.

This is because the distant light did not update the node's
light linking settings when they are added to the node.

A simple demo file will be added to the tests suit as
light_link_distant_tree.blend.

Pull Request: #108311
Fix crash when selecting all bones in armature
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d36c329e16
Pressing 'A' to select all pose bones in an armature caused a segfault,
as `id->override_library->runtime->tag` was checked while
`id->override_library->runtime` was `nullptr`. An extra check resolved
the crash.
Merge remote-tracking branch 'origin/blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
eb07e8c37b
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0f3682a88a
Renames `RNA_def_main_gpencil` to `RNA_def_main_gpencil_legacy`.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
074abff87e
Fix #108315: Illegal CUDA address with shadow-linked mesh emitters
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
cc25a37bee
A mistake in the intersection picking logic: if a mesh was hit at
least one intersection is to be recorded.

Pull Request: #108320
Cleanup: Spelling in Cycles light tree
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
82e8f1129c
Pull Request: #108324
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
9c15058d0b
This shows more clearly that there's nothing specific to curves here.
Using the new index mask implementation, things can be a bit simpler.
It's also simpler to use `complement` instead of `to_ranges_invert`,
which just made everything less standard. Also create the new curve
offsets in place instead of copying, and use implicit sharing to share
attributes when no curves were deleted.

With a version of `IndexMask::complement()` optmized locally, I observed
the following speedups with a 1.2 million point curve system:
- Delete points: 29 FPS -> 45 FPS
- Delete curves: 48 FPS -> 49 FPS
- Delete tip points: 25 FPS -> 32 FPS

Also add a method to apply the "gather" function to all attributes,
mostly as a continued experiment of consolidating attribute propagation.
This can be used more elsewhere in the future.
In several nodes, and sculpt brushes, use the proper `IndexMask` type
instead of a span of ranges to encode a selection. This allows deleting
the duplicate data copying utilities using the second format.
Pass the curves and points to keep instead of delete. In the same test
file as the previous commit, this gave an increase from 50 to 60 FPS
when deleting curves.
Cleanup: Standardize delete geometry code
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
ea937b304d
- Avoid using geometry sets from a different abstraction level
- Deduplicate basic attribute copying propagation code
- Allow more use of implicit sharing when data arrays are unchanged
- Optimize for when a point cloud delete selection is empty
- Handle face corners generically for "only face" case
This can be useful for example to add custom operators to the property
context menu.

Pull Request: #107280
Cleanup: consistenly use rnaindex -1 to mean the no or entire array
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
9a9209d8e0
Cleanup: Consolidate public point cloud/mesh conversion functions
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
93a2e5dbfa
Exposing these direct conversions separately just confuses
the API, and they're not used anywhere else anyway.
UI: Temporarily Disable Apple-specific Text Modifier Support
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
07dbdd01e8
Disable recently-added support for some Apple-specific key modifiers
when  editing UI text. Only until we can add support for same for text
objects, console, and text editor. Keeping consistent between areas.

Pull Request: #108333
It bothered me that in the Blender manual the `--debug-freestyle` was in the `Other Options` category.
Now it should appear correctly in `Debug Options`.
https://docs.blender.org/manual/en/3.6/advanced/command_line/arguments.html#other-options

Pull Request: #108179
Docs: Make Cycles Args visible in --help
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
082766bfa4
The Cycles-specific command line arguments are currently hidden
on this page [1]. To make the command visible in the manual [2] and
in `blender --help`, I added this patch.

[1] https://docs.blender.org/manual/en/3.6/advanced/command_line/render.html#cycles
[2] https://docs.blender.org/manual/en/3.6/advanced/command_line/arguments.html#argument-order

If this gets merged, please merge blender/blender-manual#104455 as well.

Pull Request: #108232
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
d133d622c1
Recently added cycles options weren't included in the help message.

Also quiet extra token warning.
A minor change that makes text a little easier to follow for developers.
Keep "Misc" options last.
This flag isn't used, even going back to the initial commit.
The in-line ends-with check could read before the string began, as it
happens this wouldn't have caused problem (based on the memory layout),
nevertheless, out of bounds buffer access is best avoided.
Merge branch 'blender-v3.6-release'
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
45bd9b58b9
BLI_path: add BLI_path_is_win32_drive_only check
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
9371349281
Also remove doxygen block for comments in a functions body.
Test: add string.StrCat test
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
d9ffa2dfc4
Revert "Cleanup: consistenly use rnaindex -1 to mean the no or entire array"
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
9ad7ad4323
This reverts commit 9a9209d8e0.

This commit caused an assert on factory startup,
needs further investigation.
PyAPI: add bpy.app.help_text() for accessing output from --help
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
3a5ba15c79
Simplify help text extraction which may be used by the manual &
man-page generation.
ByAPI: add "all" argument to bpy.app.help_text, to show all help text
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
28b8ceea7c
Optionally extract all help text, even for options not available
on the current platform or with the current build options.

Useful so it's possible to extract help text for the user-manual
which doesn't depend on the blender build used for extraction.
manpage: use bpy.app.help_text() for manual text extraction
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
61d99d450e
Call Blender directly to generate the man-page,
instead of relying on the systems Python which called Blender twice and
processed it's output.
Cleanup: consistently use rnaindex -1 to mean the no or entire array
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
8ed65fe6de
Re-apply [0] with the assert on startup resolved & doc-string updated.

[0]: 9ad7ad4323.
Missed when adding bpy.app.help_text()
Cleanup: quiet uninitialized warning for headless build
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
6e40c8d61b
CMake: don't suppress stderr with manpage generation
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
4a0f2b576c
Quiet ASAN leak reports so this isn't an issue.
Fix #108316: CUDA error rendering Attic scene
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
52015737c9
The light tree dependent on the first threshold to evaluate to 1
when picking up an emitter.

Pull Request: #108323
Metal: Improve GPU debugger support
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0a004fbad4
This patch improves how debug groups are displayed
within captures. Passes are now split to align with
debug groups, such that navigation of captures is
more intuitive.

To closer represent useful information, debug groups are now
deferred to align with passes, with the addition of Macros to
control capture display options.

METAL_DEBUG_CAPTURE_MAX_NESTED_GROUPS limits debug
group nesting, and METAL_DEBUG_CAPTURE_HIDE_EMPTY allows
hiding of debug groups which do not contain any commands.

Authored by Apple: Michael Parkin-White

Pull Request: #108287
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
e99a2fb61c
Help text: corrections & minor changes for the user manual
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
ab73a8abba
- BLENDER_STARTUP_FILE was included as a literal instead of expanding
  into 'startup.blend' as intended.
- Single quote cycles device (matching image formats).
- Include all GPU back-ends from bpy.app.help_text(all=True)
- Minor changes to simplify conversion to RST.
Merge branch 'blender-v3.6-release'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
db43b27227
Function naming made it seem main_args_setup might need to call
main_args_setup_post, when this was in fact only needed for handing
final arguments.

Call BLI_args_parse directly and expose main_args_handle_load_file
as a public function. Move handle_load_file into a separate function
which is called by --open-last.
Command line argument --open-last exists if the file isn't found
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1f3a0fbad8
Don't create a new empty file when --open-last is used.
Author
Member

I think the conclusion from the last module meeting was that the thing this patch does for instances should be done for joining as well. I'll try to update the patch and add join handling.

I *think* the conclusion from the last module meeting was that the thing this patch does for instances should be done for joining as well. I'll try to update the patch and add join handling.
Martijn Versteegh force-pushed pass_active_color_to_instances from 0068cd0771 to f5c52ce17f 2023-06-15 10:29:05 +02:00 Compare
Author
Member

rebased onto blender-v3.6-release

rebased onto blender-v3.6-release
Martijn Versteegh force-pushed pass_active_color_to_instances from f5c52ce17f to c3a8457b42 2023-06-15 23:46:45 +02:00 Compare
Author
Member

rebased onto blender-v3.6-release again.

I had to untangle some erroneous merges with main.

rebased onto blender-v3.6-release again. I had to untangle some erroneous merges with main.
Martijn Versteegh force-pushed pass_active_color_to_instances from c3a8457b42 to 3f83adf70f 2023-07-13 00:58:15 +02:00 Compare
Martijn Versteegh changed title from WIP: Pass on color_attribute metadata through instancing, only for mesh to WIP: Pass on color_attribute metadata through instancing, only for mesh 2023-07-13 01:00:07 +02:00
Martijn Versteegh changed target branch from blender-v3.6-release to main 2023-07-13 01:00:09 +02:00
Martijn Versteegh added 1 commit 2023-07-13 01:47:16 +02:00
Member

Seems in !117249 it has been more or less decided that active wont be set from procedural geometry?

Seems in !117249 it has been more or less decided that **active** wont be set from procedural geometry?
This pull request has changes conflicting with the target branch.
  • source/blender/blenkernel/BKE_instances.hh
  • source/blender/geometry/intern/realize_instances.cc
  • source/blender/nodes/geometry/nodes/node_geo_instance_on_points.cc

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u pass_active_color_to_instances:Baardaap-pass_active_color_to_instances
git checkout Baardaap-pass_active_color_to_instances
Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#107066
No description provided.