mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 15:21:51 +00:00
Rename ColumnDrawerArgs to SpriteDrawerArgs
This commit is contained in:
parent
e17c8c1678
commit
2f365e7d2b
18 changed files with 95 additions and 95 deletions
|
@ -156,7 +156,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
void R_UpdateFuzzPos(const ColumnDrawerArgs &args)
|
||||
void R_UpdateFuzzPos(const SpriteDrawerArgs &args)
|
||||
{
|
||||
int yl = MAX(args.dc_yl, 1);
|
||||
int yh = MIN(args.dc_yh, fuzzviewheight);
|
||||
|
|
|
@ -23,7 +23,7 @@ namespace swrenderer
|
|||
class SkyDrawerArgs;
|
||||
class WallDrawerArgs;
|
||||
class SpanDrawerArgs;
|
||||
class ColumnDrawerArgs;
|
||||
class SpriteDrawerArgs;
|
||||
|
||||
extern int ylookup[MAXHEIGHT];
|
||||
extern uint8_t shadetables[/*NUMCOLORMAPS*16*256*/];
|
||||
|
@ -58,23 +58,23 @@ namespace swrenderer
|
|||
virtual void DrawWallRevSubClampColumn(const WallDrawerArgs &args) = 0;
|
||||
virtual void DrawSingleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool fadeSky) = 0;
|
||||
virtual void DrawDoubleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool fadeSky) = 0;
|
||||
virtual void DrawColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void FillColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void FillAddColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void FillAddClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void FillSubClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void FillRevSubClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawFuzzColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawAddColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawTranslatedColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawTranslatedAddColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawShadedColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawAddClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawAddClampTranslatedColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawSubClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawSubClampTranslatedColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawRevSubClampColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawRevSubClampTranslatedColumn(const ColumnDrawerArgs &args) = 0;
|
||||
virtual void DrawColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void FillColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void FillAddColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void FillAddClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void FillSubClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void FillRevSubClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawFuzzColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawAddColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawTranslatedColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawTranslatedAddColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawShadedColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawAddClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawAddClampTranslatedColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawSubClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawSubClampTranslatedColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawRevSubClampColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawRevSubClampTranslatedColumn(const SpriteDrawerArgs &args) = 0;
|
||||
virtual void DrawSpan(const SpanDrawerArgs &args) = 0;
|
||||
virtual void DrawSpanMasked(const SpanDrawerArgs &args) = 0;
|
||||
virtual void DrawSpanTranslucent(const SpanDrawerArgs &args) = 0;
|
||||
|
@ -91,5 +91,5 @@ namespace swrenderer
|
|||
void R_InitFuzzTable(int fuzzoff);
|
||||
void R_InitParticleTexture();
|
||||
|
||||
void R_UpdateFuzzPos(const ColumnDrawerArgs &args);
|
||||
void R_UpdateFuzzPos(const SpriteDrawerArgs &args);
|
||||
}
|
||||
|
|
|
@ -862,7 +862,7 @@ namespace swrenderer
|
|||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
PalColumnCommand::PalColumnCommand(const ColumnDrawerArgs &args)
|
||||
PalColumnCommand::PalColumnCommand(const SpriteDrawerArgs &args)
|
||||
{
|
||||
_count = args.dc_count;
|
||||
_dest = args.Dest();
|
||||
|
@ -1759,7 +1759,7 @@ namespace swrenderer
|
|||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
DrawFuzzColumnPalCommand::DrawFuzzColumnPalCommand(const ColumnDrawerArgs &args)
|
||||
DrawFuzzColumnPalCommand::DrawFuzzColumnPalCommand(const SpriteDrawerArgs &args)
|
||||
{
|
||||
_yl = args.dc_yl;
|
||||
_yh = args.dc_yh;
|
||||
|
|
|
@ -69,7 +69,7 @@ namespace swrenderer
|
|||
class PalColumnCommand : public DrawerCommand
|
||||
{
|
||||
public:
|
||||
PalColumnCommand(const ColumnDrawerArgs &args);
|
||||
PalColumnCommand(const SpriteDrawerArgs &args);
|
||||
FString DebugInfo() override { return "PalColumnCommand"; }
|
||||
|
||||
protected:
|
||||
|
@ -110,7 +110,7 @@ namespace swrenderer
|
|||
class DrawFuzzColumnPalCommand : public DrawerCommand
|
||||
{
|
||||
public:
|
||||
DrawFuzzColumnPalCommand(const ColumnDrawerArgs &args);
|
||||
DrawFuzzColumnPalCommand(const SpriteDrawerArgs &args);
|
||||
void Execute(DrawerThread *thread) override;
|
||||
FString DebugInfo() override { return "DrawFuzzColumnPalCommand"; }
|
||||
|
||||
|
@ -257,23 +257,23 @@ namespace swrenderer
|
|||
void DrawWallRevSubClampColumn(const WallDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawWallRevSubClamp1PalCommand>(args); }
|
||||
void DrawSingleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool fadeSky) override { DrawerCommandQueue::QueueCommand<DrawSingleSky1PalCommand>(args, solid_top, solid_bottom, fadeSky); }
|
||||
void DrawDoubleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool fadeSky) override { DrawerCommandQueue::QueueCommand<DrawDoubleSky1PalCommand>(args, solid_top, solid_bottom, fadeSky); }
|
||||
void DrawColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnPalCommand>(args); }
|
||||
void FillColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnPalCommand>(args); }
|
||||
void FillAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddPalCommand>(args); }
|
||||
void FillAddClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddClampPalCommand>(args); }
|
||||
void FillSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnSubClampPalCommand>(args); }
|
||||
void FillRevSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnRevSubClampPalCommand>(args); }
|
||||
void DrawFuzzColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawFuzzColumnPalCommand>(args); R_UpdateFuzzPos(args); }
|
||||
void DrawAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddPalCommand>(args); }
|
||||
void DrawTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTranslatedPalCommand>(args); }
|
||||
void DrawTranslatedAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTlatedAddPalCommand>(args); }
|
||||
void DrawShadedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnShadedPalCommand>(args); }
|
||||
void DrawAddClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampPalCommand>(args); }
|
||||
void DrawAddClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampTranslatedPalCommand>(args); }
|
||||
void DrawSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampPalCommand>(args); }
|
||||
void DrawSubClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampTranslatedPalCommand>(args); }
|
||||
void DrawRevSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampPalCommand>(args); }
|
||||
void DrawRevSubClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampTranslatedPalCommand>(args); }
|
||||
void DrawColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnPalCommand>(args); }
|
||||
void FillColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnPalCommand>(args); }
|
||||
void FillAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddPalCommand>(args); }
|
||||
void FillAddClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddClampPalCommand>(args); }
|
||||
void FillSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnSubClampPalCommand>(args); }
|
||||
void FillRevSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnRevSubClampPalCommand>(args); }
|
||||
void DrawFuzzColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawFuzzColumnPalCommand>(args); R_UpdateFuzzPos(args); }
|
||||
void DrawAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddPalCommand>(args); }
|
||||
void DrawTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTranslatedPalCommand>(args); }
|
||||
void DrawTranslatedAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTlatedAddPalCommand>(args); }
|
||||
void DrawShadedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnShadedPalCommand>(args); }
|
||||
void DrawAddClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampPalCommand>(args); }
|
||||
void DrawAddClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampTranslatedPalCommand>(args); }
|
||||
void DrawSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampPalCommand>(args); }
|
||||
void DrawSubClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampTranslatedPalCommand>(args); }
|
||||
void DrawRevSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampPalCommand>(args); }
|
||||
void DrawRevSubClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampTranslatedPalCommand>(args); }
|
||||
void DrawSpan(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanPalCommand>(args); }
|
||||
void DrawSpanMasked(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanMaskedPalCommand>(args); }
|
||||
void DrawSpanTranslucent(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanTranslucentPalCommand>(args); }
|
||||
|
|
|
@ -246,7 +246,7 @@ namespace swrenderer
|
|||
return "DrawColumn\n" + args.ToString();
|
||||
}
|
||||
|
||||
DrawColumnLLVMCommand::DrawColumnLLVMCommand(const ColumnDrawerArgs &drawerargs)
|
||||
DrawColumnLLVMCommand::DrawColumnLLVMCommand(const SpriteDrawerArgs &drawerargs)
|
||||
{
|
||||
auto shade_constants = drawerargs.ColormapConstants();
|
||||
|
||||
|
@ -326,7 +326,7 @@ namespace swrenderer
|
|||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
DrawFuzzColumnRGBACommand::DrawFuzzColumnRGBACommand(const ColumnDrawerArgs &drawerargs)
|
||||
DrawFuzzColumnRGBACommand::DrawFuzzColumnRGBACommand(const SpriteDrawerArgs &drawerargs)
|
||||
{
|
||||
_x = drawerargs.dc_x;
|
||||
_yl = drawerargs.dc_yl;
|
||||
|
|
|
@ -150,7 +150,7 @@ namespace swrenderer
|
|||
FString DebugInfo() override;
|
||||
|
||||
public:
|
||||
DrawColumnLLVMCommand(const ColumnDrawerArgs &drawerargs);
|
||||
DrawColumnLLVMCommand(const SpriteDrawerArgs &drawerargs);
|
||||
|
||||
void Execute(DrawerThread *thread) override;
|
||||
};
|
||||
|
@ -201,7 +201,7 @@ namespace swrenderer
|
|||
int _fuzzviewheight;
|
||||
|
||||
public:
|
||||
DrawFuzzColumnRGBACommand(const ColumnDrawerArgs &drawerargs);
|
||||
DrawFuzzColumnRGBACommand(const SpriteDrawerArgs &drawerargs);
|
||||
void Execute(DrawerThread *thread) override;
|
||||
FString DebugInfo() override;
|
||||
};
|
||||
|
@ -362,23 +362,23 @@ namespace swrenderer
|
|||
void DrawWallRevSubClampColumn(const WallDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawWallRevSubClamp1LLVMCommand>(args); }
|
||||
void DrawSingleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool skyFade) override { DrawerCommandQueue::QueueCommand<DrawSingleSky1LLVMCommand>(args, solid_top, solid_bottom, skyFade); }
|
||||
void DrawDoubleSkyColumn(const SkyDrawerArgs &args, uint32_t solid_top, uint32_t solid_bottom, bool skyFade) override { DrawerCommandQueue::QueueCommand<DrawDoubleSky1LLVMCommand>(args, solid_top, solid_bottom, skyFade); }
|
||||
void DrawColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnLLVMCommand>(args); }
|
||||
void FillColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnLLVMCommand>(args); }
|
||||
void FillAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddLLVMCommand>(args); }
|
||||
void FillAddClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddClampLLVMCommand>(args); }
|
||||
void FillSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnSubClampLLVMCommand>(args); }
|
||||
void FillRevSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnRevSubClampLLVMCommand>(args); }
|
||||
void DrawFuzzColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawFuzzColumnRGBACommand>(args); R_UpdateFuzzPos(args); }
|
||||
void DrawAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddLLVMCommand>(args); }
|
||||
void DrawTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTranslatedLLVMCommand>(args); }
|
||||
void DrawTranslatedAddColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTlatedAddLLVMCommand>(args); }
|
||||
void DrawShadedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnShadedLLVMCommand>(args); }
|
||||
void DrawAddClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampLLVMCommand>(args); }
|
||||
void DrawAddClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampTranslatedLLVMCommand>(args); }
|
||||
void DrawSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampLLVMCommand>(args); }
|
||||
void DrawSubClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampTranslatedLLVMCommand>(args); }
|
||||
void DrawRevSubClampColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampLLVMCommand>(args); }
|
||||
void DrawRevSubClampTranslatedColumn(const ColumnDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampTranslatedLLVMCommand>(args); }
|
||||
void DrawColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnLLVMCommand>(args); }
|
||||
void FillColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnLLVMCommand>(args); }
|
||||
void FillAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddLLVMCommand>(args); }
|
||||
void FillAddClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnAddClampLLVMCommand>(args); }
|
||||
void FillSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnSubClampLLVMCommand>(args); }
|
||||
void FillRevSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<FillColumnRevSubClampLLVMCommand>(args); }
|
||||
void DrawFuzzColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawFuzzColumnRGBACommand>(args); R_UpdateFuzzPos(args); }
|
||||
void DrawAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddLLVMCommand>(args); }
|
||||
void DrawTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTranslatedLLVMCommand>(args); }
|
||||
void DrawTranslatedAddColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnTlatedAddLLVMCommand>(args); }
|
||||
void DrawShadedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnShadedLLVMCommand>(args); }
|
||||
void DrawAddClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampLLVMCommand>(args); }
|
||||
void DrawAddClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnAddClampTranslatedLLVMCommand>(args); }
|
||||
void DrawSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampLLVMCommand>(args); }
|
||||
void DrawSubClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnSubClampTranslatedLLVMCommand>(args); }
|
||||
void DrawRevSubClampColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampLLVMCommand>(args); }
|
||||
void DrawRevSubClampTranslatedColumn(const SpriteDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawColumnRevSubClampTranslatedLLVMCommand>(args); }
|
||||
void DrawSpan(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanLLVMCommand>(args); }
|
||||
void DrawSpanMasked(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanMaskedLLVMCommand>(args); }
|
||||
void DrawSpanTranslucent(const SpanDrawerArgs &args) override { DrawerCommandQueue::QueueCommand<DrawSpanTranslucentLLVMCommand>(args); }
|
||||
|
|
|
@ -59,7 +59,7 @@ namespace swrenderer
|
|||
return active_drawers;
|
||||
}
|
||||
|
||||
ColumnDrawerArgs::ColumnDrawerArgs()
|
||||
SpriteDrawerArgs::SpriteDrawerArgs()
|
||||
{
|
||||
colfunc = &SWPixelFormatDrawers::DrawColumn;
|
||||
basecolfunc = &SWPixelFormatDrawers::DrawColumn;
|
||||
|
@ -151,7 +151,7 @@ namespace swrenderer
|
|||
ds_source_mipmapped = tex->Mipmapped() && tex->GetWidth() > 1 && tex->GetHeight() > 1;
|
||||
}
|
||||
|
||||
void ColumnDrawerArgs::DrawMaskedColumn(int x, fixed_t iscale, FTexture *tex, fixed_t col, double spryscale, double sprtopscreen, bool sprflipvert, const short *mfloorclip, const short *mceilingclip, bool unmasked)
|
||||
void SpriteDrawerArgs::DrawMaskedColumn(int x, fixed_t iscale, FTexture *tex, fixed_t col, double spryscale, double sprtopscreen, bool sprflipvert, const short *mfloorclip, const short *mceilingclip, bool unmasked)
|
||||
{
|
||||
// Handle the linear filtered version in a different function to reduce chances of merge conflicts from zdoom.
|
||||
if (r_swtruecolor && !drawer_needs_pal_input) // To do: add support to R_DrawColumnHoriz_rgba
|
||||
|
@ -228,7 +228,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
void ColumnDrawerArgs::DrawMaskedColumnBgra(int x, fixed_t iscale, FTexture *tex, fixed_t col, double spryscale, double sprtopscreen, bool sprflipvert, const short *mfloorclip, const short *mceilingclip, bool unmasked)
|
||||
void SpriteDrawerArgs::DrawMaskedColumnBgra(int x, fixed_t iscale, FTexture *tex, fixed_t col, double spryscale, double sprtopscreen, bool sprflipvert, const short *mfloorclip, const short *mceilingclip, bool unmasked)
|
||||
{
|
||||
dc_x = x;
|
||||
dc_iscale = iscale;
|
||||
|
@ -343,7 +343,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
bool ColumnDrawerArgs::SetBlendFunc(int op, fixed_t fglevel, fixed_t bglevel, int flags)
|
||||
bool SpriteDrawerArgs::SetBlendFunc(int op, fixed_t fglevel, fixed_t bglevel, int flags)
|
||||
{
|
||||
// r_drawtrans is a seriously bad thing to turn off. I wonder if I should
|
||||
// just remove it completely.
|
||||
|
@ -467,7 +467,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
fixed_t ColumnDrawerArgs::GetAlpha(int type, fixed_t alpha)
|
||||
fixed_t SpriteDrawerArgs::GetAlpha(int type, fixed_t alpha)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
|
@ -479,7 +479,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
bool ColumnDrawerArgs::SetPatchStyle(FRenderStyle style, fixed_t alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade)
|
||||
bool SpriteDrawerArgs::SetPatchStyle(FRenderStyle style, fixed_t alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade)
|
||||
{
|
||||
fixed_t fglevel, bglevel;
|
||||
|
||||
|
@ -581,14 +581,14 @@ namespace swrenderer
|
|||
SetColorMapLight(&identitycolormap, 0, 0);
|
||||
}
|
||||
|
||||
if (!ColumnDrawerArgs::SetBlendFunc(style.BlendOp, fglevel, bglevel, style.Flags))
|
||||
if (!SpriteDrawerArgs::SetBlendFunc(style.BlendOp, fglevel, bglevel, style.Flags))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ColumnDrawerArgs::SetPatchStyle(FRenderStyle style, float alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade)
|
||||
bool SpriteDrawerArgs::SetPatchStyle(FRenderStyle style, float alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade)
|
||||
{
|
||||
return SetPatchStyle(style, FLOAT2FIXED(alpha), translation, color, basecolormap, shadedlightshade);
|
||||
}
|
||||
|
@ -724,12 +724,12 @@ namespace swrenderer
|
|||
dc_dest_y = y;
|
||||
}
|
||||
|
||||
void ColumnDrawerArgs::FillColumn()
|
||||
void SpriteDrawerArgs::FillColumn()
|
||||
{
|
||||
Drawers()->FillColumn(*this);
|
||||
}
|
||||
|
||||
void ColumnDrawerArgs::SetDest(int x, int y)
|
||||
void SpriteDrawerArgs::SetDest(int x, int y)
|
||||
{
|
||||
int pixelsize = r_swtruecolor ? 4 : 1;
|
||||
dc_dest = dc_destorg + (ylookup[y] + x) * pixelsize;
|
||||
|
|
|
@ -36,7 +36,7 @@ namespace swrenderer
|
|||
|
||||
typedef void(SWPixelFormatDrawers::*DrawerFunc)(const DrawerArgs &args);
|
||||
typedef void(SWPixelFormatDrawers::*WallDrawerFunc)(const WallDrawerArgs &args);
|
||||
typedef void(SWPixelFormatDrawers::*ColumnDrawerFunc)(const ColumnDrawerArgs &args);
|
||||
typedef void(SWPixelFormatDrawers::*SpriteDrawerFunc)(const SpriteDrawerArgs &args);
|
||||
typedef void(SWPixelFormatDrawers::*SpanDrawerFunc)(const SpanDrawerArgs &args);
|
||||
|
||||
class DrawerArgs
|
||||
|
@ -163,10 +163,10 @@ namespace swrenderer
|
|||
int dc_dest_y = 0;
|
||||
};
|
||||
|
||||
class ColumnDrawerArgs : public DrawerArgs
|
||||
class SpriteDrawerArgs : public DrawerArgs
|
||||
{
|
||||
public:
|
||||
ColumnDrawerArgs();
|
||||
SpriteDrawerArgs();
|
||||
|
||||
bool SetPatchStyle(FRenderStyle style, fixed_t alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade = 0);
|
||||
bool SetPatchStyle(FRenderStyle style, float alpha, int translation, uint32_t color, FDynamicColormap *&basecolormap, fixed_t shadedlightshade = 0);
|
||||
|
@ -200,10 +200,10 @@ namespace swrenderer
|
|||
fixed_t dc_srcalpha;
|
||||
fixed_t dc_destalpha;
|
||||
|
||||
ColumnDrawerFunc colfunc;
|
||||
ColumnDrawerFunc basecolfunc;
|
||||
ColumnDrawerFunc fuzzcolfunc;
|
||||
ColumnDrawerFunc transcolfunc;
|
||||
SpriteDrawerFunc colfunc;
|
||||
SpriteDrawerFunc basecolfunc;
|
||||
SpriteDrawerFunc fuzzcolfunc;
|
||||
SpriteDrawerFunc transcolfunc;
|
||||
|
||||
private:
|
||||
bool SetBlendFunc(int op, fixed_t fglevel, fixed_t bglevel, int flags);
|
||||
|
|
|
@ -72,7 +72,7 @@ namespace swrenderer
|
|||
WallDrawerArgs walldrawerargs;
|
||||
walldrawerargs.SetStyle(true, additive, FLOAT2FIXED(alpha));
|
||||
|
||||
ColumnDrawerArgs columndrawerargs;
|
||||
SpriteDrawerArgs columndrawerargs;
|
||||
FDynamicColormap *patchstylecolormap = nullptr;
|
||||
bool visible = columndrawerargs.SetPatchStyle(LegacyRenderStyles[additive ? STYLE_Add : STYLE_Translucent], alpha, 0, 0, patchstylecolormap);
|
||||
|
||||
|
|
|
@ -274,7 +274,7 @@ namespace swrenderer
|
|||
{
|
||||
int x = x1;
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
|
||||
if (cameraLight->fixedlightlev >= 0)
|
||||
drawerargs.SetColorMapLight((r_fullbrightignoresectorcolor) ? &FullNormalLight : usecolormap, 0, FIXEDLIGHT2SHADE(cameraLight->fixedlightlev));
|
||||
|
@ -315,7 +315,7 @@ namespace swrenderer
|
|||
} while (needrepeat--);
|
||||
}
|
||||
|
||||
void RenderDecal::DrawColumn(ColumnDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip)
|
||||
void RenderDecal::DrawColumn(SpriteDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip)
|
||||
{
|
||||
float iscale = walltexcoords.VStep[x] * maskedScaleY;
|
||||
double spryscale = 1 / iscale;
|
||||
|
|
|
@ -20,7 +20,7 @@ namespace swrenderer
|
|||
{
|
||||
struct DrawSegment;
|
||||
class ProjectedWallTexcoords;
|
||||
class ColumnDrawerArgs;
|
||||
class SpriteDrawerArgs;
|
||||
|
||||
class RenderDecal
|
||||
{
|
||||
|
@ -29,6 +29,6 @@ namespace swrenderer
|
|||
|
||||
private:
|
||||
static void Render(side_t *wall, DBaseDecal *first, DrawSegment *clipper, int wallshade, float lightleft, float lightstep, seg_t *curline, const FWallCoords &wallC, bool foggy, FDynamicColormap *basecolormap, const short *walltop, const short *wallbottom, int pass);
|
||||
static void DrawColumn(ColumnDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip);
|
||||
static void DrawColumn(SpriteDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip);
|
||||
};
|
||||
}
|
||||
|
|
|
@ -587,7 +587,7 @@ namespace swrenderer
|
|||
return;
|
||||
}
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
drawerargs.SetColorMapLight(Light.BaseColormap, 0, Light.ColormapNum << FRACBITS);
|
||||
|
||||
FDynamicColormap *basecolormap = static_cast<FDynamicColormap*>(Light.BaseColormap);
|
||||
|
|
|
@ -245,7 +245,7 @@ namespace swrenderer
|
|||
return;
|
||||
}
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
drawerargs.SetColorMapLight(vis->Light.BaseColormap, 0, vis->Light.ColormapNum << FRACBITS);
|
||||
|
||||
FDynamicColormap *basecolormap = static_cast<FDynamicColormap*>(vis->Light.BaseColormap);
|
||||
|
|
|
@ -187,7 +187,7 @@ namespace swrenderer
|
|||
|
||||
FDynamicColormap *basecolormap = static_cast<FDynamicColormap*>(sprite->Light.BaseColormap);
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
drawerargs.SetColorMapLight(sprite->Light.BaseColormap, 0, sprite->Light.ColormapNum << FRACBITS);
|
||||
|
||||
bool visible = drawerargs.SetPatchStyle(sprite->RenderStyle, sprite->Alpha, sprite->Translation, sprite->FillColor, basecolormap);
|
||||
|
@ -311,7 +311,7 @@ namespace swrenderer
|
|||
return (kvxslab_t*)(((uint8_t*)slab) + 3 + slab->zleng);
|
||||
}
|
||||
|
||||
void RenderVoxel::FillBox(ColumnDrawerArgs &drawerargs, DVector3 origin, double extentX, double extentY, int color, short *cliptop, short *clipbottom, bool viewspace, bool pixelstretch)
|
||||
void RenderVoxel::FillBox(SpriteDrawerArgs &drawerargs, DVector3 origin, double extentX, double extentY, int color, short *cliptop, short *clipbottom, bool viewspace, bool pixelstretch)
|
||||
{
|
||||
double viewX, viewY, viewZ;
|
||||
if (viewspace)
|
||||
|
|
|
@ -31,7 +31,7 @@ struct FVoxel;
|
|||
|
||||
namespace swrenderer
|
||||
{
|
||||
class ColumnDrawerArgs;
|
||||
class SpriteDrawerArgs;
|
||||
|
||||
// [RH] A c-buffer. Used for keeping track of offscreen voxel spans.
|
||||
struct FCoverageBuffer
|
||||
|
@ -83,7 +83,7 @@ namespace swrenderer
|
|||
|
||||
enum { DVF_OFFSCREEN = 1, DVF_SPANSONLY = 2, DVF_MIRRORED = 4 };
|
||||
|
||||
static void FillBox(ColumnDrawerArgs &drawerargs, DVector3 origin, double extentX, double extentY, int color, short *cliptop, short *clipbottom, bool viewspace, bool pixelstretch);
|
||||
static void FillBox(SpriteDrawerArgs &drawerargs, DVector3 origin, double extentX, double extentY, int color, short *cliptop, short *clipbottom, bool viewspace, bool pixelstretch);
|
||||
|
||||
static kvxslab_t *GetSlabStart(const FVoxelMipLevel &mip, int x, int y);
|
||||
static kvxslab_t *GetSlabEnd(const FVoxelMipLevel &mip, int x, int y);
|
||||
|
|
|
@ -179,7 +179,7 @@ namespace swrenderer
|
|||
rereadcolormap = false;
|
||||
}
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
|
||||
int shade = LIGHT2SHADE(spr->sector->lightlevel + R_ActualExtraLight(spr->foggy));
|
||||
double GlobVis = LightVisibility::Instance()->WallGlobVis();
|
||||
|
@ -245,7 +245,7 @@ namespace swrenderer
|
|||
}
|
||||
}
|
||||
|
||||
void RenderWallSprite::DrawColumn(ColumnDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip)
|
||||
void RenderWallSprite::DrawColumn(SpriteDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip)
|
||||
{
|
||||
float iscale = walltexcoords.VStep[x] * maskedScaleY;
|
||||
double spryscale = 1 / iscale;
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
namespace swrenderer
|
||||
{
|
||||
class ProjectedWallTexcoords;
|
||||
class ColumnDrawerArgs;
|
||||
class SpriteDrawerArgs;
|
||||
|
||||
class RenderWallSprite : public VisibleSprite
|
||||
{
|
||||
|
@ -30,7 +30,7 @@ namespace swrenderer
|
|||
void Render(short *cliptop, short *clipbottom, int minZ, int maxZ) override;
|
||||
|
||||
private:
|
||||
static void DrawColumn(ColumnDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip);
|
||||
static void DrawColumn(SpriteDrawerArgs &drawerargs, int x, FTexture *WallSpriteTile, const ProjectedWallTexcoords &walltexcoords, double texturemid, float maskedScaleY, bool sprflipvert, const short *mfloorclip, const short *mceilingclip);
|
||||
|
||||
FWallCoords wallc;
|
||||
uint32_t Translation = 0;
|
||||
|
|
|
@ -184,7 +184,7 @@ void DCanvas::DrawTextureParms(FTexture *img, DrawParms &parms)
|
|||
translation = parms.remap->Remap;
|
||||
}
|
||||
|
||||
ColumnDrawerArgs drawerargs;
|
||||
SpriteDrawerArgs drawerargs;
|
||||
|
||||
if (translation != NULL)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue