mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2025-02-18 01:51:44 +00:00
models: Fix Anachronox resolution == 1
DKM2 has different sequence of packed verts so exchange to correct sequence
This commit is contained in:
parent
af6d0b26bd
commit
079267996d
1 changed files with 9 additions and 0 deletions
|
@ -220,9 +220,18 @@ Mod_LoadFrames_MD2Anox(dmdx_t *pheader, byte *src, size_t inframesize,
|
||||||
/* verts are 32 bit and swap are inside vonvert code*/
|
/* verts are 32 bit and swap are inside vonvert code*/
|
||||||
for (j=0; j < pheader->num_xyz; j ++)
|
for (j=0; j < pheader->num_xyz; j ++)
|
||||||
{
|
{
|
||||||
|
short tmp;
|
||||||
|
|
||||||
Mod_LoadFrames_VertDKM2(poutframe->verts + j, *((int *)inverts));
|
Mod_LoadFrames_VertDKM2(poutframe->verts + j, *((int *)inverts));
|
||||||
|
|
||||||
/* int vert + 2 bytes */
|
/* int vert + 2 bytes */
|
||||||
inverts += 6;
|
inverts += 6;
|
||||||
|
|
||||||
|
/* DKM2 has opposite vert list in packed format */
|
||||||
|
tmp = poutframe->verts[j].v[0];
|
||||||
|
poutframe->verts[j].v[0] = poutframe->verts[j].v[2];
|
||||||
|
poutframe->verts[j].v[2] = tmp;
|
||||||
|
|
||||||
/* norm convert logic is unknown */
|
/* norm convert logic is unknown */
|
||||||
poutframe->verts[j].lightnormalindex = 0;
|
poutframe->verts[j].lightnormalindex = 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue