Page 1 of 3

WaitLeftMouse takes 4 seconds to react on m68k

Posted: Wed Jan 02, 2019 1:20 pm
by asrael
Hi.

I have a small program. In the main loop it waits for 'WaitLeftMouse'.
There is a debug log before and after with timing.
Sometimes, or actually most of the time when I click in the window it takes ~4 seconds until the 'WaitLeftMouse' wakes up.
Any idea what's wrong there?


Manfred

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Wed Jan 02, 2019 6:33 pm
by airsoftsoftwair
Sounds weird... show some code please...

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Fri Jan 04, 2019 10:14 am
by asrael
It's pretty simple.

I've stripped it down to this:

Code: Select all

/*
Some @Xyz setup.
Most notably:
*/
@DISPLAY { Title = "", Width = 400, Height = 460, Color = #BLUE }

Repeat
	DebugPrint(GetDate(#DATELOCAL), "Waiting for left mouse...")
	WaitLeftMouse
	DebugPrint(GetDate(#DATELOCAL), Left mouse pressed.");
Forever
According to the log output 80% of the time from clicking left mouse to the second log output takes ages (subjective feeling).
If I click as soon as possible as the first log output appears, the second comes ~2 seconds later.


Regards,
Manfred

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Fri Jan 04, 2019 9:29 pm
by airsoftsoftwair
WaitLeftMouse() won't wake up until the left mouse button is up again. Are you releasing it immediately after clicking it?

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Sat Jan 05, 2019 7:19 pm
by asrael
I'm doing a mouse button click - press, and immediately release.
I've just tested again and the delay varies. But it's 2-4 seconds.
Which feels like an eternity.
On MorphOS there is no such delay.


Manfred

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Sat Jan 05, 2019 10:22 pm
by airsoftsoftwair
Weird. What system is this exactly? Which version of AmigaOS? Any patches?

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Sat Jan 05, 2019 10:51 pm
by asrael
This is on two Vampirized systems. A600 and A2000. Pretty much stock otherwise, previously 3.9, now 3.1.4.
I'll give it a try on a few more none Vampire systems.


Manfred

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Sun Jan 06, 2019 3:33 pm
by airsoftsoftwair
Yes, please test on a non-Vampire system as this looks very strange.

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Tue Jan 08, 2019 10:49 am
by asrael
OK, Tested on an A1200 with ACA card.
Seems like the delay is not present there.


Manfred

Re: WaitLeftMouse takes 4 seconds to react on m68k

Posted: Tue Jan 08, 2019 5:35 pm
by airsoftsoftwair
Hmm, strange. Unfortunately, I don't have a Vampire here for testing. Maybe report this issue to the Vampire team, I doubt that this is a Hollywood problem.