FStaticLightingMesh

A mesh which is used for computing static lighting.

Windows
MacOS
Linux

Inheritance Hierarchy

Syntax

class FStaticLightingMesh : public virtual FRefCountedObject

Remarks

A mesh which is used for computing static lighting.

Variables

Name Description

Public variable

const uint32: ...

 

bCastShadow

Whether the mesh casts a shadow.

Public variable

FBox

 

BoundingBox

The bounding box of the mesh.

Public variable

const uint32: ...

 

bTwoSidedMaterial

Whether the mesh uses a two-sided material.

Public variable

const UPrimitiv...

 

Component

The primitive component this mesh was created by.

Public variable

FGuid

 

Guid

Unique ID for tracking this lighting mesh during distributed lighting

Public variable

uint32

 

HLODChildEndIndex

Public variable

uint32

 

HLODChildStartIndex

Public variable

uint32

 

HLODTreeIndex

Public variable

const int32

 

NumShadingTriangles

The number of shading triangles in the mesh.

Public variable

const int32

 

NumShadingVertices

The number of shading vertices in the mesh.

Public variable

const int32

 

NumTriangles

The number of triangles in the mesh that will be used for visibility tests.

Public variable

const int32

 

NumVertices

The number of vertices in the mesh that will be used for visibility tests.

Public variable

TArray< TRefCou...

 

OtherMeshLODs

Other FStaticLightingMesh's that should be considered the same mesh object (just different LOD), and should not shadow this LOD.

Public variable

const TArray< U...

 

RelevantLights

The lights which affect the mesh's primitive.

Public variable

FGuid

 

SourceMeshGuid

Cached guid for the source mesh

Public variable

const int32

 

TextureCoordinateIndex

The texture coordinate index which is used to parametrize materials.

Public variable

TArray< int32 >

 

VisibilityIds

Used for precomputed visibility

Constructors

Name Description

Public function

FStaticLightingMesh

(
    int32 InNumTriangles,
    int32 InNumShadingTriangles,
    int32 InNumVertices,
    int32 InNumShadingVertices,
    int32 InTextureCoordinateIndex,
    bool bInCastShadow,
    bool bInTwoSidedMaterial,
    const TArray< ULightComponent*...,
    const UPrimitiveComponent*cons...,
    const FBox& InBoundingBox,
    const FGuid& InGuid
)

Initialization constructor.

Destructors

Name Description

Public function Virtual

~FStaticLightingMesh()

Virtual destructor.

Functions

Name Description

Public function Virtual Const

void

 

ExportMeshInstance

(
    FLightmassExporter* Exporter
)

Export static lighting mesh instance data to an exporter

Public function Virtual Const

const FGuid ...

 

GetLightingGuid()

Returns the Guid used for static lighting.

Public function Virtual Const

void

 

GetShadingTriangle

(
    int32 TriangleIndex,
    FStaticLightingVertex& OutV0,
    FStaticLightingVertex& OutV1,
    FStaticLightingVertex& OutV2
)

Accesses a triangle for shading.

Public function Virtual Const

void

 

GetShadingTriangleIndices

(
    int32 TriangleIndex,
    int32& OutI0,
    int32& OutI1,
    int32& OutI2
)

Accesses a triangle's vertex indices for shading.

Public function Const

void

 

GetTriangle

(
    int32 TriangleIndex,
    FStaticLightingVertex& OutV0,
    FStaticLightingVertex& OutV1,
    FStaticLightingVertex& OutV2
)

Accesses a triangle.

Public function Const

void

 

GetTriangleIndices

(
    int32 TriangleIndex,
    int32& OutI0,
    int32& OutI1,
    int32& OutI2
)

Accesses a triangle's vertex indices.

Public function Const

FLightRayInt...

 

IntersectLightRay

(
    const FVector& Start,
    const FVector& End,
    bool bFindNearestIntersection
)

Checks if a line segment intersects the mesh.

Public function Virtual Const

bool

 

IsControllingShadowPerElement()

Public function Virtual Const

bool

 

IsTriangleCastingShadow

(
    uint32 TriangleIndex
)

Public function Virtual Const

bool

 

IsUniformShadowCaster()

Checks whether ShouldCastShadow will return true always.

Public function Virtual Const

bool

 

ShouldCastShadow

(
    ULightComponent* Light,
    const FStaticLightingMapping* ...
)

Determines whether the mesh should cast a shadow from a specific light on a specific mapping.

References

Module

Engine

Header

Runtime/Engine/Public/StaticLighting.h

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback