OpenEnroth d1a3925
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
BLVFace Struct Reference

#include <Indoor.h>

Public Member Functions

void _get_normals (Vec3f *outU, Vec3f *outV)
 
void FromODM (const ODMFace *face)
 
void SetTexture (std::string_view filename)
 
GraphicsImageGetTexture () const
 
bool Invisible () const
 
bool Visible () const
 
bool isPortal () const
 
bool isFluid () const
 
bool Indoor_sky () const
 
bool Clickable () const
 
bool Pressure_Plate () const
 
bool Ethereal () const
 
bool IsAnimated () const
 
void ToggleIsAnimated ()
 
void Flatten (FlatFace *points, int model_idx, FaceAttributes override_plane=0) const
 
bool Contains (const Vec3f &pos, int model_idx, int slack=0, FaceAttributes override_plane=0) const
 

Public Attributes

Planef facePlane
 
PlaneZCalcf zCalc
 
FaceAttributes attributes
 
std::span< int16_t > vertexIds
 
std::span< int16_t > textureUs
 
std::span< int16_t > textureVs
 
uint16_t faceExtraId = 0
 
GraphicsImagetexture = nullptr
 
int animationId = 0
 
int texunit = -1
 
int texlayer = -1
 
int sectorId = 0
 
int backSectorId = 0
 
BBoxf boundingBox
 
PolygonType polygonType = POLYGON_Invalid
 
uint8_t numVertices = 0
 

Member Function Documentation

◆ _get_normals()

void BLVFace::_get_normals ( Vec3f outU,
Vec3f outV 
)

◆ Clickable()

bool BLVFace::Clickable ( ) const
inline

◆ Contains()

bool BLVFace::Contains ( const Vec3f pos,
int  model_idx,
int  slack = 0,
FaceAttributes  override_plane = 0 
) const
Parameters
posPoint to check.
model_idxModel that this face belongs to, or MODEL_INDOOR for faces in indoor locations.
slackIf a point is at most slack units away from the edge, it'll still be considered to be lying on the edge.
override_planePlane override. By default the check is performed in the face's primary plane that is set in attributes, but this behavior can be overridden by e.g. passing FACE_XY_PLANE.
Returns
Whether the point lies inside this polygon, if projected on the face's primary plane.

◆ Ethereal()

bool BLVFace::Ethereal ( ) const
inline

◆ Flatten()

void BLVFace::Flatten ( FlatFace points,
int  model_idx,
FaceAttributes  override_plane = 0 
) const
Parameters
[out]pointsCoordinate storage. The storage is populated by the coordinates of this face's vertices projected onto this face's primary plane.
model_idxModel that this face belongs to, or MODEL_INDOOR for faces in indoor locations.
override_planePlane override.
See also
BLVFace::Contains

◆ FromODM()

void BLVFace::FromODM ( const ODMFace face)

◆ GetTexture()

GraphicsImage * BLVFace::GetTexture ( ) const

◆ Indoor_sky()

bool BLVFace::Indoor_sky ( ) const
inline

◆ Invisible()

bool BLVFace::Invisible ( ) const
inline

◆ IsAnimated()

bool BLVFace::IsAnimated ( ) const
inline

◆ isFluid()

bool BLVFace::isFluid ( ) const
inline

◆ isPortal()

bool BLVFace::isPortal ( ) const
inline

◆ Pressure_Plate()

bool BLVFace::Pressure_Plate ( ) const
inline

◆ SetTexture()

void BLVFace::SetTexture ( std::string_view  filename)

◆ ToggleIsAnimated()

void BLVFace::ToggleIsAnimated ( )
inline

◆ Visible()

bool BLVFace::Visible ( ) const
inline

Member Data Documentation

◆ animationId

int BLVFace::animationId = 0

◆ attributes

FaceAttributes BLVFace::attributes

◆ backSectorId

int BLVFace::backSectorId = 0

◆ boundingBox

BBoxf BLVFace::boundingBox

◆ faceExtraId

uint16_t BLVFace::faceExtraId = 0

◆ facePlane

Planef BLVFace::facePlane

◆ numVertices

uint8_t BLVFace::numVertices = 0

◆ polygonType

PolygonType BLVFace::polygonType = POLYGON_Invalid

◆ sectorId

int BLVFace::sectorId = 0

◆ texlayer

int BLVFace::texlayer = -1

◆ texture

GraphicsImage* BLVFace::texture = nullptr

◆ textureUs

std::span<int16_t> BLVFace::textureUs

U (horizontal) texture coordinates for each vertex, in texture pixels. Has numVertices elements.

◆ textureVs

std::span<int16_t> BLVFace::textureVs

V (vertical) texture coordinates for each vertex, in texture pixels. Has numVertices elements.

◆ texunit

int BLVFace::texunit = -1

◆ vertexIds

std::span<int16_t> BLVFace::vertexIds

Indices into the vertex array for this face's vertices. Points into IndoorLocation::pVertices for indoor faces. Has numVertices elements.

◆ zCalc

PlaneZCalcf BLVFace::zCalc

The documentation for this struct was generated from the following files: