UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
Chaos::FColoringGraph Class Reference

#include <ColoringGraph.h>

Public Member Functions

int32 GetNumIslands () const
 
int32 GetVertexIsland (int32 VertexIndex) const
 
int32 GetVertexIslandSize (int32 VertexIndex) const
 
int32 GetVertexLevel (int32 VertexIndex) const
 
void SetVertexLevel (int32 VertexIndex, int32 Level)
 
int32 GetVertexColor (int32 VertexIndex) const
 
void ReserveVertices (int32 InNumVertices)
 
void ReserveEdges (int32 InNumEdges)
 
int32 AddVertex ()
 
int32 AddVertices (int32 InNumVertices)
 
int32 AddEdge (int32 VertexIndex0, int32 VertexIndex1)
 
void Islandize ()
 
void Levelize ()
 
void Colorize ()
 

Detailed Description

A graph used by the constraints system. Supports

  • partitioning vertices into connected groups (islands)
  • assigning a level to each vertex based on distance from "level 0" vertices
  • colorizing vertices

Member Function Documentation

◆ AddEdge()

int32 Chaos::FColoringGraph::AddEdge ( int32  VertexIndex0,
int32  VertexIndex1 
)
inline

◆ AddVertex()

int32 Chaos::FColoringGraph::AddVertex ( )
inline

◆ AddVertices()

int32 Chaos::FColoringGraph::AddVertices ( int32  InNumVertices)
inline

◆ Colorize()

void Chaos::FColoringGraph::Colorize ( )

Assign a color to all vertices. Vertices of the same color do not share any edges (i.e., are not directly connected).

◆ GetNumIslands()

int32 Chaos::FColoringGraph::GetNumIslands ( ) const
inline

◆ GetVertexColor()

int32 Chaos::FColoringGraph::GetVertexColor ( int32  VertexIndex) const
inline

◆ GetVertexIsland()

int32 Chaos::FColoringGraph::GetVertexIsland ( int32  VertexIndex) const
inline

◆ GetVertexIslandSize()

int32 Chaos::FColoringGraph::GetVertexIslandSize ( int32  VertexIndex) const
inline

◆ GetVertexLevel()

int32 Chaos::FColoringGraph::GetVertexLevel ( int32  VertexIndex) const
inline

◆ Islandize()

void Chaos::FColoringGraph::Islandize ( )

Assign each vertex to an island. Vertcies in different islands are isolated from each other - thee is no path which connectes them.

◆ Levelize()

void Chaos::FColoringGraph::Levelize ( )

Assign a "level" to all vertices. Level is the distance from a Vertex with Level = 0 (Level 0 vertices are specified by the user with SetVertexLevel)

◆ ReserveEdges()

void Chaos::FColoringGraph::ReserveEdges ( int32  InNumEdges)
inline

◆ ReserveVertices()

void Chaos::FColoringGraph::ReserveVertices ( int32  InNumVertices)
inline

◆ SetVertexLevel()

void Chaos::FColoringGraph::SetVertexLevel ( int32  VertexIndex,
int32  Level 
)
inline

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