Starshatter_Open
Open source Starshatter engine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Video.cpp
Go to the documentation of this file.
1 /* Project nGenEx
2  Destroyer Studios LLC
3  Copyright © 1997-2004. All Rights Reserved.
4 
5  SUBSYSTEM: nGenEx.lib
6  FILE: Video.cpp
7  AUTHOR: John DiCamillo
8 
9 
10  OVERVIEW
11  ========
12  Abstract Video Interface (singleton definition)
13 */
14 
15 #include "MemDebug.h"
16 #include "Video.h"
17 #include "VideoSettings.h"
18 
19 // +--------------------------------------------------------------------+
20 
22 
23 // +--------------------------------------------------------------------+
24 
26 {
27  status = VIDEO_OK;
28  video_instance = this;
29 
30  shadow_enabled = true;
31  bump_enabled = true;
32  spec_enabled = true;
33 
34  camera = 0;
35 }
36 
38 {
39  if (video_instance == this)
40  video_instance = 0;
41 }
42 
43 // +--------------------------------------------------------------------+
44 
45 bool
47 {
48  const VideoSettings* vs = GetVideoSettings();
49 
50  if (vs)
51  return vs->IsWindowed();
52 
53  return false;
54 }
55 
56 bool
58 {
59  const VideoSettings* vs = GetVideoSettings();
60 
61  if (vs)
62  return !vs->IsWindowed();
63 
64  return true;
65 }