English Amiga Board


Go Back   English Amiga Board > Support > support.Other

 
 
Thread Tools
Old 22 January 2022, 23:18   #341
tomcat666
Retro Freak

tomcat666's Avatar
 
Join Date: Nov 2001
Location: Slovenia
Age: 48
Posts: 1,214
Unfortunetly it is not developed anymore. The native screen has much lower horizontal resolution but it will position the mouse to the furthest right on the new screen, it will not leave the mouse on the same position as on the previous screen... So for some reason it thinks the monitors are in the wrong order.
tomcat666 is offline  
Old 23 January 2022, 11:25   #342
Thomas Richter
Registered User
 
Join Date: Jan 2019
Location: Germany
Posts: 1,593
There are two aspects here I should clarify:

First, please understand that this utility is not part of P96 and not distributed as part of P96. It is solely authored by me and distributed by me. See also the ReadMe that came with it. Thus, please do not post at iComp, they are not related to this thing.

Second, a technical aspect, maybe I wasn't clear: If the mouse leaves the current screen, P96ScreenCx does two things: It first triggers a screen switch (ScreenToFront()), but this leaves the mouse position in its original place. Second, it moves the mouse to the opposide edge of the new screen to create the illusion that the two screens are side-by-side. This mouse movement is performed by synthesizing mouse movement events through a well-known mechanism of the input.device of a system. For a reason unclear to me, AmiStart seems to swallow these synthetic mouse movement events.

Long story short: I wouldn't know how to solve this problem. I cannot synthesize mouse movement events to push the pointer to the right place in any other way; the current way is the system way. However, I do not know the backgrounds of AmiStart well enough.

Thus, either do without Amistart, or do without P96ScreenCx, there is nothing what I can do, I am sorry.
Thomas Richter is offline  
Old 23 January 2022, 11:42   #343
tomcat666
Retro Freak

tomcat666's Avatar
 
Join Date: Nov 2001
Location: Slovenia
Age: 48
Posts: 1,214
Thank you for the explanation. Really appretitated... Will try debugging it with a friend, maybe he comes up with something
tomcat666 is offline  
Old 24 January 2022, 13:56   #344
tomcat666
Retro Freak

tomcat666's Avatar
 
Join Date: Nov 2001
Location: Slovenia
Age: 48
Posts: 1,214
Hi

My good friend Amigo/Binary helped with investigation of the issue. Thanks to him there is an elegant fix available.

In a nut shell there is no fault in either P96ScreenCX (as you thought) or AmiStart. The problem is that commodities.library itself removes the events it dispatches forward to the commodities and because it has a priority higher that intuition (int. has 50, commodities have 53) the intuition does not get the events anymore.

He fixed it by having an utility that listens for the same events with priority 51 and puts them back as soon as they arrive so the intuition finally gets them.

Works like a charm too.

If anyone wants the fix and the source, here it is :
http://pc.sux.org/tomcat/AmiStartP96ScreenCXFix.zip
tomcat666 is offline  
Old 24 January 2022, 15:06   #345
coldacid
WinUAE 4000/40, V4SA
coldacid's Avatar
 
Join Date: Apr 2020
Location: Candinavia
Posts: 439
You or your friend should get that uploaded on Aminet if it hasn't already been. Although seeing as it isn't a fix for P96ScreenCX exactly but rather a workaround for commodities, perhaps with a different name.
coldacid is offline  
Old 24 January 2022, 18:03   #346
a/b
Registered User

 
Join Date: Jun 2016
Location: europe
Posts: 573
Quote:
Originally Posted by coldacid View Post
You or your friend should get that uploaded on Aminet if it hasn't already been. Although seeing as it isn't a fix for P96ScreenCX exactly but rather a workaround for commodities, perhaps with a different name.
Not sure if it's needed though. Would like to get a clarification from Thomas first.
Namely, events get nullified because class=RAWMOUSE shouldn't have a subclass *afaik*, but his utility is setting it to $10 (couldn't find anything in 3.0 includes, so not sure whether it's some private intuition/input flag, or his own flag e.g. to be able to identify fake event later on when they get dispatched, or something else), which then results in commodities.library event handler at 53 to nullify them: if subclass is not 0 (plus some extra conditions for class=NEWPOINTERPOS that are irrelevant), that for RAWMOUSE events means nullification, and intuition at 50 doesn't get to have them.
a/b is offline  
Old 24 January 2022, 18:40   #347
Thomas Richter
Registered User
 
