mirror of
https://github.com/open-goal/jak-project.git
synced 2024-10-20 11:26:18 -04:00
[sprite glow] fix crashes (#2256)
Co-authored-by: ManDude <7569514+ManDude@users.noreply.github.com>
This commit is contained in:
parent
618455500d
commit
41fabd43f7
|
@ -409,7 +409,8 @@ void GlowRenderer::add_sprite_pass_3(const SpriteGlowOutput& data, int sprite_id
|
|||
|
||||
// handle adgif stuff
|
||||
{
|
||||
ASSERT(data.adgif.tex0_addr == (u32)GsRegisterAddress::TEX0_1);
|
||||
// don't check upper bits: ps2 GS ignores them and ND uses them as flags.
|
||||
ASSERT((u8)data.adgif.tex0_addr == (u8)GsRegisterAddress::TEX0_1);
|
||||
GsTex0 reg(data.adgif.tex0_data);
|
||||
record.tbp = reg.tbp0();
|
||||
record.draw_mode.set_tcc(reg.tcc());
|
||||
|
|
|
@ -73,7 +73,9 @@ class GlowRenderer {
|
|||
GLuint tex;
|
||||
};
|
||||
|
||||
static constexpr int kDownsampleBatchWidth = 16;
|
||||
// max sprites should be 128 in simple sprite, plus 256 from aux = 384
|
||||
// 20 width = 20 * 20 = 400 sprites > 384.
|
||||
static constexpr int kDownsampleBatchWidth = 20;
|
||||
static constexpr int kMaxSprites = kDownsampleBatchWidth * kDownsampleBatchWidth;
|
||||
static constexpr int kMaxVertices = kMaxSprites * 32; // check.
|
||||
static constexpr int kMaxIndices = kMaxSprites * 32; // check.
|
||||
|
|
Loading…
Reference in a new issue