Age | Commit message (Collapse) | Author |
|
|
|
|
|
No functional changes.
|
|
The goal is to make the Add menu more convenient for the new curves object.
The following changes are done:
* Add `curves` submenu.
* Add an `Empty Hair` operator that also sets the surface object.
* Rename the old operator to `Random`. It's mostly for testing at this point.
Differential Revision: https://developer.blender.org/D14556
|
|
This operator snaps the first point of every curve to the corresponding
surface object. The shape of individual curves or their orientation is
not changed.
There are two different attachment modes:
* `Nearest`: Move each curve so that the first point is on the closest
point on the surface. This should be used when the topology of the
surface mesh changed, but the shape generally stayed the same.
* `Deform`: Use the existing attachment information that is stored
for curves to move curves to their new location when the surface
mesh was deformed. This generally does not work when the
topology changed.
The purpose of the operator is to help setup the "ground truth"
for how curves are attached to the surface. When the ground
truth surface changed, the original curves have to be updated
as well. Deforming curves based on an animated surface will be
done with geometry nodes independent of the operator.
In the UI, the operator is currently exposed in curves sculpt mode
in the `Curves > Snap Curves to Surface` menu.
Differential Revision: https://developer.blender.org/D14515
|
|
|
|
Avoid errors in the legacy Pose Library panel (in Armature properties)
when the Pose Library add-on is disabled.
It's unfortunate that a built-in panel now has knowledge of an add-on.
Then again, it's temporary (one or two Blender releases), and it now uses
feature detection instead of just assuming the add-on is enabled.
|
|
|
|
No functional changes.
|
|
The operator could crash in case the context "object" was overridden
from python, but the "active_object" wasnt (and the active object was
not a mesh).
Reason for the crash is a mismatch in the operators poll function
`data_transfer_poll` vs. `dt_layers_select_src_itemf` -- in the former,
the overriden "object" was respected (and if this was a mesh, the poll
was permissive), in the later it wasnt and only the "active_object" was
used (if this was not a mesh, a crash would happen trying to get an
evaluated mesh).
Now rectify how the object which is used is being fetched -> use
`ED_object_active_context` everywhere (see also rBe560bbe1d584).
Maniphest Tasks: T96888
Differential Revision: https://developer.blender.org/D14552
|
|
This does two things:
* Introduce new `materialize_compressed` methods. Those are used
when the dst array should not have any gaps.
* Add materialize methods in various classes where they were missing
(and therefore caused overhead, because slower fallbacks had to be used).
|
|
This improves performance e.g. when creating an integer attribute
based on an index field. For 4 million vertices, I measured a speedup
from 3.5 ms to 1.2 ms.
|
|
|
|
|
|
Also remove redundant NULL check.
|
|
Add the ability to get/set the selected text.
**Calling the new methods:**
- `bpy.data.texts["Text"].region_as_string()`
- `bpy.data.texts["Text"].region_from_string("Replacement")`
|
|
|
|
|
|
Expose the "Connected" mode from the weld modifier in the
"Merge by Distance" geometry node. This method only merges
vertices along existing edges, but it can be much faster
because it doesn't have to build a KD Tree of all selected
points.
Differential Revision: https://developer.blender.org/D14321
|
|
Use a regular property split layout instead of a grid flow.
Also fix part of T65393.
Differential Revision: https://developer.blender.org/D13558
|
|
Change the modifier name in the modifier stack to "Curvature 3D"
to be consistent with the modifier name in the drop-down.
Differential Revision: https://developer.blender.org/D14476
|
|
Remove the extra space given for decorators on right of the popover.
Differential Revision: https://developer.blender.org/D14518
|
|
If all islands had a size of zero, a division by zero would occur in
`GEO_uv_parametrizer_pack`, causing the UV coordinates to be set to
NaN. An alternative approach would be to skip packing islands with a
zero size, but If UV coordinates are for example outside the 0-1 range,
it's better if they get moved into that range.
Differential Revision: https://developer.blender.org/D14522
|
|
Set the curve resolution to Bezier and Nurbs curves when converting
data using `curves_to_curve_eval`. This was missed in 9ec12c26f16ea3d.
Differential Revision: https://developer.blender.org/D14577
|
|
|
|
Add "for_write" on function names that retrieve mutable data arrays.
Though this makes function names longer, it's likely worth it because
it allows more easily using the const functions in a non-const context,
and reduces cases of mistakenly retrieving with edit access.
In the long term, this situation might change more if we implement
attributes storage that is accessible directly on `CurvesGeometry`
without duplicating the attribute API on geometry components,
which is currently the rough plan.
Differential Revision: https://developer.blender.org/D14562
|
|
Change uses of "Hair" in Render Settings UI in the property editor
and the "Hair Info" node to use the "Curves" name to reflect the
design described in T95355, where hair is just a use case of a more
general curves data type.
While these settings still affect the particle hair system,
the idea is that if we have to choose one naming scheme to align
with, we should choose the option that aligns with future plans
and current development efforts, especially since the particle
system is considered a legacy feature.
A few notes:
- "Principled Hair BSDF" is not affected since it's meant for hair.
- Python API property identifiers are not affected.
Differential Revision: https://developer.blender.org/D14573
|
|
The last length value was not initialized, and all length values were
moved one position towards the front of each curve incorrectly.
Also fix an assert when a curve only had a single point.
|
|
This deduplicates the code a bit.
|
|
This workaround is not needed since
228f7f1c850897cac85b2c4b42cf9052976b7be1
|
|
Differential Revision: https://developer.blender.org/D14471
|
|
This revision allows to specify CUDA host compiler (nvcc's -ccbin command
line option) when configuring the build. It addresses the case where the
C/C++ compiler to be used in CUDA toolchain should be different from the
default C/C++ compiler, for instance in case of compilers versions conflicts
or multiple installed compilers.
The new CMake option is named `CUDA_HOST_COMPILER` and can be used as follows:
`cmake -DCUDA_HOST_COMPILER=<path-to-host-compiler>`
If the option is not specified, the build configuration behaves as previously.
Differential Revision: https://developer.blender.org/D14248
|
|
This caused an ASAN report for new/delete type mismatch
when using the snake hook brush in curves sculpt mode.
|
|
When showing an action data-block added to a library overridden object
in the Graph Editor, the visibility toggles would be disabled.
Toggling the visibility should be possible still and works with the
shortcuts, just the button was incorrectly disabled.
Also added the usual disabled hint for the tooltip.
Differential Revision: https://developer.blender.org/D14568
Reviewed by: Bastien Montagne
|
|
Iterate over meta strip content and duplicate animation for all strips.
recursively.
|
|
This commit disables the 'last updated' value (which is the date the
sphinx doc is generated), and instead modifies the 'commit' field from
the 'html_context' data to get:
- a link to the commit itself.
- the date of that commit.
This avoids having the whole documentation detected as changed every
time it is re-generated by the buildbot.
Reviewed By: dfelinto, campbellbarton
Differential Revision: https://developer.blender.org/D14429
|
|
Original rework of caches during undo/redo (see D8183) had a very bad
flaw hidden in it: using the key of a ghash as source of data.
While this was effectively working then (cache pointer itself being part
of the key, and said cache pointers not being cleared on file write),
this is a general very bad way to do things.
Now that cache pointers are more and more cleared on file write (as part
of clearing runtime-data to reduce false-positives when checking if an
ID has changed or not), this has to be fixed properly by:
* Not storing the cache pointer itself in the IDCacheKey.
* In undo context, in readfile code trying to preserve caches, store the
cache pointers as values of the mapping, together with the usages counter
The first change potentially affects all usages of
`BKE_idtype_id_foreach_cache`, but in practice this code is only used by
memfile reading code (i.e. undo) currently.
Related to T97015.
Reviewed By: brecht
Maniphest Tasks: T97015
Differential Revision: https://developer.blender.org/D14559
|
|
|
|
Python exceptions are now shown in the info editor,
this also resolves an old bug where errors were printed twice.
This was originally based on D9752 by @ShadowChaser although many
changes have been made from the original patch.
Details:
- BPy_errors_to_report no longer prints additional output.
- BKE_report_print_test was added so it's possible to check if calling
BKE_report also printed to the stdout.
- Callers to BPy_errors_to_report are responsible for ensuring output
is printed to the stdout/stderr.
- Python exceptions no longer add a trailing newline,
needed to avoid blank-space when displayed in the info-editor.
|
|
Off by one error placing text from an error.
|
|
|
|
This avoids script authors using `eval("context.%s" % data_path)`
to access paths starting from the context,
which isn't good practice especially if the data_path isn't trusted.
Now it's possible to resplve paths such as:
context.path_resolve('active_object.modifiers[0].name')
|
|
Internally an empty string is used to access context member `__dir__`,
which caused `getattr(context, "")` to succeed returning None.
|
|
Access the keys of the collection instead of the layers names
and use a set to detect collisions. There is no need to access the
duplicate layers themselves. Roughly twice as fast.
|
|
Resolves deprecation warnings.
|
|
|
|
Ensures new members will be zeroed, the compiler is able to optimize
this into identical compiled output.
|
|
Ideally this wouldn't be needed, I couldn't find a good solution
to avoid casting when comparing const/non-const pointers in this case.
|
|
This is an internal usage parameter.
No functional changes.
|
|
The parameters indicating whether it is allocated are always `false` and
it is up to the caller to free them.
Also clang-format was triggered.
|