Move swrenderer into a namespace, add multithreading framework, and move drawers to commands

This commit is contained in:
Magnus Norddahl 2016-12-07 09:34:49 +01:00
commit 3ff91807b8
25 changed files with 5709 additions and 3226 deletions

View file

@ -42,13 +42,20 @@
#include "r_3dfloors.h"
#include "textures/textures.h"
#include "r_data/voxels.h"
#include "r_thread.h"
namespace swrenderer
{
void R_SWRSetWindow(int windowSize, int fullWidth, int fullHeight, int stHeight, float trueratio);
void R_SetupColormap(player_t *);
void R_SetupFreelook();
void R_InitRenderer();
}
using namespace swrenderer;
//==========================================================================
//
// DCanvas :: Init
@ -154,9 +161,11 @@ void FSoftwareRenderer::Precache(BYTE *texhitlist, TMap<PClassActor*, bool> &act
void FSoftwareRenderer::RenderView(player_t *player)
{
R_BeginDrawerCommands();
R_RenderActorView (player->mo);
// [RH] Let cameras draw onto textures that were visible this frame.
FCanvasTextureInfo::UpdateAll ();
R_EndDrawerCommands();
}
//==========================================================================