This shows you the differences between two versions of the page.
|Next revision||Previous revision|
redirecting_20the_20vdu_20commands_20to_20a_20sprite [2020/06/05 11:31]
alex_farlie Inital page...
redirecting_20the_20vdu_20commands_20to_20a_20sprite [2020/06/05 11:52]
alex_farlie Delete - Duplicate
|Line 1:||Line 1:|
|-||(Based on the code posted by Richard Rusell at Stardot forums - https://stardot.org.uk/forums/viewtopic.php?f=54&t=19564&p=272049#p272049)||+||#REDIRECT [[Drawing to an in-memory bitmap/texture]]|
|-||When writing programs that are likely to use the same graphics repeatedly, it can be avdanatagous to plot the graphics once, and reproduce it many times. Thus the situation may arise where it is desired to redirect the VDU drivers to plot somewhere other than the main output window.||+|
|-||This can be done by selecting an appropriate 'alternative' bitmap (BB4W) or Texture (BBC Basic for SDL) into the relevant device/rendering context (@memhdc%). BB4W uses a Windows "device context", wheres as BBC Basic for SDL uses an SDL "rendering context".). SYS calls are be used, and the calls used differ between the two dialects. (INKEY(-256) can be used to determine which dialect is in use.||+|