guillaumechereau / goxel

Goxel: Free and Open Source 3D Voxel Editor
GNU General Public License v3.0
2.73k stars 219 forks source link

Add shortcut to toggle orthographic view (Feature Request) #306

Open Enchoseon opened 1 year ago

Enchoseon commented 1 year ago

A very useful quality-of-life change would be a shortcut to toggle whether the current camera is orthographic.

Quickly switching between perspective and orthographic mode is helpful for visually seeing the relative dimensions and positions of things that's extra-useful when working with voxels (e.g. lasering through a wall of blocks without perspective distortion).

guillaumechereau commented 1 year ago

Is there any common used shortcut for this function in other editor?

Enchoseon commented 1 year ago

In Blender it's Numpad5.

In Maya it's ~1-2 clicks on the viewcube, iirc.

I find the Numpad5 shortcut to be the most convenient, but that might be my bias as a Blender user :)

guillaumechereau commented 1 year ago

But what if we don't have numerical keypad (like me!)

Currently the '5' shortcut is used to reset the view, I think I will change it to '6' and then assign 5 to toggle ortho/perspective.

guillaumechereau commented 1 year ago

OK I pushed a quick fix. I move the reset to the shortcut '0' for now.

One remaining issue is that the zoom is not correctly computed when we reset and so the scale of the image changes a lot when we do so.