ref: soft: fix -Wmissing-prototypes

This commit is contained in:
Alibek Omarov 2024-01-27 20:18:17 +03:00
parent 661e60720d
commit 7152393089
21 changed files with 149 additions and 151 deletions

View File

@ -41,7 +41,7 @@ R_Alias_clip_z
pfv0 is the unclipped vertex, pfv1 is the z-clipped vertex
================
*/
void R_Alias_clip_z (finalvert_t *pfv0, finalvert_t *pfv1, finalvert_t *out)
static void R_Alias_clip_z (finalvert_t *pfv0, finalvert_t *pfv1, finalvert_t *out)
{
float scale;
@ -183,7 +183,7 @@ void R_Alias_clip_bottom (finalvert_t *pfv0, finalvert_t *pfv1,
#endif
int R_AliasClip (finalvert_t *in, finalvert_t *out, int flag, int count,
static int R_AliasClip (finalvert_t *in, finalvert_t *out, int flag, int count,
void(*clip)(finalvert_t *pfv0, finalvert_t *pfv1, finalvert_t *out) )
{
int i,j,k;

View File

@ -373,7 +373,7 @@ R_DrawTorus
Draw beamtours
================
*/
void R_DrawTorus( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
static void R_DrawTorus( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
{
int i, noiseIndex, noiseStep;
float div, length, fraction, factor, vLast, vStep;
@ -462,7 +462,7 @@ R_DrawDisk
Draw beamdisk
================
*/
void R_DrawDisk( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
static void R_DrawDisk( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
{
float div, length, fraction;
float w, vLast, vStep;
@ -520,7 +520,7 @@ R_DrawCylinder
Draw beam cylinder
================
*/
void R_DrawCylinder( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
static void R_DrawCylinder( vec3_t source, vec3_t delta, float width, float scale, float freq, float speed, int segments )
{
float div, length, fraction;
float vLast, vStep;
@ -577,7 +577,7 @@ R_DrawBeamFollow
drawi followed beam
==============
*/
void R_DrawBeamFollow( BEAM *pbeam, float frametime )
static void R_DrawBeamFollow( BEAM *pbeam, float frametime )
{
particle_t *pnew, *particles;
float fraction, div, vLast, vStep, saved_fraction;
@ -737,7 +737,7 @@ R_DrawRing
Draw beamring
================
*/
void R_DrawRing( vec3_t source, vec3_t delta, float width, float amplitude, float freq, float speed, int segments )
static void R_DrawRing( vec3_t source, vec3_t delta, float width, float amplitude, float freq, float speed, int segments )
{
int i, j, noiseIndex, noiseStep;
float div, length, fraction, factor, vLast, vStep;
@ -894,7 +894,7 @@ R_BeamRecomputeEndpoints
Recomputes beam endpoints..
==============
*/
qboolean R_BeamRecomputeEndpoints( BEAM *pbeam )
static qboolean R_BeamRecomputeEndpoints( BEAM *pbeam )
{
if( FBitSet( pbeam->flags, FBEAM_STARTENTITY ))
{
@ -947,7 +947,7 @@ R_BeamDraw
Update beam vars and draw it
==============
*/
void R_BeamDraw( BEAM *pbeam, float frametime )
static void R_BeamDraw( BEAM *pbeam, float frametime )
{
model_t *model;
vec3_t delta;
@ -1193,7 +1193,7 @@ R_BeamDrawCustomEntity
initialize beam from server entity
==============
*/
void R_BeamDrawCustomEntity( cl_entity_t *ent )
static void R_BeamDrawCustomEntity( cl_entity_t *ent )
{
BEAM beam;
float amp = ent->curstate.body / 100.0f;

View File

@ -51,7 +51,7 @@ static qboolean makeclippededge;
R_ConcatRotations
================
*/
void R_ConcatRotations (float in1[3][3], float in2[3][3], float out[3][3])
static void R_ConcatRotations (float in1[3][3], float in2[3][3], float out[3][3])
{
out[0][0] = in1[0][0] * in2[0][0] + in1[0][1] * in2[1][0] +
in1[0][2] * in2[2][0];
@ -81,7 +81,7 @@ void R_ConcatRotations (float in1[3][3], float in2[3][3], float out[3][3])
R_EntityRotate
================
*/
void R_EntityRotate (vec3_t vec)
static void R_EntityRotate (vec3_t vec)
{
vec3_t tvec;
@ -348,7 +348,7 @@ void R_RecursiveClipBPoly (bedge_t *pedges, mnode_t *pnode, msurface_t *psurf)
R_RecursiveClipBPoly
================
*/
void R_RecursiveClipBPoly (bedge_t *pedges, mnode_t *pnode, msurface_t *psurf)
static void R_RecursiveClipBPoly (bedge_t *pedges, mnode_t *pnode, msurface_t *psurf)
{
bedge_t *psideedges[2], *pnextedge, *ptedge;
int i, side, lastside;
@ -781,7 +781,7 @@ int r_leafkeys[MAX_MAP_LEAFS];
R_RecursiveWorldNode
================
*/
void R_RecursiveWorldNode (mnode_t *node, int clipflags)
static void R_RecursiveWorldNode (mnode_t *node, int clipflags)
{
int i, c, side, *pindex;
vec3_t acceptpt, rejectpt;

View File

@ -65,7 +65,7 @@ static void GAME_EXPORT CL_FillRGBABlend( float _x, float _y, float _w, float _h
}
void Mod_UnloadTextures( model_t *mod );
qboolean GAME_EXPORT Mod_ProcessRenderData( model_t *mod, qboolean create, const byte *buf )
static qboolean GAME_EXPORT Mod_ProcessRenderData( model_t *mod, qboolean create, const byte *buf )
{
qboolean loaded = true;
@ -224,7 +224,7 @@ static const char * GAME_EXPORT GL_TextureName( unsigned int texnum )
return R_GetTexture( texnum )->name;
}
const byte * GAME_EXPORT GL_TextureData( unsigned int texnum )
static const byte * GAME_EXPORT GL_TextureData( unsigned int texnum )
{
rgbdata_t *pic = R_GetTexture( texnum )->original;
@ -233,7 +233,7 @@ const byte * GAME_EXPORT GL_TextureData( unsigned int texnum )
return NULL;
}
void Mod_BrushUnloadTextures( model_t *mod )
static void Mod_BrushUnloadTextures( model_t *mod )
{
int i;
@ -276,7 +276,7 @@ void Mod_UnloadTextures( model_t *mod )
}
}
void GAME_EXPORT R_ProcessEntData( qboolean allocate, cl_entity_t *entities, unsigned int max_entities )
static void GAME_EXPORT R_ProcessEntData( qboolean allocate, cl_entity_t *entities, unsigned int max_entities )
{
tr.entities = entities;
tr.max_entities = max_entities;
@ -289,17 +289,17 @@ static void GAME_EXPORT R_Flush( unsigned int flags )
// stubs
void GAME_EXPORT GL_SetTexCoordArrayMode( uint mode )
static void GAME_EXPORT GL_SetTexCoordArrayMode( uint mode )
{
}
void GAME_EXPORT GL_BackendStartFrame( void )
static void GAME_EXPORT GL_BackendStartFrame( void )
{
}
void GAME_EXPORT GL_BackendEndFrame( void )
static void GAME_EXPORT GL_BackendEndFrame( void )
{
}
@ -312,12 +312,12 @@ void GAME_EXPORT GL_SetRenderMode(int mode)
/// maybe, setup block drawing function pointers here
}
void GAME_EXPORT R_ShowTextures( void )
static void GAME_EXPORT R_ShowTextures( void )
{
// textures undone too
}
void GAME_EXPORT R_ShowTree( void )
static void GAME_EXPORT R_ShowTree( void )
{
// do we really need this here???
}
@ -338,47 +338,47 @@ void R_InitSkyClouds(mip_t *mt, texture_t *tx, qboolean custom_palette)
}
void GAME_EXPORT GL_SubdivideSurface( model_t *mod, msurface_t *fa )
static void GAME_EXPORT GL_SubdivideSurface( model_t *mod, msurface_t *fa )
{
}
void GAME_EXPORT DrawSingleDecal(decal_t *pDecal, msurface_t *fa)
static void GAME_EXPORT DrawSingleDecal(decal_t *pDecal, msurface_t *fa)
{
}
void GAME_EXPORT GL_SelectTexture(int texture)
static void GAME_EXPORT GL_SelectTexture(int texture)
{
}
void GAME_EXPORT GL_LoadTexMatrixExt(const float *glmatrix)
static void GAME_EXPORT GL_LoadTexMatrixExt(const float *glmatrix)
{
}
void GAME_EXPORT GL_LoadIdentityTexMatrix( void )
static void GAME_EXPORT GL_LoadIdentityTexMatrix( void )
{
}
void GAME_EXPORT GL_CleanUpTextureUnits(int last)
static void GAME_EXPORT GL_CleanUpTextureUnits(int last)
{
}
void GAME_EXPORT GL_TexGen(unsigned int coord, unsigned int mode)
static void GAME_EXPORT GL_TexGen(unsigned int coord, unsigned int mode)
{
}
void GAME_EXPORT GL_TextureTarget(uint target)
static void GAME_EXPORT GL_TextureTarget(uint target)
{
}
void GAME_EXPORT GL_BuildLightmaps( void )
static void GAME_EXPORT GL_BuildLightmaps( void )
{
CL_RunLightStyles();
}
@ -398,7 +398,7 @@ byte *GAME_EXPORT Mod_GetCurrentVis( void )
return NULL;
}
const char *R_GetConfigName( void )
static const char *R_GetConfigName( void )
{
return "ref_soft"; // software specific cvars will go to ref_soft.cfg
}
@ -558,7 +558,8 @@ ref_interface_t gReffuncs =
VGUI_GenerateTexture,
};
int EXPORT GAME_EXPORT GetRefAPI( int version, ref_interface_t *funcs, ref_api_t *engfuncs, ref_globals_t *globals )
int EXPORT GetRefAPI( int version, ref_interface_t *funcs, ref_api_t *engfuncs, ref_globals_t *globals );
int EXPORT GetRefAPI( int version, ref_interface_t *funcs, ref_api_t *engfuncs, ref_globals_t *globals )
{
if( version != REF_API_VERSION )
return 0;

View File

@ -179,7 +179,7 @@ void R_DecalComputeBasis( msurface_t *surf, int flags, vec3_t textureSpaceBasis[
VectorNormalize2( surf->texinfo->vecs[1], textureSpaceBasis[1] );
}
void R_SetupDecalTextureSpaceBasis( decal_t *pDecal, msurface_t *surf, int texture, vec3_t textureSpaceBasis[3], float decalWorldScale[2] )
static void R_SetupDecalTextureSpaceBasis( decal_t *pDecal, msurface_t *surf, int texture, vec3_t textureSpaceBasis[3], float decalWorldScale[2] )
{
int width, height;
@ -199,7 +199,7 @@ void R_SetupDecalTextureSpaceBasis( decal_t *pDecal, msurface_t *surf, int textu
}
// Build the initial list of vertices from the surface verts into the global array, 'verts'.
void R_SetupDecalVertsForMSurface( decal_t *pDecal, msurface_t *surf, vec3_t textureSpaceBasis[3], float *verts )
static void R_SetupDecalVertsForMSurface( decal_t *pDecal, msurface_t *surf, vec3_t textureSpaceBasis[3], float *verts )
{
float *v;
int i;
@ -216,7 +216,7 @@ void R_SetupDecalVertsForMSurface( decal_t *pDecal, msurface_t *surf, vec3_t tex
}
// Figure out where the decal maps onto the surface.
void R_SetupDecalClip( decal_t *pDecal, msurface_t *surf, int texture, vec3_t textureSpaceBasis[3], float decalWorldScale[2] )
static void R_SetupDecalClip( decal_t *pDecal, msurface_t *surf, int texture, vec3_t textureSpaceBasis[3], float decalWorldScale[2] )
{
R_SetupDecalTextureSpaceBasis( pDecal, surf, texture, textureSpaceBasis, decalWorldScale );
@ -231,7 +231,7 @@ void R_SetupDecalClip( decal_t *pDecal, msurface_t *surf, int texture, vec3_t te
// Clip polygon to decal in texture space
// JAY: This code is lame, change it later. It does way too much work per frame
// It can be made to recursively call the clipping code and only copy the vertex list once
int R_ClipInside( float *vert, int edge )
static int R_ClipInside( float *vert, int edge )
{
switch( edge )
{
@ -255,7 +255,7 @@ int R_ClipInside( float *vert, int edge )
return 0;
}
void R_ClipIntersect( float *one, float *two, float *out, int edge )
static void R_ClipIntersect( float *one, float *two, float *out, int edge )
{
float t;
@ -356,7 +356,7 @@ static int SHClip( float *vert, int vertCount, float *out, int edge )
return outCount;
}
float *R_DoDecalSHClip( float *pInVerts, decal_t *pDecal, int nStartVerts, int *pVertCount )
static float *R_DoDecalSHClip( float *pInVerts, decal_t *pDecal, int nStartVerts, int *pVertCount )
{
float *pOutVerts = g_DecalClipVerts[0];
int outCount;
@ -376,7 +376,7 @@ float *R_DoDecalSHClip( float *pInVerts, decal_t *pDecal, int nStartVerts, int *
//-----------------------------------------------------------------------------
// Generate clipped vertex list for decal pdecal projected onto polygon psurf
//-----------------------------------------------------------------------------
float *R_DecalVertsClip( decal_t *pDecal, msurface_t *surf, int texture, int *pVertCount )
static float *R_DecalVertsClip( decal_t *pDecal, msurface_t *surf, int texture, int *pVertCount )
{
float decalWorldScale[2];
vec3_t textureSpaceBasis[3];
@ -511,7 +511,7 @@ R_DecalCreatePoly
creates mesh for decal on first rendering
====================
*/
glpoly_t *R_DecalCreatePoly( decalinfo_t *decalinfo, decal_t *pdecal, msurface_t *surf )
static glpoly_t *R_DecalCreatePoly( decalinfo_t *decalinfo, decal_t *pdecal, msurface_t *surf )
{
int lnumverts;
glpoly_t *poly;
@ -618,7 +618,7 @@ static void R_DecalCreate( decalinfo_t *decalinfo, msurface_t *surf, float x, fl
R_AddDecalToSurface( pdecal, surf, decalinfo );
}
void R_DecalSurface( msurface_t *surf, decalinfo_t *decalinfo )
static void R_DecalSurface( msurface_t *surf, decalinfo_t *decalinfo )
{
// get the texture associated with this surface
mtexinfo_t *tex = surf->texinfo;

View File

@ -63,7 +63,7 @@ int GAME_EXPORT R_GetSpriteTexture( const model_t *m_pSpriteModel, int frame )
Draw_StretchPicImplementation
=============
*/
void R_DrawStretchPicImplementation( int x, int y, int w, int h, int s1, int t1, int s2, int t2, image_t *pic )
static void R_DrawStretchPicImplementation( int x, int y, int w, int h, int s1, int t1, int s2, int t2, image_t *pic )
{
pixel_t *source, *dest;
unsigned int v, u, sv;

View File

@ -144,7 +144,7 @@ sentinel at the end (actually, this is the active edge table starting at
edge_head.next).
==============
*/
void R_InsertNewEdges (edge_t *edgestoadd, edge_t *edgelist)
static void R_InsertNewEdges (edge_t *edgestoadd, edge_t *edgelist)
{
edge_t *next_edge;
@ -192,7 +192,7 @@ addedge:
R_RemoveEdges
==============
*/
void R_RemoveEdges (edge_t *pedge)
static void R_RemoveEdges (edge_t *pedge)
{
do
@ -212,7 +212,7 @@ void R_RemoveEdges (edge_t *pedge)
R_StepActiveU
==============
*/
void R_StepActiveU (edge_t *pedge)
static void R_StepActiveU (edge_t *pedge)
{
edge_t *pnext_edge, *pwedge;
@ -284,7 +284,7 @@ pushback:
R_CleanupSpan
==============
*/
void R_CleanupSpan (void)
static void R_CleanupSpan (void)
{
surf_t *surf;
int iu;
@ -752,7 +752,7 @@ vec3_t local_modelorg;
D_MipLevelForScale
=============
*/
int D_MipLevelForScale (float scale)
static int D_MipLevelForScale (float scale)
{
int lmiplevel;
@ -779,7 +779,7 @@ D_FlatFillSurface
Simple single color fill with no texture mapping
==============
*/
void D_FlatFillSurface (surf_t *surf, int color)
static void D_FlatFillSurface (surf_t *surf, int color)
{
espan_t *span;
pixel_t *pdest;
@ -801,7 +801,7 @@ void D_FlatFillSurface (surf_t *surf, int color)
D_CalcGradients
==============
*/
void D_CalcGradients (msurface_t *pface)
static void D_CalcGradients (msurface_t *pface)
{
mplane_t *pplane;
float mipscale;
@ -888,7 +888,7 @@ D_BackgroundSurf
The grey background filler seen when there is a hole in the map
==============
*/
void D_BackgroundSurf (surf_t *s)
static void D_BackgroundSurf (surf_t *s)
{
// set up a gradient for the background surface that places it
// effectively at infinity distance from the viewpoint
@ -905,7 +905,7 @@ void D_BackgroundSurf (surf_t *s)
D_TurbulentSurf
=================
*/
void D_TurbulentSurf (surf_t *s)
static void D_TurbulentSurf (surf_t *s)
{
d_zistepu = s->d_zistepu;
d_zistepv = s->d_zistepv;
@ -966,12 +966,6 @@ void D_TurbulentSurf (surf_t *s)
}
qboolean alphaspans;
void D_AlphaSpans16 (espan_t *pspan);
void D_AddSpans16 (espan_t *pspan);
void D_BlendSpans16 (espan_t *pspan, int alpha );
void TurbulentZ8 (espan_t *pspan, int alpha );
/*
==============
D_SolidSurf
@ -979,7 +973,7 @@ D_SolidSurf
Normal surface cached, texture mapped surface
==============
*/
void D_AlphaSurf (surf_t *s)
static void D_AlphaSurf (surf_t *s)
{
int alpha;
@ -1086,7 +1080,7 @@ D_SolidSurf
Normal surface cached, texture mapped surface
==============
*/
void D_SolidSurf (surf_t *s)
static void D_SolidSurf (surf_t *s)
{
d_zistepu = s->d_zistepu;
d_zistepv = s->d_zistepv;
@ -1197,7 +1191,7 @@ D_DrawflatSurfaces
To allow developers to see the polygon carving of the world
=============
*/
void D_DrawflatSurfaces (void)
static void D_DrawflatSurfaces (void)
{
surf_t *s;

View File

@ -432,7 +432,7 @@ static int COUNT_BITS( uint mask )
return i;
}
void R_BuildScreenMap( void )
static void R_BuildScreenMap( void )
{
int i;
uint rshift = FIRST_BIT(swblit.rmask), gshift = FIRST_BIT(swblit.gmask), bshift = FIRST_BIT(swblit.bmask);
@ -497,7 +497,7 @@ void R_BuildScreenMap( void )
#define FOR_EACH_COLOR(x) for( r##x = 0; r##x < BIT(3); r##x++ ) for( g##x = 0; g##x < BIT(3); g##x++ ) for( b##x = 0; b##x < BIT(2); b##x++ )
void R_BuildBlendMaps( void )
static void R_BuildBlendMaps( void )
{
unsigned int r1, g1, b1;
unsigned int r2, g2, b2;

View File

@ -44,14 +44,6 @@ void GAME_EXPORT GL_Bind( int tmu, unsigned int texnum )
{
image_t *image;
extern void (*d_pdrawspans)(void *);
extern void R_PolysetFillSpans8 ( void * );
extern void R_PolysetDrawSpansConstant8_33( void *pspanpackage);
extern void R_PolysetDrawSpansTextureBlended( void *pspanpackage);
extern void R_PolysetDrawSpansBlended( void *pspanpackage);
extern void R_PolysetDrawSpansAdditive( void *pspanpackage);
extern void R_PolysetDrawSpansGlow( void *pspanpackage);
image = &r_images[texnum];
//vid.rendermode = kRenderNormal;
@ -359,7 +351,7 @@ GL_BoxFilter3x3
box filter 3x3
=================
*/
void GL_BoxFilter3x3( byte *out, const byte *in, int w, int h, int x, int y )
static void GL_BoxFilter3x3( byte *out, const byte *in, int w, int h, int x, int y )
{
int r = 0, g = 0, b = 0, a = 0;
int count = 0, acount = 0;
@ -406,7 +398,7 @@ GL_ApplyFilter
Apply box-filter to 1-bit alpha
=================
*/
byte *GL_ApplyFilter( const byte *source, int width, int height )
static byte *GL_ApplyFilter( const byte *source, int width, int height )
{
byte *in = (byte *)source;
byte *out = (byte *)source;
@ -794,7 +786,7 @@ static void GL_ProcessImage( image_t *tex, rgbdata_t *pic )
GL_CheckTexName
================
*/
qboolean GL_CheckTexName( const char *name )
static qboolean GL_CheckTexName( const char *name )
{
int len;

View File

@ -339,7 +339,7 @@ R_LightVec
check bspmodels to get light from
=================
*/
colorVec R_LightVecInternal( const vec3_t start, const vec3_t end, vec3_t lspot, vec3_t lvec )
static colorVec R_LightVecInternal( const vec3_t start, const vec3_t end, vec3_t lspot, vec3_t lvec )
{
float last_fraction;
int i, maxEnts = 1;

View File

@ -408,6 +408,7 @@ float *R_DecalSetupVerts( decal_t *pDecal, msurface_t *surf, int texture, int *o
void R_EntityRemoveDecals( model_t *mod );
//void DrawDecalsBatch( void );
void R_ClearDecals( void );
void R_DecalComputeBasis( msurface_t *surf, int flags, vec3_t textureSpaceBasis[3] );
#if 0
@ -590,6 +591,27 @@ void VGUI_DrawQuad( const vpoint_t *ul, const vpoint_t *lr );
void VGUI_GetTextureSizes( int *width, int *height );
int VGUI_GenerateTexture( void );
//
// r_polyse.c
//
// !!! if this is changed, it must be changed in asm_draw.h too !!!
typedef struct {
void *pdest;
short *pz;
int count;
pixel_t *ptex;
int sfrac, tfrac, light, zi;
} spanpackage_t;
extern void (*d_pdrawspans)( spanpackage_t * );
void R_PolysetFillSpans8( spanpackage_t * );
void R_PolysetDrawSpans8_33( spanpackage_t * );
void R_PolysetDrawSpansConstant8_33( spanpackage_t *pspanpackage);
void R_PolysetDrawSpansTextureBlended( spanpackage_t *pspanpackage);
void R_PolysetDrawSpansBlended( spanpackage_t *pspanpackage);
void R_PolysetDrawSpansAdditive( spanpackage_t *pspanpackage);
void R_PolysetDrawSpansGlow( spanpackage_t *pspanpackage);
//#include "vid_common.h"
//
@ -1055,6 +1077,10 @@ void D_DrawSpans16 (espan_t *pspans);
void D_DrawZSpans (espan_t *pspans);
void Turbulent8 (espan_t *pspan);
void NonTurbulent8 (espan_t *pspan); //PGM
void D_BlendSpans16( espan_t *pspan, int alpha );
void D_AlphaSpans16( espan_t *pspan );
void D_AddSpans16( espan_t *pspan );
void TurbulentZ8( espan_t *pspan, int alpha );
surfcache_t *D_CacheSurface (msurface_t *surface, int miplevel);

View File

@ -767,18 +767,13 @@ static image_t *R_RecursiveFindWaterTexture( const mnode_t *node, const mnode_t
return NULL;
}
extern void R_PolysetFillSpans8 ( void * );
extern void R_PolysetDrawSpansConstant8_33( void *pspanpackage);
extern void R_PolysetDrawSpans8_33( void *pspanpackage);
/*
=============
R_DrawEntitiesOnList
=============
*/
void R_DrawEntitiesOnList( void )
static void R_DrawEntitiesOnList( void )
{
extern void (*d_pdrawspans)(void *);
int i;
//extern int d_aflatcolor;
//d_aflatcolor = 0;
@ -994,7 +989,7 @@ int R_BmodelCheckBBox (float *minmaxs)
R_FindTopNode
===================
*/
mnode_t *R_FindTopnode (vec3_t mins, vec3_t maxs)
static mnode_t *R_FindTopnode (vec3_t mins, vec3_t maxs)
{
mplane_t *splitplane;
int sides;
@ -1096,7 +1091,7 @@ void RotatedBBox (vec3_t mins, vec3_t maxs, vec3_t angles, vec3_t tmins, vec3_t
R_DrawBEntitiesOnList
=============
*/
void R_DrawBEntitiesOnList (void)
static void R_DrawBEntitiesOnList (void)
{
int i, clipflags;
vec3_t oldorigin;
@ -1382,7 +1377,7 @@ void R_DrawBrushModel(cl_entity_t *pent)
R_EdgeDrawing
================
*/
void R_EdgeDrawing (void)
static void R_EdgeDrawing (void)
{
edge_t ledges[NUMSTACKEDGES +
((CACHE_SIZE - 1) / sizeof(edge_t)) + 1];
@ -1511,7 +1506,7 @@ void R_MarkLeaves( void )
R_MarkLeaves
===============
*/
void R_MarkLeaves (void)
static void R_MarkLeaves (void)
{
byte *vis;
mnode_t *node;
@ -1609,7 +1604,7 @@ gamma will be reset for
some type of screenshots
===============
*/
qboolean R_DoResetGamma( void )
static qboolean R_DoResetGamma( void )
{
// FIXME: this looks ugly. apply the backward gamma changes to the output image
return false;
@ -1867,7 +1862,7 @@ void GAME_EXPORT R_NewMap (void)
R_InitTurb
================
*/
void R_InitTurb (void)
static void R_InitTurb (void)
{
int i;

View File

@ -150,7 +150,7 @@ void Matrix4x4_CreateRotate( matrix4x4 out, float angle, float x, float y, float
out[3][3]=1.0f;
}
void Matrix4x4_CreateScale( matrix4x4 out, float x )
static void Matrix4x4_CreateScale( matrix4x4 out, float x )
{
out[0][0] = x;
out[0][1] = 0.0f;
@ -170,7 +170,7 @@ void Matrix4x4_CreateScale( matrix4x4 out, float x )
out[3][3] = 1.0f;
}
void Matrix4x4_CreateScale3( matrix4x4 out, float x, float y, float z )
static void Matrix4x4_CreateScale3( matrix4x4 out, float x, float y, float z )
{
out[0][0] = x;
out[0][1] = 0.0f;

View File

@ -43,7 +43,7 @@ struct qfrustum_s qfrustum;
D_Patch
================
*/
void D_Patch (void)
static void D_Patch (void)
{
#if id386
extern void D_Aff8Patch( void );
@ -159,7 +159,7 @@ void TransformVector (vec3_t in, vec3_t out)
R_SetUpFrustumIndexes
===============
*/
void R_SetUpFrustumIndexes (void)
static void R_SetUpFrustumIndexes (void)
{
int i, j, *pindex;
@ -195,7 +195,7 @@ Called every time the vid structure or r_refdef changes.
Guaranteed to be called before the first refresh
===============
*/
void R_ViewChanged (vrect_t *vr)
static void R_ViewChanged (vrect_t *vr)
{
int i;
float verticalFieldOfView, horizontalFieldOfView, xOrigin, yOrigin;

View File

@ -27,15 +27,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#define DPS_MAXSPANS MAXHEIGHT+1
// 1 extra for spanpackage that marks end
// !!! if this is changed, it must be changed in asm_draw.h too !!!
typedef struct {
void *pdest;
short *pz;
int count;
pixel_t *ptex;
int sfrac, tfrac, light, zi;
} spanpackage_t;
typedef struct {
int isflattop;
int numleftedges;
@ -107,7 +98,7 @@ byte *skinstart;
void (*d_pdrawspans)(spanpackage_t *pspanpackage);
void R_PolysetStub (spanpackage_t *pspanpackage)
static void R_PolysetStub (spanpackage_t *pspanpackage)
{
}
@ -341,7 +332,7 @@ quotient must fit in 32 bits.
FIXME: GET RID OF THIS! (FloorDivMod)
====================
*/
void FloorDivMod (float numer, float denom, int *quotient,
static void FloorDivMod (float numer, float denom, int *quotient,
int *rem)
{
int q, r;
@ -394,7 +385,7 @@ void FloorDivMod (float numer, float denom, int *quotient,
R_PolysetSetUpForLineScan
====================
*/
void R_PolysetSetUpForLineScan(fixed8_t startvertu, fixed8_t startvertv,
static void R_PolysetSetUpForLineScan(fixed8_t startvertu, fixed8_t startvertv,
fixed8_t endvertu, fixed8_t endvertv)
{
float dm, dn;
@ -1334,7 +1325,7 @@ void R_PolysetDrawSpans8_66(spanpackage_t *pspanpackage)
} while (pspanpackage->count != -999999);
}
void R_PolysetDrawSpansConstant8_66( spanpackage_t *pspanpackage)
static void R_PolysetDrawSpansConstant8_66( spanpackage_t *pspanpackage)
{
int lcount;
pixel_t *lpdest;

View File

@ -215,7 +215,7 @@ void R_EmitSkyBox (void)
R_EmitEdge
================
*/
void R_EmitEdge (mvertex_t *pv0, mvertex_t *pv1)
static void R_EmitEdge (mvertex_t *pv0, mvertex_t *pv1)
{
edge_t *edge, *pcheck;
int u_check;
@ -413,7 +413,7 @@ void R_EmitEdge (mvertex_t *pv0, mvertex_t *pv1)
R_ClipEdge
================
*/
void R_ClipEdge (mvertex_t *pv0, mvertex_t *pv1, clipplane_t *clip)
static void R_ClipEdge (mvertex_t *pv0, mvertex_t *pv1, clipplane_t *clip)
{
float d0, d1, f;
mvertex_t clipvert;
@ -517,7 +517,7 @@ void R_ClipEdge (mvertex_t *pv0, mvertex_t *pv1, clipplane_t *clip)
R_EmitCachedEdge
================
*/
void R_EmitCachedEdge (void)
static void R_EmitCachedEdge (void)
{
edge_t *pedge_t;

View File

@ -61,7 +61,7 @@ void D_DrawTurbulent8Span (void)
D_DrawTurbulent8Span
=============
*/
void D_DrawTurbulent8ZSpan (void)
static void D_DrawTurbulent8ZSpan (void)
{
int sturb, tturb;
@ -892,7 +892,7 @@ D_DrawSpans16
FIXME: actually make this subdivide by 16 instead of 8!!!
=============
*/
void D_BlendSpans16 (espan_t *pspan, int alpha)
void D_BlendSpans16( espan_t *pspan, int alpha )
{
int count, spancount;
pixel_t *pbase, *pdest;

View File

@ -459,7 +459,7 @@ NOTE: we using prevblending[0] and [1] for holds interval
between frames where are we lerping
================
*/
float R_GetSpriteFrameInterpolant( cl_entity_t *ent, mspriteframe_t **oldframe, mspriteframe_t **curframe )
static float R_GetSpriteFrameInterpolant( cl_entity_t *ent, mspriteframe_t **oldframe, mspriteframe_t **curframe )
{
msprite_t *psprite;
mspritegroup_t *pspritegroup;
@ -625,7 +625,7 @@ R_CullSpriteModel
Cull sprite model by bbox
================
*/
qboolean R_CullSpriteModel( cl_entity_t *e, vec3_t origin )
static qboolean R_CullSpriteModel( cl_entity_t *e, vec3_t origin )
{
vec3_t sprite_mins, sprite_maxs;
float scale = 1.0f;
@ -689,7 +689,7 @@ R_SpriteOccluded
Do occlusion test for glow-sprites
================
*/
qboolean R_SpriteOccluded( cl_entity_t *e, vec3_t origin, float *pscale )
static qboolean R_SpriteOccluded( cl_entity_t *e, vec3_t origin, float *pscale )
{
if( e->curstate.rendermode == kRenderGlow )
{

View File

@ -250,7 +250,7 @@ static qboolean R_StudioComputeBBox( vec3_t bbox[8] )
return true; // visible
}
void R_StudioComputeSkinMatrix( mstudioboneweight_t *boneweights, matrix3x4 result )
static void R_StudioComputeSkinMatrix( mstudioboneweight_t *boneweights, matrix3x4 result )
{
float flWeight0, flWeight1, flWeight2, flWeight3;
int i, numbones = 0;
@ -385,7 +385,7 @@ pfnGetPlayerState
===============
*/
entity_state_t *R_StudioGetPlayerState( int index )
static entity_state_t *R_StudioGetPlayerState( int index )
{
if( !RI.drawWorld )
return &RI.currententity->curstate;
@ -516,7 +516,7 @@ StudioPlayerBlend
====================
*/
void R_StudioPlayerBlend( mstudioseqdesc_t *pseqdesc, int *pBlend, float *pPitch )
static void R_StudioPlayerBlend( mstudioseqdesc_t *pseqdesc, int *pBlend, float *pPitch )
{
// calc up/down pointing
*pBlend = (*pPitch * 3.0f);
@ -577,7 +577,7 @@ StudioSetUpTransform
====================
*/
void R_StudioSetUpTransform( cl_entity_t *e )
static void R_StudioSetUpTransform( cl_entity_t *e )
{
vec3_t origin, angles;
@ -649,7 +649,7 @@ StudioEstimateInterpolant
====================
*/
float R_StudioEstimateInterpolant( cl_entity_t *e )
static float R_StudioEstimateInterpolant( cl_entity_t *e )
{
float dadt = 1.0f;
@ -668,7 +668,7 @@ StudioFxTransform
====================
*/
void R_StudioFxTransform( cl_entity_t *ent, matrix3x4 transform )
static void R_StudioFxTransform( cl_entity_t *ent, matrix3x4 transform )
{
switch( ent->curstate.renderfx )
{
@ -712,7 +712,7 @@ StudioCalcBoneAdj
====================
*/
void R_StudioCalcBoneAdj( float dadt, float *adj, const byte *pcontroller1, const byte *pcontroller2, byte mouthopen )
static void R_StudioCalcBoneAdj( float dadt, float *adj, const byte *pcontroller1, const byte *pcontroller2, byte mouthopen )
{
mstudiobonecontroller_t *pbonecontroller;
float value = 0.0f;
@ -777,7 +777,7 @@ StudioCalcRotations
====================
*/
void R_StudioCalcRotations( cl_entity_t *e, float pos[][3], vec4_t *q, mstudioseqdesc_t *pseqdesc, mstudioanim_t *panim, float f )
static void R_StudioCalcRotations( cl_entity_t *e, float pos[][3], vec4_t *q, mstudioseqdesc_t *pseqdesc, mstudioanim_t *panim, float f )
{
int i, frame;
float adj[MAXSTUDIOCONTROLLERS];
@ -824,7 +824,7 @@ StudioMergeBones
====================
*/
void R_StudioMergeBones( cl_entity_t *e, model_t *m_pSubModel )
static void R_StudioMergeBones( cl_entity_t *e, model_t *m_pSubModel )
{
int i, j;
mstudiobone_t *pbones;
@ -884,7 +884,7 @@ StudioSetupBones
====================
*/
void R_StudioSetupBones( cl_entity_t *e )
static void R_StudioSetupBones( cl_entity_t *e )
{
float f;
mstudiobone_t *pbones;
@ -1064,7 +1064,7 @@ StudioBuildNormalTable
NOTE: m_pSubModel must be set
====================
*/
void R_StudioBuildNormalTable( void )
static void R_StudioBuildNormalTable( void )
{
cl_entity_t *e = RI.currententity;
mstudiomesh_t *pmesh;
@ -1115,7 +1115,7 @@ NOTE: m_pSubModel must be set
g_studio.verts must be computed
====================
*/
void R_StudioGenerateNormals( void )
static void R_StudioGenerateNormals( void )
{
int v0, v1, v2;
vec3_t e0, e1, norm;
@ -1210,7 +1210,7 @@ StudioSetupChrome
====================
*/
void R_StudioSetupChrome( float *pchrome, int bone, vec3_t normal )
static void R_StudioSetupChrome( float *pchrome, int bone, vec3_t normal )
{
float n;
@ -1318,7 +1318,7 @@ R_StudioDynamicLight
===============
*/
void R_StudioDynamicLight( cl_entity_t *ent, alight_t *plight )
static void R_StudioDynamicLight( cl_entity_t *ent, alight_t *plight )
{
movevars_t *mv = tr.movevars;
vec3_t lightDir, vecSrc, vecEnd;
@ -1509,7 +1509,7 @@ pfnStudioEntityLight
===============
*/
void R_StudioEntityLight( alight_t *lightinfo )
static void R_StudioEntityLight( alight_t *lightinfo )
{
int lnum, i, j, k;
float minstrength, dist2, f, r2;
@ -1591,7 +1591,7 @@ R_StudioSetupLighting
===============
*/
void R_StudioSetupLighting( alight_t *plight )
static void R_StudioSetupLighting( alight_t *plight )
{
float scale = 1.0f;
int i;
@ -1621,7 +1621,7 @@ R_StudioLighting
===============
*/
void R_StudioLighting( float *lv, int bone, int flags, vec3_t normal )
static void R_StudioLighting( float *lv, int bone, int flags, vec3_t normal )
{
float illum;
@ -1756,7 +1756,7 @@ R_LightStrength
====================
*/
void R_LightStrength( int bone, vec3_t localpos, vec4_t light[MAX_LOCALLIGHTS] )
static void R_LightStrength( int bone, vec3_t localpos, vec4_t light[MAX_LOCALLIGHTS] )
{
int i;
@ -1830,7 +1830,7 @@ mstudiotexture_t * GAME_EXPORT R_StudioGetTexture( cl_entity_t *e )
return ptexture;
}
void R_StudioSetRenderamt( int iRenderamt )
static void R_StudioSetRenderamt( int iRenderamt )
{
if( !RI.currententity ) return;
@ -1845,7 +1845,7 @@ R_StudioSetCullState
sets true for enable backculling (for left-hand viewmodel)
===============
*/
void R_StudioSetCullState( int iCull )
static void R_StudioSetCullState( int iCull )
{
// This function intentionally does nothing
}
@ -1857,7 +1857,7 @@ R_StudioRenderShadow
just a prefab for render shadow
===============
*/
void R_StudioRenderShadow( int iSprite, float *p1, float *p2, float *p3, float *p4 )
static void R_StudioRenderShadow( int iSprite, float *p1, float *p2, float *p3, float *p4 )
{
if( !p1 || !p2 || !p3 || !p4 )
return;
@ -2574,7 +2574,7 @@ R_StudioGetForceFaceFlags
===============
*/
int R_StudioGetForceFaceFlags( void )
static int R_StudioGetForceFaceFlags( void )
{
return g_nForceFaceFlags;
}
@ -2585,7 +2585,7 @@ R_StudioSetForceFaceFlags
===============
*/
void R_StudioSetForceFaceFlags( int flags )
static void R_StudioSetForceFaceFlags( int flags )
{
g_nForceFaceFlags = flags;
}
@ -2596,7 +2596,7 @@ pfnStudioSetHeader
===============
*/
void R_StudioSetHeader( studiohdr_t *pheader )
static void R_StudioSetHeader( studiohdr_t *pheader )
{
m_pStudioHeader = pheader;
m_fDoRemap = false;
@ -2608,7 +2608,7 @@ R_StudioSetRenderModel
===============
*/
void R_StudioSetRenderModel( model_t *model )
static void R_StudioSetRenderModel( model_t *model )
{
RI.currentmodel = model;
}
@ -2664,7 +2664,7 @@ R_StudioSetChromeOrigin
===============
*/
void R_StudioSetChromeOrigin( void )
static void R_StudioSetChromeOrigin( void )
{
VectorCopy( RI.vieworg, g_studio.chrome_origin );
}
@ -2752,7 +2752,7 @@ GL_StudioSetRenderMode
set rendermode for studiomodel
===============
*/
void GL_StudioSetRenderMode( int rendermode )
static void GL_StudioSetRenderMode( int rendermode )
{
GL_SetRenderMode( rendermode );
#if 0
@ -2824,7 +2824,7 @@ StudioRenderFinal
====================
*/
void R_StudioRenderFinal( void )
static void R_StudioRenderFinal( void )
{
int i, rendermode;
@ -2911,7 +2911,7 @@ StudioRenderModel
====================
*/
void R_StudioRenderModel( void )
static void R_StudioRenderModel( void )
{
R_StudioSetChromeOrigin();
R_StudioSetForceFaceFlags( 0 );
@ -2940,7 +2940,7 @@ StudioEstimateGait
====================
*/
void R_StudioEstimateGait( entity_state_t *pplayer )
static void R_StudioEstimateGait( entity_state_t *pplayer )
{
vec3_t est_velocity;
float dt;
@ -2996,7 +2996,7 @@ StudioProcessGait
====================
*/
void R_StudioProcessGait( entity_state_t *pplayer )
static void R_StudioProcessGait( entity_state_t *pplayer )
{
mstudioseqdesc_t *pseqdesc;
int iBlend;

View File

@ -374,7 +374,7 @@ R_TextureAnim
Returns the proper texture for a given time and base texture, do not process random tiling
===============
*/
texture_t *R_TextureAnim( texture_t *b )
static texture_t *R_TextureAnim( texture_t *b )
{
texture_t *base = b;
int count, reletive;
@ -424,7 +424,7 @@ R_TextureAnimation
Returns the proper texture for a given time and surface
===============
*/
texture_t *R_TextureAnimation( msurface_t *s )
static texture_t *R_TextureAnimation( msurface_t *s )
{
texture_t *base = s->texinfo->texture;
int count, reletive;
@ -1024,7 +1024,7 @@ void D_FlushCaches( void )
D_SCAlloc
=================
*/
surfcache_t *D_SCAlloc (int width, int size)
static surfcache_t *D_SCAlloc (int width, int size)
{
surfcache_t *new;
qboolean wrapped_this_time;
@ -1105,8 +1105,7 @@ surfcache_t *D_SCAlloc (int width, int size)
}
//=============================================================================
void R_DecalComputeBasis( msurface_t *surf, int flags, vec3_t textureSpaceBasis[3] );
void R_DrawSurfaceDecals( void )
static void R_DrawSurfaceDecals( void )
{
msurface_t *fa = r_drawsurf.surf;
decal_t *p;

View File

@ -41,7 +41,7 @@ R_AliasCheckBBox
#define BBOX_MUST_CLIP_Z 2
#define BBOX_TRIVIAL_REJECT 8
void VectorInverse (vec3_t v)
static void VectorInverse (vec3_t v)
{
v[0] = -v[0];
v[1] = -v[1];