mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2025-02-16 17:11:03 +00:00
models: fix embeded image load
This commit is contained in:
parent
b21391954d
commit
0d48f5e0ec
1 changed files with 3 additions and 9 deletions
|
@ -723,13 +723,7 @@ Mod_LoadModel_MDL(const char *mod_name, const void *buffer, int modfilelen,
|
|||
// verts are all 8 bit, so no swapping needed
|
||||
for (j=0; j < num_xyz; j ++)
|
||||
{
|
||||
int k;
|
||||
|
||||
for (k=0; k < 3; k++)
|
||||
{
|
||||
poutvertx[j].v[k] = pinvertx[j].v[k] * 0xFF;
|
||||
}
|
||||
|
||||
Mod_LoadFrames_VertMD2(poutvertx + j, pinvertx[j].v);
|
||||
poutvertx[j].lightnormalindex = pinvertx[j].lightnormalindex;
|
||||
}
|
||||
curr_pos += sizeof(dtrivertx_t) * num_xyz;
|
||||
|
@ -2329,12 +2323,12 @@ Mod_ReLoadSkins(struct image_s **skins, findimage_t find_image, loadimage_t load
|
|||
for (i = 0; i < pheader->num_skins; i++)
|
||||
{
|
||||
skins[i] = load_image(
|
||||
(char *)pheader + pheader->ofs_skins + i*MAX_SKINNAME,
|
||||
(char *)pheader + pheader->ofs_skins + i * MAX_SKINNAME,
|
||||
images, pheader->skinwidth, pheader->skinwidth,
|
||||
pheader->skinheight, pheader->skinheight,
|
||||
pheader->skinheight * pheader->skinwidth,
|
||||
it_skin, pheader->num_imgbit);
|
||||
images += (pheader->skinheight * pheader->skinwidth * pheader->ofs_imgbit / 8);
|
||||
images += (pheader->skinheight * pheader->skinwidth * pheader->num_imgbit / 8);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue