Age | Commit message (Collapse) | Author |
|
With temporary I mean that this is not intended to be part of the
eventual asset system design. For that we are planning to have an
`AssetRepresentation` instead, see T87235. Once the `AssetList` is
implemented (see T88184), that would be the owner of the asset
representations.
However for the upcoming asset system, asset browser, asset view and
pose library commits we need some kind of asset handle to pass around.
That is what this commit introduces.
Idea is a handle to wrap the `FileDirEntry` representing the asset, and
an API to access its data (currently very small, will be extended in
further commits). So the fact that an asset is currently a file
internally is abstracted away. However: We have to expose it as file in
the Python API, because we can't return the asset-handle directly there,
for reasons explained in the code. So the active asset file is exposed
as `bpy.context.asset_file_handle`.
|
|
For the Asset Browser, this returns the active asset library of the
Asset Browser, otherwise it returns the one active in the workspace.
This gives simple access to the active asset library from UI code and
Python scripts. For example the upcoming Pose Library add-on uses this,
as well as the upcoming asset view template.
|
|
This per-workspace active asset library will be used by the asset views
later. Note that Asset Browsers have their own active asset library,
overriding the one from the workspace.
As part of this the `FileSelectAssetLibraryUID` type gets replaced by
`AssetLibraryReference` which is on the asset level now, not the
File/Asset Browser level. But some more work is needed to complete that,
which is better done in a separate commit.
This also moves the asset library from/to enum-value logic from RNA to
the editor asset level, which will later be used by the asset view.
|
|
Update vertex weights between simulation steps if they have changed.
This allows for animated vertex weights in the cloth sim.
Reviewed By: Sebastian Parborg
Differential Revision: http://developer.blender.org/D11640
|
|
The `__enter__` function of the `bpy.data.libraries.load` context manager
was storing a pointer to a stack-allocated variable, which was subsequently
used in the `__exit__` function, causing a crash. This is now fixed.
Thanks @Severin for the patch.
|
|
.rst file.
If text strips have the same start frame but are stacked on top of each
other in different channels the order in which they are written in the
.rst file was random before.
Reviewed By: Richard Antalik
Differential Revision: https://developer.blender.org/D11903
|
|
parameter.
|
|
|
|
Match the same shortcut for the 3D view & UV editor.
|
|
Mainly naming (also droping the `layer_collection` in favor of just
`layer` for internal code, this is clear enough and much shorter). Add
proper parent/child identifiers, `r_` prefix for parameters also used as
return values, etc.
Also made some parameters const.
|
|
This was a regression in rBc27ef1e9e8e663e02173e518c1e669e9845b3d1f.
|
|
The original refactor for vertex groups (3b6ee8cee708)
forgot to bump the minimum file requirement.
I'm also bumping the subversion to 12 so everyone can switch to a
working subversion number.
Differential Revision: https://developer.blender.org/D11931
|
|
This was a regression in rB3b6ee8cee7080af200e25e944fe30d310240e138.
|
|
This makes node trees with long links that cross other nodes easier to work with.
Dimmed links will be ignored by various modal operators like cut and reroute insertion.
Differential Revision: https://developer.blender.org/D11813
|
|
|
|
This shows the text as part of the assertion message.
|
|
|
|
|
|
Useful when TLS requires it's own allocated structures.
|
|
Useful when thread-local storage has it's own memory arena containing
data which is kept after the multi-threaded operation has finished.
|
|
This logic is from the curve sundivide node, used to add points with
proper handles in between two existing points. However, the same logic
is used for trimming of Bezier splines, and possibly interactive point
insertion in the future, so it's helpful as a general utility.
The logic is converted to depend on a bezier spline instead of being
static. A temporary segment spline can be used for the latter use case.
|
|
No behavioral change expected here.
|
|
This adds id_properties_clear() and id_properties_ensure() functions
to RNA structs. This is meant as an initial change based on discussion
in review of D9697. However, they may be useful in other situations.
The change requires refactoring the internal idproperties callback to
return a pointer to the IDProperty pointer, which actually turns out
to be quite a nice cleanup.
An id_properties attribute could be added in the future potentially.
Differential Revision: https://developer.blender.org/D11908
|
|
The BKE_gpencil_stroke_add_points API function worked well for
creating the primitives in the add object menu, but it expected a
specific data format that doesn't make sense in a dynamic context.
As evidence of that we can see the way source data was duplicated
in the line art file just to use this API function.
This commit solves that problem in two ways:
- Clean up the line art function (this should make it faster too).
- Move/rename the function so its intended use is more clear.
Differential Revision: https://developer.blender.org/D11909
|
|
properties.
Non-pointer-like properties that are not editable should never generate
override operations.
While harmless (those would never be applied back anyway), better not
clutter override operations list, and also enjoy the symbolic
performances improvement here.
NOTE: Pointer-like properties (pointers and collections) remain
processed as usual here since they usually imply recursivity. We could
make an exception to the exception for ID pointers, but for now I don't
think this is worth it.
|
|
Issue would happen when the original, linked data already had 'Disk Cache'
setting enabled. Override would then see no difference with linked data,
and not create any rule for it (as expected).
Root of the issue was that in Cloth modifier copy code, those disk cache
settings were not copied at all, so every time local overrides were
re-generated by copying linked data, those flags would be reset to their
default values.
NOTE: this might exist in other PointCache usages as well, but this code is
in such a bad state that I'd rather do minimal strictly needed changes
there, on a case-by-case basis. Proper recode of that whole system is
wayyyyy out of scope here.
|
|
|
|
When image strip is added from python using `image_strip_add` operator
and directory path is not terminated with slash, last part of directory
was ignored.
Use `BLI_join_dirfile` instead of simple string concatenation.
|
|
Found loading a cycles-x .blend file saved with different integer values for
enum items.
|
|
Constraining to X axis caused snapping to not work at all. Constraining
to Y axis caused snapping indicator to be drawn, when snapping doesn't
occur.
Reviewed By: mano-wii
Differential Revision: https://developer.blender.org/D11898
|
|
nodes or sockets" error
rBfe22635bf664 introduced a utility to check for this (but it was always
returning true).
This wasnt a problem in master (since it is unused there), but in the
2.93 branch, this utility is actually used and the error results in all
geometry nodetrees to appear with the "Node group has unidentified nodes
or sockets" message (and being unusable).
Now return false in has_undefined_nodes_or_sockets if all nodes and
sockets have been successfully checked.
This commit then needs to end up in the 2.93 branch.
Maniphest Tasks: T89851
Differential Revision: https://developer.blender.org/D11911
|
|
Differential Revision: https://developer.blender.org/D11851
|
|
Socket inspection helps with debugging a geometry node group.
Now, when hovering over a socket, a tooltip will appear that provides
information about the data in the socket. Note, socket inspection only
works for sockets that have been computed already. Nodes that are not
connected to an output are not computed.
Future improvements can include ui changes to make the tooltip look
more like in the original design (T85251). Furthermore, additional
information could be shown if necessary.
Differential Revision: https://developer.blender.org/D11842
|
|
The bake animation was not using the remap of time done by grease pencil time modifier.
|
|
Use more direct access to next/previous vertices.
- `BM_edge_other_vert(l_curr->e, l_curr->v)` -> `l_curr->next->v`.
- `BM_edge_other_vert(l_curr->prev->e, l_curr->v)` -> `l_curr->prev->v`.
Add asserts to keep the intention clear.
|
|
Depending on the modifiers, geometry can be destructive which is not safe.
|
|
Adds full frame implementation to this node operations.
No functional changes.
2.5x faster than tiled fallback on average.
Reviewed By: jbakker
Differential Revision: https://developer.blender.org/D11690
|
|
Adds full frame implementation to this node operation.
No functional changes.
|
|
Not causing issues in current master because all buffer areas are at
(0, 0) position and `Extend` is not used. But areas may be at any
position in future developments and it will crash.
Reviewed By: jbakker
Differential Revision: https://developer.blender.org/D11784
|
|
Link sockets are always connected to inserted translate or scale
operation `Color` sockets even when they have different data type.
This causes crashes on full frame mode when operations read inputs
with non expected datatypes.
Because data type conversions need to be executed before, convert
resolutions must ensure same datatypes are linked.
|
|
This commit moves the storage of `bDeformGroup` and the active index
to `Mesh`, `Lattice`, and `bGPdata` instead of `Object`. Utility
functions are added to allow easy access to the vertex groups given
an object or an ID.
As explained in T88951, the list of vertex group names is currently
stored separately per object, even though vertex group data is stored
on the geometry. This tends to complicate code and cause bugs,
especially as geometry is created procedurally and tied less closely
to an object.
The "Copy Vertex Groups to Linked" operator is removed, since they
are stored on the geometry anyway.
This patch leaves the object-level python API for vertex groups in
place. Creating a geometry-level RNA API can be a separate step;
the changes in this commit are invasive enough as it is.
Note that opening a file saved in 3.0 in an earlier version means
the vertex groups will not be available.
Differential Revision: https://developer.blender.org/D11689
|
|
With this option enabled, updating the geometry is no longer deform only.
|
|
|
|
Only DNA_customdata_types.h is needed for BMEditMesh.
|
|
|
|
Also remove white-space added last commit.
|
|
- Make the variable to store the name 'static'.
- Use STRNCPY macro.
- Set the first character to nil instead of memset for the while string.
|
|
When adding texts or various simple effects I often copy-paste strips
to reuse properties from a template such as font or position. I assume
this is common workflow. Issue with this workflow is, that active strip
is not changed after pasting, so when adjusting property, it is original
strip that is being modified.
This is not issue when duplicating strips - selection state is
transfered to duplicate strips, such that duplicate of active strip is
set to be active and duplicate of selected strip is set to selected.
Implement same selection transfering behavior in paste operator, that
exists in duplicate operator.
Since strip can be deleted after copying, it is not possible to rely
on sequencer state. This is true even when pasting strips to different
scene. Therefore active strip name must be stored in clipboard.
Reviewed By: sergey, Severin
Differential Revision: https://developer.blender.org/D11781
|
|
Caused by fba9cd019f21, then fixed by 0e4245bc28e6, but without
subversion bump, so some files were still broken after fix.
Repeat fix again, but this time also bump subversion.
Reviewed By: mont29
Differential Revision: https://developer.blender.org/D11864
|
|
|