mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-13 16:07:45 +00:00
Fix missing particles in true color mode
This commit is contained in:
parent
351874be30
commit
42efc7334e
3 changed files with 12 additions and 2 deletions
|
@ -570,12 +570,15 @@ public:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Redirects all drawing commands to worker threads until Finish is called
|
// Redirects all drawing commands to worker threads until End is called
|
||||||
// Begin/End blocks can be nested.
|
// Begin/End blocks can be nested.
|
||||||
static void Begin();
|
static void Begin();
|
||||||
|
|
||||||
// Wait until all worker threads finished executing commands
|
// End redirection and wait until all worker threads finished executing
|
||||||
static void End();
|
static void End();
|
||||||
|
|
||||||
|
// Waits until all worker threads finished executing
|
||||||
|
static void WaitForWorkers();
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -97,6 +97,11 @@ void DrawerCommandQueue::End()
|
||||||
queue->threaded_render--;
|
queue->threaded_render--;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void DrawerCommandQueue::WaitForWorkers()
|
||||||
|
{
|
||||||
|
Instance()->Finish();
|
||||||
|
}
|
||||||
|
|
||||||
void DrawerCommandQueue::Finish()
|
void DrawerCommandQueue::Finish()
|
||||||
{
|
{
|
||||||
auto queue = Instance();
|
auto queue = Instance();
|
||||||
|
|
|
@ -2686,6 +2686,8 @@ void R_DrawParticle_RGBA(vissprite_t *vis)
|
||||||
int countbase = vis->x2 - x1;
|
int countbase = vis->x2 - x1;
|
||||||
|
|
||||||
R_DrawMaskedSegsBehindParticle(vis);
|
R_DrawMaskedSegsBehindParticle(vis);
|
||||||
|
|
||||||
|
DrawerCommandQueue::WaitForWorkers();
|
||||||
|
|
||||||
uint32_t fg = shade_pal_index_simple(color, calc_light_multiplier(LIGHTSCALE(0, vis->Style.ColormapNum << FRACBITS)));
|
uint32_t fg = shade_pal_index_simple(color, calc_light_multiplier(LIGHTSCALE(0, vis->Style.ColormapNum << FRACBITS)));
|
||||||
uint32_t fg_red = (fg >> 16) & 0xff;
|
uint32_t fg_red = (fg >> 16) & 0xff;
|
||||||
|
|
Loading…
Reference in a new issue