Blender Git Statistics -> Branches -> asset-browser-snap-dragging

"Asset-browser-snap-dragging" branch

Total commits : 22
Total committers : 1
First Commit : April 21, 2021
Latest Commit : September 14, 2021


Commits by Month

DateNumber of Commits
September, 20212
August, 20210
July, 20210
June, 20214
May, 20216
April, 202110

Committers

AuthorNumber of Commits
Julian Eisel22

Popular Files

FilenameTotal Edits
view3d_placement.c5
wm_dragdrop.c3
object_add.c3
space_view3d.c3
object.c2
WM_types.h2
WM_gizmo_types.h2
WM_api.h2
ED_view3d.h2
file_draw.c1

Latest commits Feed

September 14, 2021, 14:47 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
September 13, 2021, 16:14 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
June 13, 2021, 21:48 (GMT)
Adjustments to drag info drawing

* Change the "Add Named Object" drag into string to "Add Object". The "Named"
part is kinda useless info and relates to an implementation detail.
* Draw drag info closer to the cursor. Looked quite off before.
June 13, 2021, 20:06 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
June 13, 2021, 20:03 (GMT)
Fix merge error after last merge
June 5, 2021, 16:01 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
May 21, 2021, 00:52 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
May 11, 2021, 11:16 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
May 6, 2021, 19:45 (GMT)
Snap based on the bounding box when dropping, not origin

This makes the dropping use the object's bounding box for snapping, so
that it matches the bounding box we draw while dragging.

Not that this may have to be optional in future, there may be valid
cases to use the origin instead of the bounding box for snapping.
May 6, 2021, 12:34 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
May 4, 2021, 15:33 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
May 4, 2021, 14:56 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
April 30, 2021, 18:35 (GMT)
Fix crash when dragging emtpy into the 3D View
April 30, 2021, 10:43 (GMT)
Merge branch 'master' into asset-browser-snap-dragging
April 30, 2021, 00:25 (GMT)
Show a bounding box for object assets while dragging

Note: Object assets have to be saved with this commit or later for the bounding
box to appear.

Basic idea is:
* Store the bounding box (and related info) in the asset metadata.
* The bounding box has to be updated and written to custom properties of the
asset metadata.
* There's a new `AssetTypeInfo` struct, to set asset type dependent callbacks
or data (in future). ID types can conveniently define asset-type info as part
of their `IDTypeInfo` definition.
* The asset-type info can contain a custom callback to be executed before the
asset is saved. This is how the object can write its custom asset metadata.
* The dropbox can also register a callback to set properties for its
gizmo-group now. Used to copy
* The "placement plane" gizmo is scaled to the bounding box size too.
* For local ID assets, the data should be accessed directly, so the file
doesn't have to be saved to get the bounding box updated.

Also:
* Added proper gizmo group custom property support to C (was already supported
in Python, or in C with some hacking).
* Store the basis matrix (world matrix without parent or constraint transforms)
in the custom asset metadata. Used by the placement gizmo to scale the
bounding box to match the result visually when dropping.
* The preview image is disabled while dragging objects over the 3D view.
* The bounding box always snaps with its lower edge (Z axis) to the surface.
Snapping with other axes can be added still.
* However, actually dropping the object still uses the origin, so the drop
position may not match what the bounding box indicated. This could be changed
to also use the bounding box instead. Or the drawn bounding box should be
translated to respect the origin position.
April 29, 2021, 16:50 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
April 28, 2021, 20:48 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
April 26, 2021, 19:02 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
April 26, 2021, 12:38 (GMT)
Merge remote-tracking branch 'origin/master' into asset-browser-snap-dragging
April 22, 2021, 10:03 (GMT)
Basic snapping support for dropping objects

Uses the same snapping logic as the placement plane from the Add Object
tool, which means it matches the plane that we already draw as a
preview.

This is quite primitive at this point - you can't change options for the
snapping like the up-axis or the snapping target - but it already feels
quite great.
Another limitation is that it uses the origin of the dropped object to
place it, the bounding box should give better results in practice. This
is something we can add.

MiikaHweb - Blender Git Statistics v1.06
By: Miika HämäläinenLast update: Nov-07-2014 14:18 MiikaHweb | 2003-2021