1
0
Fork 0
forked from len0rd/rockbox

quake: merge the remaining Pocket Quake PQ_OPT changes

I didn't do _OPT3 because it's disabled in the PQ source.

This gives as +0.2FPS boost over the last commit.

Change-Id: I9c3c8fb7bd23262beb810da6e9469d6b6c4b2a81
This commit is contained in:
Franklin Wei 2019-08-09 20:31:24 -04:00
parent ee70dad305
commit f5bb7fddec
7 changed files with 767 additions and 4 deletions

View file

@ -588,6 +588,9 @@ void Mod_LoadVertexes (lump_t *l)
dvertex_t *in;
mvertex_t *out;
int i, count;
#ifdef USE_PQ_OPT2
mvertex_fxp_t *out2;
#endif
in = (void *)(mod_base + l->fileofs);
if (l->filelen % sizeof(*in))
@ -595,6 +598,11 @@ void Mod_LoadVertexes (lump_t *l)
count = l->filelen / sizeof(*in);
out = Hunk_AllocName ( count*sizeof(*out), loadname);
#ifdef USE_PQ_OPT2
out2 = Hunk_AllocName ( count*sizeof(*out2), loadname);
loadmodel->vertexes_fxp = out2;
#endif
loadmodel->vertexes = out;
loadmodel->numvertexes = count;
@ -603,6 +611,14 @@ void Mod_LoadVertexes (lump_t *l)
out->position[0] = LittleFloatUnaligned (in->point[0]);
out->position[1] = LittleFloatUnaligned (in->point[1]);
out->position[2] = LittleFloatUnaligned (in->point[2]);
#ifdef USE_PQ_OPT2
out2->position[0] = (int)(out->position[0]*524288.0f); //13.19
out2->position[1] = (int)(out->position[1]*524288.0f); //13.19
out2->position[2] = (int)(out->position[2]*524288.0f); //13.19
out2++;
#endif
}
}