Rebel Fork Framework
Urho3D::DefaultBakedSceneCollector Class Reference

Standard scene collector for light baking. More...

#include <Urho3D/Glow/BakedSceneCollector.h>

Inheritance diagram for Urho3D::DefaultBakedSceneCollector:
Urho3D::BakedSceneCollector

Classes

struct  ChunkData
 Chunk data. More...
 

Public Member Functions

void LockScene (Scene *scene, const Vector3 &chunkSize) override
 
ea::vector< IntVector3GetChunks () override
 Return all scene chunks.
 
BakedSceneBackgroundArrayPtr GetBackgrounds () override
 Return all scene backgrounds. [0] is expected to be pitch-black background.
 
ea::vector< Component * > GetUniqueGeometries (const IntVector3 &chunkIndex) override
 Return unique geometries within chunk.
 
void CommitGeometries (const IntVector3 &chunkIndex) override
 Called when geometries were changed externally.
 
ea::vector< LightProbeGroup * > GetUniqueLightProbeGroups (const IntVector3 &chunkIndex) override
 Return unique light probe groups within chunk. Order of groups must stay the same for each call.
 
ZoneGetLightProbeGroupZone (const IntVector3 &chunkIndex, LightProbeGroup *lightProbeGroup) override
 Return zone that corresponds to light probe group within chunk.
 
unsigned GetZoneBackground (const IntVector3 &chunkIndex, Zone *zone) override
 Return background index for zone within chunk.
 
BoundingBox GetChunkBoundingBox (const IntVector3 &chunkIndex) override
 Return bounding box of unique nodes of the chunk.
 
ea::vector< Light * > GetLightsInBoundingBox (const IntVector3 &chunkIndex, const BoundingBox &boundingBox) override
 Return lights intersecting given volume.
 
ea::vector< Component * > GetGeometriesInBoundingBox (const IntVector3 &chunkIndex, const BoundingBox &boundingBox) override
 Return geometries intersecting given volume.
 
ea::vector< LightProbeGroup * > GetLightProbeGroupsInBoundingBox (const IntVector3 &chunkIndex, const BoundingBox &boundingBox) override
 Return light probe groups intersecting given volume.
 
ea::vector< Component * > GetGeometriesInFrustum (const IntVector3 &chunkIndex, const Frustum &frustum) override
 Return geometries intersecting given frustum. The frustum is guaranteed to contain specified chunk.
 
void UnlockScene () override
 Called after everything else. Scene objects must stay unchanged until this call.
 
- Public Member Functions inherited from Urho3D::BakedSceneCollector
virtual ~BakedSceneCollector ()
 Destruct.
 

Private Member Functions

ea::vector< Component * > CollectGeometriesFromDrawables (const ea::vector< Drawable * > drawables)
 Filter drawables and return relevant components.
 

Private Attributes

Scenescene_ {}
 Scene.
 
Vector3 chunkSize_
 Chunk size.
 
BoundingBox boundingBox_
 Bounding box of the scene.
 
IntVector3 chunkGridDimension_
 Dimensions of chunk grid.
 
Octreeoctree_ {}
 Scene Octree.
 
ea::unordered_map< IntVector3, ChunkDatachunks_
 
ea::vector< LightProbeGroup * > lightProbeGroups_
 
ea::vector< Zone * > zones_
 
BakedSceneBackgroundArrayPtr backgrounds_
 
ea::unordered_map< Zone *, unsigned > zoneToBackgroundMap_
 

Detailed Description

Standard scene collector for light baking.

Member Function Documentation

◆ LockScene()

void Urho3D::DefaultBakedSceneCollector::LockScene ( Scene scene,
const Vector3 chunkSize 
)
overridevirtual

Member Data Documentation

◆ backgrounds_

BakedSceneBackgroundArrayPtr Urho3D::DefaultBakedSceneCollector::backgrounds_
private

Baking backgrounds

◆ chunks_

ea::unordered_map<IntVector3, ChunkData> Urho3D::DefaultBakedSceneCollector::chunks_
private

All relevant objects within scene


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