diff --git a/common/cl_main.c b/common/cl_main.c index 18e5077..e71a6a7 100644 --- a/common/cl_main.c +++ b/common/cl_main.c @@ -1250,6 +1250,10 @@ void CL_RelinkEntities (void) if (ent->msgtime != cl.mtime[0]) { ent->model = NULL; +#ifdef EXPERIMENTAL + ent->translate_start_time = 0; + ent->rotate_start_time = 0; +#endif continue; } diff --git a/common/gl_rmain.c b/common/gl_rmain.c index ff01e46..d3e61be 100644 --- a/common/gl_rmain.c +++ b/common/gl_rmain.c @@ -151,6 +151,10 @@ R_CullBox (vec3_t mins, vec3_t maxs) { return false; } +#ifdef EXPERIMENTAL +/* + R_BlendedRotateForEntity +*/ void R_BlendedRotateForEntity (entity_t *e) { @@ -216,6 +220,7 @@ R_BlendedRotateForEntity (entity_t *e) glRotatef (-e->angles1[0] + (-blend * d[0]), 0, 1, 0); glRotatef ( e->angles1[2] + ( blend * d[2]), 1, 0, 0); } +#endif void R_RotateForEntity (entity_t *e) @@ -414,7 +419,7 @@ GL_DrawAliasFrame (aliashdr_t *paliashdr, int posenum) } } - +#ifdef EXPERIMENTAL /* GL_DrawAliasBlendedFrame */ @@ -432,8 +437,7 @@ GL_DrawAliasBlendedFrame (aliashdr_t *paliashdr, int pose1, int pose2, lastposenum0 = pose1; lastposenum = pose2; - verts1 = (trivertx_t *)((byte *)paliashdr + - paliashdr->posedata); + verts1 = (trivertx_t *)((byte *)paliashdr + paliashdr->posedata); verts2 = verts1; verts1 += pose1 * paliashdr->poseverts; @@ -485,7 +489,7 @@ GL_DrawAliasBlendedFrame (aliashdr_t *paliashdr, int pose1, int pose2, glEnd (); } } - +#endif /* @@ -573,6 +577,7 @@ R_SetupAliasFrame (int frame, aliashdr_t *paliashdr) } +#ifdef EXPERIMENTAL /* R_SetupAliasBlendedFrame */ @@ -620,6 +625,8 @@ R_SetupAliasBlendedFrame (int frame, aliashdr_t *paliashdr, entity_t *e) GL_DrawAliasBlendedFrame (paliashdr, e->pose1, e->pose2, blend); } +#endif + /* R_DrawAliasModel @@ -736,9 +743,11 @@ R_DrawAliasModel (entity_t *e) GL_DisableMultitexture(); glPushMatrix (); +#ifdef EXPERIMENTAL if (r_interptransform->value) R_BlendedRotateForEntity (e); else +#endif R_RotateForEntity (e); if (!strcmp (clmodel->name, "progs/eyes.mdl") && @@ -789,10 +798,12 @@ R_DrawAliasModel (entity_t *e) if (gl_affinemodels->value) glHint (GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST); +#ifdef EXPERIMENTAL if (r_interpanimation->value) R_SetupAliasBlendedFrame (currententity->frame, paliashdr, currententity); else +#endif R_SetupAliasFrame (currententity->frame, paliashdr); diff --git a/common/gl_rmisc.c b/common/gl_rmisc.c index a8f6f23..b8ceeec 100644 --- a/common/gl_rmisc.c +++ b/common/gl_rmisc.c @@ -212,11 +212,13 @@ void R_Init (void) r_shadows = Cvar_Get ("r_shadows", "0", CVAR_NONE, "None"); +#ifdef EXPERIMENTAL // FIXME: Change these back to 1 .. --KB r_interpanimation = Cvar_Get ("r_interpanimation", "0", CVAR_ARCHIVE, "toggles interpolation of model animation"); r_interptransform = Cvar_Get ("r_interptransform", "0", CVAR_ARCHIVE, "toggles interpolation of model transformation"); +#endif r_wateralpha = Cvar_Get ("r_wateralpha", "1", CVAR_NONE, "Alpha value for water textures, valid range is " diff --git a/common/glquake.h b/common/glquake.h index 58ff93b..cc07308 100644 --- a/common/glquake.h +++ b/common/glquake.h @@ -185,8 +185,10 @@ extern cvar_t *r_waterwarp; extern cvar_t *r_fullbright; extern cvar_t *r_lightmap; extern cvar_t *r_shadows; +#ifdef EXPERIMENTAL extern cvar_t *r_interpanimation; extern cvar_t *r_interptransform; +#endif extern cvar_t *r_wateralpha; extern cvar_t *r_dynamic; extern cvar_t *r_novis; diff --git a/common/render.h b/common/render.h index 4f5eb9f..30c10f8 100644 --- a/common/render.h +++ b/common/render.h @@ -78,20 +78,22 @@ typedef struct entity_s vec3_t msg_origins[2]; // last 2 updates (0 is newest) vec3_t msg_angles[2]; // last 2 updates (0 is newest) int effects; // light, particles, etc - float translate_start_time; - vec3_t origin1; - vec3_t origin2; vec3_t origin; - float rotate_start_time; - vec3_t angles1; - vec3_t angles2; vec3_t angles; struct model_s *model; // NULL = no model struct efrag_s *efrag; // linked list of efrags int frame; +#ifdef EXPERIMENTAL + float translate_start_time; + vec3_t origin1; + vec3_t origin2; + float rotate_start_time; + vec3_t angles1; + vec3_t angles2; float frame_start_time; float frame_interval; int pose1, pose2; +#endif float syncbase; // for client-side animations byte *colormap; int skinnum; // for Alias models