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

TransformControls: Redesigned translation/scale modes and increased line thickness #22061

Merged
merged 9 commits into from
Jun 29, 2021

Conversation

mrdoob
Copy link
Owner

@mrdoob mrdoob commented Jun 29, 2021

Related issue: #22048

Description

We've had a few reports of people being confused with how the translation handles get inverted depending of the camera location so I decided to try a different design.

While I was at it I also made the lines thicker.

Live links:
https://raw.githack.com/mrdoob/three.js/dev/editor/
https://raw.githack.com/mrdoob/three.js/dev/examples/misc_controls_transform.html

Before:

Screen.Recording.2021-06-29.at.4.13.47.PM.mov

After:

Screen.Recording.2021-06-29.at.4.14.43.PM.mov

/cc @arodic

@mrdoob mrdoob added this to the r130 milestone Jun 29, 2021
@mrdoob mrdoob merged commit 3c6262f into dev Jun 29, 2021
@mrdoob mrdoob deleted the transform branch June 29, 2021 16:37
@arodic
Copy link
Contributor

arodic commented Jun 30, 2021

The purpose of the axis flipping was primarily to mitigate handle occlusion at various angles. For example, you can't pick x axis when its pointing away from the camera because it is occluded by other parts of the gizmo.

Flipping the axis at certain threshold was a neat solution but it had one problem - in flipped state it misrepresented the coordinate system directions. That is why I also flipped the arrow head to indicate the real direction of the axis. My understanding is that head flipping part confused some users not the axis flipping part.

Anyway, this new design looks nice but it has one problem. At some angles, the invisible picker geometry of the negative axis perfectly occludes another visible positive axis like in this image below. So if you hover the blue axis on the right you would expect z axis to get highlighted, but x gets highlighted instead.

Screen Shot 2021-06-29 at 10 59 31 PM

@arodic
Copy link
Contributor

arodic commented Jun 30, 2021

Another issue is object sorting and transparency.

Gizmo objects are rendered as transparent without depth write/test. I think this was to make the geometry always be visible no matter what is in the depth buffer.

I notice in this version sometimes geometry from the back gets rendered on top. Perhaps there is a way to fix this.

@mrdoob
Copy link
Owner Author

mrdoob commented Jun 30, 2021

@arodic Yeah, I noticed these issues too. It will definitely benefit of some iteration...

@nipmarsh
Copy link

nipmarsh commented Oct 5, 2021

The current version is really problematic because of these issues... In practice, the gizmo is unusable

@mrdoob
Copy link
Owner Author

mrdoob commented Oct 30, 2021

@nipmarsh I use it every day. Seems usable to me?

@nipmarsh
Copy link

@mrdoob The problems are linked to @arodic comments. I have 50 users using the previous version daily and when I updated it to the last one, all my users screamed at me... Depending on the camera view the previous version can adapt whereas the new one cannot... to grab translation plane, you have to move your camera which in practice made the gizmo not very efficient

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.

3 participants