mirror of
https://github.com/kevinbentley/Descent3.git
synced 2025-01-22 11:28:56 +00:00
[Cleanup] Removed function declarations that are not implemented.
This commit is contained in:
parent
a637f1e883
commit
7b71873a69
@ -424,10 +424,8 @@ class grViewport {
|
|||||||
tCharProperties char_Props;
|
tCharProperties char_Props;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void draw_text(grTextAlign align, int x, int y, char *str);
|
|
||||||
void draw_text_line(int x, int y, char *str);
|
void draw_text_line(int x, int y, char *str);
|
||||||
void draw_text_line_clip(int x, int y, char *str);
|
void draw_text_line_clip(int x, int y, char *str);
|
||||||
int clip_line(int &l, int &t, int &r, int &b);
|
|
||||||
int clip_rect(int &x1, int &y1, int &x2, int &y2);
|
int clip_rect(int &x1, int &y1, int &x2, int &y2);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -487,10 +485,6 @@ public:
|
|||||||
grSurface *lock(); // lock and
|
grSurface *lock(); // lock and
|
||||||
void unlock(); // unlock (implicitly locks surface)
|
void unlock(); // unlock (implicitly locks surface)
|
||||||
|
|
||||||
friend grSurface *VP_GET_DRAWING_SURFACE();
|
|
||||||
friend void VP_BEGIN_DRAWING(grViewport *vp);
|
|
||||||
friend void VP_END_DRAWING();
|
|
||||||
|
|
||||||
// these functions only work on locked surfaces.
|
// these functions only work on locked surfaces.
|
||||||
void hline(ddgr_color, int x1, int x2, int y1);
|
void hline(ddgr_color, int x1, int x2, int y1);
|
||||||
void line(ddgr_color color, int x1, int y1, int x2, int y2);
|
void line(ddgr_color color, int x1, int y1, int x2, int y2);
|
||||||
|
@ -38,15 +38,6 @@ struct mem_bitmap {
|
|||||||
|
|
||||||
#define MEMFLAG_TRANSBLT 1
|
#define MEMFLAG_TRANSBLT 1
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Line Drawing Functions
|
|
||||||
|
|
||||||
void gr_Line(gr_pen *pen, int x1, int y1, int x2, int y2);
|
|
||||||
void gr_HLine(gr_pen *pen, int x1, int x2, int y);
|
|
||||||
void gr_VLine(gr_pen *pen, int y1, int y2, int x);
|
|
||||||
void gr_Rect(gr_pen *pen, int l, int t, int r, int b);
|
|
||||||
void gr_FillRect(gr_pen *pen, int l, int t, int r, int b);
|
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
// ---------------------------------------------------------------------------
|
||||||
// Memory surface functions
|
// Memory surface functions
|
||||||
|
|
||||||
|
@ -113,10 +113,6 @@ void GoalClearAll(object *obj);
|
|||||||
int GoalAddGoal(object *obj, uint32_t goal_type, void *args, int level = 0, float influence = 1.0f, int f_goal = 0,
|
int GoalAddGoal(object *obj, uint32_t goal_type, void *args, int level = 0, float influence = 1.0f, int f_goal = 0,
|
||||||
int guid = -1, char subtype = 0);
|
int guid = -1, char subtype = 0);
|
||||||
|
|
||||||
// Adds a ending condition to a goal
|
|
||||||
int GoalAddDisabler(object *obj, int goal_index, uint8_t ender_type, void *args, float percent = 1.0f,
|
|
||||||
float interval = 0.0f);
|
|
||||||
|
|
||||||
// Adds a enabler condition to a goal
|
// Adds a enabler condition to a goal
|
||||||
int GoalAddEnabler(object *obj, int goal_index, uint8_t enabler_type, void *arg_struct, float percent, float interval);
|
int GoalAddEnabler(object *obj, int goal_index, uint8_t enabler_type, void *arg_struct, float percent, float interval);
|
||||||
|
|
||||||
|
@ -183,7 +183,6 @@ void AITurnTowardsPosition(object *obj, /*velocity *new_vel,*/ vector *pos /*, b
|
|||||||
bool AIFindHidePos(object *hide_obj, object *view_obj, vector *hpos, int *hroom, float max_hide_time = 3.0f);
|
bool AIFindHidePos(object *hide_obj, object *view_obj, vector *hpos, int *hroom, float max_hide_time = 3.0f);
|
||||||
int AIFindRoomWithFlag(object *obj, int flag);
|
int AIFindRoomWithFlag(object *obj, int flag);
|
||||||
object *AIFindObjOfType(object *obj, int type, int id, bool f_ignore_init_room, int parent_handle = OBJECT_HANDLE_NONE);
|
object *AIFindObjOfType(object *obj, int type, int id, bool f_ignore_init_room, int parent_handle = OBJECT_HANDLE_NONE);
|
||||||
float AIFindDist(vector *s_pos, int s_roomnum, vector *e_pos, int e_roomnum, int flags);
|
|
||||||
bool AIStatusCircleFrame(object *obj, object *g_obj, float dist, float c_dist, int *status_reg);
|
bool AIStatusCircleFrame(object *obj, object *g_obj, float dist, float c_dist, int *status_reg);
|
||||||
bool AIObjEnemy(object *obj, object *target);
|
bool AIObjEnemy(object *obj, object *target);
|
||||||
bool AISetTarget(object *obj, int handle);
|
bool AISetTarget(object *obj, int handle);
|
||||||
|
@ -252,8 +252,6 @@ void MakeBOAVisTable(bool from_lighting = 0);
|
|||||||
void ComputeAABB(bool f_full);
|
void ComputeAABB(bool f_full);
|
||||||
|
|
||||||
bool BOA_ComputeMinDist(int start_room, int end_room, float max_check_dist, float *dist, int *num_blockages = NULL);
|
bool BOA_ComputeMinDist(int start_room, int end_room, float max_check_dist, float *dist, int *num_blockages = NULL);
|
||||||
bool BOA_ComputePropDist(int start_room, vector *start_pos, int end_room, vector *end_pos, float *dist,
|
|
||||||
int *num_blockages);
|
|
||||||
bool BOA_IsSoundAudible(int start_room, int end_room);
|
bool BOA_IsSoundAudible(int start_room, int end_room);
|
||||||
bool BOA_IsVisible(int start_room, int end_room);
|
bool BOA_IsVisible(int start_room, int end_room);
|
||||||
bool BOA_HasPossibleBlockage(int start_room, int end_room);
|
bool BOA_HasPossibleBlockage(int start_room, int end_room);
|
||||||
|
@ -52,9 +52,6 @@
|
|||||||
#ifndef _DEATHINFO_H
|
#ifndef _DEATHINFO_H
|
||||||
#define _DEATHINFO_H
|
#define _DEATHINFO_H
|
||||||
|
|
||||||
// Get the death delay type
|
|
||||||
#define DEATH_DELAY(f) (f & DF_DELAY_MASK)
|
|
||||||
|
|
||||||
// Get the explosion size
|
// Get the explosion size
|
||||||
#define DEATH_EXPL_SIZE(f) (f & DF_EXPL_SIZE_MASK)
|
#define DEATH_EXPL_SIZE(f) (f & DF_EXPL_SIZE_MASK)
|
||||||
|
|
||||||
|
@ -40,8 +40,6 @@ void D3W_TouchSound(int sound_index);
|
|||||||
void MonoPrintf(int n, char *format, ...);
|
void MonoPrintf(int n, char *format, ...);
|
||||||
// checks a players inventory for an object type/id
|
// checks a players inventory for an object type/id
|
||||||
bool InvCheckItem(int playernum, int type, int id);
|
bool InvCheckItem(int playernum, int type, int id);
|
||||||
// adds an object to a player inventory
|
|
||||||
bool InvAdd(int playernum, object *obj, bool remove = true);
|
|
||||||
// adds a type/id to a player inventory
|
// adds a type/id to a player inventory
|
||||||
bool InvAddTypeID(int playernum, int type, int id, int aux_type = -1, int aux_id = -1, int flags = 0, const char *description = NULL);
|
bool InvAddTypeID(int playernum, int type, int id, int aux_type = -1, int aux_id = -1, int flags = 0, const char *description = NULL);
|
||||||
// removes a type/id from a players inventory
|
// removes a type/id from a players inventory
|
||||||
|
@ -307,9 +307,6 @@ bool LoadMissionLevel(int level);
|
|||||||
// initializes the mission script
|
// initializes the mission script
|
||||||
bool InitMissionScript();
|
bool InitMissionScript();
|
||||||
|
|
||||||
// Objectives
|
|
||||||
void CompletedPrimaryObjective();
|
|
||||||
|
|
||||||
// Shows text on a background
|
// Shows text on a background
|
||||||
void ShowProgressScreen(const char *str, const char *str2 = NULL, bool flip = true);
|
void ShowProgressScreen(const char *str, const char *str2 = NULL, bool flip = true);
|
||||||
|
|
||||||
|
@ -31,9 +31,6 @@
|
|||||||
// inits the Telcom system...needs to be called before anything else, only needs to be called once
|
// inits the Telcom system...needs to be called before anything else, only needs to be called once
|
||||||
void TelComInit(void);
|
void TelComInit(void);
|
||||||
|
|
||||||
// handles input processing, etc
|
|
||||||
void TelComDefer(void);
|
|
||||||
|
|
||||||
// Pages in all the necessary bitmaps, textures & sounds for the TelCom so that they are in memory
|
// Pages in all the necessary bitmaps, textures & sounds for the TelCom so that they are in memory
|
||||||
void TelcomPageAllIn(void);
|
void TelcomPageAllIn(void);
|
||||||
|
|
||||||
@ -150,17 +147,6 @@ int HotSpotL(int hotspot);
|
|||||||
int HotSpotR(int hotspot);
|
int HotSpotR(int hotspot);
|
||||||
int HotSpotT(int hotspot);
|
int HotSpotT(int hotspot);
|
||||||
int HotSpotB(int hotspot);
|
int HotSpotB(int hotspot);
|
||||||
/*
|
|
||||||
void TCStartPowerupSound(void);
|
|
||||||
void TCStopPowerupSound(void);
|
|
||||||
void TCStartPowerDownSound(void);
|
|
||||||
void TCStopPowerDownSound(void);
|
|
||||||
void TCStartRunningSound(void);
|
|
||||||
void TCStopRunningSound(void);
|
|
||||||
void TCStartStaticSound(float amp);
|
|
||||||
*/
|
|
||||||
void TCStartBulbSound(void);
|
|
||||||
void DoCursor(void);
|
|
||||||
|
|
||||||
extern hotspotmap_t hotspotmap;
|
extern hotspotmap_t hotspotmap;
|
||||||
extern windowmap_t windowmap;
|
extern windowmap_t windowmap;
|
||||||
|
@ -101,7 +101,6 @@ void BuildBSPTree();
|
|||||||
// Runs a ray through the bsp tree
|
// Runs a ray through the bsp tree
|
||||||
// Returns true if a ray is occludes
|
// Returns true if a ray is occludes
|
||||||
int BSPRayOccluded(vector *start, vector *end, bspnode *node);
|
int BSPRayOccluded(vector *start, vector *end, bspnode *node);
|
||||||
int BSPReportStatus(vector *start, bspnode *node);
|
|
||||||
|
|
||||||
// Walks the BSP tree and frees up any nodes/polygons that we might be using
|
// Walks the BSP tree and frees up any nodes/polygons that we might be using
|
||||||
void DestroyBSPTree(bsptree *tree);
|
void DestroyBSPTree(bsptree *tree);
|
||||||
|
@ -173,8 +173,6 @@ struct tDetailSettings {
|
|||||||
|
|
||||||
// Call this with one of the above defines to set the detail level to a predefined set (custom level is ignored)
|
// Call this with one of the above defines to set the detail level to a predefined set (custom level is ignored)
|
||||||
void ConfigSetDetailLevel(int level);
|
void ConfigSetDetailLevel(int level);
|
||||||
// returns the current detail level that the given tDetailSettings is at
|
|
||||||
int ConfigGetDetailLevel(tDetailSettings *ds);
|
|
||||||
|
|
||||||
#define DETAIL_LEVEL_LOW 0
|
#define DETAIL_LEVEL_LOW 0
|
||||||
#define DETAIL_LEVEL_MED 1
|
#define DETAIL_LEVEL_MED 1
|
||||||
|
@ -214,16 +214,6 @@ void D3DeferHandler(bool is_active);
|
|||||||
void SetFunctionMode(function_mode mode);
|
void SetFunctionMode(function_mode mode);
|
||||||
function_mode GetFunctionMode();
|
function_mode GetFunctionMode();
|
||||||
|
|
||||||
// these functions create viewports from the game screen in a 'nice' C way
|
|
||||||
void CreateGameViewport(grViewport **vp);
|
|
||||||
void DestroyGameViewport(grViewport *vp);
|
|
||||||
|
|
||||||
inline void CREATE_VIEWPORT(grViewport **vp) { CreateGameViewport(vp); }
|
|
||||||
|
|
||||||
inline void DESTROY_VIEWPORT(grViewport *vp) { DestroyGameViewport(vp); }
|
|
||||||
|
|
||||||
inline void DELAY(float secs) { Descent->delay(secs); }
|
|
||||||
|
|
||||||
#ifndef RELEASE
|
#ifndef RELEASE
|
||||||
// this is called when you hit a debug break!
|
// this is called when you hit a debug break!
|
||||||
void D3DebugStopHandler();
|
void D3DebugStopHandler();
|
||||||
|
@ -212,9 +212,6 @@ void DoDebrisFrame(object *obj);
|
|||||||
// Process a dying object for one frame
|
// Process a dying object for one frame
|
||||||
void DoDyingFrame(object *objp);
|
void DoDyingFrame(object *objp);
|
||||||
|
|
||||||
// A quick way to see where a weapon hits. Weapons make debris.
|
|
||||||
void CreateWeaponDebris(object *obj);
|
|
||||||
|
|
||||||
// Creates a concussive blast (physics based -- no visuals)
|
// Creates a concussive blast (physics based -- no visuals)
|
||||||
void MakeShockwave(object *explode_obj_ptr, int parent_handle);
|
void MakeShockwave(object *explode_obj_ptr, int parent_handle);
|
||||||
|
|
||||||
|
@ -331,13 +331,6 @@ extern int Missile_camera_window;
|
|||||||
// contains all relevent information for gamemode pertaining to d3x system.
|
// contains all relevent information for gamemode pertaining to d3x system.
|
||||||
extern gamemode Gamemode_info;
|
extern gamemode Gamemode_info;
|
||||||
|
|
||||||
// Starts the game-engine "cutscene"
|
|
||||||
// Puts the player in AI mode, sets the view to an external camera, switches to letterbox, & puts the player on a path
|
|
||||||
// Parameters: camera - the camera for the view
|
|
||||||
// pathnum - the path the player should follow
|
|
||||||
// time - if > 0.0, how long the sequence plays before the level ends
|
|
||||||
void StartEndlevelSequence(object *camera, int pathnum, float time);
|
|
||||||
|
|
||||||
inline void ResetGamemode() {
|
inline void ResetGamemode() {
|
||||||
Gamemode_info.scriptname[0] = 0;
|
Gamemode_info.scriptname[0] = 0;
|
||||||
Gamemode_info.requested_num_teams = 1;
|
Gamemode_info.requested_num_teams = 1;
|
||||||
|
@ -313,7 +313,6 @@ extern int Num_textures;
|
|||||||
|
|
||||||
// Inits the texture system, returning 1 if successful
|
// Inits the texture system, returning 1 if successful
|
||||||
int InitTextures();
|
int InitTextures();
|
||||||
void ShutdownTextures();
|
|
||||||
|
|
||||||
// Set aside a texture for use
|
// Set aside a texture for use
|
||||||
int AllocTexture(void);
|
int AllocTexture(void);
|
||||||
|
@ -358,17 +358,10 @@ bool AddBlinkingHUDMessage(const char *format, ...);
|
|||||||
// a "-playermessages" command line.
|
// a "-playermessages" command line.
|
||||||
bool AddFilteredHUDMessage(const char *format, ...);
|
bool AddFilteredHUDMessage(const char *format, ...);
|
||||||
|
|
||||||
// initializes other hud stuff
|
|
||||||
void SetHUDEnergyImage(const char *energy_img);
|
|
||||||
void SetHUDAfterburnImage(const char *afterburn_img);
|
|
||||||
|
|
||||||
// Renders all the messages we have in the message list. If HUD_MESSAGE_TIME has
|
// Renders all the messages we have in the message list. If HUD_MESSAGE_TIME has
|
||||||
// elapsed, then punt the oldest message and move the others up one
|
// elapsed, then punt the oldest message and move the others up one
|
||||||
void RenderHUDMessages();
|
void RenderHUDMessages();
|
||||||
|
|
||||||
// renders ship stats
|
|
||||||
void RenderHUDStats(tStatMask stat_mask);
|
|
||||||
|
|
||||||
// Handles all incoming keys for an inputted hud message
|
// Handles all incoming keys for an inputted hud message
|
||||||
void DoHUDInputMessageKey(int key);
|
void DoHUDInputMessageKey(int key);
|
||||||
|
|
||||||
|
@ -74,29 +74,12 @@ void ClearDynamicLightmaps();
|
|||||||
void ApplyLightingToTerrain(vector *pos, int cellnum, float light_dist, float red_scale, float green_scale,
|
void ApplyLightingToTerrain(vector *pos, int cellnum, float light_dist, float red_scale, float green_scale,
|
||||||
float blue_scale, vector *light_direction = NULL, float dot_range = 0);
|
float blue_scale, vector *light_direction = NULL, float dot_range = 0);
|
||||||
|
|
||||||
// Gets the viewable lightmap elements
|
|
||||||
void FindValidLightmapElements(face *fp, dynamic_face *dynamic_fp, vector *light_pos, float light_dist);
|
|
||||||
// Does a quad tree algo to find what lightmap elements are viewable from our lightsource
|
|
||||||
int SearchLightQuadTree(face *fp, vector *rvec, vector *uvec, dynamic_face *dynamic_fp, vector *light_pos,
|
|
||||||
float light_dist);
|
|
||||||
|
|
||||||
// Given a float, returns the index into the Ubyte_float_table that this number
|
// Given a float, returns the index into the Ubyte_float_table that this number
|
||||||
// corresponds to
|
// corresponds to
|
||||||
uint8_t Float_to_ubyte(float fnum);
|
uint8_t Float_to_ubyte(float fnum);
|
||||||
|
|
||||||
extern float Ubyte_to_float[];
|
extern float Ubyte_to_float[];
|
||||||
|
|
||||||
// Draws the shadows that happen to be falling on a particular face
|
|
||||||
void DoShadowsForFace(room *rp, int facenum);
|
|
||||||
|
|
||||||
// Sets the num_timer_faces field in Room structure to correspond to the number of faces
|
|
||||||
// that have flickering lights
|
|
||||||
void CountFaceLights();
|
|
||||||
|
|
||||||
// Goes through all rooms and all faces and lights any faces that have their timer values
|
|
||||||
// set
|
|
||||||
void DoFaceLighting();
|
|
||||||
|
|
||||||
// Sets pulse parameters for an entire room
|
// Sets pulse parameters for an entire room
|
||||||
void SetRoomPulse(room *rp, uint8_t pulse_time, uint8_t pulse_offset);
|
void SetRoomPulse(room *rp, uint8_t pulse_time, uint8_t pulse_offset);
|
||||||
|
|
||||||
|
@ -102,10 +102,6 @@ struct menu {
|
|||||||
// this displays the main menu options and runs the menu system
|
// this displays the main menu options and runs the menu system
|
||||||
int MainMenu();
|
int MainMenu();
|
||||||
|
|
||||||
// opens options menu.
|
|
||||||
// ingame = true (if calling while playing the game)
|
|
||||||
void MenuOptions(bool ingame);
|
|
||||||
|
|
||||||
// DisplayLevelWarpDlg
|
// DisplayLevelWarpDlg
|
||||||
// pass in the max level allowed to be chosen, if -1, than all levels are allowed (a.k.a level warp cheat)
|
// pass in the max level allowed to be chosen, if -1, than all levels are allowed (a.k.a level warp cheat)
|
||||||
int DisplayLevelWarpDlg(int max_level);
|
int DisplayLevelWarpDlg(int max_level);
|
||||||
|
@ -911,12 +911,6 @@ void MultiExtractMatrix(matrix *dest, multi_orientation *src);
|
|||||||
|
|
||||||
void MultiSendBlowupBuilding(int, int, float);
|
void MultiSendBlowupBuilding(int, int, float);
|
||||||
|
|
||||||
// Return index of powerup that has matching table entry
|
|
||||||
int MultiMatchPowerup(int unique_id);
|
|
||||||
|
|
||||||
// Return index of robot that has matching table entry
|
|
||||||
int MultiMatchRobot(int unique_id);
|
|
||||||
|
|
||||||
// Builds the tables for uniquely identifying powerups and robots
|
// Builds the tables for uniquely identifying powerups and robots
|
||||||
void MultiBuildMatchTables();
|
void MultiBuildMatchTables();
|
||||||
|
|
||||||
|
@ -35,8 +35,4 @@ struct saved_move {
|
|||||||
extern saved_move SavedMoves[];
|
extern saved_move SavedMoves[];
|
||||||
extern int Current_saved_move;
|
extern int Current_saved_move;
|
||||||
|
|
||||||
// Alloc and free saved move
|
|
||||||
extern int MultiAllocSavedMove();
|
|
||||||
extern void MultiFreeSavedMove(int);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// Returns true if we're starting a multiplayer game
|
// Returns true if we're starting a multiplayer game
|
||||||
int MainMultiplayerMenu();
|
int MainMultiplayerMenu();
|
||||||
int SearchMasterTrackerGameMenu();
|
int SearchMasterTrackerGameMenu();
|
||||||
int LoginMasterTrackerGameMenu();
|
|
||||||
int AutoConnectPXO();
|
int AutoConnectPXO();
|
||||||
int AutoConnectLANIP();
|
int AutoConnectLANIP();
|
||||||
int AutoConnectHeat();
|
int AutoConnectHeat();
|
||||||
|
@ -766,9 +766,6 @@ void ObjDoFrameAll();
|
|||||||
// set viewer object to next object in array
|
// set viewer object to next object in array
|
||||||
void ObjGotoNextViewer();
|
void ObjGotoNextViewer();
|
||||||
|
|
||||||
// move an object for the current frame
|
|
||||||
void ObjMoveOne(object *obj);
|
|
||||||
|
|
||||||
// Sets the position of an object. This should be called whenever an object moves.
|
// Sets the position of an object. This should be called whenever an object moves.
|
||||||
// Parameters: obj - the object being moved
|
// Parameters: obj - the object being moved
|
||||||
// pos - the new position
|
// pos - the new position
|
||||||
|
@ -552,10 +552,6 @@ int GetObjectImage(int handle);
|
|||||||
// Given an object, renders the representation of this object
|
// Given an object, renders the representation of this object
|
||||||
void DrawObject(object *obj);
|
void DrawObject(object *obj);
|
||||||
|
|
||||||
// Moves an object from a given index into a new one (above MAX_STATIC_IDS)
|
|
||||||
// returns new index
|
|
||||||
int MoveObjectFromIndex(int index);
|
|
||||||
|
|
||||||
// Remap all the static object ids (objects that must have a specific index) into their assigned slots.
|
// Remap all the static object ids (objects that must have a specific index) into their assigned slots.
|
||||||
void RemapStaticIDs();
|
void RemapStaticIDs();
|
||||||
|
|
||||||
|
@ -245,7 +245,6 @@ int osipf_AISetGoalFlags(int objhandle, int goal_handle, int flags, uint8_t f_en
|
|||||||
uint8_t osipf_AITurnTowardsVectors(int objhandle, vector *fvec, vector *uvec);
|
uint8_t osipf_AITurnTowardsVectors(int objhandle, vector *fvec, vector *uvec);
|
||||||
uint8_t osipf_AIMoveTowardsPosition(int objhandle, vector *pos, int *roomnum, float scalar, bool f_bline,
|
uint8_t osipf_AIMoveTowardsPosition(int objhandle, vector *pos, int *roomnum, float scalar, bool f_bline,
|
||||||
bool f_bline_if_vis);
|
bool f_bline_if_vis);
|
||||||
uint8_t osipf_AIMoveTowardsDir(int objhandle, vector *dir, float scalar);
|
|
||||||
|
|
||||||
void osipf_AIValue(int objhandle, char op, char vtype, void *ptr);
|
void osipf_AIValue(int objhandle, char op, char vtype, void *ptr);
|
||||||
|
|
||||||
|
@ -192,7 +192,7 @@
|
|||||||
// Brings up a window where you can select a pilot to use
|
// Brings up a window where you can select a pilot to use
|
||||||
void PilotSelect();
|
void PilotSelect();
|
||||||
|
|
||||||
// creates a new pilot (and pilot file) (if you call this you should call PilotConfig() after it)
|
// creates a new pilot (and pilot file)
|
||||||
// Returns: true on success
|
// Returns: true on success
|
||||||
// Pilot: pointer to pilot structure to be filled in with name and filename (should then configure the rest)
|
// Pilot: pointer to pilot structure to be filled in with name and filename (should then configure the rest)
|
||||||
bool PilotCreate(pilot *Pilot, bool dontallowcancel);
|
bool PilotCreate(pilot *Pilot, bool dontallowcancel);
|
||||||
|
@ -286,7 +286,6 @@ void GenerateTerrainLight();
|
|||||||
void BuildMinMaxTerrain();
|
void BuildMinMaxTerrain();
|
||||||
void BuildTerrainNormals();
|
void BuildTerrainNormals();
|
||||||
|
|
||||||
int DrawTerrainTriangles(int n);
|
|
||||||
int LoadPCXTerrain(char *);
|
int LoadPCXTerrain(char *);
|
||||||
|
|
||||||
// Given a position, returns the terrain segment that that position is in/over
|
// Given a position, returns the terrain segment that that position is in/over
|
||||||
@ -297,11 +296,6 @@ int GetTerrainCellFromPos(vector *pos);
|
|||||||
// The return value is a valid room number, meaning it has the outside flag set
|
// The return value is a valid room number, meaning it has the outside flag set
|
||||||
int GetTerrainRoomFromPos(vector *pos);
|
int GetTerrainRoomFromPos(vector *pos);
|
||||||
|
|
||||||
// Given a position, returns the collision terrain segment that that position is in/over
|
|
||||||
int GetColTerrainSegFromPos(vector *pos);
|
|
||||||
// Given a terrain cell, returns the collision terrain segment that that position is in/over
|
|
||||||
int GetColTerrainSegFromTerrainSeg(int cell_index);
|
|
||||||
|
|
||||||
// Computes the center of the segment in x,z and also sets y touching the ground
|
// Computes the center of the segment in x,z and also sets y touching the ground
|
||||||
void ComputeTerrainSegmentCenter(vector *pos, int segnum);
|
void ComputeTerrainSegmentCenter(vector *pos, int segnum);
|
||||||
// Given an position, returns the terrain Y coord at that location
|
// Given an position, returns the terrain Y coord at that location
|
||||||
@ -322,10 +316,6 @@ void GetSpecialRotatedPoint(g3Point *dest, int x, int z, float yvalue);
|
|||||||
// Takes our light angle and fills in the appropriate values in the lightsource vector
|
// Takes our light angle and fills in the appropriate values in the lightsource vector
|
||||||
void GenerateLightSource();
|
void GenerateLightSource();
|
||||||
|
|
||||||
// Returns the terrain segment index of the farthest point that mine segment "mine_seg"
|
|
||||||
// touches. Based on Camera_direction
|
|
||||||
int GetFurthestMineSegment(int mine_seg);
|
|
||||||
|
|
||||||
// codes a point for visibility in the window passed to RenderTerrain()
|
// codes a point for visibility in the window passed to RenderTerrain()
|
||||||
uint8_t CodeTerrainPoint(g3Point *p);
|
uint8_t CodeTerrainPoint(g3Point *p);
|
||||||
|
|
||||||
@ -335,9 +325,6 @@ void GenerateLODDeltas();
|
|||||||
// Generates lightmaps based on the info given by the .light field of each Terrain_seg
|
// Generates lightmaps based on the info given by the .light field of each Terrain_seg
|
||||||
void UpdateTerrainLightmaps();
|
void UpdateTerrainLightmaps();
|
||||||
|
|
||||||
// Makes a four sided rectangle pinched into a triangle
|
|
||||||
void MakePinchBitmap(int dest_bm, int src_bm);
|
|
||||||
|
|
||||||
// Gets the dynamic light value for this position
|
// Gets the dynamic light value for this position
|
||||||
float GetTerrainDynamicScalar(vector *pos, int seg);
|
float GetTerrainDynamicScalar(vector *pos, int seg);
|
||||||
|
|
||||||
|
@ -380,10 +380,6 @@ void RemapWeapons();
|
|||||||
// and changes the old index to the new index
|
// and changes the old index to the new index
|
||||||
void RemapAllWeaponObjects(int old_index, int new_index);
|
void RemapAllWeaponObjects(int old_index, int new_index);
|
||||||
|
|
||||||
// Creates a weapon
|
|
||||||
// Returns the objnum of the weapon object
|
|
||||||
int CreateWeaponObject(int weapon_num, int segnum, vector *position, int flags);
|
|
||||||
|
|
||||||
// Creates an weapon and sends it speeding on its way
|
// Creates an weapon and sends it speeding on its way
|
||||||
// returns the objnum of the weapon
|
// returns the objnum of the weapon
|
||||||
int CreateAndFireWeapon(vector *pos, vector *dir, object *parent, int weapon_num);
|
int CreateAndFireWeapon(vector *pos, vector *dir, object *parent, int weapon_num);
|
||||||
@ -419,9 +415,6 @@ bool WeaponCalcGun(vector *gun_point, vector *gun_normal, object *obj, int gun_n
|
|||||||
// Checks for relation between weapons and other objects
|
// Checks for relation between weapons and other objects
|
||||||
extern bool ObjectsAreRelated(int o1, int o2);
|
extern bool ObjectsAreRelated(int o1, int o2);
|
||||||
|
|
||||||
// A quick way to see where a weapon hits. Weapons make debris.
|
|
||||||
void CreateWeaponDebris(object *obj);
|
|
||||||
|
|
||||||
// Selects a weapon
|
// Selects a weapon
|
||||||
void SelectWeapon(int slot);
|
void SelectWeapon(int slot);
|
||||||
|
|
||||||
|
@ -50,8 +50,6 @@ int bm_tga_alloc_file(CFILE *infile, char *name, int format = 0);
|
|||||||
// Loads a pcx file and converts it to 16 bit. Returns bitmap handle or -1 on error
|
// Loads a pcx file and converts it to 16 bit. Returns bitmap handle or -1 on error
|
||||||
int bm_pcx_alloc_file(CFILE *infile);
|
int bm_pcx_alloc_file(CFILE *infile);
|
||||||
|
|
||||||
int bm_tga_load_short_file(CFILE *infile, char *name);
|
|
||||||
|
|
||||||
// Pages in bitmap index n. Returns 1 if successful, 0 if not
|
// Pages in bitmap index n. Returns 1 if successful, 0 if not
|
||||||
int bm_page_in_file(int n);
|
int bm_page_in_file(int n);
|
||||||
|
|
||||||
|
@ -76,11 +76,9 @@
|
|||||||
#define mprintf(...) Debug_ConsolePrintf(__VA_ARGS__)
|
#define mprintf(...) Debug_ConsolePrintf(__VA_ARGS__)
|
||||||
// Prints a formatted string on window n at row, col.
|
// Prints a formatted string on window n at row, col.
|
||||||
#define mprintf_at(...) Debug_ConsolePrintfAt(__VA_ARGS__)
|
#define mprintf_at(...) Debug_ConsolePrintfAt(__VA_ARGS__)
|
||||||
#define DebugBlockPrint(...)
|
|
||||||
#else // ifdef _DEBUG
|
#else // ifdef _DEBUG
|
||||||
// DAJ defined in target headers
|
// DAJ defined in target headers
|
||||||
#define mprintf(...)
|
#define mprintf(...)
|
||||||
#define mprintf_at(...)
|
#define mprintf_at(...)
|
||||||
#define DebugBlockPrint(...)
|
|
||||||
#endif // ifdef _DEBUG
|
#endif // ifdef _DEBUG
|
||||||
#endif
|
#endif
|
||||||
|
@ -85,7 +85,6 @@ static struct {
|
|||||||
tJoyInfo caps;
|
tJoyInfo caps;
|
||||||
} Joysticks[MAX_JOYSTICKS];
|
} Joysticks[MAX_JOYSTICKS];
|
||||||
void joy_Close();
|
void joy_Close();
|
||||||
void joy_GetState(tJoystick stick, tJoyPos *pos);
|
|
||||||
static int joyGetNumDevs(void);
|
static int joyGetNumDevs(void);
|
||||||
// closes a stick
|
// closes a stick
|
||||||
// closes connection with controller.
|
// closes connection with controller.
|
||||||
|
@ -57,8 +57,6 @@
|
|||||||
#include "vecmat.h"
|
#include "vecmat.h"
|
||||||
|
|
||||||
void DrawWorld(grViewport *vp, vector *view_target, matrix *view_orient, float view_dist, int start_room, float rad);
|
void DrawWorld(grViewport *vp, vector *view_target, matrix *view_orient, float view_dist, int start_room, float rad);
|
||||||
void DrawWorldRoom(grViewport *vp, vector *view_target, matrix *view_orient, float view_dist, int start_room,
|
|
||||||
int depth);
|
|
||||||
|
|
||||||
void DrawTerrainWorld(grViewport *vp, vector *view_target, matrix *view_orient, float view_dist);
|
void DrawTerrainWorld(grViewport *vp, vector *view_target, matrix *view_orient, float view_dist);
|
||||||
|
|
||||||
|
@ -193,24 +193,6 @@ void grtext_Flush();
|
|||||||
// renders all text but DOESN'T flush buffer
|
// renders all text but DOESN'T flush buffer
|
||||||
void grtext_Render();
|
void grtext_Render();
|
||||||
|
|
||||||
// gets character information for the current string
|
|
||||||
// ch is a SINGLE CHARACTER
|
|
||||||
// col is the color of the current string as reported through formatting, or GR_NULL if no info
|
|
||||||
// x is the old x before call and the new potential adjusted x after the call.
|
|
||||||
// newline if it's a newline.
|
|
||||||
// line start x;
|
|
||||||
struct tGetCharInfo {
|
|
||||||
int sx; // this will not be modified. the initial x on the same line as the string
|
|
||||||
|
|
||||||
ddgr_color col; // these values will be modified
|
|
||||||
int x, w; // x of char, and width of char.
|
|
||||||
bool newline; // reached a newline?
|
|
||||||
bool font_char; // character exists in font?
|
|
||||||
char ch;
|
|
||||||
};
|
|
||||||
|
|
||||||
const char *grtext_GetChar(const char *str, tGetCharInfo *ci);
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
// font functions!
|
// font functions!
|
||||||
|
|
||||||
|
34
lib/3d.h
34
lib/3d.h
@ -187,8 +187,6 @@
|
|||||||
#include "grdefs.h"
|
#include "grdefs.h"
|
||||||
#include "float.h"
|
#include "float.h"
|
||||||
|
|
||||||
extern int g3d_interp_outline; // if on, polygon models outlined in white
|
|
||||||
|
|
||||||
extern vector Matrix_scale; // how the matrix is currently scaled
|
extern vector Matrix_scale; // how the matrix is currently scaled
|
||||||
|
|
||||||
// Structure for storing u,v,light values. This structure doesn't have a
|
// Structure for storing u,v,light values. This structure doesn't have a
|
||||||
@ -294,25 +292,12 @@ void g3_DoneInstance();
|
|||||||
|
|
||||||
// Misc utility functions:
|
// Misc utility functions:
|
||||||
|
|
||||||
// get current field of view. Fills in angle for x & y
|
|
||||||
void g3_GetFOV(float *fov_x, float *fov_y);
|
|
||||||
|
|
||||||
// get zoom. For a given window size, return the zoom which will achieve
|
|
||||||
// the given FOV along the given axis.
|
|
||||||
float g3_GetZoom(char axis, float fov, int16_t window_width, int16_t window_height);
|
|
||||||
|
|
||||||
// returns the normalized, unscaled view vectors
|
|
||||||
void g3_GetViewVectors(vector *forward, vector *up, vector *right);
|
|
||||||
|
|
||||||
// returns true if a plane is facing the viewer. takes the unrotated surface
|
// returns true if a plane is facing the viewer. takes the unrotated surface
|
||||||
// normal of the plane, and a point on it. The normal need not be normalized
|
// normal of the plane, and a point on it. The normal need not be normalized
|
||||||
bool g3_CheckNormalFacing(vector *v, vector *norm);
|
bool g3_CheckNormalFacing(vector *v, vector *norm);
|
||||||
|
|
||||||
// Point definition and rotation functions:
|
// Point definition and rotation functions:
|
||||||
|
|
||||||
// returns codes_and & codes_or of a list of points numbers
|
|
||||||
g3Codes g3_CheckCodes(int nv, g3Point **pointlist);
|
|
||||||
|
|
||||||
// rotates a point. returns codes. does not check if already rotated
|
// rotates a point. returns codes. does not check if already rotated
|
||||||
uint8_t g3_RotatePoint(g3Point *dest, vector *src);
|
uint8_t g3_RotatePoint(g3Point *dest, vector *src);
|
||||||
|
|
||||||
@ -363,25 +348,6 @@ void g3_DrawBitmap(vector *pos, float width, float height, int bm, int color = -
|
|||||||
// Draws a bitmap that has been rotated about its center. Angle of rotation is passed as 'rot_angle'
|
// Draws a bitmap that has been rotated about its center. Angle of rotation is passed as 'rot_angle'
|
||||||
void g3_DrawRotatedBitmap(vector *pos, angle rot_angle, float width, float height, int bm, int color = -1);
|
void g3_DrawRotatedBitmap(vector *pos, angle rot_angle, float width, float height, int bm, int color = -1);
|
||||||
|
|
||||||
// specifies 2d drawing routines to use instead of defaults. Passing
|
|
||||||
// NULL for either or both restores defaults
|
|
||||||
void g3_SetSpecialRender(void (*tmap_drawer)(), void (*flat_drawer)(), int (*line_drawer)());
|
|
||||||
|
|
||||||
// Object functions:
|
|
||||||
|
|
||||||
// init code for bitmap models
|
|
||||||
void g3_InitPolygonModel(void *model_ptr);
|
|
||||||
|
|
||||||
// un-initialize, i.e., convert color entries back to RGB15
|
|
||||||
void g3_UninitPolygonModel(void *model_ptr);
|
|
||||||
|
|
||||||
// alternate interpreter for morphing object
|
|
||||||
void g3_DrawMorphingModel(void *model_ptr, int *model_bitmaps, angvec *anim_angles, float light, vector *new_points);
|
|
||||||
|
|
||||||
// this remaps the 15bpp colors for the models into a new palette. It should
|
|
||||||
// be called whenever the palette changes
|
|
||||||
void g3_RemapInterpColors(void);
|
|
||||||
|
|
||||||
// Draw a wireframe box aligned with the screen. Used for the editor.
|
// Draw a wireframe box aligned with the screen. Used for the editor.
|
||||||
// Parameters: color - the color to draw the lines
|
// Parameters: color - the color to draw the lines
|
||||||
// pnt - the center point
|
// pnt - the center point
|
||||||
|
29
lib/Ddgr.h
29
lib/Ddgr.h
@ -232,33 +232,4 @@ bool ddgr_surf_FlipVideo(ddgr_surface *sf);
|
|||||||
void ddgr_surf_Clear(ddgr_surface *dsf, ddgr_color col, int l, int t, int w, int h);
|
void ddgr_surf_Clear(ddgr_surface *dsf, ddgr_color col, int l, int t, int w, int h);
|
||||||
bool ddgr_surf_Blt(ddgr_surface *dsf, int dx, int dy, ddgr_surface *ssf, int sx, int sy, int sw, int sh);
|
bool ddgr_surf_Blt(ddgr_surface *dsf, int dx, int dy, ddgr_surface *ssf, int sx, int sy, int sw, int sh);
|
||||||
|
|
||||||
/*
|
|
||||||
8-bit palette surface structures
|
|
||||||
*/
|
|
||||||
struct ddgr_rgb {
|
|
||||||
uint8_t r, g, b; // RGB triplet
|
|
||||||
uint8_t x; // reserved...
|
|
||||||
};
|
|
||||||
|
|
||||||
struct ddgr_palette {
|
|
||||||
void *obj; // internal object
|
|
||||||
ddgr_rgb rgb[256]; // rgb values for palette.
|
|
||||||
};
|
|
||||||
|
|
||||||
// attaches a palette to an 8-bit surface only.
|
|
||||||
bool ddgr_surf_AttachPalette(ddgr_surface *surf, ddgr_palette *pal);
|
|
||||||
|
|
||||||
// grabs a palette.
|
|
||||||
bool ddgr_surf_GetPalette(ddgr_surface *surf, ddgr_palette *pal);
|
|
||||||
|
|
||||||
// creates and destroys palette objects.
|
|
||||||
bool ddgr_8bit_CreatePalette(ddgr_palette *pal);
|
|
||||||
bool ddgr_8bit_DestroyPalette(ddgr_palette *pal);
|
|
||||||
|
|
||||||
// loads a palette with specified entriyes
|
|
||||||
bool ddgr_8bit_LoadPalette(ddgr_palette *pal, int start, int count);
|
|
||||||
|
|
||||||
// returns an index into the palette
|
|
||||||
int ddgr_8bit_FindClosestColor(ddgr_palette *pal, ddgr_color col);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -426,28 +426,6 @@ bool ddio_ffjoy_SupportAutoCenter(tDevice dev);
|
|||||||
Private Functions
|
Private Functions
|
||||||
===========================================================================
|
===========================================================================
|
||||||
*/
|
*/
|
||||||
#if defined(WIN32)
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
// ddio_ffjoy_AcquireErr
|
|
||||||
// Purpose:
|
|
||||||
// Handle success/err reporting
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
static int ddio_ffjoy_AcquireErr(HRESULT res, int dev_num);
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
// FFEnumCallback
|
|
||||||
// Purpose:
|
|
||||||
// Initialize all connected joysticks.
|
|
||||||
//
|
|
||||||
// Input:
|
|
||||||
// pdinst info about the current joystick being enumed.
|
|
||||||
// pvRef the direct input object that was passed in before
|
|
||||||
// starting the enum process.
|
|
||||||
// Return:
|
|
||||||
// DIENUM_CONTINUE continue calling us with any more devices
|
|
||||||
// DIENUM_STOP all done, don't call us back anymore, go away.
|
|
||||||
// -------------------------------------------------------------------
|
|
||||||
BOOL CALLBACK FFEnumCallback(LPCDIDEVICEINSTANCE pdinst, LPVOID pvRef);
|
|
||||||
#endif
|
|
||||||
// Given a filename resource, this loads the file and creates a resource
|
// Given a filename resource, this loads the file and creates a resource
|
||||||
// for it. It returns a handle to that resource.
|
// for it. It returns a handle to that resource.
|
||||||
// If it returns NULL, then it couldn't load the project.
|
// If it returns NULL, then it couldn't load the project.
|
||||||
|
@ -125,11 +125,6 @@ struct tJoyInfo {
|
|||||||
#define JOY_INFO "INFO"
|
#define JOY_INFO "INFO"
|
||||||
#define JOY_POLL "POLL"
|
#define JOY_POLL "POLL"
|
||||||
|
|
||||||
struct tJoyPacket {
|
|
||||||
char coda[4]; // used to identify packet
|
|
||||||
char buf[128];
|
|
||||||
};
|
|
||||||
|
|
||||||
struct tJoyPos {
|
struct tJoyPos {
|
||||||
int x;
|
int x;
|
||||||
int y;
|
int y;
|
||||||
|
@ -393,11 +393,6 @@ uint16_t nw_CalculateChecksum(void *vptr, int len);
|
|||||||
// Sends data on an unreliable socket
|
// Sends data on an unreliable socket
|
||||||
int nw_Send(network_address *who_to, void *data, int len, int flags);
|
int nw_Send(network_address *who_to, void *data, int len, int flags);
|
||||||
|
|
||||||
// nw_ReceiveFromSocket will get data out of the socket and stuff it into the packet_buffers
|
|
||||||
// nw_Receive now calls this function, then determines which of the packet buffers
|
|
||||||
// to package up and use
|
|
||||||
void nw_ReceiveFromSocket();
|
|
||||||
|
|
||||||
// routine to "free" a packet buffer
|
// routine to "free" a packet buffer
|
||||||
void nw_FreePacket(int id);
|
void nw_FreePacket(int id);
|
||||||
|
|
||||||
@ -413,24 +408,9 @@ int nw_SendReliable(uint32_t socketid, uint8_t *data, int length, bool urgent =
|
|||||||
// and this may be a source of bugs).
|
// and this may be a source of bugs).
|
||||||
int nw_ReceiveReliable(SOCKET socket, uint8_t *buffer, int max_len);
|
int nw_ReceiveReliable(SOCKET socket, uint8_t *buffer, int max_len);
|
||||||
|
|
||||||
// Returns the current protocol in use
|
|
||||||
int nw_GetProtocolType();
|
|
||||||
|
|
||||||
// Copies my address into the passed argument
|
// Copies my address into the passed argument
|
||||||
void nw_GetMyAddress(network_address *addr);
|
void nw_GetMyAddress(network_address *addr);
|
||||||
|
|
||||||
// Sends a packet to the game tracker
|
|
||||||
int nw_SendGameTrackerPacker(void *packet);
|
|
||||||
|
|
||||||
// Checks for an incoming game tracker packet.
|
|
||||||
int nw_ReceiveGameTracker(void *packet);
|
|
||||||
|
|
||||||
// Send a packet to the pilot tracker
|
|
||||||
int nw_SendPilotTrackerPacket(void *packet);
|
|
||||||
|
|
||||||
// Checks for an incoming pilot tracker packet.
|
|
||||||
int nw_ReceivePilotTracker(void *packet);
|
|
||||||
|
|
||||||
int nw_PingCompare(const void *arg1, const void *arg2);
|
int nw_PingCompare(const void *arg1, const void *arg2);
|
||||||
|
|
||||||
// initialize the buffering system
|
// initialize the buffering system
|
||||||
|
@ -29,132 +29,5 @@ int opengl_Init(oeApplication *app, renderer_preferred_state *pref_state);
|
|||||||
|
|
||||||
// Closes down opengl
|
// Closes down opengl
|
||||||
void opengl_Close(const bool just_resizing=false);
|
void opengl_Close(const bool just_resizing=false);
|
||||||
void opengl_Shutdown();
|
|
||||||
|
|
||||||
// The main drawing function...draws a flat/textured/gouraud polygon
|
|
||||||
void opengl_DrawPolygon(int, g3Point **, int, int);
|
|
||||||
|
|
||||||
void opengl_SetFlatColor(ddgr_color color);
|
|
||||||
|
|
||||||
// Ends a frame
|
|
||||||
void opengl_EndFrame();
|
|
||||||
|
|
||||||
// Flips the screen
|
|
||||||
void opengl_Flip();
|
|
||||||
|
|
||||||
// Does setup for a new frame
|
|
||||||
void opengl_BeginFrame(int, int, int, int, int);
|
|
||||||
|
|
||||||
// Tells opengl what kind of texturing (linear/perspective) we want
|
|
||||||
void opengl_SetTextureType(texture_type);
|
|
||||||
|
|
||||||
// Sets the lighting state of opengl
|
|
||||||
void opengl_SetLightingState(light_state state);
|
|
||||||
|
|
||||||
// Sets the opengl color model (either rgb or mono)
|
|
||||||
void opengl_SetColorModel(color_model state);
|
|
||||||
|
|
||||||
// Sets the state of bilinear filtering for our textures
|
|
||||||
void opengl_SetFiltering(int8_t state);
|
|
||||||
|
|
||||||
// Sets the state of zbuffering to on or off
|
|
||||||
void opengl_SetZBufferState(int8_t state);
|
|
||||||
|
|
||||||
// Sets the near/far z values for zbuffering
|
|
||||||
void opengl_SetZValues(float nearz, float farz);
|
|
||||||
|
|
||||||
// Sets a bitmap as a lightmap to rendered on top of the next texture map
|
|
||||||
// a -1 value indicates no lighting map
|
|
||||||
void opengl_SetLightingMap(int handle);
|
|
||||||
|
|
||||||
// Clears the display to a specified color
|
|
||||||
void opengl_ClearScreen(ddgr_color color);
|
|
||||||
|
|
||||||
// Fills a rectangle on the display
|
|
||||||
void opengl_FillRect(ddgr_color color, int x1, int y1, int x2, int y2);
|
|
||||||
|
|
||||||
// Sets a pixel on the display
|
|
||||||
void opengl_SetPixel(ddgr_color color, int x, int y);
|
|
||||||
|
|
||||||
// Sets the near and far plane of fog
|
|
||||||
void opengl_SetFogBorders(float nearz, float farz);
|
|
||||||
|
|
||||||
// Sets the fog state to on or off
|
|
||||||
void opengl_SetFogState(int8_t state);
|
|
||||||
|
|
||||||
// Fills in projection variables
|
|
||||||
void opengl_GetProjectionParameters(int *width, int *height);
|
|
||||||
void opengl_GetProjectionScreenParameters(int &screenLX, int &screenTY, int &screenW, int &screenH);
|
|
||||||
|
|
||||||
// Returns the aspect ratio of the physical screen
|
|
||||||
float opengl_GetAspectRatio();
|
|
||||||
|
|
||||||
// Sets texture wrapping type
|
|
||||||
void opengl_SetWrapType(wrap_type val);
|
|
||||||
|
|
||||||
// Sets the constant alpha value
|
|
||||||
void opengl_SetAlphaValue(uint8_t val);
|
|
||||||
|
|
||||||
// Sets the overall alpha scale factor (all alpha values are scaled by this value)
|
|
||||||
// usefull for motion blur effect
|
|
||||||
void opengl_SetAlphaFactor(float val);
|
|
||||||
|
|
||||||
// Returns the current Alpha factor
|
|
||||||
float opengl_GetAlphaFactor(void);
|
|
||||||
|
|
||||||
// Sets the type of alpha blending you want
|
|
||||||
void opengl_SetAlphaType(int8_t atype);
|
|
||||||
|
|
||||||
// Sets whether or not to write into the zbuffer
|
|
||||||
void opengl_SetZBufferWriteMask(int state);
|
|
||||||
|
|
||||||
// Gets the current state of the renderer
|
|
||||||
void opengl_GetRenderState(rendering_state *rstate);
|
|
||||||
|
|
||||||
// draws a line
|
|
||||||
void opengl_DrawLine(int x1, int y1, int x2, int y2);
|
|
||||||
|
|
||||||
// draws a line
|
|
||||||
void opengl_DrawSpecialLine(g3Point *p0, g3Point *p1);
|
|
||||||
|
|
||||||
// Sets the color that opengl uses for fog
|
|
||||||
void opengl_SetFogColor(ddgr_color color);
|
|
||||||
|
|
||||||
// Sets the coplanar z bias for rendered polygons
|
|
||||||
void opengl_SetCoplanarPolygonOffset(float factor);
|
|
||||||
|
|
||||||
// Sets up a some global preferences for openGL
|
|
||||||
int opengl_SetPreferredState(renderer_preferred_state *pref_state);
|
|
||||||
|
|
||||||
// Sets the gamma correction value
|
|
||||||
void opengl_SetGammaValue(float val);
|
|
||||||
|
|
||||||
// Takes a screenshot of the frontbuffer and puts it into the passed bitmap handle
|
|
||||||
void opengl_Screenshot(int bm_handle);
|
|
||||||
|
|
||||||
// Returns the pixel color at x,y
|
|
||||||
ddgr_color opengl_GetPixel(int, int);
|
|
||||||
|
|
||||||
// Clears the zbuffer
|
|
||||||
void opengl_ClearZBuffer();
|
|
||||||
|
|
||||||
// Clears the texture cache
|
|
||||||
void opengl_ResetCache();
|
|
||||||
|
|
||||||
// Takes a bitmap and blits it to the screen using linear frame buffer stuff
|
|
||||||
// X and Y are the destination X,Y
|
|
||||||
void opengl_CopyBitmapToFramebuffer(int bm_handle, int x, int y);
|
|
||||||
|
|
||||||
// Gets a renderer ready for a framebuffer copy, or stops a framebuffer copy
|
|
||||||
void opengl_SetFrameBufferCopyState(bool state);
|
|
||||||
|
|
||||||
#if defined(WIN32)
|
|
||||||
// returns directdraw object
|
|
||||||
void *opengl_DirectDrawObj();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// returns rendering statistics for the frame
|
|
||||||
void opengl_GetStatistics(tRendererStats *stats);
|
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -187,9 +187,6 @@ extern void vm_MatrixMul(matrix *, matrix *, matrix *);
|
|||||||
// Multiply a matrix times the transpose of a matrix
|
// Multiply a matrix times the transpose of a matrix
|
||||||
void vm_MatrixMulTMatrix(matrix *dest, matrix *src0, matrix *src1);
|
void vm_MatrixMulTMatrix(matrix *dest, matrix *src0, matrix *src1);
|
||||||
|
|
||||||
// Computes all math look up tables, must be called before any vector stuff is used
|
|
||||||
extern void vm_InitMathTables();
|
|
||||||
|
|
||||||
// Given a vector, returns the magnitude. Uses sqrt so it's slow
|
// Given a vector, returns the magnitude. Uses sqrt so it's slow
|
||||||
extern float vm_GetMagnitude(vector *);
|
extern float vm_GetMagnitude(vector *);
|
||||||
|
|
||||||
|
@ -66,9 +66,4 @@ void mng_LoadLocalGamefilePage(CFILE *);
|
|||||||
// Reads in a page off the net
|
// Reads in a page off the net
|
||||||
void mng_LoadNetGamefilePage(CFILE *, bool overlay = false);
|
void mng_LoadNetGamefilePage(CFILE *, bool overlay = false);
|
||||||
|
|
||||||
// First searches through the gamefile index to see if the gamefile is already
|
|
||||||
// loaded. If not, searches in the table file and loads it.
|
|
||||||
// Returns index of gamefile if found, -1 if not
|
|
||||||
int mng_GetGuaranteedGamefilePage(char *name, CFILE *infile = NULL);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -500,9 +500,6 @@ int mod_GetLastError(void) {
|
|||||||
|
|
||||||
void dd_GetWorkingDir(char *path, int len);
|
void dd_GetWorkingDir(char *path, int len);
|
||||||
bool dd_SetWorkingDir(const char *path);
|
bool dd_SetWorkingDir(const char *path);
|
||||||
bool dd_FindFileStart(const char *wildcard, char *namebuf);
|
|
||||||
bool dd_FindNextFile(char *namebuf);
|
|
||||||
void dd_FindFileClose();
|
|
||||||
|
|
||||||
// retrieve the current working folder where file operation will occur.
|
// retrieve the current working folder where file operation will occur.
|
||||||
void dd_GetWorkingDir(char *path, int len) { getcwd(path, len); }
|
void dd_GetWorkingDir(char *path, int len) { getcwd(path, len); }
|
||||||
|
@ -199,7 +199,6 @@ public:
|
|||||||
void Send(oms_q_evt *evt); // sends an event to the stream.
|
void Send(oms_q_evt *evt); // sends an event to the stream.
|
||||||
void Reset(OutrageMusicSeq *seq = NULL); // reset stream.
|
void Reset(OutrageMusicSeq *seq = NULL); // reset stream.
|
||||||
void SetVolume(float vol); // volume.
|
void SetVolume(float vol); // volume.
|
||||||
int GetPlayRequestCount(); // tells how many play events send are pending processing.
|
|
||||||
|
|
||||||
// event senders
|
// event senders
|
||||||
public:
|
public:
|
||||||
|
@ -398,9 +398,6 @@ int fvi_QuickDistObjectList(vector *pos, int init_roomnum, float rad, int16_t *o
|
|||||||
// fills in u & v. if l is non-NULL fills it in also
|
// fills in u & v. if l is non-NULL fills it in also
|
||||||
// extern void fvi_FindHitpointUV(float *u,float *v,float *l, vector *pnt,segment *seg,int sidenum,int facenum);
|
// extern void fvi_FindHitpointUV(float *u,float *v,float *l, vector *pnt,segment *seg,int sidenum,int facenum);
|
||||||
|
|
||||||
// Returns true if the object is through any walls
|
|
||||||
extern int fvi_ObjectIntersectsWall(object *objp);
|
|
||||||
|
|
||||||
extern int FVI_counter;
|
extern int FVI_counter;
|
||||||
extern int FVI_room_counter;
|
extern int FVI_room_counter;
|
||||||
|
|
||||||
|
@ -58,9 +58,6 @@ extern void vm_MatrixMul(matrix *, matrix *, matrix *);
|
|||||||
// Multiply a matrix times the transpose of a matrix
|
// Multiply a matrix times the transpose of a matrix
|
||||||
void vm_MatrixMulTMatrix(matrix *dest, matrix *src0, matrix *src1);
|
void vm_MatrixMulTMatrix(matrix *dest, matrix *src0, matrix *src1);
|
||||||
|
|
||||||
// Computes all math look up tables, must be called before any vector stuff is used
|
|
||||||
extern void vm_InitMathTables();
|
|
||||||
|
|
||||||
// Given a vector, returns the magnitude. Uses sqrt so it's slow
|
// Given a vector, returns the magnitude. Uses sqrt so it's slow
|
||||||
extern float vm_GetMagnitude(vector *);
|
extern float vm_GetMagnitude(vector *);
|
||||||
|
|
||||||
|
@ -285,8 +285,6 @@ public:
|
|||||||
void SetLLSoundQuantity(int n_sounds);
|
void SetLLSoundQuantity(int n_sounds);
|
||||||
int GetLLSoundQuantity();
|
int GetLLSoundQuantity();
|
||||||
|
|
||||||
bool SetLLevelType(); // These are
|
|
||||||
|
|
||||||
// Pause and Resume the library
|
// Pause and Resume the library
|
||||||
void PauseSounds(bool f_all_sounds = false);
|
void PauseSounds(bool f_all_sounds = false);
|
||||||
void ResumeSounds();
|
void ResumeSounds();
|
||||||
|
@ -28,7 +28,6 @@ class sound_buffer_info;
|
|||||||
|
|
||||||
void lnxsound_SetError(int code);
|
void lnxsound_SetError(int code);
|
||||||
void lnxsound_ErrorText(const char *fmt, ...);
|
void lnxsound_ErrorText(const char *fmt, ...);
|
||||||
inline void sb_adjust_properties_2d(sound_buffer_info *sb, float f_volume, float f_pan, uint16_t frequency);
|
|
||||||
|
|
||||||
class emulated_listener {
|
class emulated_listener {
|
||||||
public:
|
public:
|
||||||
@ -122,7 +121,6 @@ public:
|
|||||||
|
|
||||||
friend void lnxsound_SetError(int code);
|
friend void lnxsound_SetError(int code);
|
||||||
friend void lnxsound_ErrorText(const char *fmt, ...);
|
friend void lnxsound_ErrorText(const char *fmt, ...);
|
||||||
friend inline void sb_adjust_properties_2d(sound_buffer_info *sb, float f_volume, float f_pan, uint16_t frequency);
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
@ -271,11 +271,8 @@ private:
|
|||||||
friend int ADecodeFileRead(void *data, void *buf, uint32_t qty);
|
friend int ADecodeFileRead(void *data, void *buf, uint32_t qty);
|
||||||
void *StreamCallback(int *size); // invoked by omsStreamCB.
|
void *StreamCallback(int *size); // invoked by omsStreamCB.
|
||||||
int ReadFileData(int buf, int len); // reads in decompressed raw data.
|
int ReadFileData(int buf, int len); // reads in decompressed raw data.
|
||||||
int ReadFileDirect(char *buf, int len); // reads in decompressed raw data.
|
|
||||||
void UpdateData(); // updates file buffers
|
void UpdateData(); // updates file buffers
|
||||||
void End(); // cleans up after a stop.
|
|
||||||
void Reset(); // resets to start of stream.
|
void Reset(); // resets to start of stream.
|
||||||
bool OpenDigitalStream(); // opens and prepares a digital stream
|
|
||||||
bool ReopenDigitalStream(uint8_t fbufidx, int nbufs);
|
bool ReopenDigitalStream(uint8_t fbufidx, int nbufs);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@ -333,7 +330,6 @@ public:
|
|||||||
int CurrentMeasure() const { // returns current measure.
|
int CurrentMeasure() const { // returns current measure.
|
||||||
return m_curmeasure;
|
return m_curmeasure;
|
||||||
};
|
};
|
||||||
int TotalMeasures() const; // total measure count
|
|
||||||
int GetSoundHandle() const { // returns the sound library handle for this stream.
|
int GetSoundHandle() const { // returns the sound library handle for this stream.
|
||||||
return m_llshandle;
|
return m_llshandle;
|
||||||
};
|
};
|
||||||
|
@ -110,9 +110,6 @@ extern float UI_aspect_y;
|
|||||||
#define UI_X(_x) ((int)(UI_aspect_x * (_x)))
|
#define UI_X(_x) ((int)(UI_aspect_x * (_x)))
|
||||||
#define UI_Y(_y) ((int)(UI_aspect_y * (_y)))
|
#define UI_Y(_y) ((int)(UI_aspect_y * (_y)))
|
||||||
|
|
||||||
// retrieves input for user interface
|
|
||||||
bool ui_Poll();
|
|
||||||
|
|
||||||
// flushes out key input info currently in ui.
|
// flushes out key input info currently in ui.
|
||||||
void ui_KeyFlush();
|
void ui_KeyFlush();
|
||||||
|
|
||||||
|
1
ui/ui.h
1
ui/ui.h
@ -1117,7 +1117,6 @@ public:
|
|||||||
// gadget management
|
// gadget management
|
||||||
void AddGadget(UIGadget *gadget); // adds a gadget to the gadget list
|
void AddGadget(UIGadget *gadget); // adds a gadget to the gadget list
|
||||||
void RemoveGadget(UIGadget *gadget); // removes a gadget from the list.
|
void RemoveGadget(UIGadget *gadget); // removes a gadget from the list.
|
||||||
UIGadget *GetGadgetFromID(int id); // returns the gadget pointer given an id if in window
|
|
||||||
void SetFocusOnGadget(UIGadget *gadget, bool key = false);
|
void SetFocusOnGadget(UIGadget *gadget, bool key = false);
|
||||||
|
|
||||||
UIGadget *GetFocus() { return m_GadgetCur; };
|
UIGadget *GetFocus() { return m_GadgetCur; };
|
||||||
|
@ -148,7 +148,4 @@ bool ui_IsCursorVisible(); // is the cursor visible?
|
|||||||
// frees ui input cache
|
// frees ui input cache
|
||||||
void ui_Flush();
|
void ui_Flush();
|
||||||
|
|
||||||
// does screen shot
|
|
||||||
void ui_DoScreenshot();
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user