Age | Commit message (Collapse) | Author |
|
Scaling handles while dragging could be distracting, especially at
extreme values where handles could become large on-screen.
Now all gizmos are shown while scaling.
GIZMO_GT_arrow_3d now now support changing their length while being
dragged as well as negative lengths.
|
|
This resolves a minor inconsistency displaying the scale gizmo handles
since they're cubes it's noticeable when they're not axes aligned.
|
|
When interacting with translate/rotate/scale gizmo, show the gizmo while
it's in use. There are some exceptions to this, as showing all scale
gizmos while scaling causes the gizmos to become large & distracting so
in this case only the gizmo being dragged is shown.
Resolves T63743.
|
|
Now gizmos forward the original event to transform so assuming an LMB
event is no longer needed.
|
|
This patch makes it possible to manipulate strips without need to use
update functions to recalculate effect and meta strips.
Prior to this change function `SEQ_time_update_sequence` had to be used
to update mainly effects and meta strips. This was implemented in a way
that relied on sorted list of strips, which can't always be done and in
rare cases this approach failed.
In case of meta strips, `seqbase` had to be passed and compared with
"active" one to determine whether meta strip should be updated or not.
This is especially weak system that is prone to bugs when functions are
used by python API functions.
Finally, other strip types had startdisp` and `enddisp` fields updated
by this function and a lot of code relied on these fields even if strip
start, length and offsets are available. This is completely
unnecessary.
Implemented changes:
All effects and meta strips are updated when strip handles are moved or
strip is translated, without need to call any update function.
Function `SEQ_time_update_sequence` has been split to
`SEQ_time_update_meta_strip_range` and
`seq_time_update_effects_strip_range`. These functions should be only
used within sequencer module code. Meta update is used for versioning,
which is only reason for it not being declared internally.
Sequence fields `startdisp` and `enddisp` are now only used for
effects to store strip start and end points. These fields should be
used only internally within sequencer module code.
Use function `SEQ_time_*_handle_frame_get` to get strip start and end
points.
To update effects and meta strips with reasonable performance, cache
for "parent" meta strip and attached effects is added to
`SequenceLookup` cache, so it shares invalidation mechanisms.
All caches are populated during single iteration.
There should be no functional changes.
Differential Revision: https://developer.blender.org/D14990
|
|
Mostly duplicate includes, also use nullptr, and using default
member initializers.
|
|
|
|
The logic of skipping selected handles was inverted
and confusing.
|
|
This limiting prevented visual keyframing from working correctly and is
not consistent with object rotation, so limiting is removed.
|
|
Avoid multiple `sound.bl_rna.properties["channels"].enum_items` in
the same line. Note we might want a way to avoid having to do this.
|
|
|
|
The change was kind of intentional on {rB21e72496a629}.
That commit made mouse movement to "select" the contraint in Auto
Constraint a requirement.
This deduplicated the code a bit, but this requirement is not
comfortable for the first "selection" of the contraint.
So the constraint "selection" is now done in two ways:
- If there is no contraint, the "selection" is done immediately;
- If there is already a constraint, the "selection" is delayed by 1 event to simulate a constraint cancellation if there is no mouse movement.
|
|
|
|
|
|
The shortcut is G-G.
Caused by loop argument "shadowing".
|
|
Switch from a single function with a lot of branching at its top level
to dedicated function calls with own documentation.
|
|
Pattern is expected to be freely resized to any size, and the search
area s to become bigger when needed.
Remove confusing pattern size clamping which was actually clamping
search area.
There should be no functional changes.
|
|
|
|
In rare cases the mesh has not been evaluated when snapping, this fix
just prevents the crash as is done elsewhere in Blender when the
evaluated mesh isn't available, there is a separate report (T96536)
about evaluation not working properly.
|
|
Regression in rBd2271cf939.
|
|
Use more robust logic for "Constrain to Image Bounds" when scaling UVs.
Reviewed By: campbellbarton
Ref D14882
|
|
|
|
Unlike 3Dview snapping, UV snapping is always done to the UV closest to
the mouse cursor, no matter the distance.
From the user's point of view, this appears to be an inconsistency (See
{T93538}).
Therefore, set a minimum distance for snapping and, as in 3D View and
highlight the snap with a drawing of a circle.
Release Note: https://wiki.blender.org/wiki/Reference/Release_Notes/3.3/Modeling
Reviewed By: #uv_editing, campbellbarton
Maniphest Tasks: T93538
Differential Revision: https://developer.blender.org/D13873
|
|
This was reported explicitly for originally being in face selectmode,
but could also crash when in vertex selectmode (when doing multiple
cuts).
The reason here is that `MESH_OT_loopcut` switches to edge select mode
(needed for `TRANSFORM_OT_edge_slide`, done in `ringsel_finish`), but was
only doing this on the active object's editmesh, all other participating
meshes would keep their selectmode which would now be out of sync with
both the active object's editmesh and scene settings for these.
This causes problems later in 'Select Linked'. Here, a mixture of
objects are used. First the viewcontext is set up with the active
object, then all participating objects are iterated (changing the
viewcontext to another object), then `unified_findnearest` would use that
changed viewcontext which would now contain the last object iterated. To
repeat: this could now have a different selectmode than the active
object which is later **again** used to get the nearest `BMElem` from in
`EDBM_elem_from_selectmode`. So in the failing case, we could get an
edge (but no face because of edge selectmode) from `unified_findnearest`,
`EDBM_elem_from_selectmode` would return NULL though (edge provided, but
in face selectmode), leading to the crash.
To solve this I assume it is best to change selectmode on all
participating meshes in multi-object editmode loopcut if necessary so
these are always in sync for following operations.
Alternatively, `Select Linked` (and probably lots more operators) would
have to be tweaked to pay closer attention which object is really used
to get selectmode from.
Note the selectmode is actually set back from edge selectmode in certain
cases (see `USE_LOOPSLIDE_HACK`), this patch changes that as well to act
on all participating meshes.
Maniphest Tasks: T95752
Differential Revision: https://developer.blender.org/D14791
|
|
Recent cleanups 9a8669ac81b99b2 and 1c790555a02bfc3
incorrectly interpereted the bitfield width syntax as a default
value. Also resolve two other compilation warnings.
|
|
When height is limited, it is defined by space occupied by strips,
but at least channels 1 to 7 will be always visible. This allows it to
easily overview timeline content by zooming out to maximum extent in Y
axis and panning in X axis.
More channels can be "created" on demand by moving strip to higher
channel. When strip is removed and highest channel becomes empty, view
will stay as is until it is moved down. Then new highest point is
remembered and it is not possible to pan upwards until strip is moved to
higher channel.
Limiting takes into account height of scrubbing and markers area as
well as scrollers. This means that when zoomed out to maximum extent,
no strips are obstructed by fixed UI element.
Fixes T57976
Reviewed By: Severin
Differential Revision: https://developer.blender.org/D14263
|
|
This patch adds the drag and drop strip previews in the VSE.
It also adds two new functions to the drag and drop API.
1. "draw_in_view" for callbacks that wants to draw elements in local viewport coordinates
2. "on_drag_start" that can be used for prefetching data only once at the start of the drag.
Reviewed By: Julian, Campbell
Differential Revision: http://developer.blender.org/D14560
|
|
|
|
Use C++ types instead of GHash to make code easier to read and simpler.
Differential Revision: https://developer.blender.org/D14758
|
|
|
|
Changes:
- Remove `BLI_memarena` (Use `MEM_cnew` and `MEM_delete` to allocate cached data)
- Implement `snap_object_data_mesh_free_ensure` and `snap_object_data_editmesh_free_ensure` and skip need to get original key Object for editmesh data
- Use `BMEditMesh` as key for editmesh `Ghash`
- Make a better distinction between `SnapObjectData`s. (`SnapData_Mesh` and `SnapData_EditMesh`)
|
|
Some of the enum values are a mixture of others and make it difficult
for the IDE to identify them.
Separating these values makes debugging easier.
|
|
The editing data of a `SURF`s is similar to that of Curves and should be supported for snapping.
But unlike Curve objects, for snapping, only support the nurb points if the object is in edit mode.
This matches the solution for Meshes and avoids having to create a kind
of "boundbox" for the SURF nurb points.
|
|
|
|
The problem is old.
rB52be06301257 (fixed by rB4b35d6950d4f) just masked it.
`Object->data`, on evaluated objects, is not a safe pointer to get
objects with the same `BMEditData`.
Use `Object->runtime.data_orig` instead.
|
|
Use `SEQ_relation_is_effect_of_strip` for checking effect-input
relationship where this is applicable.
|
|
This operator moves the view to show the selected visible strips.
Reviewed By: ISS
Differential Revision: https://developer.blender.org/D14222
|
|
|
|
Error in 5da02548e99ac67338cbdf2a5088261408f5e7bf
|
|
The `BMEditMesh` pointer is the same in the original or evaluated mesh.
Also a clang-format was missed.
|
|
In some cases, selected elements do not contribute to snapping.
So ignore these elements when creating the edit meshes bound box.
|
|
Meshes without loops are still valid for snapping.
|
|
Also ensure space around text in C-comment blocks.
|
|
|
|
Since effect strips can't be transformed directly, their selection had
to be forced in order to process them. This often failed in more
complicated scenarios, because there was no attempt to parse hierarchy
completely. In worst case only one effect in chain would be selected.
This code was marked by `XXX_DURIAN_ANIM_TX_HACK`.
Instead solution described above, a collection of strips that depend
on non effect strip position is built by function
`query_time_dependent_strips_strips` and it is stored in `TransSeq`.
In `flushTransSeq` this collection is iterated and transformation offset
is applied to effect strip animation. Strips in collection should be
consistent with true state of dependency and should be complete.
Functional changes:
- When 2-input effect strip changes position, animation is offset even
if only handles are moved. This only applies to 2-input effect however.
- Selection is not extended to include effect strips anymore. If effects
are to be moved, they must be selected manually. This is because
previously it was very hard to reorganize effects in chain, since moving
first strip in chain would always select anywhere from 1 to n effects.
So creating or filling gap in channel would almos always result in
collision especially if their order in timeline doesn't perfectly
represent their order in chain.
|
|
This workaround is not needed since
228f7f1c850897cac85b2c4b42cf9052976b7be1
|
|
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.
|
|
The `BVHCacheType bvh_cache_type` parameter defines specific
`BVHTrees` that cannot be customized.
So it doesn't make sense to pass this value to any
`*bvhtree_from_[...]_ex` function as the `BVHTrees` created in these
cases are custom and cannot be saved in the cache.
This also resulted in a nice cleanup in the code.
Differential Revision: https://developer.blender.org/D14479
|
|
|