Age | Commit message (Collapse) | Author |
|
This patch adds a to_curve method to the Object ID. This method is
analogous to the to_mesh method. The method can operate on curve and
text objects. For text objects, the text is converted into a 3D Curve ID
and that curve is returned. For curve objects, if apply_modifiers is
true, the spline deform modifiers will be applied and a Curve ID with
the result will be returned, otherwise a copy of the curve will be
returned.
The goal of this addition is to allow the developer to access the splines
of text objects and to get the result of modifier applications which was
otherwise not possible.
Reviewed By: Brecht
Differential Revision: https://developer.blender.org/D10354
|
|
This also fixes the issue reported in T85651.
Differential Revision: https://developer.blender.org/D10477
|
|
This makes the code more readable.
|
|
This is needed to support Python 3.10's Postponed annotation evaluation.
It also simplifies type checking.
|
|
|
|
|
|
|
|
|
|
Previously the same functions were used to both set and get the active
state for outliner tree elements. This has quite a few problems.
- It's hard to tell when data is changed or simply read
- It prevents using `const`
- The code is full of if statements, making it longer and less readable.
This commit replaces the `tree_element_type_active` and
`tree_element_active` functions with `_get` and `_set` variants. One
has const arguments and returns the active state, the other deals only
with setting the state. While this refactor results in slightly more
lines of code, the result is much better in my opinion.
This commit also removes unused variables from arguments of the affected
functions.
Differential Revision: https://developer.blender.org/D10232
|
|
This commit adds a simple string input node, intended for use in the
attribute workflow to make using the same attribute name in multiple
places easier. The node is function node similar to the existing vector
input node.
Ref T84971
Differential Revision: https://developer.blender.org/D10316
|
|
This makes the nodes look more consistent with the rest of the UI
by using the same split with right aligned labels as the property editor
and elsewhere. Additionally, for consistency, the "Type" part of some
dropdowns is removed. It already wasn't displayed everywhere, and
it gets redundant quite quickly.
|
|
|
|
The "Hide Collection" operators assigned to the number keys in edit mode
trigger a redraw of the outliner, but as an optimization, they do *not*
trigger a rebuild of the tree.
This optimization is valid because unlike the collection exclude toggle,
the heirarchy is not affected by collection visibility. However, it means
that currently you must trigger a rebuild to get the correct "grayed out"
status after using the operator.
Rather than trigger a rebuild in this case to solve the bug, this patch
moves the decision for whether to gray out the text of a tree element
to the draw step rather than the build step. This means that any change
to the corresponding properties doesn't require a full tree rebuild.
Note that changing the "hide_viewport" property from the outliner still
causes a tree rebuild. I think that's because of the checks in
`outliner_collection_set_flag_recursive_fn`.
That could be optimized in the future.
Differential Revision: https://developer.blender.org/D10240
|
|
0 cannot be used to initialize the whole settings struct.
|
|
Add the Simple subdivision option to Geometry nodes, as a new node
instead of part of the existing subdivision node because of future
backend changes to the Simple option. (See T85584)
https://developer.blender.org/D10409
|
|
|
|
This reverts commit 7ee518cf705fcebee2d110bfbb6bf00a0f170efb.
Causes T84869. The initial issue is less bad than this. We are looking into
alternative fixes for 2.93 (see D9854 and D9853).
|
|
Empty attribute names are just a recipe for problems.
|
|
As now is possible to use multiframe in Draw mode, the option to display only lines must be disabled.
|
|
This adds fuzzy search functionality to various input fields in Blender
where one can choose a value from many existing values (e.g. the
Vertex Group property in the Displace modifier).
Differential Revision: https://developer.blender.org/D10446
|
|
Following with the changes included to interpolate strokes of different number of points, a full review has been done in the interpolation tools.
* Interpolate now is a tool and not an operator. It was not logic to have this tool as a button.
* Interpolate tool parameters have been moved to topbar.
* Interpolate popover has been removed from topbar and interpolate `Sequence` operator has been moved to grease pencil menu.
* Interpolate Sequence now include a Redo panel.
* Interpolate tool now allows to select the strokes by pairs. This allows to interpolate any stroke with any stroke and not as before that it was only possible by drawing order. If no stroke is selected, the interpolation is done as before.
* Now is possible interpolate again if a previous keyframe exist. Before, it was impossible to interpolate two times in same frame and this made impossible to do the interpolation by groups of frames.
* New automatic option to `Flip strokes` if the stroke and end are not in the right position. Also the flip can be set manually for corner cases.
* Cleanup of menus related to interpolate.
* Fixed some bugs and removed parameters from scene because now all are tool or operator contained.
* Some code cleanup and function renames.
This commit also includes the some codebase to future implementation of the concept `Vertex Active` that now does not exist in grease pencil.
|
|
|
|
This patch implements the list panel system D7490 for FCurve modifiers.
The UI layouts are updated to make use of subpanels and to be consistent
with the rest of the interface, and easier to understand.
See the differential revision for screenshots.
This commit also significantly cleans up the FModifier UI code, and
improves, mainly by replacing the old button creation code is with
the newer interface API using RNA. In turn there is a bit of complexity
added because each FModifier has a separate panel.
Although reordering of FModifiers was not implemented before, we get
drag and drop basically for free here, so it is also included.
As noted in some older to do tasks, FModifiers aren't evaluated
in perfect order, which may be a point of improvement for the future.
Differential Revision: https://developer.blender.org/D7997
|
|
The problem was introduced fixing task T85035.
As the frame was set again when render, if there was a time modifier, the frame was not remaped to the right frame number.
|
|
|
|
|
|
|
|
Previously, functions would have to ask for every geometry type explicitely.
Using a vector is return type is fine. In practice this will probably never
allocate because of the small buffer optimization in vector.
|
|
Address issue raised by T77920
|
|
C/Python defined types were accessible but not exposed in dir(bpy.types)
|
|
This is needed to support `typing.get_type_hints`,
which expects each classes module to have a module '__dict__'.
|
|
|
|
This function will be used by multiple functions.
|
|
If the axes are aligned in auto pivot mode then the rotation axis would be (0,0,0).
We now fall back to the x axis in this case. If that fails, we fall back to the y axis.
Differential Revision: https://developer.blender.org/D10466
|
|
This makes it easier to use the api.
|
|
Previously, the density was set per point. That implies that when a
point has a non-zero weight, points might be distributed in all
connected polygons. By specifying the density per corner, this
limitation is removed. Note, per-point density maps (such as vertex
groups) can still be used. They will be adapted to the corner domain
without loss of information.
Differential Revision: https://developer.blender.org/D10461
|
|
See T77920
|
|
|
|
|
|
|
|
|
|
|
|
Crash happened in versioning code on NULL dereference in function
seq_convert_transform_crop() for Strip crop and transform
fields.
Strips created after rB1fd7b380f4cf were assumed to have crop and
transform always initialized, but this wasn't the case. This has been
fixed in 2.90, but not in versioning code.
Initialize these fields if they are not initialized already.
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D10463
|
|
Avoid look for frame if the actual frame is already available.
|
|
When edit using Onion skin, the edit line was missing.
|
|
E.g. steps to reproduce:
* Enter Vertex Paint mode
* In the tool settings, right-click > "Edit Source"
When creating a number slider via `layout.prop(..., slider=True)`, the UI code
would reallocate the number button to be a number-slider button. That's because
we now actually have different button data-structures for these (see
e6f0b60c2e911). The edit source code stored data based on the button pointers,
which didn't get updated after changing the type. The fix just adds this
updating.
|
|
This was added to assist upgrading scripts to Blender 2.8x,
now 2.9x is released there is no need to keep this block.
|
|
|
|
|
|
|