mingl fix
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3892 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
604576ae18
commit
c0e6bcfeb4
1 changed files with 7 additions and 1 deletions
|
@ -1060,9 +1060,11 @@ struct
|
||||||
int surfnum;
|
int surfnum;
|
||||||
entity_t *ent;
|
entity_t *ent;
|
||||||
|
|
||||||
|
#ifdef SKELETALMODELS
|
||||||
float bonepose[MAX_BONES*12];
|
float bonepose[MAX_BONES*12];
|
||||||
float *usebonepose;
|
float *usebonepose;
|
||||||
int bonecount;
|
int bonecount;
|
||||||
|
#endif
|
||||||
|
|
||||||
vecV_t *acoords;
|
vecV_t *acoords;
|
||||||
vec3_t *anorm;
|
vec3_t *anorm;
|
||||||
|
@ -1432,6 +1434,7 @@ qboolean Alias_GAliasBuildMesh(mesh_t *mesh, galiasinfo_t *inf, int surfnum, ent
|
||||||
mesh->snormals_array = meshcache.anorms;
|
mesh->snormals_array = meshcache.anorms;
|
||||||
mesh->tnormals_array = meshcache.anormt;
|
mesh->tnormals_array = meshcache.anormt;
|
||||||
|
|
||||||
|
#ifdef SKELETALMODELS
|
||||||
if (meshcache.usebonepose)
|
if (meshcache.usebonepose)
|
||||||
{
|
{
|
||||||
mesh->bonenums = (byte_vec4_t*)((char*)inf + inf->ofs_skel_idx);
|
mesh->bonenums = (byte_vec4_t*)((char*)inf + inf->ofs_skel_idx);
|
||||||
|
@ -1439,6 +1442,7 @@ qboolean Alias_GAliasBuildMesh(mesh_t *mesh, galiasinfo_t *inf, int surfnum, ent
|
||||||
mesh->bones = meshcache.usebonepose;
|
mesh->bones = meshcache.usebonepose;
|
||||||
mesh->numbones = inf->numbones;
|
mesh->numbones = inf->numbones;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
return false; //don't generate the new vertex positions. We still have them all.
|
return false; //don't generate the new vertex positions. We still have them all.
|
||||||
}
|
}
|
||||||
meshcache.surfnum = inf->shares_verts;
|
meshcache.surfnum = inf->shares_verts;
|
||||||
|
@ -1458,8 +1462,8 @@ qboolean Alias_GAliasBuildMesh(mesh_t *mesh, galiasinfo_t *inf, int surfnum, ent
|
||||||
//we don't support meshes with one pose skeletal and annother not.
|
//we don't support meshes with one pose skeletal and annother not.
|
||||||
//we don't support meshes with one group skeletal and annother not.
|
//we don't support meshes with one group skeletal and annother not.
|
||||||
|
|
||||||
meshcache.usebonepose = NULL;
|
|
||||||
#ifdef SKELETALMODELS
|
#ifdef SKELETALMODELS
|
||||||
|
meshcache.usebonepose = NULL;
|
||||||
if (inf->numbones)
|
if (inf->numbones)
|
||||||
{
|
{
|
||||||
meshcache.usebonepose = Alias_GetBonePositions(inf, &e->framestate, meshcache.bonepose, MAX_BONES);
|
meshcache.usebonepose = Alias_GetBonePositions(inf, &e->framestate, meshcache.bonepose, MAX_BONES);
|
||||||
|
@ -1567,6 +1571,7 @@ qboolean Alias_GAliasBuildMesh(mesh_t *mesh, galiasinfo_t *inf, int surfnum, ent
|
||||||
meshcache.anorms = mesh->snormals_array;
|
meshcache.anorms = mesh->snormals_array;
|
||||||
meshcache.anormt = mesh->tnormals_array;
|
meshcache.anormt = mesh->tnormals_array;
|
||||||
|
|
||||||
|
#ifdef SKELETALMODELS
|
||||||
if (meshcache.usebonepose)
|
if (meshcache.usebonepose)
|
||||||
{
|
{
|
||||||
mesh->bonenums = (byte_vec4_t*)((char*)inf + inf->ofs_skel_idx);
|
mesh->bonenums = (byte_vec4_t*)((char*)inf + inf->ofs_skel_idx);
|
||||||
|
@ -1574,6 +1579,7 @@ qboolean Alias_GAliasBuildMesh(mesh_t *mesh, galiasinfo_t *inf, int surfnum, ent
|
||||||
mesh->bones = meshcache.usebonepose;
|
mesh->bones = meshcache.usebonepose;
|
||||||
mesh->numbones = inf->numbones;
|
mesh->numbones = inf->numbones;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return true; //to allow the mesh to be dlighted.
|
return true; //to allow the mesh to be dlighted.
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue