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

Pivot alignment #366

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

pgilfernandez
Copy link

Hi,

I've been working on this new feature the last two weeks. It's not finished yet but it is full feature ready so I thought it was the moment to show it.

Till now, the only graphical option to align the object pivot was by opening the contextual menu and selecting "Center pivot":

screenshot

I extended the geometry alignment widget to allow pivot alignment. In the way I restructured the dropdowns and renamed "Pivot" to "Geometry by Pivot" as it really aligns the geometry using the pivot as the center point.

Now "Pivot" option introduces real pivot alignment with options to align it to Scene, Last selected, Last selected pivot and Bounding Box (most common use):

menus

Please, have a look at the video showing them all:

pivot_alignment1.mp4

I would say the feature state is the following:

  • align pivot relative to his bounding box
  • align pivot relative to scene
  • align pivot relative to last selected
  • align pivot relative to last selected pivot
  • cleaning up not used functions and/or simplify it all
  • make them undoable/redoable
  • fix known issue: text object doesn't work properly when "align pivot relative to last selected pivot" (It kinda but not as expected)
  • fix known issue: null object make Friction to crash when aligning pivot to any relative to option...

Help is appreciated as the remaining tasks could make me fall into a maze and loose a lot of time for probably simple fixes that I don't reach to find.... BTW, I'll continue trying, hehehe.

Cheers

@pgilfernandez pgilfernandez marked this pull request as draft December 10, 2024 16:29
@rodlie
Copy link
Member

rodlie commented Dec 10, 2024

Cool, will take a look later today or in a couple of days (a bit busy this week).

@rodlie
Copy link
Member

rodlie commented Dec 10, 2024

Note we are in a feature freeze, but depending on how intrusive this change will end up I may allow it in v1.0.

@pgilfernandez
Copy link
Author

Note we are in a feature freeze, but depending on how intrusive this change will end up I may allow it in v1.0.

Yes, I know... anyway, in case you decide to postpone it there is a chance to just add support for "align pivot relative to bounding box", that was the original feature I was going to add but I found myself going deeper and deeper creating more features...

@rodlie
Copy link
Member

rodlie commented Dec 10, 2024

As long as it does not touch anything related to load/save (project format) or introduce bugs/crashes this might end up in v1.0. I don't want to release another beta so it has to be RC-ready when/if merged into main.

Will have to look at the changes and what is marked as not done and how to fix that.

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

Successfully merging this pull request may close these issues.

2 participants