pan gesture behaves randomly #103973

Open
opened 2023-01-18 15:24:56 +01:00 by Marco · 16 comments

System Information
Operating system: macOS-12.5-x86_64-i386-64bit 64 Bits
Graphics card: AMD Radeon Pro 5500M OpenGL Engine ATI Technologies Inc. 4.1 ATI-4.8.101

Blender Version
Broken: version: 3.4.1, branch: blender-v3.4-release, commit date: 2022-12-19 17:00, hash: 55485cb379

Short description of error
Hi,

On external monitor, two fingered pan gesture on a Mac touchpad behaves randomly between orbit and zoom

This happens when you use the default Orbit & Pan navigation settings. Most of the time it works correctly: You make a two fingered pan gesture and the camera view orbits. But once a while a two fingered pan gesture will zoom the camera view (instead of obiting). As if you are making a pinch gesture (which you are not). I have disabled the pinch gesture on the system level to rule out the possibility that the pinch gesture interferes with the pan gesture. It is not a pinch gesture conflict.

To me it looks like following is happening. It seems like that although you have multi-touch gestures enabled, the two fingered pan gesture is sometimes handled as if multi-touch gestures is disabled. (When you go to Input > Touchpad preferences and disable Multi-touch Gestures then the camera view always zooms when you make a two fingered pan gesture.)

This happens about once every minute, and sometimes even a couple times a minute. It's random. When it happens and you don't end the gesture (you keep your fingers down on the touchpad) then you can continue to zoom in and out by moving two fingers left and right. So once the pan gesture handler chooses to zoom instead of to orbit then it is locked in this zoom behaviour until you end the pan gesture.

Workaround: #103973 (comment)

**System Information** Operating system: macOS-12.5-x86_64-i386-64bit 64 Bits Graphics card: AMD Radeon Pro 5500M OpenGL Engine ATI Technologies Inc. 4.1 ATI-4.8.101 **Blender Version** Broken: version: 3.4.1, branch: blender-v3.4-release, commit date: 2022-12-19 17:00, hash: `55485cb379` **Short description of error** Hi, On external monitor, two fingered pan gesture on a Mac touchpad behaves randomly between orbit and zoom This happens when you use the default Orbit & Pan navigation settings. Most of the time it works correctly: You make a two fingered pan gesture and the camera view orbits. But once a while a two fingered pan gesture will zoom the camera view (instead of obiting). As if you are making a pinch gesture (which you are not). I have disabled the pinch gesture on the system level to rule out the possibility that the pinch gesture interferes with the pan gesture. It is not a pinch gesture conflict. To me it looks like following is happening. It seems like that although you have multi-touch gestures enabled, the two fingered pan gesture is sometimes handled as if multi-touch gestures is disabled. (When you go to Input > Touchpad preferences and disable Multi-touch Gestures then the camera view always zooms when you make a two fingered pan gesture.) This happens about once every minute, and sometimes even a couple times a minute. It's random. When it happens and you don't end the gesture (you keep your fingers down on the touchpad) then you can continue to zoom in and out by moving two fingers left and right. So once the pan gesture handler chooses to zoom instead of to orbit then it is locked in this zoom behaviour until you end the pan gesture. Workaround: https://projects.blender.org/blender/blender/issues/103973#issuecomment-79513

Hello. Have you checked if this is a problem only for the system you specified, or is it the same for other OS?

Hello. Have you checked if this is a problem only for the system you specified, or is it the same for other OS?
Author

No, I haven't tested this on any other platform. Unfortunately I don not have a Windows machine at hand.

No, I haven't tested this on any other platform. Unfortunately I don not have a Windows machine at hand.
Member

Hi, thanks for the report. Does it work after factory reset?: {nav File > Defaults > Load Factory Settings}
I don't whether navigation keymap with touchpad is same on both Windows or Mac.
Could you share touchpad + keys for viewport navigation?

Hi, thanks for the report. Does it work after factory reset?: {nav File > Defaults > Load Factory Settings} I don't whether navigation keymap with touchpad is same on both Windows or Mac. Could you share touchpad + keys for viewport navigation?
Author

@PratikPB2123 I have reset to factory settings like you suggest and then restarted Blender. And then I took the following screen grabs of my preferences. The key map is very long. Is there a better way to dump this information?

I'll give it a go with these factory settings and let you know if this issue persists. I don't know if previous versions of Blender also had this same behavior because I am not a frequent user of Blender. I use it once a while for 3d projects. The previous version that I have installed is 2.91.0.

