Wing Commander
Reconstructed Win32 source (1996)
Loading...
Searching...
No Matches
wc1base.h File Reference

Common types, macros and utility prototypes. More...

#include <windows.h>
#include <ddraw.h>
#include <mmsystem.h>
#include <conio.h>
#include <direct.h>
#include <io.h>
#include <ctype.h>
#include <errno.h>
#include <fcntl.h>
#include <math.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>

Go to the source code of this file.

Data Structures

struct  IxSample
struct  IxSound
struct  Viewport
struct  Shape
struct  MouseCursorState
struct  InputEvent
struct  InputEventState
struct  InputDeviceSample
struct  RasterSurface
struct  RasterClip
struct  ShapeFrame
struct  RLETransformVertex
struct  RLEShape
struct  RLEFrameHeader
struct  FontWorkspace
struct  TextContext
struct  CockpitReadout
struct  ModalTextPanel
struct  HudMessageSlot
struct  RoomMenu
struct  ScreenAllocation
struct  WaveTableEntry
struct  ActiveSoundEntry
struct  TaggedAllocationHeader
struct  GuardedAllocation
struct  DebugOverlayConsole

Macros

#define DEGREES_TO_RADIANS   0.017453292519943295
#define COM_RELEASE(surface)
#define SPRITE_ROW_OFFSET(viewport, row)

Typedefs

typedef unsigned short UINT16
typedef void * PackedResourcePointer
typedef struct IxSound IxSound
typedef struct IxSample IxSample
typedef struct Viewport Viewport
typedef struct MouseCursorState MouseCursorState
typedef char MouseCursorState_size_must_be_0x1c[sizeof(MouseCursorState)==0x1c ? 1 :-1]
typedef struct InputEvent InputEvent
typedef struct InputEventState InputEventState
typedef struct InputDeviceSample InputDeviceSample
typedef struct RasterSurface RasterSurface
typedef struct RasterClip RasterClip
typedef struct RLEFrameHeader RLEFrameHeader
typedef struct FontWorkspace FontWorkspace
typedef struct TextContext TextContext
typedef struct CockpitReadout CockpitReadout
typedef struct ModalTextPanel ModalTextPanel
typedef struct HudMessageSlot HudMessageSlot
typedef struct RoomMenu RoomMenu
typedef struct ScreenAllocation ScreenAllocation
typedef char CockpitReadout_size_must_be_0x0a[sizeof(CockpitReadout)==0x0a ? 1 :-1]
typedef char RoomMenu_size_must_be_0x29[sizeof(RoomMenu)==0x29 ? 1 :-1]
typedef struct WaveTableEntry WaveTableEntry
typedef struct ActiveSoundEntry ActiveSoundEntry
typedef struct DebugOverlayConsole DebugOverlayConsole

Enumerations

enum  GAME_MODE { Player = 0 }
enum  GAME_STATUS { ALIVE = 0 }

Functions

void ShowOnScreenMessage (int flags, short duration, const char *fmt,...)
void SoundDebugPrintf (const char *fmt,...)
void SystemDebugPrintf (const char *fmt,...)

Detailed Description

Common types, macros and utility prototypes.

wc1.h adds the data headers after these; the Win32 shell (winmain.c) includes them itself because it declares main.c's option flags with its own types.

Definition in file wc1base.h.

Macro Definition Documentation

◆ COM_RELEASE

#define COM_RELEASE ( surface)
Value:
do { if ((surface) != 0) { IDirectDrawSurface_Release(surface); (surface) = 0; } } while (0)

Definition at line 34 of file wc1base.h.

Referenced by DIBerror(), DIBpositionWindow(), and DIBunInstall().

◆ DEGREES_TO_RADIANS

#define DEGREES_TO_RADIANS   0.017453292519943295

Definition at line 31 of file wc1base.h.

Referenced by CosFixed(), and SinFixed().

◆ SPRITE_ROW_OFFSET

#define SPRITE_ROW_OFFSET ( viewport,
row )
Value:
viewport->rowOffsets[row]

Definition at line 83 of file wc1base.h.

Referenced by CaptureSpriteBackground(), and RestoreSpriteBackground().

Typedef Documentation

◆ ActiveSoundEntry

typedef struct ActiveSoundEntry ActiveSoundEntry

◆ CockpitReadout

typedef struct CockpitReadout CockpitReadout

◆ CockpitReadout_size_must_be_0x0a

typedef char CockpitReadout_size_must_be_0x0a[ sizeof(CockpitReadout)==0x0a ? 1 :-1]

Definition at line 304 of file wc1base.h.

◆ DebugOverlayConsole

DebugOverlayConsole::DebugOverlayConsole

Definition at line 23 of file debug.cpp.

◆ FontWorkspace

typedef struct FontWorkspace FontWorkspace

◆ HudMessageSlot

typedef struct HudMessageSlot HudMessageSlot

◆ InputDeviceSample

typedef struct InputDeviceSample InputDeviceSample

◆ InputEvent

typedef struct InputEvent InputEvent

◆ InputEventState

typedef struct InputEventState InputEventState

◆ IxSample

typedef struct IxSample IxSample

Definition at line 49 of file wc1base.h.

◆ IxSound

typedef struct IxSound IxSound

Definition at line 48 of file wc1base.h.

◆ ModalTextPanel

typedef struct ModalTextPanel ModalTextPanel

◆ MouseCursorState

typedef struct MouseCursorState MouseCursorState

◆ MouseCursorState_size_must_be_0x1c

typedef char MouseCursorState_size_must_be_0x1c[ sizeof(MouseCursorState)==0x1c ? 1 :-1]

Definition at line 116 of file wc1base.h.

◆ PackedResourcePointer

Definition at line 44 of file wc1base.h.

◆ RasterClip

typedef struct RasterClip RasterClip

◆ RasterSurface

typedef struct RasterSurface RasterSurface

◆ RLEFrameHeader

typedef struct RLEFrameHeader RLEFrameHeader

◆ RoomMenu

typedef struct RoomMenu RoomMenu

◆ RoomMenu_size_must_be_0x29

typedef char RoomMenu_size_must_be_0x29[ sizeof(RoomMenu)==0x29 ? 1 :-1]

Definition at line 306 of file wc1base.h.

◆ ScreenAllocation

typedef struct ScreenAllocation ScreenAllocation

◆ TextContext

typedef struct TextContext TextContext

◆ UINT16

typedef unsigned short UINT16

Definition at line 41 of file wc1base.h.

◆ Viewport

typedef struct Viewport Viewport

◆ WaveTableEntry

typedef struct WaveTableEntry WaveTableEntry

Enumeration Type Documentation

◆ GAME_MODE

enum GAME_MODE
Enumerator
Player 

Definition at line 404 of file wc1base.h.

◆ GAME_STATUS

Enumerator
ALIVE 

Definition at line 409 of file wc1base.h.

Function Documentation

◆ ShowOnScreenMessage()

◆ SoundDebugPrintf()

◆ SystemDebugPrintf()