Regression from 7ec7dac860 (I assume). While the block active state is
relevant during drawing to avoid glitches, it should be ignored during
handling. Explained further in comment.
The functionality to frame channels in the Graph Editor
did not take into account any NLA mapping, causing the
viewport to frame the wrong part.
Fix it by mapping the `rctf` x-values
I had to remove the `const` on a parameter from the function
since `ANIM_nla_mapping_get` doesn't take a `const`.
Pull Request: https://projects.blender.org/blender/blender/pulls/114325
Implements #108948 - support for custom point domain attributes for PLY
import and export. Notes:
- Custom attributes are always represented as scalar floats. PLY itself
has some data types that blender can't fully represent, e.g. double or
uint32, or some that fit into a float just fine but blender does not have
them as separate types (e.g. int16).
- When importing, any PLY vertex attribute that is not one of "standard"
names (position, normal, etc.) gets turned into a custom attribute.
- For exporting, more complex custom attributes (e.g. 2D/3D floats,
quaternions, colors) get turned into several PLY attributes, with "_x"
like suffix.
Custom attribute import/export is on by default in the UI.
Pull Request: https://projects.blender.org/blender/blender/pulls/114320
Reviewed By: Hans Goudey
The issue was that the undo system detected that node trees have been changed
even though they have not. This is because the memory dump of the node tree
changed after unrelated changes. The root issue was that
`bNodeTreeInterface::write` also wrote the struct, and the pointer of the
`bNodeTreeInterface` itself. While this pointer is generally stable, it is not
during file-write, because when IDs are written, a shallow copy is created
first (see `BLO_write_init_id_buffer_from_id`). The temporary buffer for this
shallow copy is allocated on the heap, so its pointer may change over time.
The fix is to simply not write the `bNodeTreeInterface` separately, since it's
already embedded in `bNodeTree`.
Pull Request: https://projects.blender.org/blender/blender/pulls/114322
This PR replaces submissions with pipeline barriers when generating
mipmaps. This would reduce the amount of submissions and improve
performance during mipmap generation as dependencies will be tracked
between commands.
Pull Request: https://projects.blender.org/blender/blender/pulls/114306
Mistake in 4d668e6825. `draw_seq_strips()` would use
`UI_view2d_view_orthoSpecial()` to only scale drawing horizontally, but didn't
reset the matrix state for normal view-space drawing. Result is that the
preview range drawing would be broken, and so were add-ons using the
`POST_VIEW` draw callback.
Pull Request: https://projects.blender.org/blender/blender/pulls/114285
Address issues raised by #114155.
Also fix sphinx documentation generation using incorrect identifiers
when looking up references from PyStruct types
(was looking for `bpy.app.bpy.app.driver_namespace.py`).
Regression in [0] which only ran drag events if the press event passed
through.
Resolve using the same logic as select picking
(see: WM_operator_flag_only_pass_through_on_press).
[0]: 4d0f846b93
Adjust clamping of inputs in the Principled BSDF to avoid errors and
inconsistencies between render engines, while trying to leave as many
inputs as possible unclamped for artisitc purposes.
Pull Request: https://projects.blender.org/blender/blender/pulls/112895
The last good commit was 8474716abb.
After this commits from main were pushed to blender-v4.0-release. These are
being reverted.
Commits a4880576dc from to b26f176d1a that happend afterwards were meant for
4.0, and their contents is preserved.
This patch replaces MeshPolygon.loop_start's use of
RNA_def_property_int_funcs with RNA_def_property_int_sdna to enable raw
array access.
RNA_def_property_int_funcs disables the PROP_INTERN_RAW_ACCESS flag,
which forces rna_raw_access to fall back to its slower loop when using
bpy_prop_collection.foreach_get/foreach_set from Python.
Because MeshPolygon uses the MIntProperty struct and loop_start accesses
the "i" field of MIntProperty directly, it can use
RNA_def_property_int_sdna like other props that directly access the "i"
field of a StructRNA using the MIntProperty struct.
This then speeds up the Python API bpy_prop_collection.foreach_get/
foreach_set access of MeshPolygon.loop_total to the same speeds as
generic int attributes.
Given a mesh with 98304 faces:
foreach_get with a compatible buffer object:
- Face int attribute: ~0.23ms
- MeshPolygon.loop_start (before): ~1.8ms
- MeshPolygon.loop_start (after): ~0.23ms
foreach_get with a Python list:
- Face int attribute: ~2.2ms
- MeshPolygon.loop_start (before): ~3.4ms
- MeshPolygon.loop_start (after): ~2.2ms
foreach_set with a compatible buffer object:
- Face int attribute: ~0.25ms
- MeshPolygon.loop_start (before): ~2.3ms
- MeshPolygon.loop_start (after): ~0.25ms
foreach_set with a Python list:
- Face int attribute: ~1.1ms
- MeshPolygon.loop_start (before): ~3.1ms
- MeshPolygon.loop_start (after): ~1.1ms
Pull Request: https://projects.blender.org/blender/blender/pulls/114262
If region overlap was disabled, the full background of the asset shelf
header would be drawn, unlike usually where we keep the space between
button sections transparent. But resizing the region by dragging wasn't
possible from the space between the button sections, even though the
header was fully opaque.
Button section drawing should only be respected when region overlap is
enabled.
The Huang model has issues with fireflies in various scenes, and the
defualt choice is somewhat arbitrary anyway as they have both pros and
cons. For now be conservative and keep the default the same as before.
The asset shelf was hidden by default in 04d22d73f3. But this only
affected existing 3D Views, not newly created ones. This wasn't
intentional, 3D Views should have the same defaults here.
When a spherical reflection probe is in the scene and the viewport
is set to a lookdev world the scene was constantly being updated.
The cause for this was that the reflection probes where updated when
the lookdev shader was compiled, but that is almost always the case.
This PR fixes this by checking the compile status and compile status
change. Only the first time the world has been compiled the world
reflection probe will be marked dirty.
Pull Request: https://projects.blender.org/blender/blender/pulls/114276
This PR will use "EEVEE (Legacy)" for the legacy EEVEE and renames
"EEVEE Next" to "EEVEE".
When starting Blender EEVEE Legacy will still be the default. We
will change the default to EEVEE when all missing features have been
addressed.
After that we can cleanup idnames and panels etc.
Pull Request: https://projects.blender.org/blender/blender/pulls/114272
Goal is to reduce the number of command buffer flushes by tracking what is
happening in the different command queues. This is an initial step towards
advanced queue-ing strategies.
The new (intermediate) strategy records commands to different command
buffers based on what they do. There is a command buffer for data transfers,
compute pipelines and graphics pipelines.
When a compute command is recorded it ensures that all graphic commands
are finished. When a graphic command is recorded it ensures all compute
commands are finished. When a graphic or compute command is scheduled
all recorded data transfer commands are scheduled as well.
Some improvements are expected as multiple compute and data transfers
commands can now be scheduled at the same time and don't need to unbind
and rebind render passes. Especially when using EEVEE-Next which is
compute centric the performance change is visible for the user.
Pull Request: https://projects.blender.org/blender/blender/pulls/114104
`WM_draw_region_free()` should manage region-draw data, and not change
region state. This should be done by normal region state management
functions. Especially for a flag like `ARegion::visible` which is just
the cached result of the region's visibility evaluation, not the proper
way to actualy manage the region visibility.
The old name `region_subwindow()` wasn't really saying anything, and
basically had nothing to do with what the function actually did. Give it
a name that describes better what it does:
`region_evaluate_visibility()`.
The changes in #112906 (Vulkan: Use Point Shaders When Drawing Points)
broke point sizes for the nodes editor grid on Metal. That PR switched the grid
point drawing code to a shader that sets its own point size, but (at least on Metal)
setting the point size in the shader has no effect unless `GPU_program_point_size(true)`
has been called to allow shader-specified point sizes.
This PR adds the necessary call to `GPU_program_point_size(true)` to fix that problem,
as well as a corresponding "cleanup" call to set it to `false` again.
Pull Request: https://projects.blender.org/blender/blender/pulls/114218
`FromIDsBuilderPipeline` is used to build a minimal depsgraph from
a set of IDs. However, the "visibility" of those IDs is still calculated
based on things like the view layer and the relations. Typically we want
all of these to be visible, the builder just happened to be used in
cases when all of the IDs were already visible so far.
This is needed for node tools which may reference objects or other
IDs from outside of the active depsgraph.
Co-authored by: "Sergey Sharybin <sergey@blender.org>"
The problem was that the array of `IndexMask`s was set to the
number of objects selected and not the number of curves in all
selected objects.
This fixes the transform code from relying on undefined behavior.
Pull Request: https://projects.blender.org/blender/blender/pulls/114088