Join Date: Jan 2019
Location: Germany
Posts: 1,593
The commodities library does not filter input events out that go "downstream" to intuition, but only those that go to into its handlers, otherwise the commodity would not work at all. The value 0x10 is used here to achieve exactly that, it indicates that the event is "synthetic". The problem P96ScreenCx has to solve is that the synthetic mouse event created by the commodity should not trigger another "recursive" screen switch by the mouse reaching the other end of the screen as part of reaction on the event. The tool cannot know how many mouse ticks the mouse has to travel to reach the other end of the screen and thus may, without a further indication, trigger a switch.
Thomas Richter is offline  
Old 24 January 2022, 19:08   #348
a/b
Registered User

 
Join Date: Jun 2016
Location: europe
Posts: 573
Yeah, I understand that. They get removed when the app is running (it's using cx for event handling, I typically use either IDCMP or input.device so can't tell more about this first hand, and how to avoid it.. exe is ~1MB), but this could be generalized for an arbitrary app?
I did a test earlier with a prio=100 handler that sets subclass of those events to 0 and it doesn't work: events are perpetually generated (as you pointed out) and mouse becomes unusable.
However, wouldn't it be sufficient to use class+subclass+code+x+y combo (rawmouse, 0, nobutton, +/-4095, 0, all legit values) to correctly identify them with 99.9% repeating, and avoid a "problematic" private subclass that cx handler apparently doesn't like (it only allows documented subclasses: $00-$03 for class=NEWPOINTERPOS)?
Either way, I don't have a horse in this race, just an opinion about choosing between 2 evils.
a/b is offline  
Old 24 January 2022, 20:23   #349
Thomas Richter
Registered User
 
Join Date: Jan 2019
Location: Germany
Posts: 1,593
Actually, what I did there was all just too complicated. Please find a test version attached and please report back.
Attached Files
File Type: zip P96ScreenCx.zip (3.1 KB, 7 views)
Thomas Richter is offline  
Old 24 January 2022, 20:27   #350
tomcat666
Retro Freak

tomcat666's Avatar
 
Join Date: Nov 2001
Location: Slovenia
Age: 48
Posts: 1,214
Quote:
Originally Posted by Thomas Richter View Post
Actually, what I did there was all just too complicated. Please find a test version attached and please report back.
After quick tests on winuae and pistorm a500 everything seems to work fine with this version.
Thank you !

Last edited by tomcat666; 24 January 2022 at 20:33.
tomcat666 is offline  
Old 24 January 2022, 20:30   #351
a/b
Registered User

 
Join Date: Jun 2016
Location: europe
Posts: 573
Quote:
Originally Posted by Thomas Richter View Post
Actually, what I did there was all just too complicated. Please find a test version attached and please report back.
a/b is offline  
Old Yesterday, 07:45   #352
nagares
Registered User

 
Join Date: Dec 2017
Location: Germany
Posts: 9
Quote:
Originally Posted by gdonner View Post
He's asked the PVS author, Ralph Torchia, twice now for better code, but no answer.
I wrote with Ralph Torchia this night.
Sadly, he lost all Amigahardware including software and source codes in a flood.
If he still had it he would release it to the community.
nagares is offline  
Old Yesterday, 17:26   #353
gdonner
Ancient Amiga User

gdonner's Avatar
 
Join Date: Mar 2018
Location: Elkhart, IN USA
Posts: 184
Quote:
Originally Posted by nagares View Post
I wrote with Ralph Torchia this night.
Sadly, he lost all Amiga hardware including software and source codes in a flood.
If he still had it he would release it to the community.
OK, thanks for letting us know!
gdonner is offline  
 


Currently Active Users Viewing This Thread: 2 (0 members and 2 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
P96: What's the right way to do X? Warty Coders. General 2 21 December 2020 01:00
Providing 2 fire button support / cd32 joypad support amigapd request.Other 0 13 July 2015 18:20
Portaudio support (was: WinUAE support for ASIO drivers) Akira support.WinUAE 57 28 March 2009 22:15
Classic WB P96 Anubis project.ClassicWB 5 08 May 2006 15:30
amiga-news.de: Collected software-news Paul News 0 14 November 2004 16:50

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 09:27.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, vBulletin Solutions Inc.
Page generated in 0.09812 seconds with 15 queries