mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-05-06 19:01:04 +03:00
Added reallight functions, unimplemented
This commit is contained in:
parent
415a5e60da
commit
22fdf36cc6
2 changed files with 78 additions and 0 deletions
|
@ -45,10 +45,74 @@ typedef struct {
|
||||||
int numLights;
|
int numLights;
|
||||||
} dlightInfo_t;
|
} dlightInfo_t;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
vec3_t point;
|
||||||
|
int s;
|
||||||
|
int t;
|
||||||
|
} patchLightBlock_t;
|
||||||
|
|
||||||
dlightInfo_t dli;
|
dlightInfo_t dli;
|
||||||
|
|
||||||
void R_SetupEntityLightingGrid(trRefEntity_t* ent);
|
void R_SetupEntityLightingGrid(trRefEntity_t* ent);
|
||||||
|
|
||||||
|
static int R_RecursiveDlightPatch(patchLightBlock_t* plb) {
|
||||||
|
patchLightBlock_t cut[4];
|
||||||
|
qboolean added;
|
||||||
|
int index;
|
||||||
|
|
||||||
|
// FIXME: unimplemented
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int R_RealDlightPatch(srfGridMesh_t* srf, int dlightBit) {
|
||||||
|
int x, y;
|
||||||
|
int i, j;
|
||||||
|
int i2, j2;
|
||||||
|
int steps[2][2];
|
||||||
|
dlight_t* dl;
|
||||||
|
qboolean added;
|
||||||
|
float* origin;
|
||||||
|
drawVert_t* dv;
|
||||||
|
|
||||||
|
// FIXME: unimplemented
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int R_RealDlightFace(srfSurfaceFace_t* srf, int dlightBits) {
|
||||||
|
int x, y;
|
||||||
|
byte* src, * dst;
|
||||||
|
int i, j;
|
||||||
|
vec3_t vec;
|
||||||
|
vec3_t vecStepS, vecStepT;
|
||||||
|
dlight_t* dl;
|
||||||
|
float d;
|
||||||
|
qboolean added;
|
||||||
|
float* origin;
|
||||||
|
|
||||||
|
// FIXME: unimplemented
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int R_RealDlightTerrain(cTerraPatchUnpacked_t* srf, int dlightBits) {
|
||||||
|
dlight_t* dl;
|
||||||
|
int x, y;
|
||||||
|
byte* dst, * src;
|
||||||
|
vec3_t vec;
|
||||||
|
float delta, dist;
|
||||||
|
float* origin;
|
||||||
|
int i, j, k;
|
||||||
|
int di, dj;
|
||||||
|
qboolean added;
|
||||||
|
float lmScale;
|
||||||
|
int lumelsPerHeight;
|
||||||
|
float heightPerLumelSquared;
|
||||||
|
float z00, z01;
|
||||||
|
float z10, z11;
|
||||||
|
|
||||||
|
// FIXME: unimplemented
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
===============
|
===============
|
||||||
R_TransformDlights
|
R_TransformDlights
|
||||||
|
@ -526,3 +590,14 @@ qboolean R_AllocLMBlock(int w, int h, int* x, int* y) {
|
||||||
|
|
||||||
return qtrue;
|
return qtrue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
qboolean R_DlightSample(byte* src, const vec3_t vec, byte* dst) {
|
||||||
|
int r, g, b;
|
||||||
|
int k;
|
||||||
|
qboolean added;
|
||||||
|
vec3_t dir;
|
||||||
|
float add;
|
||||||
|
|
||||||
|
// FIXME: unimplemented
|
||||||
|
return qfalse;
|
||||||
|
}
|
||||||
|
|
|
@ -1906,6 +1906,9 @@ void R_GetLightingForSmoke(vec3_t vLight, const vec3_t vOrigin);
|
||||||
void R_SetupEntityLighting( const trRefdef_t *refdef, trRefEntity_t *ent );
|
void R_SetupEntityLighting( const trRefdef_t *refdef, trRefEntity_t *ent );
|
||||||
void RB_SetupEntityGridLighting();
|
void RB_SetupEntityGridLighting();
|
||||||
void RB_SetupStaticModelGridLighting(trRefdef_t* refdef, cStaticModelUnpacked_t* ent, const vec3_t lightOrigin);
|
void RB_SetupStaticModelGridLighting(trRefdef_t* refdef, cStaticModelUnpacked_t* ent, const vec3_t lightOrigin);
|
||||||
|
int R_RealDlightPatch(srfGridMesh_t* srf, int dlightBit);
|
||||||
|
int R_RealDlightFace(srfSurfaceFace_t* srf, int dlightBits);
|
||||||
|
int R_RealDlightTerrain(cTerraPatchUnpacked_t* srf, int dlightBits);
|
||||||
void R_TransformDlights( int count, dlight_t *dl, orientationr_t *ori );
|
void R_TransformDlights( int count, dlight_t *dl, orientationr_t *ori );
|
||||||
void RB_Light_Real(unsigned char* colors);
|
void RB_Light_Real(unsigned char* colors);
|
||||||
void RB_Sphere_BuildDLights();
|
void RB_Sphere_BuildDLights();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue