Remove the SMP renderer feature
This commit is contained in:
parent
3f489fe5f2
commit
51df89ab13
35 changed files with 160 additions and 839 deletions
|
@ -40,11 +40,6 @@ typedef unsigned int glIndex_t;
|
|||
|
||||
#define BUFFER_OFFSET(i) ((char *)NULL + (i))
|
||||
|
||||
// everything that is needed by the backend needs
|
||||
// to be double buffered to allow it to run in
|
||||
// parallel on a dual cpu machine
|
||||
#define SMP_FRAMES 2
|
||||
|
||||
// 14 bits
|
||||
// can't be increased without changing bit packing for drawsurfs
|
||||
// see QSORT_SHADERNUM_SHIFT
|
||||
|
@ -1138,8 +1133,8 @@ typedef struct srfGridMesh_s
|
|||
surfaceType_t surfaceType;
|
||||
|
||||
// dynamic lighting information
|
||||
int dlightBits[SMP_FRAMES];
|
||||
int pshadowBits[SMP_FRAMES];
|
||||
int dlightBits;
|
||||
int pshadowBits;
|
||||
|
||||
// culling information
|
||||
vec3_t meshBounds[2];
|
||||
|
@ -1182,8 +1177,8 @@ typedef struct
|
|||
surfaceType_t surfaceType;
|
||||
|
||||
// dynamic lighting information
|
||||
int dlightBits[SMP_FRAMES];
|
||||
int pshadowBits[SMP_FRAMES];
|
||||
int dlightBits;
|
||||
int pshadowBits;
|
||||
|
||||
// culling information
|
||||
cplane_t plane;
|
||||
|
@ -1214,8 +1209,8 @@ typedef struct
|
|||
surfaceType_t surfaceType;
|
||||
|
||||
// dynamic lighting information
|
||||
int dlightBits[SMP_FRAMES];
|
||||
int pshadowBits[SMP_FRAMES];
|
||||
int dlightBits;
|
||||
int pshadowBits;
|
||||
|
||||
// culling information
|
||||
// vec3_t bounds[2];
|
||||
|
@ -1280,8 +1275,8 @@ typedef struct srfVBOMesh_s
|
|||
int fogIndex;
|
||||
|
||||
// dynamic lighting information
|
||||
int dlightBits[SMP_FRAMES];
|
||||
int pshadowBits[SMP_FRAMES];
|
||||
int dlightBits;
|
||||
int pshadowBits;
|
||||
|
||||
// culling information
|
||||
vec3_t bounds[2];
|
||||
|
@ -1752,7 +1747,6 @@ typedef struct {
|
|||
// all state modified by the back end is seperated
|
||||
// from the front end state
|
||||
typedef struct {
|
||||
int smpFrame;
|
||||
trRefdef_t refdef;
|
||||
viewParms_t viewParms;
|
||||
orientationr_t or;
|
||||
|
@ -1798,8 +1792,6 @@ typedef struct {
|
|||
int viewCount; // incremented every view (twice a scene if portaled)
|
||||
// and every R_MarkFragments call
|
||||
|
||||
int smpFrame; // toggles from 0 to 1 every endFrame
|
||||
|
||||
int frameSceneNum; // zeroed at RE_BeginFrame
|
||||
|
||||
qboolean worldMapLoaded;
|
||||
|
@ -2082,8 +2074,6 @@ extern cvar_t *r_portalOnly;
|
|||
|
||||
extern cvar_t *r_subdivisions;
|
||||
extern cvar_t *r_lodCurveError;
|
||||
extern cvar_t *r_smp;
|
||||
extern cvar_t *r_showSmp;
|
||||
extern cvar_t *r_skipBackEnd;
|
||||
|
||||
extern cvar_t *r_stereoEnabled;
|
||||
|
@ -2327,11 +2317,6 @@ void GLimp_Init( void );
|
|||
void GLimp_Shutdown( void );
|
||||
void GLimp_EndFrame( void );
|
||||
|
||||
qboolean GLimp_SpawnRenderThread( void (*function)( void ) );
|
||||
void *GLimp_RendererSleep( void );
|
||||
void GLimp_FrontEndSleep( void );
|
||||
void GLimp_WakeRenderer( void *data );
|
||||
|
||||
void GLimp_LogComment( char *comment );
|
||||
void GLimp_Minimize(void);
|
||||
|
||||
|
@ -2586,7 +2571,7 @@ SCENE GENERATION
|
|||
============================================================
|
||||
*/
|
||||
|
||||
void R_ToggleSmpFrame( void );
|
||||
void R_InitNextFrame( void );
|
||||
|
||||
void RE_ClearScene( void );
|
||||
void RE_AddRefEntityToScene( const refEntity_t *ent );
|
||||
|
@ -2700,7 +2685,6 @@ RENDERER BACK END FUNCTIONS
|
|||
=============================================================
|
||||
*/
|
||||
|
||||
void RB_RenderThread( void );
|
||||
void RB_ExecuteRenderCommands( const void *data );
|
||||
|
||||
/*
|
||||
|
@ -2828,9 +2812,7 @@ typedef enum {
|
|||
#define MAX_POLYVERTS 3000
|
||||
|
||||
// all of the information needed by the back end must be
|
||||
// contained in a backEndData_t. This entire structure is
|
||||
// duplicated so the front and back end can run in parallel
|
||||
// on an SMP machine
|
||||
// contained in a backEndData_t
|
||||
typedef struct {
|
||||
drawSurf_t drawSurfs[MAX_DRAWSURFS];
|
||||
dlight_t dlights[MAX_DLIGHTS];
|
||||
|
@ -2844,20 +2826,15 @@ typedef struct {
|
|||
extern int max_polys;
|
||||
extern int max_polyverts;
|
||||
|
||||
extern backEndData_t *backEndData[SMP_FRAMES]; // the second one may not be allocated
|
||||
extern backEndData_t *backEndData; // the second one may not be allocated
|
||||
|
||||
extern volatile renderCommandList_t *renderCommandList;
|
||||
|
||||
extern volatile qboolean renderThreadActive;
|
||||
|
||||
|
||||
void *R_GetCommandBuffer( int bytes );
|
||||
void RB_ExecuteRenderCommands( const void *data );
|
||||
|
||||
void R_InitCommandBuffers( void );
|
||||
void R_ShutdownCommandBuffers( void );
|
||||
|
||||
void R_SyncRenderThread( void );
|
||||
void R_IssuePendingRenderCommands( void );
|
||||
|
||||
void R_AddDrawSurfCmd( drawSurf_t *drawSurfs, int numDrawSurfs );
|
||||
void R_AddCapShadowmapCmd( int dlight, int cubeSide );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue