Pabulum Graphics Library version 1.0 Library Reference All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted by any means, electronic, mechanical, photocopying, recording, or otherwise, without express written permission from Sergio Fernandez. The software described in this publication is furnished under a license agreement and may be used or copied only in accordance with the terms of that agreement. This publication and its associated software are sold without warranties, either expressed or implied, regarding their merchantability or fitness for any particular application or purpose. The information in this publication is subject to change without notice and does not represent a commitment on the part of Sergio Fernandez. In no event shall Sergio Fernandez be liable for any loss of profit or any other commercial damage, including but not limited to special, incidental, consequential, or other damages resulting from the use of or the inability to use this product. All brand and product names mentioned in this publication are trademarks or registered trademarks of their respective holders. C O N T E N T S Introduction 1 GetCursor .......... 14 What's in this manual ........... 1 GetCursorX ......... 14 GetCursorY ......... 14 Part 1 Programmer's Reference GetDacs ............ 14 GetError ........... 15 Chapter 1 - Reference lookup 2 GetFHeight ......... 15 Sample procedure ................ 2 GetFWidth .......... 15 BackGroundLink .................. 2 GetImage ........... 16 BackGroundRemove ................ 3 GetJoystickButton .. 16 ChangeCursor .................... 3 GetJoystickX ....... 16 Circle .......................... 3 GetJoystickY ....... 16 Circle3D ........................ 4 GetMaxColor ........ 17 ClearKeyBoard ................... 4 GetMaxX ............ 17 ClearViewPort ................... 4 GetMaxY ............ 17 CopyPage ........................ 4 GetMode ............ 17 CopyRegion ...................... 5 GetMouseButton ..... 18 CreatePage ...................... 5 GetMouseX .......... 18 CursorMovement .................. 5 GetMouseY .......... 18 CursorRange ..................... 6 GetPaletteRGB ...... 18 DetectFileType .................. 6 _GetPixel .......... 19 DisplayCursor ................... 6 GetPixel ........... 19 DisplayFile ..................... 7 GetSoundStatus ..... 19 Ellipse ......................... 7 GetVersion ......... 20 Ellipse3D ....................... 7 GetViewPort ........ 20 FileBrightness .................. 8 HideCursor ......... 20 FileContrast .................... 8 _HorizontalLine .... 20 FileRGB ......................... 8 HorizontalLine ..... 21 FillCircle ...................... 9 ImageSize .......... 21 FillCircle3D .................... 9 InvertFile ......... 21 FillEllipse ..................... 10 JoystickAvail ...... 22 FillEllipse3D ................... 10 JoystickLimits ..... 22 FillPage ........................ 10 Keypressed ......... 22 FillPolygon ..................... 10 LeftButtonActive ... 22 _FillPolygon .................... 11 Line ............... 23 FlipHorizontal .................. 11 Line3D ............. 23 FloodFill ....................... 11 LineRel ............ 23 Frame ........................... 12 LineRel3D .......... 24 FreeFont ........................ 12 LineTo ............. 24 Get3DVersion .................... 12 LineTo3D ........... 24 GetActivePage ................... 12 LoadFile ........... 25 GetBkColor ...................... 13 LoadFont ........... 25 GetBuffer ....................... 13 LoopSound .......... 25 GetColor ........................ 13 MouseAvail ......... 25 GetColorsUsed ................... 13 MouseRange ......... 26 i MoveCursor ...................... 26 Part 2 Appendixes MoveMouse ....................... 26 MoveRel ......................... 26 Appendix A Error MoveRel3D ....................... 27 messages 40 MoveTo .......................... 27 MoveTo3D ........................ 27 Index 41 OutText ......................... 27 Paint ........................... 28 Polygon ......................... 28 PrintChar ....................... 28 Projection ...................... 29 PutImage ........................ 29 PutImage3D ...................... 29 _PutPixel ....................... 30 PutPixel ........................ 30 PutPixel3D ...................... 30 ReadKey ......................... 30 Rect ............................ 31 RelativeMovement ................ 31 ReleaseFile ..................... 31 ReleasePage ..................... 31 Retrace ......................... 32 RightButtonActive ............... 32 SBAvail ......................... 32 SBContinue ...................... 32 SBLoad .......................... 33 SBPause ......................... 33 SBPlay .......................... 33 SBRecord ........................ 33 SBRelease ....................... 34 SBSave .......................... 34 SBSpeaker ....................... 34 SetActivePage ................... 34 SetBorder ....................... 35 SetBkColor ...................... 35 SetColor ........................ 35 SetCursor ....................... 35 SetDacs ......................... 36 SetFontStyle .................... 36 SetLineStyle .................... 36 SetMode ......................... 37 SetOrigin3D ..................... 37 SetPalette ...................... 37 SetPaletteRGB ................... 38 SetViewPort ..................... 38 SetVisualPage ................... 38 TestCard ........................ 39 UseFont ......................... 39 ii I N T R O D U C T I O N This manual contains definitions of all the Pabulum Graphics Library routines. Pabulum Graphics Library v1.0 is made up of the following units: DRIVER.TPU FFORMAT.TPU GENERAL.TPU GRAPH.TPU GRAPH3D.TPU SOUNDS.TPU What's in the manual Chapter 1:Reference lookup an alphabetical reference of all Pabulum Graphics library procedures and functions. Each entry gives syntax, and operative description, return values if necessary, together with a reference list of relative routines and information on any required steps needed before using the routine. Appedix A:Error messages give all possible error messages that the GetError function may return, including what procedure may cause the error. 1 P A R T 1 Programmer's Reference C H A P T E R 1 Reference lookup This chapter contains a detailed description of all the procedures and functions in the Pabulum Graphics library. The following sample library look-up entry explains where to look for details about each procedure and function. Function name Unit Name SYNTAX How it's declared FUNCTION What it Does PARAMETERS What each parameter is for RETURN VALUE What it returns if it's a function NOTE Additional information or requirements needed to use the function SEE ALSO Related routines BackGroundLink Graph SYNTAX PROCEDURE BackGroundLink(P:Pointer); FUNCTION Adds a procedure to a list of procedures that will be executed in the background while the program runs. PARAMETERS P:Pointer -> a pointer to a procedure. NOTE Procedures passed must meet certain criterias. See MultiTsk.PAS for a demonstration on how the procedure must work. SEE ALSO BackGroundRemove. 2 BackGroundRemove Graph SYNTAX PROCEDURE BackGroundRemove(P:Pointer); FUNCTION Removes a procedure from the list of procedures executing in the background. PARAMETERS P:Pointer -> a pointer to the procedure SEE ALSO BackGroundLink ChangeCursor Driver SYNTAX PROCEDURE ChangeCursor(P:pointer); FUNCTION Uses the cursor image that P points to as the new cursor. The P pointer must point to an image obtained with GetImage. PARAMETERS P:Pointer -> A pointer to the new cursor image. SEE ALSO DisplayCursor, GetImage, HideCursor. Circle Graph SYNTAX PROCEDURE Circle(X,Y:Integer; Radius:Word); FUNCTION Draw a circle using the current color set by SetColor. PARAMETERS X,Y:Integer -> Coordinates for the center of the circle. Radius:Word -> Radius of the circle SEE ALSO Ellipse, FillCircle, FillEllipse, SetColor. 3 Circle3D Graph3D SYNTAX PROCEDURE Circle3D(X,Y,Z:Integer; Radius:Word); FUNCTION Draw a circle using the current color set by SetColor on Location X,Y,Z in 3D space. PARAMETERS X,Y,Z:Integer -> Coordinates for the center of the circle in 3D space. Radius:Word -> Radius of the circle SEE ALSO Ellipse3D, FillCircle3D, FillEllipse3D, SetOrigin3D. ClearKeyBoard Driver SYNTAX PROCEDURE ClearKeyBoard; FUNCTION Empties the keyboard buffer. SEE ALSO KeyPressed, ReadKey. ClearViewPort Graph SYNTAX PROCEDURE ClearViewPort; FUNCTION Clears the region defined by SetViewPort using the background color as set by the last call to SetBkColor. SEE ALSO GetViewPort, SetBkColor, SetViewPort. CopyPage Graph SYNTAX PROCEDURE CopyPage(Source:Byte; Dest:Byte); FUNCTION Copies the page source to the page destination. PARAMETERS Source:Byte -> the page that will be copied. Dest:Byte -> the page Source will be copied to. NOTE In mode 4,5,6 and 19 Source and Dest must be 0 or a page Created using CreatePage. SEE ALSO CopyRegion, CreatePage. 4 CopyRegion Graph SYNTAX PROCEDURE CopyRegion(X1,Y1, X2,Y2:Integer; X,Y:Integer; Source,Dest:Byte); FUNCTION Copies a region in the source page to a region in the destination page. PARAMETERS X1,Y1, X2,Y2:Integer -> The points bounding the rectangular region that will be copied. X,Y:integer -> The top left corner of the position that region will be copied to. Source:Byte -> The page that will be copied. Dest:Byte -> The page Source will be copied to. NOTE X locations will be round off from pixel locations to byte locations specific to the graphic mode you are in. SEE ALSO CopyPage, CreatePage. CreatePage Graph SYNTAX PROCEDURE CreatePage(N:Byte); FUNCTION Creates a virtual page in memory to be used by mode 4,5,6 and 19. PARAMETERS N:Byte -> the number to assign the new page. n may take the value 1..3. page 0 is reserved for the actual screen. SEE ALSO ReleasePage, SetActivePage CursorMovement Driver SYNTAX PROCEDURE CursorMovement(M:MovementType); FUNCTION Define how the cursor will move. Absolute movement allows the cursor to move in any numbers of steps in any given moment depending on the Device being used. Relative Movement will move the cursor a specific number of step as set by RelativeMovement. PARAMETERS M:MovementType -> Relative or Absolute. SEE ALSO RelativeMovement, SetCursor. 5 CursorRange Driver SYNTAX PROCEDURE CursorRange(X1,Y1,X2,Y2:Word); FUNCTION Define a Rectangular Region that the cursor be bounded by. Once set, the user cannot move the cursor out of this region. PARAMETERS X1,Y1:Word -> Top left corner of the region. X2,Y2:Word -> Bottom right corner of the region. SEE ALSO GetCursorX,GetCursorY,MoveCursor. DetectFileType FFormat SYNTAX FUNCTION DetectFileType(Name:String):FType; FUNCTION Will determine what is graphics file format of the given file. PARAMETERS Name:String -> Name of the Graphics file. RETURN VALUE Unknown,BMP,ILBM or PCX. SEE ALSO LoadFile. DisplayCursor Driver SYNTAX PROCEDURE DisplayCursor; FUNCTION Makes the cursor visible. SEE ALSO HideCursor. 6 DisplayFile FFormat SYNTAX PROCEDURE DisplayFile(P:pointer; X,Y:Integer); FUNCTION Will Display file P points to in the active page at location X,Y Relative to the current viewport. PARAMETERS P:Pointer -> a pointer to the loaded image. X,Y:Integer -> the location of the top left corner of the image relative to the viewport. SEE ALSO LoadFile, ReleaseFile, SetViewPort. Ellipse Graph SYNTAX PROCEDURE Ellipse(X, Y:Integer; XRadius, YRadius:Word); FUNCTION Draws an ellipse at location X,Y using the current color. PARAMETERS X,Y:Integer -> Location of the center of the ellipse XRadius,YRadius:Word -> the X and Y Radius of the ellipse SEE ALSO FillEllipse. Ellipse3D Graph3D SYNTAX PROCEDURE Ellipse3D(X, Y, Z:Integer; XRadius, YRadius:Word); FUNCTION Draws an ellipse at location X,Y,Z in 3D Space using the current color. PARAMETERS X,Y,Z:Integer -> Location of the center of the ellipse in 3D Space. XRadius,YRadius:Word -> the X and Y Radius of the ellipse SEE ALSO FillEllipse3D. 7 FileBrightness FFormat SYNTAX PROCEDURE FileBrightness(P:Pointer; gamma:real); FUNCTION Adjust the brightness of the image that P points to. PARAMETERS P:Pointer -> Pointer to the Image. gamma:real -> Brightness control variable. gamma < 1.0 makes image brighter gamma > 1.0 makes image darker SEE ALSO FileContrast, InvertFile. FileContrast FFormat SYNTAX PROCEDURE FileContrast(P:Pointer; Low,High:real); FUNCTION Enhances the contrast of the image that P points to. PARAMETERS P:Pointer -> Pointer to the Image. Low,High:real -> upper and lower bound of the enchanced image. Low and High are in the range 0..1. NOTE The closer the Low and high values are the greater the contrast. SEE ALSO FileBrightness, InvertFile. FileRGB FFormat SYNTAX FUNCTION FileRGB(P:Pointer):Pointer; FUNCTION Return a pointer to the images array of RGB's. PARAMETERS P:Pointer -> Pointer to the Image. RETURN VALUE Pointer to an array of triple byte representing the images RGB palette. NOTE The Array Size Depends on the number of colors being used. SEE ALSO GetColorsUsed. 8 FillCircle Graph SYNTAX PROCEDURE FillCircle(X,Y:Integer; Radius:Word); FUNCTION Draw a Filled circle using the Current Color set by SetColor. PARAMETERS X,Y:Integer -> Coordinates for the center of the circle. Radius:Word -> Radius of the circle SEE ALSO Circle, Ellipse, FillEllipse, SetColor. FillCircle3D Graph3D SYNTAX PROCEDURE FillCircle3D(X, Y, Z:Integer; Radius:Word); FUNCTION Draw a Filled circle using the Current Color set by SetColor on Location X,Y,Z in 3D space. PARAMETERS X,Y,Z:Integer -> Coordinates for the center of the circle in 3D space. Radius:Word -> Radius of the Circle SEE ALSO Circle3D, Ellipse3D, FillEllipse3D, SetOrigin3D. FillEllipse Graph SYNTAX PROCEDURE FillEllipse(X, Y:Integer; XRadius, YRadius:Word); FUNCTION Draws a Filled ellipse at location X,Y using the current color. PARAMETERS X, Y:Integer -> Location of the center of the ellipse XRadius,YRadius:Word -> the X and Y Radius of the ellipse SEE ALSO Ellipse. 9 FillEllipse3D Graph3D SYNTAX PROCEDURE FillEllipse3D(X, Y, Z:Integer; XRadius, YRadius:Word); FUNCTION Draws a filled ellipse at location X,Y,Z in 3D space using the current color. PARAMETERS X, Y, Z:Integer -> Location of the center of the ellipse in 3D space. XRadius,YRadius:Word -> The X and Y Radius of the ellipse SEE ALSO FillEllipse3D. FillPage Graph SYNTAX PROCEDURE FillPage(C:Byte); FUNCTION Fills the entire active page with the given color. PARAMETERS C:Byte -> The color to fill the page with. SEE ALSO ClearViewPort, SetActivePage. FillPolygon Graph SYNTAX PROCEDURE FillPolygon(NumbPoints:Word; VAR Points); FUNCTION Draws a filled polygon using the current color. PARAMETERS NumbPoints:Word -> The number of (x,y) points in the Array. VAR Points -> The array containing the points. NOTE The array must contains the pairs of integers the first for the x coordinate and the Second for the y. SEE ALSO _FillPolygon, Polygon, SetColor. 10 _FillPolygon Graph SYNTAX PROCEDURE _FillPolygon(NumbPoints:Word; VAR Points); FUNCTION Draws a filled simple polygon using the current color. PARAMETERS NumbPoints:Word -> The number of (x,y) points in the Array. VAR Points -> The array containing the points. NOTE The array must contains the pairs of integers the first for the x coordinate and the Second for the y. SEE ALSO FillPolygon, Polygon, SetColor. FlipHorizontal FFormat SYNTAX PROCEDURE FileHorizontal(P:Pointer); FUNCTION takes the image that P points to and flips it upside down. PARAMETERS P:Pointer -> Pointer to the Image. FloodFill Graph SYNTAX PROCEDURE FloodFill(X,Y:Integer; C:Byte); FUNCTION Fill a region with the given color bounded by the give color and any color with was not the color at location X,Y. PARAMETERS X,Y:Integer -> Starting flood fill coordinates. C:byte -> The fill color. SEE ALSO Paint. 11 Frame Graph SYNTAX PROCEDURE Frame(X1,Y1, X2,Y2:Integer); FUNCTION Draw an unfilled rectangle with the current Color, and Line Style. PARAMETERS X1,Y1, X2,Y2:integer -> The end points of the frame. SEE ALSO SetColor, SetLineStyle FreeFont Graph SYNTAX PROCEDURE FreeFont(Font:Pointer); FUNCTION Release Memory Allocated by LoadFont. PARAMETERS Font:Pointer -> pointer to the Font loaded with LoadFont. SEE ALSO LoadFont, UseFont. Get3DVersion Graph3D SYNTAX FUNCTION Get3DVersion:Word; FUNCTION Return the version number of the Graph3D unit. RETURN VALUE Word with the high byte representing the integer part of the version and the low byte the fraction part. SEE ALSO GetVersion. GetActivePage Graph SYNTAX FUNCTION GetActivePage:Byte; FUNCTION Returns the Number of the current active page. RETURN VALUE Byte with the value of the current active page. SEE ALSO SetActivePage. 12 GetBkColor Graph SYNTAX FUNCTION GetBkColor:Byte; FUNCTION Returns the background color as set by SetBkColor. RETURN VALUE Byte that holds the background color. SEE ALSO SetBkColor. GetBuffer Graph SYNTAX FUNCTION GetBuffer:Pointer; FUNCTION Returns a pointer to the Graph's unit buffer. the buffer is used by the Graph unit and the Graph3D unit. RETURN VALUE Pointer to a 40K buffer. GetColor Graph SYNTAX FUNCTION GetColor:Byte; FUNCTION Returns the value of the current color as set by SetColor. RETURN VALUE Byte that holds the Current color. SEE ALSO SetColor. GetColorsUsed FFormat SYNTAX FUNCTION GetColorsUsed(P:Pointer):WORD; FUNCTION Returns the Number of colors used by image file that P points to. PARAMETERS P:Pointer -> Pointer to the image. RETURN VALUE WORD that holds the number of colors used starting from index zero by the image file. SEE ALSO FileRGB. 13 GetCursor Driver SYNTAX FUNCTION GetCursor:CursorType; FUNCTION Returns the name of the device used to control the cursor. RETURN VALUE None,Joystick or Mouse. SEE ALSO SetCursor. GetCursorX Driver SYNTAX FUNCTION GetCursorX:WORD; FUNCTION Returns the Horizontal location of the Cursor. RETURN VALUE Word that hold the Horizontal cursor Location. SEE ALSO GetCursorY, MoveCursor. GetCursorY Driver SYNTAX FUNCTION GetCursorY:WORD; FUNCTION Returns the vertical location of the Cursor. RETURN VALUE Word that hold the vertical cursor Location. SEE ALSO GetCursorX, MoveCursor. GetDacs Graph SYNTAX PROCEDURE GetDacs(F:byte; N:Word; P:Pointer); FUNCTION Returns an array holding the RGB triples of the current Dac values. PARAMETERS F:Byte -> Index of first RGB triple. N:Byte -> Numbers of triples to get. P:Pointer -> a pointer to an array where values will be loaded to. NOTE For VGA only. SEE ALSO SetDacs, SetPaletteRGB. 14 GetError General SYNTAX FUNCTION GetError:Integer; FUNCTION Returns the status of the error variable in the General unit. RETURN VALUE Integer -> 0 = No Error otherwise an error has occured. NOTE The Error Status will be set to zero after every call to this function. See appendix A for listing of possible errors. GetFHeight FFormat SYNTAX FUNCTION GetFHeight(P:Pointer):Word; FUNCTION Returns the height in pixels of the image that P points to. PARAMETERS P:Pointer -> pointer to the image. RETURN VALUE Word with image height. SEE ALSO GetFWidth. GetFWidth FFormat SYNTAX FUNCTION GetFWidth(P:Pointer):Word; FUNCTION Returns the Width in pixels of the image that P points to. PARAMETERS P:Pointer -> pointer to the image. RETURN VALUE Word with image width. SEE ALSO GetFHeight. 15 GetImage Graph SYNTAX PROCEDURE GetImage(P:Pointer; X1, Y1, X2, Y2:Integer); FUNCTION Saves an encoded image of a specified region into a buffer. PARAMETERS P:Pointer -> Pointer to a buffer. X1,Y1, X2,Y2:Integer -> Rectangular region on screen. NOTE A Call To ImageSize must be made before a call to this Procedure. SEE ALSO ImageSize, PutImage. GetJoystickButton Driver SYNTAX FUNCTION GetJoystickButton:Byte; FUNCTION Returns which mouse buttons are being pressed. RETURN VALUE Byte -> bit 0 = 1: Joystick first button active bit 1 = 1: Joystick Second Button Active SEE ALSO GetJoystickX, GetJoystickY. GetJoystickX Driver SYNTAX FUNCTION GetJoystickX:Word; FUNCTION Returns the horizontal value of the Joystick. RETURN VALUE Word with horizontal value of joystick position. SEE ALSO GetJoystickY. GetJoystickY Driver SYNTAX FUNCTION GetJoystickY:Word; FUNCTION Returns the vertical value of the Joystick. RETURN VALUE Word with vertical value of joystick position. SEE ALSO GetJoystickX. 16 GetMaxColor Graph SYNTAX FUNCTION GetMaxColor:Byte; FUNCTION Returns the highest color value that can be passed to the SetColor procedure RETURN VALUE Byte with highest color value accepted by the graphic mode. SEE ALSO SetColor. GetMaxX Graph SYNTAX FUNCTION GetMaxX:Integer; FUNCTION Returns the rightmost column of the current mode. RETURN VALUE Integer with the modes horizontal resolution. SEE ALSO GetMaxY. GetMaxY Graph SYNTAX FUNCTION GetMaxY:Integer; FUNCTION Returns the bottom-most row of the current mode. RETURN VALUE Integer with the modes vertical resolution. SEE ALSO GetMaxX. GetMode Graph SYNTAX FUNCTION GetMode:Byte; FUNCTION Returns the value of the current mode as set by SetMode. RETURN VALUE Byte with current mode value. SEE ALSO SetMode. 17 GetMouseButton Driver SYNTAX FUNCTION GetMouseButton:Byte; FUNCTION Returns which mouse buttons are being pressed. RETURN VALUE Byte -> bit 0 = 1: Left mouse active bit 1 = 1: Right Mouse active but 2 = 1: Center mouse active SEE ALSO GetMouseX, GetMouseY. GetMouseX Driver SYNTAX FUNCTION GetMouseX:Word; FUNCTION Returns the horizontal value of the Mouse. RETURN VALUE Word with horizontal value of Mouse position. SEE ALSO GetMouseY. GetMouseY Driver SYNTAX FUNCTION GetMouseY:Word; FUNCTION Returns the vertical value of the Mouse. RETURN VALUE Word with vertical value of Mouse position. SEE ALSO GetMouseX. GetPaletteRGB Graph SYNTAX PROCEDURE GetPaletteRGB(Index:Byte; VAR Red, Green, Blue:Byte); FUNCTION Returns the red, green, and blue component values of the given Index. PARAMETERS Index:Byte -> the palette index value. VAR Red, Green, Blue:Byte -> The variable that will hold the red, green, and blue RGB value in that order. NOTE For VGA mode only SEE ALSO SetPaletteRGB. 18 _GetPixel Graph SYNTAX FUNCTION _GetPixel(X,Y:Integer):Byte; FUNCTION Returns the color value of the pixel at position X,Y in absolute coordinates. This function is faster that GetPixel because it does not adjust its position to the viewport's origin. PARAMETERS X,Y:Integer -> Location of pixel in active page. RETURN VALUE Byte with color value of that location. SEE ALSO _SetPixel,SetPixel,GetPixel. GetPixel Graph SYNTAX FUNCTION GetPixel(X,Y:Integer):Byte; FUNCTION Returns the color value of the pixel at position X,Y with respect to the viewport. PARAMETERS X,Y:Integer -> Location of pixel in active page. RETURN VALUE Byte with color value of that location. SEE ALSO _SetPixel,SetPixel,_GetPixel. GetSoundStatus Sounds SYNTAX FUNCTION GetSoundStatus:TSCommand; FUNCTION Returns the Status of the Sound Manager. RETURN VALUE cmRest,cmPlay,cmRecord,cmPause SEE ALSO SBPause, SBPlay, SBRecord. 19 GetVersion Graph SYNTAX FUNCTION GetVersion:Word; FUNCTION Returns the version of the Graph unit. RETURN VALUE Word with the high byte representing the integer part of the version and the low byte the fraction part. SEE ALSO Get3DVersion. GetViewPort Graph SYNTAX PROCEDURE GetViewPort(var R:TRect); FUNCTION Get the current viewport setting. PARAMETERS VAR R:TRect -> Variable of type TRect as defined by the general unit. RETURN VALUE The upper-left and lower-right coordinates of the current viewport. SEE ALSO SetViewPort. HideCursor Driver SYNTAX PROCEDURE HideCursor; FUNCTION Make the Active cursor invisible. SEE ALSO DisplayCursor _HorizontalLine Graph SYNTAX PROCEDURE _HorizontalLine(Y,X1,X2:Integer); FUNCTION Draw a HorizontalLine with out clipping and without respect to the viewport. PARAMETERS Y:Integer -> The Y location on the line. X1,X2:Integer -> The left an right end-points of the line. SEE ALSO HorizontalLine 20 HorizontalLine Graph SYNTAX PROCEDURE HorizontalLine(Y,X1,X2:Integer); FUNCTION Draw a HorizontalLine in the current viewport. PARAMETERS Y:Integer -> The Y location on the line. X1,X2:Integer -> The left an right end-points of the line. SEE ALSO _HorizontalLine. ImageSize Graph SYNTAX FUNCTION ImageSize(X1 ,Y1 ,X2 ,Y2:Integer; Mth:Word):Longint; FUNCTION Returns the size in bytes of the region bounded by X1, Y1, X2, Y2 encoded using the best method from the Mth options. PARAMETERS X1, Y1:Integer -> Top-left region of image. X2, Y2:Integer; -> bottom-right region of image. Mth:Word -> encoding methods = (ImgBlock, ImgCompB, ImgLine). RETURN VALUE Longint size of memory needed to capture image. SEE ALSO GetImage. InvertFile FFormat SYNTAX PROCEDURE InvertFile(P:Pointer); FUNCTION Inverts the pixels in the image that P points to. PARAMETERS P:Pointer -> Pointer to the Image. NOTE The new pixels value in the best fit to the invert of the original value, and may not be the exact invert if the exact invert is not available. SEE ALSO FileBrightness, InvertFile. 21 JoystickAvail Driver SYNTAX FUNCTION JoystickAvail:Boolean; FUNCTION Returns true if a Joystick was detected. RETURN VALUE Boolean. SEE ALSO MouseAvail. JoystickLimits Driver SYNTAX PROCEDURE JoystickLimits(X1,Y1, X2,Y2:Integer); FUNCTION Sets the Joystick Range. PARAMETERS X1,Y1:Integer -> The smallest X,Y Joystick values. X2,Y2:Integer -> The Largest X,Y Joystick Values. SEE ALSO GetJoystickX, GetJoystickY. KeyPressed Driver SYNTAX FUNCTION KeyPressed:Boolean; FUNCTION Returns true if a key has been pressed. RETURN VALUE Boolean. SEE ALSO ReadKey. LeftButtonActive Driver SYNTAX FUNCTION LeftButtonActive:Boolean; FUNCTION Returns true if the left button of the current cursor device was pressed. RETURN VALUE Boolean. SEE ALSO RightButtonActive, SetCursor. 22 Line Graph SYNTAX PROCEDURE Line(X1,Y1, X2,Y2:Integer); FUNCTION Draws a line from point (X1,Y1) to (X2,Y2) using the current color and Line Style. PARAMETERS X1,Y1, X2,Y2:Integer -> The two end-points of the line. SEE ALSO LineRel, LineTo, SetColor, SetLineStyle. Line3D Graph3D SYNTAX PROCEDURE Line3D(X1,Y1,Z1, X2,Y2,Z2:Integer); FUNCTION Draws a line in 3D Space from point (X1,Y1,Z1) to (X2,Y2,Z2) using the current color and Line style. PARAMETERS X1,Y1,Z1, X2,Y2,Z2:Integer -> The two end-points of the line. SEE ALSO LineRel3D, LineTo3D, SetColor, SetLineStyle. LineRel Graph SYNTAX PROCEDURE LineRel(Dx,Dy:Integer); FUNCTION Draws a line a distance (Dx,Dy) from the current pointer (CP). PARAMETERS Dx,Dy:Integer -> The X and Y distance from the CP point and the new position of the current pointer. SEE ALSO Line, LineTo, SetColor, SetLineStyle. 23 LineRel3D Graph3D SYNTAX PROCEDURE LineRel3D(Dx,Dy,Dz:Integer); FUNCTION Draws a line in 3D space a distance (Dx, Dy, Dz) from the current pointer (CP3D). PARAMETERS Dx,Dy,Dz:Integer -> The X, Y and Z distance from the CP Point and the new position of the current 3D pointer. SEE ALSO Line3D, LineTo3D, SetColor, SetLineStyle. LineTo Graph SYNTAX PROCEDURE LineTo(X,Y:Integer); FUNCTION Draws a line from the current pointer (CP) to point (X,Y). PARAMETERS X,Y:Integer -> The new position of the current pointer. SEE ALSO Line, LineRel, SetColor, SetLineStyle. LineTo3D Graph3D SYNTAX PROCEDURE LineTo3D(X,Y,Z:Integer); FUNCTION Draws a line in 3D space from the current 3D pointer (CP3D) to point (X,Y,Z). PARAMETERS X,Y,Z:Integer -> The new position of the current 3D pointer. SEE ALSO Line3D, LineRel3D, SetColor, SetLineStyle. 24 LoadFile FFormat SYNTAX PROCEDURE LoadFile(Name:STRING; Tp:FType; VAR P:Pointer); FUNCTION Loads and image file from disk to memory. PARAMETERS Name:STRING -> The name of the file Tp:FType -> file type = (Unknown,BMP,ILBM,PCX); ILBM = ILBM or IFF file P:Pointer -> Pointer to location in memory of file. SEE ALSO DetectFileType, DisplayFile, ReleaseFile. LoadFont Graph SYNTAX PROCEDURE LoadFont(Name:STRING; VAR Font:Pointer); FUNCTION Loads a font file from disk to memory. PARAMETERS Name:STRING -> The name of the file Font:Pointer -> Pointer to location in memory of Font. SEE ALSO FreeFont, UseFont. LoopSound Sounds SYNTAX Procedure LoopSound(B:Boolean); FUNCTION Continuously loops a sound file in the background. PARAMETERS B:Boolean -> True = loop Sound False = Don't loop Sound SEE ALSO SBContinue, SBPause, SBPlay. MouseAvail Driver SYNTAX FUNCTION MouseAvail:Boolean; FUNCTION Returns true if a mouse was detected. RETURN VALUE Boolean. SEE ALSO JoystickAvail. 25 MouseRange Driver SYNTAX PROCEDURE MouseRange(X1,Y1, X2,Y2:Integer); FUNCTION Sets the Mouse Range. PARAMETERS X1,Y1:Integer -> The smallest X,Y Mouse values. X2,Y2:Integer -> The Largest X,Y Mouse values. SEE ALSO GetMouseX, GetMouseY. MoveCursor Driver SYNTAX PROCEDURE MoveCursor(X,Y:Integer); FUNCTION Move the cursor to locations X,Y. PARAMETERS X,Y:Integer -> The new cursor position. SEE ALSO GetCursor, GetCursorX, GetCursorY. MoveMouse Driver SYNTAX PROCEDURE MoveMouse(X,Y:Integer); FUNCTION Move the Mouse cursor to locations X,Y. PARAMETERS X,Y:Integer -> The new cursor position. SEE ALSO GetMouseX, GetMouseY. MoveRel Graph SYNTAX PROCEDURE MoveRel(Dx,Dy:Integer); FUNCTION Moves the current pointer (CP) a distance (Dx,Dy) from its current position. PARAMETERS Dx,Dy:Integer -> The X and Y distance from the CP Point and the new position of the current pointer. SEE ALSO MoveTo. 26 MoveRel3D Graph3D SYNTAX PROCEDURE MoveRel3D(Dx,Dy,Dz:Integer); FUNCTION Moves the current 3D pointer (CP3D) a distance (Dx, Dy, Dz) from its current position. PARAMETERS Dx, Dy, Dz:Integer -> The X,Y and Z distance from the CP Point and the new position of the current pointer. SEE ALSO MoveTo3D. MoveTo Graph SYNTAX PROCEDURE MoveTo(X,Y:Integer); FUNCTION Moves the current pointer (CP) to position X,Y PARAMETERS X, Y:Integer -> The new position of the current pointer. SEE ALSO MoveRel. MoveTo3D Graph3D SYNTAX PROCEDURE MoveTo3D(X, Y, Z:Integer); FUNCTION Moves the current 3D pointer (CP3D) to position X, Y, Z PARAMETERS X, Y, Z:Integer -> The new position of the current 3D pointer. SEE ALSO MoveRel3D. OutText Graph SYNTAX PROCEDURE OutText(X, Y:Integer; S:String); FUNCTION Sends a string to the screen at the Location X,Y using the current color, Font and FontStyle PARAMETERS X, Y:Integer -> The Location where the text is to be displayed. S:String -> the text to display. SEE ALSO LoadFont, PrintChar, SetFontStyle, UseFont. 27 Paint Graph SYNTAX PROCEDURE Paint(X,Y:integer); FUNCTION Change the pixel at location X,Y to the current color as set by SetColor and also changes neighboring pixels of same color to the current color. PARAMETERS X,Y:Integer -> The pixel location to be painted. SEE ALSO FloodFill. Polygon Graph SYNTAX PROCEDURE Polygon(NumbPoints:Word; VAR Points); FUNCTION Draws a polygon using the current color. PARAMETERS NumbPoints:Word -> The number of (x,y) points in the array. VAR Points -> The array containing the points. NOTE The array must contains the pairs of integers the first for the x coordinate and the Second for the y. SEE ALSO FillPolygon, SetColor. PrintChar Graph SYNTAX PROCEDURE PrintChar(X,Y:Integer; C:Char); FUNCTION Sends a Character to the screen at the Location X,Y using the current color, Font and FontStyle PARAMETERS X,Y:Integer -> The Location where the character is to be displayed. C:Char -> The Character to display. SEE ALSO LoadFont, OutText, SetFontStyle, UseFont. 28 Projection Graph3D SYNTAX PROCEDURE Project(X, Y, Z:Integer; VAR nx, ny:integer); FUNCTION Transforms a 3D coordinate into a 2D location of the Screen. PARAMETERS X,Y,Z:Integer -> The Location of the point in 3D space. VAR nx,ny:Integer -> The Location of the point in screen space. SEE ALSO SetOrigin3D. PutImage Graph SYNTAX PROCEDURE PutImage(P:Pointer; X,Y:Integer; V:Boolean); FUNCTION Put an encoded image on the screen. PARAMETERS P:Pointer -> pointer to image. X,Y:Integer -> Top-left corner of image. V:Boolean -> if V=true then image can have transparent region. if V=false then transparent color will be replaced with the value GetMaxColor. SEE ALSO GetImage, GetMaxColor, PutImage3D. PutImage3D Graph SYNTAX PROCEDURE PutImage3D(P:Pointer; X,Y,Z:Integer; V:Boolean); FUNCTION Put an encoded image on the screen. PARAMETERS P:Pointer -> pointer to image. X,Y,Z:Integer -> Top-left corner of the image in 3D space. V:Boolean -> if V=true then image can have transparent region. if V=false then transparent color with be replaced with the value GetMaxColor. SEE ALSO GetImage, GetMaxColor, PutImage. 29 _PutPixel Graph SYNTAX PROCEDURE _PutPixel(X,Y:Integer; c:Byte); FUNCTION Put a pixel on the screen with out clipping and without respect to the viewport. PARAMETERS X,Y:Integer -> Location of pixel. c:Byte -> Color of pixel. SEE ALSO GetPixel, PutPixel. PutPixel Graph SYNTAX PROCEDURE PutPixel(X,Y:Integer; c:Byte); FUNCTION Put a pixel on the current viewport. PARAMETERS X,Y:Integer -> Location of pixel. c:Byte -> Color of pixel. SEE ALSO GetPixel, _PutPixel. PutPixel3D Graph3D SYNTAX PROCEDURE PutPixel3D(X,Y,Z:Integer; c:Byte); FUNCTION Put a pixel on 3D space with respect to the current viewport. PARAMETERS X,Y,Z:Integer -> Location of pixel on 3D space. c:Byte -> Color of pixel. SEE ALSO GetPixel, _PutPixel, PutPixel. ReadKey Driver SYNTAX FUNCTION ReadKey:Char; FUNCTION Reads a character for the keyboard. RETURN VALUE Character SEE ALSO KeyPressed. 30 Rect Graph SYNTAX PROCEDURE Rect(X1,Y1, X2,Y2:Integer); FUNCTION Draw a filled rectangle with the current Color, and Line Style. PARAMETERS X1,Y1, X2,Y2:integer -> The end points of the rectangle. SEE ALSO SetColor, SetLineStyle. RelativeMovement Driver SYNTAX PROCEDURE RelativeMovement(Dx,Dy:Integer); FUNCTION Will move The cursor a distance Dx,Dy from its current position when the cursor is in Relative mode as set by CursorMovement. PARAMETERS Dx,Dy:Integer -> The distance the x and y coordinates will change. SEE ALSO CursorMovement. ReleaseFile FFormat SYNTAX PROCEDURE ReleaseFile(P:Pointer); FUNCTION Releases memory allocated by the LoadFile procedure. PARAMETERS P:Pointer -> Pointer to location in memory of image. SEE ALSO DetectFileType, DisplayFile, LoadFile. ReleasePage Graph SYNTAX PROCEDURE ReleasePage(N:Byte); FUNCTION Releases memory allocated for a virtual page by the CreatePage procedure. PARAMETERS N:Byte -> The number of the virtual page. SEE ALSO CreatePage. 31 Retrace Graph SYNTAX PROCEDURE Retrace; FUNCTION waits for the for the Screen vertical retrace. RightButtonActive Driver SYNTAX FUNCTION RightButtonActive:Boolean; FUNCTION Returns true if the Right button of the current cursor device was pressed. RETURN VALUE Boolean. SEE ALSO LeftButtonActive, SetCursor. SBAvail Sounds SYNTAX FUNCTION SBAvail:Boolean; FUNCTION Returns true if a Sound blaster or compatible card was detected. RETURN VALUE Boolean. SEE ALSO SBLoad, SBPlay. SBContinue Sounds SYNTAX PROCEDURE SBContinue; FUNCTION Continues playing any sound previously paused using the SBPause Procedure. SEE ALSO SBPause, SBPlay. 32 SBLoad Sounds SYNTAX PROCEDURE SBLoad(Name:String; VAR P:Pointer); FUNCTION Loads a sound blaster .VOC from disk to memory. PARAMETERS Name:String -> The name of the .Voc file. VAR P:Pointer -> A pointer to the location in memory of the .VOC File. SEE ALSO SBPause, SBPlay. SBPause Sounds SYNTAX PROCEDURE SBPause; FUNCTION Pauses the executions of any sounds. SEE ALSO SBContinue, SBPlay. SBPlay Sounds SYNTAX PROCEDURE SBPlay(P:Pointer); FUNCTION Plays the sound file that P points to. PARAMETERS VAR P:Pointer -> A pointer to the location in memory of the .VOC File. SEE ALSO SBContinue, SBPause. SBRecord Sounds SYNTAX PROCEDURE SBRecord(Rate:WORD; Time:WORD; VAR P:Pointer); FUNCTION Record a Sound Sample for time Time at rate Rate. PARAMETERS Rate:WORD -> How many samples per second. Time:WORD -> For how many Seconds to record. VAR P:Pointer -> A pointer to the location in memory of the .VOC File. SEE ALSO SBPlay. 33 SBRelease Sounds SYNTAX PROCEDURE SBRelease(P:Pointer); FUNCTION Releases memory allocated for a .VOC file by SBLoad or SBRecord PARAMETERS P:Pointer -> A pointer to the location in memory of the .VOC File. SEE ALSO SBLoad, SBRecord. SBSave Sounds SYNTAX PROCEDURE SBSave(Name:String; P:Pointer); FUNCTION Saves a sound blaster .VOC from memory to disk. PARAMETERS Name:String -> The name of the .Voc file. P:Pointer -> A pointer to the location in memory of the .VOC File. SEE ALSO SBPause, SBPlay. SBSpeaker Sounds SYNTAX PROCEDURE SBSpeaker(B:Byte); FUNCTION Turns the Speakers on or off. PARAMETERS B:Byte-> 0 = Turn off 1 = Turn on. SEE ALSO SBPlay. SetActivePage Graph SYNTAX PROCEDURE SetActivePage(C:Byte); FUNCTION Sets the active page for graphic output. PARAMETERS C:Byte -> Page number, starting at 0. SEE ALSO SetVisualPage. 34 SetBorder Graph SYNTAX PROCEDURE SetBorder(N:Byte); FUNCTION Sets the color of thescreen border. PARAMETERS N:Byte -> The color value in the Range of 0..63 for EGA cards 0..255 for VGA cards SEE ALSO SetPalette, SetPaletteRGB. SetBkColor Graph SYNTAX PROCEDURE SetBkColor(C:Byte); FUNCTION Sets the value of the BK color variable, which is used by routines such as ClearViewPort. PARAMETERS C:Byte -> The color value in the Range of 0..GetMaXColor. SEE ALSO ClearViewPort, GetBkColor, GetMaxColor. SetColor Graph SYNTAX PROCEDURE SetColor(C:Byte); FUNCTION Sets Current drawing color which is used by most of the basic graphics primitive such as drawing line, rectangles, circle, etc. PARAMETERS c:Byte -> The color value in the Range of 0..GetMaXColor. SEE ALSO GetColor,GetMaxColor. SetCursor Driver SYNTAX PROCEDURE SetCursor(C:CursorType); FUNCTION Define the device that will control the cursor. PARAMETERS C:CursorType -> The cursor device = {None, Joystick, Mouse} SEE ALSO GetCursor. 35 SetDacs Graph SYNTAX PROCEDURE SetDacs(F:byte; N:Word; P:Pointer); FUNCTION Defines multiple Dac color register. PARAMETERS F:Byte -> Index of first RGB triple. N:Byte -> Numbers of triples to get. P:Pointer -> A pointer to and array containing the Dac values as RGB triples. NOTE For VGA only. SEE ALSO GetDacs, SetPaletteRGB. SetFontStyle Graph SYNTAX PROCEDURE SetFontStyle(S:WORD); FUNCTION Defines the Characteristics of the font. PARAMETERS S:WORD -> Can be any combination of {FntNormal, FntItalic, FntUnderline, FntBold, FntShadow} RGB triples. NOTE The + sign is used to have more the one font characteristic. For examples for text to be Italic and shadowed use command: SetFontStyle (FntItalic + FntShadow). SEE ALSO FreeFont, LoadFont, UseFont. SetLineStyle Graph SYNTAX PROCEDURE SetLineStyle(S:WORD); FUNCTION Defines the line Pattern. PARAMETERS S:WORD -> Every bit of the word S indicates if the point of the line will be plotted. For example S=$AAAA will define a dotted line. S=$FFFF will define a solid line. SEE ALSO Frame, Line, Polygon. 36 SetMode Graph SYNTAX PROCEDURE SetMode(Mode:Byte); FUNCTION Initializes a video mode and clears the screen. PARAMETERS Mode:Byte -> The desired graphics mode: Mode Colors Resolution Card Type 4 4 Color 320x200 CGA 5 4 Color 320x200 CGA 6 2 Color 640x200 CGA 13 16 Color 320x200 EGA 14 16 Color 640x200 EGA 16 16 Color 640x350 VGA 18 16 Color 640x480 VGA 19 256 Color 320x200 MCGA 20 256 Color 320x200 VGA 21 256 Color 320x240 VGA 22 256 Color 320x400 VGA 23 256 Color 360x480 VGA SEE ALSO GetMode. SetOrigin3D Graph3D SYNTAX PROCEDURE SetOrigin3D(X, Y, Z:Integer); FUNCTION Defines the new center of the origin in 3D space PARAMETERS X,Y,Y:Integer -> location of origin in 3D space SEE ALSO GetPaletteRGB, SetPaletteRGB. SetPalette Graph SYNTAX PROCEDURE SetPalette(Index,Color:Byte); FUNCTION Changes one palette color as specified by Index and Color PARAMETERS Index:Byte -> Color index value = 0..15 Color:Byte -> New color Value. NOTE For EGA only. SEE ALSO GetPaletteRGB, SetPaletteRGB. 37 SetPaletteRGB Graph SYNTAX PROCEDURE SetPaletteRGB( Index,Reg,Green,Blue:Byte); FUNCTION Changes the palette color by modifying the RGB components. PARAMETERS Index:Byte -> Color index value Red,Green,Blue:Byte -> The Red, green, and blue intensity (0..63) NOTE For VGA only. SEE ALSO GetPaletteRGB, SetPalette. SetViewPort Graph SYNTAX PROCEDURE SetViewPort(X1,Y1,X2,Y2:integer); FUNCTION Set the Current output viewport. PARAMETERS X1,Y1:Integer -> Top-left corner of active window. X2,Y2:Integer -> Bottom-Right corner of active window. SEE ALSO GetViewPort. SetVisualPage Graph SYNTAX PROCEDURE SetVisualPage(C:Byte); FUNCTION Sets the Visual page Number. PARAMETERS c:Byte -> Page number, starting at 0. SEE ALSO SetActivePage. 38 TestCard Graph SYNTAX FUNCTION TestCard(Card:VideoCard):Boolean; FUNCTION Determines if the Specified video card is supported. PARAMETERS Card:VideoCard -> Card to Test = {CGA,EGA,VGA} RETURN VALUE Boolean = True if card is supported. SEE ALSO SetMode. UseFont Graph SYNTAX PROCEDURE UseFont(Font:Pointer); FUNCTION Points to the Character set that will be used by the OutText and PrintChar routines. PARAMETERS Font:Pointer -> Pointer to location in memory of font. SEE ALSO FreeFont, LoadFont. 39 P A R T 2 Appendices A P P E N D I X A Error Messages The following lists the possible error massages that the GetError function can return. Number Error Cause of error 1 Unable to open file Reported by LoadFile, LoadFont, or DetectFileType if its unable to open the file. 32 Error allocating Reported by CreatePage, memory GetImage, LoadFile, LoadFont SBLoad if its unable to allocate the required memory. 40 I N D E X B MoveCursor procedure 26 MoveMouse procedure 26 BackGroundLink procedure 2 ReadKey function 30 BackGroundRemove procedure 3 RelativeMovement procedure 31 RightButtonActive function 32 C SetCursor procedure 35 ChangeCursor procedure 3 E Circle procedure 3 Circle3D procedure 4 Ellipse procedure 7 ClearKeyBoard procedure 4 Ellipse3D procedure 7 ClearViewPort procedure 4 CopyPage procedure 4 F CopyRegion procedure 5 CreatePage procedure 5 FFormat unit CursorMovement procedure 5 DetectFileType function 6 CursorRange procedure 6 DisplayFile procedure 7 FileBrightness procedure 8 D FileContrast procedure 8 FileRGB function 8 DetectFileType function 6 GetColorsUsed function 13 DisplayCursor procedure 6 GetFWidth function 15 DisplayFile procedure 7 GetFHeight function 15 Driver unit InvertFile procedure 22 ChangeCursor procedure 3 LoadFile procedure 25 ClearKeyBoard procedure 4 ReleaseFile procedure 31 CursorMovement procedure 5 FileBrightness procedure 8 CursorRange procedure 6 FileContrast procedure 8 DisplayCursor procedure 6 FileRGB function 8 GetCursor function 14 FillCircle procedure 9 GetCursorX function 14 FillCircle3D procedure 9 GetCursorY function 14 FillEllipse procedure 10 GetJoystickButton function 16 FillEllipse3D procedure 10 GetJoystickX function 16 FillPage procedure 10 GetJoystickY function 16 FillPolygon procedure 10 GetMouseButton function 18 _FillPolygon procedure 11 GetMouseX function 18 FlipHorizontal procedure 11 GetMouseY function 18 FloodFill procedure 11 HideCursor procedure 20 Frame procedure 12 JoystickAvail function 22 FreeFont procedure 12 JoystickLimits procedure 22 KeyPressed function 22 G LeftButtonActive function 22 MouseAvail function 25 General unit 1 MouseRange procedure 26 GetError function 15 41 Get3DVersion function 12 GetBuffer function 13 GetActivePage function 12 GetColor function 13 GetBkColor function 13 GetDacs procedure 14 GetBuffer function 13 GetImage procedure 16 GetColor function 13 GetMaxColor function 17 GetColorsUsed function 13 GetMaxX function 17 GetCursor function 14 GetMaxY function 17 GetCursorX function 14 GetMode procedure 17 GetCursorY function 14 GetPaletteRGB procedure 18 GetDacs procedure 14 _GetPixel function 19 GetError function 15 GetPixel function 19 GetFHeight function 15 GetVersion function 20 GetFWidth function 15 GetViewPort procedure 20 GetImage procedure 16 _HorizontalLine procedure 20 GetJoystickButton function 16 HorizontalLine procedure 21 GetJoystickX function 16 ImageSize function 21 GetJoystickY function 16 Line procedure 23 GetMaxColor function 17 LineRel procedure 23 GetMaxX function 17 LineTo procedure 24 GetMaxY function 17 LoadFont procedure 25 GetMode procedure 17 MoveRel procedure 26 GetMouseButton function 18 MoveTo procedure 27 GetMouseX function 18 OutText procedure 27 GetMouseY function 18 Paint procedure 28 GetPaletteRGB procedure 18 Polygon procedure 28 _GetPixel function 19 PrintChar procedure 28 GetPixel function 19 PutImage procedure 29 GetSoundStatus function 19 _PutPixel procedure 30 GetVersion function 20 PutPixel procedure 30 GetViewPort procedure 20 Rect procedure 31 Graph unit ReleasePage procedure 31 BackGroundLink procedure 2 Retrace procedure 32 BackGroundRemove procedure 3 SetActivePage procedure 34 Circle procedure 3 SetBorder procedure 35 ClearViewPort procedure 4 SetBkColor procedure 35 CopyPage procedure 4 SetColor procedure 35 CopyRegion procedure 5 SetDacs procedure 36 CreatePage procedure 5 SetFontStyle procedure 36 Ellipse procedure 7 SetLineStyle procedure 36 FillCircle procedure 9 SetMode procedure 37 FillEllipse procedure 10 SetPalette procedure 37 FillPage procedure 10 SetPaletteRGB procedure 38 FillPolygon procedure 10 SetViewPort procedure 38 _FillPolygon procedure 11 SetVisualPage procedure 38 FlipHorizontal procedure 11 TestCard function 39 FloodFill procedure 11 UseFont procedure 39 Frame procedure 12 Graph3D unit FreeFont procedure 12 Circle3D procedure 4 GetActivePage function 12 Ellipse3D procedure 7 GetBkColor function 13 FillCircle3D procedure 9 42 FillEllipse3D procedure 10 MoveMouse procedure 26 Get3DVersion function 12 MoveRel procedure 26 Line3D procedure 23 MoveRel3D procedure 27 LineRel3D procedure 24 MoveTo procedure 27 LineTo3D procedure 24 MoveTo3D procedure 27 MoveRel3D procedure 27 MoveTo3D procedure 27 O Projection procedure 29 PutImage3D procedure 29 OutText procedure 27 PutPixel3D procedure 30 SetOrigin3D procedure 37 P H Paint procedure 28 Polygon procedure 28 HideCursor procedure 20 PrintChar procedure 28 _HorizontalLine procedure 20 Projection procedure 29 HorizontalLine procedure 21 PutImage procedure 29 PutImage3D procedure 29 I _PutPixel procedure 30 PutPixel procedure 30 ImageSize function 21 PutPixel3D procedure 30 InvertFile procedure 21 R J ReadKey function 30 JoystickAvail function 20 Rect procedure 31 JoystickLimits procedure 20 RelativeMovement procedure 31 ReleaseFile procedure 31 K ReleasePage procedure 31 Retrace procedure 32 Keypressed function 21 RightButtonActive function 32 L S LeftButtonActive function 22 SBAvail function 32 Line procedure 23 SBContinue procedure 32 Line3D procedure 23 SBLoad procedure 33 LineRel procedure 23 SBPause procedure 33 LineRel3D procedure 24 SBPlay procedure 33 LineTo procedure 24 SBRecord procedure 33 LineTo3D procedure 24 SBRelease procedure 34 LoadFile procedure 25 SBSave procedure 34 LoadFont procedure 25 SBSpeaker procedure 34 LoopSound procedure 25 SetActivePage procedure 34 SetBorder procedure 35 M SetBkColor procedure 35 SetColor procedure 35 MouseAvail function 23 SetCursor procedure 35 MouseRange procedure 26 SetDacs procedure 36 MoveCursor procedure 26 SetFontStyle procedure 36 43 SetLineStyle procedure 36 SetMode procedure 37 SetOrigin3D procedure 37 SetPalette procedure 37 SetPaletteRGB procedure 38 SetViewPort procedure 38 SetVisualPage procedure 38 Sounds unit GetSoundStatus function 19 LoopSound procedure 25 SBAvail function 32 SBContinue procedure 32 SBLoad procedure 33 SBPause procedure 33 SBPlay procedure 33 SBRecord procedure 33 SBRelease procedure 34 SBSave procedure 34 SBSpeaker procedure 34 T TestCard function 39 U UseFont procedure 39 44