DQBgetCol
SUB

Prototype

DECLARE SUB DQBgetCol (BYVAL Col, Red, Green, Blue)

Parameters

Col - Color index to retrieve data from

Red - INTEGER variable where to store the red hue

Green - INTEGER variable where to store the green hue

Blue - INTEGER variable where to store the blue hue

Returns

none

Description

Gets the red, green and blue hues of the given color and stores them into the Red, Green and Blue INTEGER variables. Hues ranges from 0-63.

Notes:

See also DQBsetCol

Example

*****************************************************************************

' All integers for speed
DEFINT A-Z

'$INCLUDE:'DIRECTQB.BI'
DIM r, g, b

' Let's initialize the library with no extra layers nor sounds nor EMS
IF DQBinit(0, 0, 0) THEN DQBclose: PRINT DQBerror$: END

DQBinitVGA

' Gets the hues for color 2 (dark green in default BIOS palette)
DQBgetCol 2, r, g, b

PRINT "Color 2 hues:"
PRINT "Red:", r
PRINT "Green:", g
PRINT "Blue:", b

' Waits for the user to press a key
WHILE INKEY$ = "": WEND

' Ends program
DQBclose

*****************************************************************************