diff --git a/include/r_local.h b/include/r_local.h index b1c9e2d..9fe4ac1 100644 --- a/include/r_local.h +++ b/include/r_local.h @@ -349,3 +349,6 @@ void R_EmitEdge (mvertex_t *pv0, mvertex_t *pv1); void R_ClipEdge (mvertex_t *pv0, mvertex_t *pv1, clipplane_t *clip); void R_SplitEntityOnNode2 (mnode_t *node); void R_MarkLights (dlight_t *light, int bit, mnode_t *node); + +void R_LoadSkys (char *); + diff --git a/include/render.h b/include/render.h index 8a1daf2..743accb 100644 --- a/include/render.h +++ b/include/render.h @@ -124,7 +124,6 @@ void R_RemoveEfrags (entity_t *ent); void R_NewMap (void); - void R_ParseParticleEffect (void); void R_RunParticleEffect (vec3_t org, vec3_t dir, int color, int count); void R_RocketTrail (vec3_t start, vec3_t end, int type); diff --git a/source/gl_rmisc.c b/source/gl_rmisc.c index 86641e6..049af79 100644 --- a/source/gl_rmisc.c +++ b/source/gl_rmisc.c @@ -195,6 +195,22 @@ void R_Envmap_f (void) GL_EndRendering (); } +/* + R_LoadSky_f +*/ +void +R_LoadSky_f () +{ + if (Cmd_Argc () != 2) + { + Con_Printf ("loadsky : load a skybox\n"); + return; + } + + R_LoadSkys (Cmd_Argv(1)); +} + + /* =============== R_Init @@ -204,7 +220,8 @@ void R_Init (void) { Cmd_AddCommand ("timerefresh", R_TimeRefresh_f); Cmd_AddCommand ("envmap", R_Envmap_f); - Cmd_AddCommand ("pointfile", R_ReadPointFile_f); + Cmd_AddCommand ("pointfile", R_ReadPointFile_f); + Cmd_AddCommand ("loadsky", R_LoadSky_f); /* Cvar_RegisterVariable (&r_norefresh); CVAR_FIXME */ diff --git a/source/r_main.c b/source/r_main.c index 8d3f86c..cc9e2ff 100644 --- a/source/r_main.c +++ b/source/r_main.c @@ -239,6 +239,8 @@ void R_InitTextures (void) } } +void R_LoadSky_f (); + /* =============== R_Init @@ -255,6 +257,7 @@ void R_Init (void) Cmd_AddCommand ("timerefresh", R_TimeRefresh_f); Cmd_AddCommand ("pointfile", R_ReadPointFile_f); + Cmd_AddCommand ("loadsky", R_LoadSky_f); /* Cvar_RegisterVariable (&r_draworder); CVAR_FIXME */ diff --git a/source/r_misc.c b/source/r_misc.c index 15a42b1..e4b4498 100644 --- a/source/r_misc.c +++ b/source/r_misc.c @@ -116,6 +116,23 @@ void R_TimeRefresh_f (void) r_refdef.viewangles[1] = startangle; } + +/* + R_LoadSky_f +*/ +void +R_LoadSky_f () +{ + if (Cmd_Argc () != 2) + { + Con_Printf ("loadsky : load a skybox\n"); + return; + } + + R_LoadSkys (Cmd_Argv(1)); +} + + /* ================ R_LineGraph diff --git a/source/r_sky.c b/source/r_sky.c index b8ba5d5..3ca49d7 100644 --- a/source/r_sky.c +++ b/source/r_sky.c @@ -288,3 +288,13 @@ void R_SetSkyFrame (void) } +/* + R_LoadSkys + + Stub function for loading a skybox. Currently we only have support for + skyboxes in GL targets, so we just do nothing here. --KB +*/ +void +R_LoadSkys (char * name) +{ +}