mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-10 07:21:58 +00:00
R_DrawEntitiesOnList: revert entity texture sorting added in r1151 as it introduces wrong alpha-sorting in contract revoked start.bsp
reported here: http://www.celephais.net/board/view_thread.php?id=60452&start=1515 git-svn-id: svn+ssh://svn.code.sf.net/p/quakespasm/code/trunk@1234 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
parent
84422cfe79
commit
e0fc971a95
1 changed files with 1 additions and 12 deletions
|
@ -594,11 +594,6 @@ void R_SetupView (void)
|
|||
//
|
||||
//==============================================================================
|
||||
|
||||
static int R_EntitySortFunc(const void *a, const void *b)
|
||||
{
|
||||
return (*(entity_t **)a)->model - (*(entity_t **)b)->model;
|
||||
}
|
||||
|
||||
/*
|
||||
=============
|
||||
R_DrawEntitiesOnList
|
||||
|
@ -606,21 +601,15 @@ R_DrawEntitiesOnList
|
|||
*/
|
||||
void R_DrawEntitiesOnList (qboolean alphapass) //johnfitz -- added parameter
|
||||
{
|
||||
entity_t *entities_sorted[MAX_VISEDICTS];
|
||||
int i;
|
||||
|
||||
if (!r_drawentities.value)
|
||||
return;
|
||||
|
||||
//ericw -- draw the entities sorted by model, to eliminate redundant texture binding
|
||||
memcpy (entities_sorted, cl_visedicts, cl_numvisedicts * sizeof(entity_t *));
|
||||
qsort (entities_sorted, cl_numvisedicts, sizeof(entity_t *), R_EntitySortFunc);
|
||||
//ericw --
|
||||
|
||||
//johnfitz -- sprites are not a special case
|
||||
for (i=0 ; i<cl_numvisedicts ; i++)
|
||||
{
|
||||
currententity = entities_sorted[i];
|
||||
currententity = cl_visedicts[i];
|
||||
|
||||
//johnfitz -- if alphapass is true, draw only alpha entites this time
|
||||
//if alphapass is false, draw only nonalpha entities this time
|
||||
|
|
Loading…
Reference in a new issue