https://archive.blender.org/developer/F14175815/image.png
https://archive.blender.org/developer/F14175822/image.png
https://archive.blender.org/developer/F14175832/image.png

@PratikPB2123 I have reset to factory settings like you suggest and then restarted Blender. And then I took the following screen grabs of my preferences. The key map is very long. Is there a better way to dump this information? I'll give it a go with these factory settings and let you know if this issue persists. I don't know if previous versions of Blender also had this same behavior because I am not a frequent user of Blender. I use it once a while for 3d projects. The previous version that I have installed is 2.91.0. https://archive.blender.org/developer/F14175815/image.png https://archive.blender.org/developer/F14175822/image.png https://archive.blender.org/developer/F14175832/image.png
Author

I just noticed that my personal customised preferences are reloaded when I restart Blender. So the screen grabs above reflect my personal preferences and not the factory default settings. I have taken thess new screen grabs that show the factory settings.

https://archive.blender.org/developer/F14175923/image.png
https://archive.blender.org/developer/F14175926/image.png
https://archive.blender.org/developer/F14175932/image.png

I just noticed that my personal customised preferences are reloaded when I restart Blender. So the screen grabs above reflect my personal preferences and not the factory default settings. I have taken thess new screen grabs that show the factory settings. https://archive.blender.org/developer/F14175923/image.png https://archive.blender.org/developer/F14175926/image.png https://archive.blender.org/developer/F14175932/image.png
Author

I've tested and this issue persists after resetting to factory settings. I should also mention that this happens in the Edit Mode. Often when I have zoomed in close to my mesh.

I've tested and this issue persists after resetting to factory settings. I should also mention that this happens in the Edit Mode. Often when I have zoomed in close to my mesh.
Member

I just noticed that my personal customised preferences are reloaded when I restart Blender.

If you close and reopen the blender, your old preferences are loaded . Please check without closing blender.


key map is very long. Is there a better way to dump this information?

Sorry I did not explain my question clearly. I only meant preferences for zoom, pan, orbit operation where this problem happen.

Is there a better way to dump this information?

Best way is to share userpref.blend file: https://docs.blender.org/manual/en/latest/advanced/blender_directory_layout.html?highlight=userpref#path-layout

