- made render call adjustments to Exhumed.

This one was easy - no special cases at all. :)
This commit is contained in:
Christoph Oelckers 2021-03-21 11:48:18 +01:00
parent 6f7e7459ea
commit ecd6e68d69

View file

@ -31,8 +31,11 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include "interpolate.h" #include "interpolate.h"
#include "glbackend/glbackend.h" #include "glbackend/glbackend.h"
#include "v_draw.h" #include "v_draw.h"
#include "render.h"
#include <string.h> #include <string.h>
EXTERN_CVAR(Bool, testnewrenderer)
BEGIN_PS_NS BEGIN_PS_NS
short bSubTitles = true; short bSubTitles = true;
@ -221,6 +224,7 @@ void DrawView(double smoothRatio, bool sceneonly)
playerZ = sprite[nSprite].z; playerZ = sprite[nSprite].z;
nSector = sprite[nSprite].sectnum; nSector = sprite[nSprite].sectnum;
nAngle = buildang(sprite[nSprite].ang); nAngle = buildang(sprite[nSprite].ang);
rotscrnang = buildlook(0);
SetGreenPal(); SetGreenPal();
@ -269,9 +273,6 @@ void DrawView(double smoothRatio, bool sceneonly)
sprite[nPlayerSprite].cstat |= CSTAT_SPRITE_TRANSLUCENT; sprite[nPlayerSprite].cstat |= CSTAT_SPRITE_TRANSLUCENT;
sprite[nDoppleSprite[nLocalPlayer]].cstat |= CSTAT_SPRITE_INVISIBLE; sprite[nDoppleSprite[nLocalPlayer]].cstat |= CSTAT_SPRITE_INVISIBLE;
} }
renderSetRollAngle(rotscrnang.asbuildf());
pan = q16horiz(clamp(pan.asq16(), gi->playerHorizMin(), gi->playerHorizMax())); pan = q16horiz(clamp(pan.asq16(), gi->playerHorizMin(), gi->playerHorizMax()));
} }
@ -357,9 +358,17 @@ void DrawView(double smoothRatio, bool sceneonly)
} }
} }
if (!testnewrenderer)
{
renderSetRollAngle(rotscrnang.asbuildf());
renderDrawRoomsQ16(nCamerax, nCameray, viewz, nCameraa.asq16(), nCamerapan.asq16(), nSector); renderDrawRoomsQ16(nCamerax, nCameray, viewz, nCameraa.asq16(), nCamerapan.asq16(), nSector);
analyzesprites(smoothRatio); analyzesprites(smoothRatio);
renderDrawMasks(); renderDrawMasks();
}
else
{
render_drawrooms(nullptr, { nCamerax, nCameray, viewz }, nSector, nCameraa.asq16(), nCamerapan.asq16(), rotscrnang.asbuildf(), RSF_UPDATESECTOR);
}
if (HavePLURemap()) if (HavePLURemap())
{ {