/* */
/* */
/* */
-/* (C) 2002 Ullrich von Bassewitz */
-/* Wacholderweg 14 */
-/* D-70597 Stuttgart */
-/* EMail: uz@musoftware.de */
+/* (C) 2002-2004 Ullrich von Bassewitz */
+/* Römerstrasse 52 */
+/* D-70794 Filderstadt */
+/* EMail: uz@cc65.org */
/* */
/* */
/* This software is provided 'as-is', without any expressed or implied */
void __fastcall__ tgi_load (unsigned char mode);
-/* Install the matching driver for the given mode. Will just load the driver
- * and check if loading was successul. Will not switch to gaphics mode.
+/* Load and install the matching driver for the given mode. Will just load
+ * the driver and check if loading was successul. Will not switch to gaphics
+ * mode.
*/
void __fastcall__ tgi_load_driver (const char* name);
-/* Install the given driver. This function is identical to tgi_load with the
- * only difference that the name of the driver is specified explicitly. You
- * should NOT use this function in most cases, use tgi_load() instead.
+/* Load and install the given driver. This function is identical to tgi_load
+ * with the only difference that the name of the driver is specified
+ * explicitly. You should NOT use this function in most cases, use tgi_load()
+ * instead.
*/
void __fastcall__ tgi_unload (void);
-/* Unload the currently loaded driver. Will call tgi_done if necessary. */
+/* Uninstall, then unload the currently loaded driver. Will call tgi_done if
+ * necessary.
+ */
+
+void __fastcall__ tgi_install (void* driver);
+/* Install an already loaded driver. */
-void __fastcall__ tgi_init (unsigned char mode);
-/* Initialize the given graphics mode. */
+void __fastcall__ tgi_uninstall (void);
+/* Uninstall the currently loaded driver but do not unload it. Will call
+ * tgi_done if necessary.
+ */
+
+void __fastcall__ tgi_init (void);
+/* Initialize the already loaded graphics driver. */
void __fastcall__ tgi_done (void);
-/* End graphics mode, switch back to text mode. Will NOT unload the driver! */
+/* End graphics mode, switch back to text mode. Will NOT uninstall or unload
+ * the driver!
+ */
unsigned char __fastcall__ tgi_geterror (void);
/* Return the error code for the last operation. This will also clear the
* error.
*/
+const char* __fastcall__ tgi_geterrormsg (unsigned char code);
+/* Get an error message describing the error in code. */
+
void __fastcall__ tgi_clear (void);
/* Clear the screen. */
-void __fastcall__ tgi_getpagecount (void);
+unsigned __fastcall__ tgi_getpagecount (void);
/* Returns the number of screen pages available. */
void __fastcall__ tgi_setviewpage (unsigned char page);
*/
const unsigned char* __fastcall__ tgi_getpalette (void);
-/* Return the current palette. Will return NULL for drivers that do not
- * support palettes.
- */
+/* Return the current palette. */
const unsigned char* __fastcall__ tgi_getdefpalette (void);
-/* Return the default palette. Will return NULL for drivers that do not
- * support palettes.
- */
+/* Return the default palette. */
unsigned __fastcall__ tgi_getxres (void);
/* Return the resolution in X direction. */
* the end of the text.
*/
+unsigned __fastcall__ tgi_ioctl (unsigned char code, unsigned val);
+/* Call the driver specific control function. What this function does for
+ * a specific code depends on the driver. The driver will set an error
+ * for unknown codes or values.
+ */
+
/* End of tgi.h */