Mouseover = light pen X-Y?
Moderator: Moderators
-
- Vic 20 Drifter
- Posts: 34
- Joined: Thu Jul 15, 2021 10:50 pm
- Location: Rapid City, SD
- Occupation: Machine Shop Lackey
Mouseover = light pen X-Y?
Does VICE or any other Vic emulator translate the mouse position over the emulated screen to light pen X,Y?
Works in Progress: Gravity Ball, a breakout variant in assembly for the unexpanded vic-20
- Mike
- Herr VC
- Posts: 5134
- Joined: Wed Dec 01, 2004 1:57 pm
- Location: Munich, Germany
- Occupation: electrical engineer
Re: Mouseover = light pen X-Y?
Indeed VICE supports light pen emulation with the mouse. You find it in the "Settings ..." menu.
Here you find a example application, MINISKETCH.
Note the physical resolution of the lightpen (registers) has a 4-pixel granularity in X and a 2-pixel granularity in Y direction. It also needs some quite involved code to check whether the lightpen is it at the screen at all (I use a simulated lightpen event at a Y position outside the visible screen for this).
Finally, the lightpen needs a bright background to work properly - using a black background is no good idea.
Here you find a example application, MINISKETCH.
Note the physical resolution of the lightpen (registers) has a 4-pixel granularity in X and a 2-pixel granularity in Y direction. It also needs some quite involved code to check whether the lightpen is it at the screen at all (I use a simulated lightpen event at a Y position outside the visible screen for this).
Finally, the lightpen needs a bright background to work properly - using a black background is no good idea.
