UFO: Alien Invasion
Loading...
Searching...
No Matches
r_lightmap.h
Go to the documentation of this file.
1
5
6
/*
7
All original material Copyright (C) 2002-2025 UFO: Alien Invasion.
8
9
This program is free software; you can redistribute it and/or
10
modify it under the terms of the GNU General Public License
11
as published by the Free Software Foundation; either version 2
12
of the License, or (at your option) any later version.
13
14
This program is distributed in the hope that it will be useful,
15
but WITHOUT ANY WARRANTY; without even the implied warranty of
16
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
17
18
See the GNU General Public License for more details.
19
20
You should have received a copy of the GNU General Public License
21
along with this program; if not, write to the Free Software
22
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
23
24
*/
25
26
#pragma once
27
28
#include "
r_entity.h
"
29
30
#define LIGHTMAP_DEFAULT_PAGE_SIZE 1024
31
#define LIGHTMAP_MAX_PAGE_SIZE 4096
32
33
#define LIGHTMAP_SAMPLE_SIZE 3
/* RGB */
34
#define DELUXEMAP_SAMPLE_SIZE 3
/* XYZ */
35
36
void
R_CreateSurfaceLightmap
(
mBspSurface_t
* surf);
37
void
R_EndBuildingLightmaps
(
void
);
38
void
R_BeginBuildingLightmaps
(
void
);
39
40
void
R_Trace
(
const
Line
& trLine,
float
size
,
int
contentmask);
41
42
typedef
struct
lightmaps_s {
43
GLuint
lightmap_texnums
[
MAX_GL_LIGHTMAPS
];
44
GLuint
deluxemap_texnums
[
MAX_GL_DELUXEMAPS
];
45
46
int
lightmap_count
;
47
int
deluxemap_count
;
48
49
bool
incomplete_atlas
;
50
51
int
size
;
52
53
unsigned
*
allocated
;
54
55
byte
*
sample_buffer
;
56
byte
*
direction_buffer
;
57
}
lightmaps_t
;
58
59
extern
lightmaps_t
r_lightmaps
;
Line
Definition
line.h:31
size
voidpf void uLong size
Definition
ioapi.h:42
r_entity.h
GLuint
QGL_EXTERN GLuint
Definition
r_gl.h:124
MAX_GL_DELUXEMAPS
#define MAX_GL_DELUXEMAPS
Definition
r_image.h:78
MAX_GL_LIGHTMAPS
#define MAX_GL_LIGHTMAPS
Definition
r_image.h:77
r_lightmaps
lightmaps_t r_lightmaps
Definition
r_lightmap.cpp:32
R_BeginBuildingLightmaps
void R_BeginBuildingLightmaps(void)
Definition
r_lightmap.cpp:273
R_CreateSurfaceLightmap
void R_CreateSurfaceLightmap(mBspSurface_t *surf)
Definition
r_lightmap.cpp:223
R_Trace
void R_Trace(const Line &trLine, float size, int contentmask)
Moves the given mins/maxs volume through the world from start to end.
Definition
r_lightmap.cpp:317
R_EndBuildingLightmaps
void R_EndBuildingLightmaps(void)
Definition
r_lightmap.cpp:298
lightmaps_t
Definition
r_lightmap.h:42
lightmaps_t::deluxemap_count
int deluxemap_count
Definition
r_lightmap.h:47
lightmaps_t::incomplete_atlas
bool incomplete_atlas
Definition
r_lightmap.h:49
lightmaps_t::allocated
unsigned * allocated
Definition
r_lightmap.h:53
lightmaps_t::direction_buffer
byte * direction_buffer
Definition
r_lightmap.h:56
lightmaps_t::lightmap_count
int lightmap_count
Definition
r_lightmap.h:46
lightmaps_t::lightmap_texnums
GLuint lightmap_texnums[MAX_GL_LIGHTMAPS]
Definition
r_lightmap.h:43
lightmaps_t::size
int size
Definition
r_lightmap.h:51
lightmaps_t::deluxemap_texnums
GLuint deluxemap_texnums[MAX_GL_DELUXEMAPS]
Definition
r_lightmap.h:44
lightmaps_t::sample_buffer
byte * sample_buffer
Definition
r_lightmap.h:55
mBspSurface_t
Definition
r_model_brush.h:83
src
client
renderer
r_lightmap.h
Generated on __DATE__ __TIME__ for UFO: Alien Invasion by
1.16.1