Silverfrost Forums

Welcome to our forums

Graphics overwriting when colour mode is \"RGB\"

25 Feb 2015 11:58 #15732

I have inherited code in 'VGA' colour mode which I wish to update to us FTN95 7.1, 'RGB' colour mode. It allows transient 'overwriting' of the graphics window by setting the VGA pen to (colour + 128) - used for drawing a 'rubber-band' box to show an area of a map to be selected while moving the cursor. Is there an equivalent trick in 'RGB', or has anyone a method for doing the equivalent.

25 Feb 2015 12:08 #15733

If I understand your question, call set_graphics_selection@ (1) should do what you are requiring. This requires you to hold down the left mouse button while selecting the region.

John

25 Feb 2015 3:16 #15736

What you are doing is a manual version of John's suggestion.

Two other alternatives are to set VGA mode, or perhaps better as you want to go for te full benefits of RGB, then use the:

SUBROUTINE GRAPHICS_WRITE_MODE@(MODE)

with MODE=3, which is XOR. THat means you write the square shape once and it appears, but the next time you write it, it disappears.

Eddie

26 Feb 2015 10:38 #15756

Thanks Eddie/John.

I'll try the GRAPHICS_WRITE_MODE as I don't want to change how the user interacts with screen.

David

4 Mar 2015 6:33 #15798

XOR is 'exclusive OR' that is 'one or other but not both'.

Please login to reply.