]> icculus.org git repositories - taylor/freespace2.git/blob - include/osapi.h
rendering functions mostly done; more complete shader setup
[taylor/freespace2.git] / include / osapi.h
1 /*
2  * Copyright (C) Volition, Inc. 1999.  All rights reserved.
3  *
4  * All source code herein is the property of Volition, Inc. You may not sell 
5  * or otherwise commercially exploit the source or things you created based on
6  * the source.
7  */
8
9 #ifndef _OSAPI_H
10 #define _OSAPI_H
11
12 #include <stdlib.h>
13
14 #include "pstypes.h"
15
16 // --------------------------------------------------------------------------------------------------
17 // OSAPI DEFINES/VARS
18 //
19
20 // set if running under MsDev - done after os_init(...) has returned
21 extern int Os_debugger_running;
22
23 // --------------------------------------------------------------------------------------------------
24 // OSAPI FUNCTIONS
25 //
26
27 // initialization/shutdown functions -----------------------------------------------
28
29 // If app_name is NULL or ommited, then TITLE is used
30 // for the app name, which is where registry keys are stored.
31 void os_init(const char *wclass, const char *title, const char *app_name = NULL, const char *version_string = NULL);
32
33 // set the main window title
34 void os_set_title( const char *title );
35 // get the main window title
36 const char *os_get_title();
37
38 // call at program end
39 void os_cleanup();
40
41
42 // window management ---------------------------------------------------------------
43
44 // toggle window size between full screen and windowed
45 void os_toggle_fullscreen();
46
47 // Returns 1 if app is not the foreground app.
48 int os_foreground();
49
50 // Returns the handle to the main window
51 SDL_Window *os_get_window();
52 // Sets the handle to the main window
53 void os_set_window(SDL_Window *win);
54
55 // process management --------------------------------------------------------------
56
57 // call to process windows messages. only does something in non THREADED mode
58 void os_poll();
59
60 // Used to stop message processing
61 void os_suspend();
62
63 // resume message processing
64 void os_resume();
65
66 #endif
67