convert line ends
[canaan.git] / prj / cam / src / render / mlight.h
blob01abf77af9f7a2b659c746dc17558c72b8df2fc5
1 /*
2 @Copyright Looking Glass Studios, Inc.
3 1996,1997,1998,1999,2000 Unpublished Work.
4 */
6 // $Header: r:/t2repos/thief2/src/render/mlight.h,v 1.12 2000/01/29 13:39:15 adurant Exp $
7 #pragma once
9 #ifndef __MLIGHT_H
10 #define __MLIGHT_H
12 #include <matrixs.h>
14 #ifdef RGB_LIGHTING
15 typedef mxs_vector rgb_vector;
16 #endif
18 typedef struct
20 mxs_vector loc;
21 mxs_vector dir;
22 #ifdef RGB_LIGHTING
23 rgb_vector bright;
24 #else
25 float bright;
26 #endif
27 float inner,outer;
28 float radius;
29 } mls_multi_light; // 32 bytes or 48 bytes
31 // ambient base for next object
32 EXTERN float mld_multi_ambient;
34 #ifdef RGB_LIGHTING
35 EXTERN rgb_vector mld_multi_rgb_ambient;
36 #endif
38 // should the next object be unlit - ie. full-brite
39 EXTERN BOOL mld_multi_unlit;
41 EXTERN BOOL mld_multi_ambient_only;
43 // by what amount do you want the next object "hilit"
44 EXTERN float mld_multi_hilight;
46 EXTERN bool mld_multi_rgb;
48 // How should the self illumination get scaled
49 // for self illuminated models
50 EXTERN float mld_illum_scale;
52 #ifdef RGB_LIGHTING
53 // Set this if you want a colored light in the bulb, rather
54 // than a white light. It will scale accordingly
55 // For instance, if you had a green light, set to 0,1,0
56 // or something like that
57 EXTERN mxs_vector mld_illum_rgb;
58 #endif
61 // initialize mlight system
62 EXTERN void ml_init_multi_lighting(void);
64 EXTERN int ml_multi_set_lights_for_object(int num, mls_multi_light *lights,
65 mxs_vector *obj_center, float obj_radius);
67 // compute lighting due to a single light, useful for non-rendering
68 // information about light on an object
69 EXTERN float ml_multi_light_on_object(mls_multi_light *inp,
70 mxs_vector *obj_center);
73 #endif