> I just noticed that my personal customised preferences are reloaded when I restart Blender. If you close and reopen the blender, [your old preferences are loaded ](https://docs.blender.org/manual/en/latest/getting_started/configuration/defaults.html#:~:text=After%20loading%20the%20factory%20settings%2C%20the%20preferences%20won%E2%80%99t%20be%20auto%2Dsaved.). Please check without closing blender. - - - > key map is very long. Is there a better way to dump this information? Sorry I did not explain my question clearly. I only meant preferences for zoom, pan, orbit operation where this problem happen. > Is there a better way to dump this information? Best way is to share `userpref.blend` file: https://docs.blender.org/manual/en/latest/advanced/blender_directory_layout.html?highlight=userpref#path-layout
Author

I have reset to factory default settings and and tested again to be 100% sure. Yes, the issue persists even when the settings are reset to factory defaults. (The second set of screen grabs are of the situation with factory default settings.)

I have made a new observation. I can only reproduce this issue when I have Blender open on my external monitor. When I drag Blender to my notebook's native screen then this doesn't seem to occur. Are the gesture event's location relative to the screen space or the window space?

To reproduce this issue you must make a coupe pan gestures in succession. I believe it has to do with the orbit animation. When you "flick" then orbit animates and decelerates. Maybe it happens when the orbit is still animating while you start the next pan gesture.

When you end the two fingered pan gesture, by lifting your fingers, then the zoom makes an abrupt jump. Most of the time the jump is so small that you hardly notice it. But if this occurs and you don't end the gesture, leaving your fingers down, then you can control the zoom. Then you can zoom in and out about 10 meters.

I also noticed that some of Blender's dialog windows (like the preferences) are always positioned in a corner of my screen. When I move them to the center and close them, they will ope in the corner again when I open them. (Maybe this is related when the position is measured relative to the screen.)

I have attached my userpref.blend to this message.

userpref.blend

I have reset to factory default settings and and tested again to be 100% sure. Yes, the issue persists even when the settings are reset to factory defaults. (The second set of screen grabs are of the situation with factory default settings.) I have made a new observation. I can only reproduce this issue when I have Blender open on my external monitor. When I drag Blender to my notebook's native screen then this doesn't seem to occur. Are the gesture event's location relative to the screen space or the window space? To reproduce this issue you must make a coupe pan gestures in succession. I believe it has to do with the orbit animation. When you "flick" then orbit animates and decelerates. Maybe it happens when the orbit is still animating while you start the next pan gesture. When you end the two fingered pan gesture, by lifting your fingers, then the zoom makes an abrupt jump. Most of the time the jump is so small that you hardly notice it. But if this occurs and you don't end the gesture, leaving your fingers down, then you can control the zoom. Then you can zoom in and out about 10 meters. I also noticed that some of Blender's dialog windows (like the preferences) are always positioned in a corner of my screen. When I move them to the center and close them, they will ope in the corner again when I open them. (Maybe this is related when the position is measured relative to the screen.) I have attached my userpref.blend to this message. [userpref.blend](https://archive.blender.org/developer/F14179444/userpref.blend)
Author

This pan issue also occurs in the UV editor. When you move the texture, using a two fingered pan gesture, then the texture also randomly zooms in and out. It is easier to reproduce this issue in the UV Editor. I have made a screen recording to demonstrate this. Here I am making many two fingered pan gestures in sequence. Moving left and right only.

Screen_Recording_Pan_Issue.mov

This pan issue also occurs in the UV editor. When you move the texture, using a two fingered pan gesture, then the texture also randomly zooms in and out. It is easier to reproduce this issue in the UV Editor. I have made a screen recording to demonstrate this. Here I am making many two fingered pan gestures in sequence. Moving left and right only. [Screen_Recording_Pan_Issue.mov](https://archive.blender.org/developer/F14181801/Screen_Recording_Pan_Issue.mov)
Author

I can confirm with certitude that this issue only occurs when Blender is open on my external screen. When I move Blender to my native notebook screen then there is no issue with the gestures.

I can confirm with certitude that this issue only occurs when Blender is open on my external screen. When I move Blender to my native notebook screen then there is no issue with the gestures.

@Blixem

If these are "scroll wheel" events triggered for some reason, then you can try disable them in the Keymap editor, just search for "wheel" key.
You can try to run Blender with "--debug-events", you will see which events are triggered. See command line docs.
Try previous versions of the Blender to find a working one. https:*download.blender.org/release/

@Blixem If these are "scroll wheel" events triggered for some reason, then you can try disable them in the Keymap editor, just search for "wheel" key. You can try to run Blender with "--debug-events", you will see which events are triggered. See [command line docs](https://docs.blender.org/manual/en/latest/advanced/command_line/index.html). Try previous versions of the Blender to find a working one. [https:*download.blender.org/release/ ](https:*download.blender.org/release/)
Author

@jenkm Thank you for your suggestion to disable the scroll wheel zooming in the key mappings! This is a workaround that works. :-)

I have an older version 2.91.0 installed that I've used to test and it turns out it also has the same issue. So this problem has been around for longer. One time a crash occurred when I started a pan gesture using this version. So perhaps the following crash report Is related:

"Blender crashes occasionally when doing scroll gesture"
https://developer.blender.org/T84322

I also came across the following post which I thought is interesting because there I see a ISMOUSE_WHEEL(event_type) check defined.
"Fix WM_event_type_mask_test ignoring wheel and gesture events"
https://developer.blender.org/rB7a736854603b640ca2a384a6cf05d0afc7fbe6dd

Also the following line of code is interesting. Is the value of the mouse wheel between MOUSEPAN and MOUSESMARTZOOM? If this is the case then a scroll wheel event is treated as a gesture. This is a potential cause for an issue like that I am experiencing.

# define ISMOUSE_GESTURE(event_type) ((event_type) >= MOUSEPAN && (event_type) <= MOUSESMARTZOOM)

"WM: categorize smart-zoom as a gesture"
https://developer.blender.org/rB4ec0a8705b86e589c32fc532280dc2e443c87f84

To recapitulate:

On Mac OSX using an external monitor only. (Not tested on other platforms.) The two fingered pan gesture on the touchpad sometimes also triggers a scroll wheel event simultaneously (besides the pan event). Effect in the 3D view: Makes the 3D view orbit and zoom simultaneously. Effect in the Image View: Makes the image move and zoom simultaneously. Frequency: One out of four pan gestures on average.

The frame rate on my external screen is much lower. This can be of influence because the deltas of the events are also larger when the time between frames is larger.

Ruled out:
This is not a gesture conflict between the pan and the pinch gesture. Because the issue persists when the pinch gesture is disabled on the system level.
This is not related to the deceleration animation like I suggested before. And it is also not caused by making pan gestures in rapid succession. I know this because the issue also happens when you make a single pan gesture when the model or image is not animating.

@jenkm Thank you for your suggestion to disable the scroll wheel zooming in the key mappings! This is a workaround that works. :-) I have an older version 2.91.0 installed that I've used to test and it turns out it also has the same issue. So this problem has been around for longer. One time a crash occurred when I started a pan gesture using this version. So perhaps the following crash report Is related: "Blender crashes occasionally when doing scroll gesture" https://developer.blender.org/T84322 I also came across the following post which I thought is interesting because there I see a ISMOUSE_WHEEL(event_type) check defined. "Fix WM_event_type_mask_test ignoring wheel and gesture events" https://developer.blender.org/rB7a736854603b640ca2a384a6cf05d0afc7fbe6dd Also the following line of code is interesting. Is the value of the mouse wheel between MOUSEPAN and MOUSESMARTZOOM? If this is the case then a scroll wheel event is treated as a gesture. This is a potential cause for an issue like that I am experiencing. > \# define ISMOUSE_GESTURE(event_type) ((event_type) >= MOUSEPAN && (event_type) <= MOUSESMARTZOOM) "WM: categorize smart-zoom as a gesture" https://developer.blender.org/rB4ec0a8705b86e589c32fc532280dc2e443c87f84 To recapitulate: On Mac OSX using an external monitor only. (Not tested on other platforms.) The two fingered pan gesture on the touchpad sometimes also triggers a scroll wheel event simultaneously (besides the pan event). Effect in the 3D view: Makes the 3D view orbit and zoom simultaneously. Effect in the Image View: Makes the image move and zoom simultaneously. Frequency: One out of four pan gestures on average. The frame rate on my external screen is much lower. This can be of influence because the deltas of the events are also larger when the time between frames is larger. Ruled out: This is not a gesture conflict between the pan and the pinch gesture. Because the issue persists when the pinch gesture is disabled on the system level. This is not related to the deceleration animation like I suggested before. And it is also not caused by making pan gestures in rapid succession. I know this because the issue also happens when you make a single pan gesture when the model or image is not animating.

I would also point out that the logic to distinguish scrolling from the traditional mouse wheel and trackpad is basically incorrect in Blender.
See D8797: Fix for handing the NSEventTypeScrollWheel events for details. I'm not sure if that's the reason, but still.

I would also point out that the logic to distinguish scrolling from the traditional mouse wheel and trackpad is basically incorrect in Blender. See [D8797: Fix for handing the NSEventTypeScrollWheel events](https://archive.blender.org/developer/D8797) for details. I'm not sure if that's the reason, but still.
Member

Hi, so the wrong event is only triggered when blender is moved to external/secondary monitor.
@jenkm , thanks for the workaround. Do you've similar setup to verify the problem?

Hi, so the wrong event is only triggered when blender is moved to external/secondary monitor. @jenkm , thanks for the workaround. Do you've similar setup to verify the problem?

I don't have an external monitor, but I reproduced something similar by swiping with three fingers. It produces a series of TRACKPADPAN events and one WHEELUPMOUSE. Which doesn't look quite right.

It seems this is not the first such report: #95873, and I feel like the latest MacBook series is needed here.

I don't know how this all relates to an external monitor, but as I said above, you need to look at the D8797 patch first. There may be trackpad events that Blender will incorrectly handle like a mouse.

I don't have an external monitor, but I reproduced something similar by swiping with **three** fingers. It produces a series of TRACKPADPAN events and one WHEELUPMOUSE. Which doesn't look quite right. It seems this is not the first such report: #95873, and I feel like the latest MacBook series is needed here. I don't know how this all relates to an external monitor, but as I said above, you need to look at the [D8797](https://archive.blender.org/developer/D8797) patch first. There may be trackpad events that Blender will incorrectly handle like a mouse.
Member

I don't know how this all relates to an external monitor, but as I said above, you need to look at the D8797 patch first

Ok, thanks. I don't have required hardware/setup to check. Will ask in others to verify the bug and the fix you had proposed (D8797).

> I don't know how this all relates to an external monitor, but as I said above, you need to look at the D8797 patch first Ok, thanks. I don't have required hardware/setup to check. Will ask in others to verify the bug and the fix you had proposed (D8797).
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#103973
No description provided.