Only dirty the uniform UVSCALEOFFSET when really needed

Broken out from #17479

With OpenGL, greatly reduces the amount of glUniform4fv calls in many games (and
similar in the other backends).
This commit is contained in:
Henrik Rydgård 2023-05-25 14:46:33 +02:00
parent 82934b9212
commit 80e47b7bd3
8 changed files with 28 additions and 23 deletions

View file

@ -1176,7 +1176,7 @@ void VertexDecoder::SetVertexType(u32 fmt, const VertexDecoderOptions &options,
steps_[numSteps_++] = morphcount == 1 ? colstep[col] : colstep_morph[col];
// All color formats decode to DEC_U8_4 currently.
// All color formats decode to DEC_U8_4.
// They can become floats later during transform though.
decFmt.c0fmt = DEC_U8_4;
decFmt.c0off = decOff;