This header file contains the frame flag macros for states, as well as the typedef for translucency maps. Note: In Doom's source code this was also the header file for player weapon sprites, or "psprites" for short.
Includes
Frame flag macros
Macro
|
Defined as
|
Description
|
FF_FRAMEMASK
|
0x3fff (16383)
|
Bit mask for the frame number
|
FF_ANIMATE
|
0x4000 (16384)
|
Simple stateless animation
|
FF_FULLBRIGHT
|
0x8000 (32768)
|
Full brightness
|
FF_TRANSMASK
|
0xf0000 (983040)
|
Bit mask for translucency flags
|
FF_TRANSSHIFT
|
16
|
Number of bits to shift up to convert tr_transxx to TR_TRANSxx
Note: This is also used by the software renderer to convert tr_transxx to an offset in bytes to transtables to get the corresponding transluency table array, as each table happens to be 256 × 256 bytes (65536, 0x10000 , or 1<<FF_TRANSSHIFT bytes) in size; e.g.: transtables + ((tr_trans50-1)<<FF_TRANSSHIFT) (or transtables + 262144 ) points to the translucency table generated using the contents of the TRANS50 lump from srb2.srb .
|
FF_TRANS10
|
(tr_trans10<<FF_TRANSSHIFT) (65536)
|
10% translucency
|
FF_TRANS20
|
(tr_trans20<<FF_TRANSSHIFT) (131072)
|
20% translucency
|
FF_TRANS30
|
(tr_trans30<<FF_TRANSSHIFT) (196608)
|
30% translucency
|
FF_TRANS40
|
(tr_trans40<<FF_TRANSSHIFT) (262144)
|
40% translucency
|
FF_TRANS50
|
(tr_trans50<<FF_TRANSSHIFT) (327680)
|
50% translucency
|
FF_TRANS60
|
(tr_trans60<<FF_TRANSSHIFT) (393216)
|
60% translucency
|
FF_TRANS70
|
(tr_trans70<<FF_TRANSSHIFT) (458752)
|
70% translucency
|
FF_TRANS80
|
(tr_trans80<<FF_TRANSSHIFT) (524288)
|
80% translucency
|
FF_TRANS90
|
(tr_trans90<<FF_TRANSSHIFT) (589824)
|
90% translucency
|
Typedefs
Name
|
Type
|
Description
|
transnum_t
|
enum
|
Translucency maps
|
transnum_t
Value
|
Name
|
Description
|
1
|
tr_trans10
|
10% translucency
|
2
|
tr_trans20
|
20% translucency
|
3
|
tr_trans30
|
30% translucency
|
4
|
tr_trans40
|
40% translucency
|
5
|
tr_trans50
|
50% translucency
|
6
|
tr_trans60
|
60% translucency
|
7
|
tr_trans70
|
70% translucency
|
8
|
tr_trans80
|
80% translucency
|
9
|
tr_trans90
|
90% translucency
|
10
|
NUMTRANSMAPS
|
Number of translucency maps
|