MouseWheel issue - getCount stay at 0 with P3D, P2D renderer


#1

Hi everyone,

I experienced an issue using MouseWheel callback function on a raspberry Pi Model 3 b+ and processing 3.4.

The function is executed but the MouseEvent.getCount() method is returning 0 when I scroll up or down the wheel. I also tried the getAmount() method but it’s the same issue.

I tried to change the renderer mode (P3D, P2D, and nothing specified). It turns out that in the third case, with no render specified, the getCount() method returns the good value.

here the piece of code I used :

int count;

void setup() {
  size(800,600,P3D);
  //size(800,600,P2D);
  //size(800,600);
}

void draw() {
  background(0);
  fill(255);
  text("Mouse Wheel: " + count, width/2, height/2);
}

void mouseWheel(MouseEvent e) {
  count = e.getCount();
}

If you already experienced the same issue or if you have any idea on how to fix it please let me know :slight_smile:

Thank you guys !


#2

Hi VCorboliou,

I also get the same problem on my Pi 3 B+ and processing 3.3.7.2.

Maybe you should raise an issue on github?


#3

Hi jb4x,

Thank you for the answer, I wanted to test it on different versions of processing but I guess it’s worthless then.

You are right for github, I just did it.


#4

Thank you for reporting! See the issues discussion of Raspberry Pi drivers with gohai here: