Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draw fish bones for Path3D and Path2D in the Editor #68860

Merged
merged 1 commit into from
Dec 6, 2022

Conversation

xiongyaohua
Copy link
Contributor

@xiongyaohua xiongyaohua commented Nov 18, 2022

Visualize Path3D direction and tilt with the so called fish bones.

image

For Path2D

Screenshot 2022-11-19 at 15 21 47

For more details, see godotengine/godot-proposals#5716 and godotengine/godot-proposals#5811

@TokageItLab
Copy link
Member

See also #68873

@xiongyaohua xiongyaohua requested review from a team as code owners November 19, 2022 07:06
@xiongyaohua xiongyaohua changed the title Draw fish bones for Path3D in the Editor Draw fish bones for Path3D and Path2D in the Editor Nov 19, 2022
@xiongyaohua
Copy link
Contributor Author

xiongyaohua commented Nov 19, 2022

See also #68873

I think that PR is a good complement to this one. Even better, this PR didn't touch any code related with gizmo handles, so both PR should be trivial to merge.

@xiongyaohua
Copy link
Contributor Author

xiongyaohua commented Nov 20, 2022

Change the visual of 3D bones, to keep it consistent with 2D bones. Since the 2D bones are facing left and right, the 3D bones do the same. But in 3D we also need to indicate the up direction, so smaller bones pointing up are added.

Screenshot 2022-11-20 at 07 58 02

If #68873 were merged, we can remove the up bone, as the up direction will be indicated by the "disk" gizmo.

scene/2d/path_2d.cpp Outdated Show resolved Hide resolved
Copy link
Member

@mhilbrunner mhilbrunner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feature approved in today's PR meeting, needs review by @godotengine/3d-editor

Comment on lines 261 to 262
// Is this BUG still relevant? Seems not.
// BUG: the following won't work when v3s, avoid drawing as a temporary workaround.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment should likely be removed if this is not a problem anymore.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed

@xiongyaohua
Copy link
Contributor Author

Small Tweak of 2D bones

new
image

old
image

@xiongyaohua
Copy link
Contributor Author

squashed.

@xiongyaohua
Copy link
Contributor Author

xiongyaohua commented Dec 5, 2022

@mhilbrunner Feature approved in today's PR meeting, needs review by https://github.com/orgs/godotengine/teams/3d-editor

Hi, is there any progress on this front? If there is no major problem is it possible to merge it for now. Minor problems or tweaks(if any) can be fixed in my followup PRs. I plan to do further refactor, improving the usability of Curve3D and CSGPolygon3D, which depends on this PR.

These fish bones are add to indicate the direction and local transforms alone the path.
@akien-mga akien-mga merged commit 14861c4 into godotengine:master Dec 6, 2022
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants