Ultimaker / Cura

3D printer / slicing GUI built on top of the Uranium framework
GNU Lesser General Public License v3.0
6.18k stars 2.08k forks source link

Zoom toward mouse direction in Orthographic mode of camera rendering. #7719

Open st4szek opened 4 years ago

st4szek commented 4 years ago

Please enable "zoom toward mouse direction" in orthographic mode of camera rendering.

Ghostkeeper commented 4 years ago

This was disabled because zooming towards the mouse direction works through changing the position of the camera ("dolly" mode), but that doesn't zoom things in orthographic mode due to the nature of the orthographic projection; things that are closer are not larger. In the orthographic projection we zoom by making the view angle smaller.

We'd need to implement it a second time, basically.

tsonis commented 4 years ago

Still, it's a basic feature for most (if not all) 3d programs, and it's pretty useful to have.

Benzolio commented 4 years ago

That always kinda bugged me that the camera zoom in perspective view changed the camera distance, because I often end up with the camera inside the model when I'm actually trying to see more detail on the outside. Zooming by changing the view angle seems a lot more natural to me to use. I'm sure there are users that prefer it that way, but it would really be nice to have the zoom toward mouse direction option in orthographic mode. Pressing the scroll wheel in to reposition is not that hard, but it does feel like something extra, since it can be handled in all my other 3d modeling software. If this alternate "zoom toward mouse" is to be implemented, I'd suggest also adding an "only zoom by view angle" option along with it to give the chance to use the new implementation in both perspective and ortho.

yepher commented 3 years ago

@Ghostkeeper do you have the commit where that was disabled?

I would really like it if the zoom followed the mouse. Currently, the zoom seems broken to me because it never zooms to a point I am personally interested in. I usually have to zoom then pan/tilt the view multiple times to see what I actually want to see.

It would actually be nice if there were a selection on the left that was just bed manipulation so dragging pans/tilts and scroll zooms the print bed.

2020-12-31 14 48 33

Ghostkeeper commented 3 years ago

This commit disabled the checkbox when the camera is in Orthographic mode: https://github.com/Ultimaker/Cura/commit/7f559987a03a8c968cb3db9a468b8931013adfa3

You can try to remove the enabled property and that Connections element to not disable the checkbox, but I think it's still not going to work then. We disabled it for a reason. If you'd like to take a hand at fixing the issue you're welcome to try though.

Dragging the middle mouse button pans the camera. Dragging the right mouse button tilts the camera. Scrolling zooms in or out. That's what I use, anyway.