flags
Set of 'switches' to be set in a VIEW definition, separated by " | ". Individual flags can also be set or reset at runtime. All flags are reset by default. The following flags are supported:
Parameters:
VISIBLE
If this flag is set, the view actively renders on the screen or on the target bmap. By resetting this flag the view is not active unless it's a postprocessing stage. The camera view is VISIBLE by default.
AUDIBLE
If this flag is set, the view position and orientation determines direction and distance of sound sources and entity sounds in the level. The view must be visible for this. The camera view has this flag set by default. To avoid a sound mix-up, only one view should have this flag set
ISOMETRIC
The view uses an orthogonal projection, rather than a perspective projection. This can be used for isometric games from a bird's view perspective. The distance of the camera to an object does not affect its size on the screen in this mode. A7.2C LC X
UNTOUCHABLE
Entities in this view don't react on the mouse. This speeds up view rendering. A7.06C LC
PROCESS_SCREEN
Prevents that a) the screen is cleared before rendering and b) that the previous view stage automatically renders into the render_target. Can be used for rendering an additional scene over the previous view (see stage). A7.07C LC
PROCESS_TARGET
Does not render a scene, but just a screen-sized rectangle with the content of the render_target or the render_stencil (see stage). Can be used for post-processing a view or for blurring the content of the stencil buffer. A7.07C LC
CHILD
Inherits all VIEW parameters from the previous stage, except for the flags, material, bmap, and stage parameters. Uses the entity culling and sorting from the previous view. A7.07C LC
TRANSLUCENT
If this flag is set, the view is displayed translucent over the background. The translucency can be given through the view's alpha parameter in percent. Some special effects can be achieved this way, but translucent views are rendered with reduced quality - static shadows are not visible and the sorting order of polygons can be wrong. A6P A7C
PORTALCLIP
If this flag is set, level surfaces are clipped away at the view's clip plane. Usually used for mirrors. NOSHADER and NOPARTICLE should be set when a clip plane is used. A6P A7C
CULL_CW
If this flag is set, polygons are culled clockwise instead of counterclockwise (the same happens when arc or aspect are negative). Useful if the view is to be rendered onto a bmap that is used for mirror or reflection effects.
NOCULL
Disables BSP tree culling for the view. If this flag is set, objects are rendered even when hidden behind walls. The BSP tree is still used for rendering, but it's precaclulated visibility information (PVS) is not used. P
NOSHADOW
If this flag is set, no dynamic model shadows are rendered. Useful for horizontal mirrors where you don't want shadows to be mirrored too.
SHADOW
The opposite of NOSHADOW: If this flag is set, only level geometry and shadow-throwing entities are rendered. If both flags are set (SHADOW | NOSHADOW), level geometry and shadow-throwing entities are rendered, but their shadows are suppressed. Useful for rendering depth maps for shadow mapping purposes. A7.07C LC
NOPARTICLE
If this flag is set, no particles are displayed in the view.
NOSHADER
If this flag is set, material effects and shaders are ignored in the view.
NOFLAG1
If this flag is set, no entities and textures with FLAG1 are displayed in the view.
NOLOD
If this flag is set, the LOD state of entities is used, but not changed by this view. Useful for shadow mapping render stages that render from a light source position and use the LOD steps from a previous view. A7.08 LC
Remarks:
In C-Script, a flag was set or reset at runtime by assigning the ON or OFF value (like panel.VISIBLE = ON;). In C, C++, or Lite-C, a flag is set by or-ing the flags parameter with the flag (panel.flags |= VISIBLE;) and reset by and-ing the flags parameter with the inverse flag (panel.flags &= ~VISIBLE;). The predefined macros set, reset, and toggle can also be used for manipulating individual flags.
Example:
VIEW* camera2 =
{
...
flags = VISIBLE | AUDIBLE;
}
...
set(camera2,NOFLAG1);
...
See also:
VIEW, layer, genius, portal, material, bmap, stage
► latest version online