{{htmlmetatags>metatag-robots=() metatag-title=(RASTER AT | ugBASIC User Manual) metatag-keywords=(ugBASIC,Commodore 64,Commodore PLUS/4,ZX Spectrum) metatag-description=(Manual page for RASTER AT) metatag-media-og:image=(:ugbasic:logo-ugbasic-fb.png) metatag-og:title=(RASTER AT | ugBASIC User Manual) metatag-og:description=(Manual page for RASTER AT) }} ====== ugBASIC User Manual ====== ===== RASTER AT ===== ===== SYNTAX ===== RASTER AT line WITH label RASTER label AT line ==== PURPOSE ==== The ''RASTER AT'' instruction will set the next execution raster line for a raster routine. A raster routine is a small program or sequence of instructions that uses a particular moment in the screen display to be activated. This is when the electron beam (the raster beam) scans the screen, line by line, to draw the image. The mechanism is simple. The computer generated an interrupt (a signal that stopped the main program being executed) every time the raster beam reached the given line on this instruction. When the interrupt occurred, the processor passed execution to the raster routine. The routine directly does something, like modify the video memory o registers. Once the change was complete (by using the instruction ''NEXT RASTER''), the processor would resume execution of the main program from where it had stopped. Using this mechanism, programmers could create very simple, but often surprisingly engaging, graphics, animations, and games, considering the hardware limitations of the time. They were essential for creating effects such as scrolling, moving sprites around the screen, creating explosion or deformation effects. Raster routines offers very precise control over image generation, allowing for customized and optimized effects, and stimulated the creativity of programmers, who could invent new ways to exploit the mechanism to create innovative visual effects. ==== EXAMPLE ==== RASTER AT #&H42 WITH rasterRoutine RASTER AT (rasterLine+1) WITH rasterRoutine ==== ABBREVIATION ==== RstAt ==== AVAILABLE ON ==== * Commodore 128 (MOS 8502) * Commodore 64 * Commodore VIC-20 * Commodore 64+REU * Commodore PLUS/4 ==== SEE ALSO ==== [[NEXT RASTER]] [[NEXT RASTER AT]] ==== ANY PROBLEM? ==== If you have encountered a problem using this command, if you think there is a bug or the explanation is unclear, please [[https://github.com/spotlessmind1975/ugbasic/issues/new?title=ISSUE ON RASTER AT|open an issue]] for this keyword on GitHub. Thank you!===== POWERED BY ===== [[:ugbasic:user:index|{{ :ugbasic:user:logo-ugbasic.png?nolink&600 |}}]]