Skip to content

Add config option for "camera" rotation navigation#956

Merged
phkahler merged 1 commit intosolvespace:masterfrom
robnee:camera
Feb 3, 2023
Merged

Add config option for "camera" rotation navigation#956
phkahler merged 1 commit intosolvespace:masterfrom
robnee:camera

Conversation

@robnee
Copy link
Contributor

@robnee robnee commented Mar 7, 2021

issue #325 requests an alternative to middle-button mouse navigation/rotation. What I think the user is asking for is an option to manipulate the camera instead of model when rotating, i.e. reversing up/down and left/right directions. This PR implements that feature (independent of turntable navigation) as a config option called "camera mouse navigation" (name could use some work). It drives me a little bit crazy but I think some are used to this and would welcome this option.

SS rotates the model when middle button dragging while some users expect
this operation to rotate the camera where left-right and up-down directions are
reversed instead.  This adds that option.
@hinell
Copy link

hinell commented Jan 17, 2022

image

An option to turn the turntable can be found in the config.

@phkahler
Copy link
Member

@hinell That option switches to a different style of rotation. The "camera" rotation is very different and acts as though your mouse is moving the camera rather than the model/sketch. So dragging to the right causes you to view the model from the right instead of rotating the model to the right which would show you the left side of it. At least that my understanding. Moving the model seems very natural to me and the idea of moving the camera would be confusing, but I can see where camera movement seems natural to some people and moving the model like we do now would be very confusing.

We'll revisit this soon. When this PR came along none of this was clear to me ;-)

@ruevs ruevs added this to the Version 3.2 milestone Jan 29, 2023
@ruevs
Copy link
Member

ruevs commented Jan 29, 2023

Note to self look at my pending reviews more often.
@phkahler this is pretty clean and looks nice, we should review/try it and consider it for 3.2.

if(SS.turntableNav) { // lock the Z to vertical
double sign = SS.cameraNav ? -1.0 : 1.0;
double s = 0.3*(PI/180)*scale*sign; // degrees per pixel
if(SS.turntableNav) { // lock the Z to vertical
Copy link
Member

@ruevs ruevs Jan 29, 2023

Choose a reason for hiding this comment

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

And also I think this fixes the CTRL-middle drag "hack" of turntable navigation.
#888 (comment)
#1307 (comment)

@ruevs ruevs self-requested a review January 29, 2023 02:19
@phkahler
Copy link
Member

phkahler commented Feb 1, 2023

As much as I hate it, I know people who want it find the existing behavior equally terrible ;-) It works fine for me on Linux and it's a really small PR!

@phkahler phkahler merged commit 3c91bf7 into solvespace:master Feb 3, 2023
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.

4 participants