UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FKTaperedCapsuleElem Struct Reference

#include <TaperedCapsuleElem.h>

+ Inheritance diagram for FKTaperedCapsuleElem:

Public Member Functions

ENGINE_API FKTaperedCapsuleElem ()
 
ENGINE_API FKTaperedCapsuleElem (float InRadius0, float InRadius1, float InLength)
 
ENGINE_API FKTaperedCapsuleElem (const FKTaperedCapsuleElem &)
 
ENGINE_API ~FKTaperedCapsuleElem ()
 
virtual FTransform GetTransform () const override final
 
void SetTransform (const FTransform &InTransform)
 
ENGINE_API void DrawElemWire (class FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, float Scale, const FColor Color) const override
 
ENGINE_API void DrawElemSolid (class FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, float Scale, const FMaterialRenderProxy *MaterialRenderProxy) const override
 
ENGINE_API void DrawElemWire (class FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, const FVector &Scale3D, const FColor Color) const
 
ENGINE_API void DrawElemSolid (class FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, const FVector &Scale3D, const FMaterialRenderProxy *MaterialRenderProxy) const
 
ENGINE_API void GetElemSolid (const FTransform &ElemTM, const FVector &Scale3D, const FMaterialRenderProxy *MaterialRenderProxy, int32 ViewIndex, FMeshElementCollector &Collector) const
 
ENGINE_API FBox CalcAABB (const FTransform &BoneTM, float Scale) const
 
ENGINE_API void ScaleElem (FVector DeltaSize, float MinSize)
 
ENGINE_API FKTaperedCapsuleElem GetFinalScaled (const FVector &Scale3D, const FTransform &RelativeTM) const
 
ENGINE_API void GetScaledRadii (const FVector &Scale3D, float &OutRadius0, float &OutRadius1) const
 
ENGINE_API float GetScaledCylinderLength (const FVector &Scale3D) const
 
ENGINE_API float GetScaledHalfLength (const FVector &Scale3D) const
 
- Public Member Functions inherited from FKShapeElem
 FKShapeElem ()
 
 FKShapeElem (EAggCollisionShape::Type InShapeType)
 
 FKShapeElem (const FKShapeElem &Copy)
 
virtual ENGINE_API ~FKShapeElem ()
 
const FKShapeElemoperator= (const FKShapeElem &Other)
 
template<typename T >
T * GetShapeCheck ()
 
const FUserDataGetUserData () const
 
const FNameGetName () const
 
void SetName (const FName &InName)
 
EAggCollisionShape::Type GetShapeType () const
 
bool GetContributeToMass () const
 
void SetContributeToMass (bool bInContributeToMass)
 
void SetCollisionEnabled (ECollisionEnabled::Type InCollisionEnabled)
 
ECollisionEnabled::Type GetCollisionEnabled () const
 
virtual void DrawElemSolid (class FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, const float Scale, const class FMaterialRenderProxy *MaterialRenderProxy) const
 

Static Public Member Functions

static ENGINE_API void DrawTaperedCapsuleSides (FPrimitiveDrawInterface *PDI, const FTransform &ElemTM, const FVector &InCenter0, const FVector &InCenter1, float InRadius0, float InRadius1, const FColor &Color, bool bInSplitTaperedCylinder=false)
 

Public Attributes

FVector Center
 
FRotator Rotation
 
float Radius0
 
float Radius1
 
float Length
 
bool bOneSidedCollision = false
 
- Public Attributes inherited from FKShapeElem
float RestOffset
 

Static Public Attributes

static ENGINE_API EAggCollisionShape::Type StaticShapeType = EAggCollisionShape::TaperedCapsule
 
- Static Public Attributes inherited from FKShapeElem
static ENGINE_API EAggCollisionShape::Type StaticShapeType = EAggCollisionShape::Unknown
 

Friends

bool operator== (const FKTaperedCapsuleElem &LHS, const FKTaperedCapsuleElem &RHS)
 

Additional Inherited Members

- Protected Member Functions inherited from FKShapeElem
void CloneElem (const FKShapeElem &Other)
 

Detailed Description

Capsule shape used for collision. Z axis is capsule axis. Has a start and end radius that can differ.

Constructor & Destructor Documentation

◆ FKTaperedCapsuleElem() [1/3]

FKTaperedCapsuleElem::FKTaperedCapsuleElem ( )

◆ FKTaperedCapsuleElem() [2/3]

FKTaperedCapsuleElem::FKTaperedCapsuleElem ( float  InRadius0,
float  InRadius1,
float  InLength 
)

◆ FKTaperedCapsuleElem() [3/3]

FKTaperedCapsuleElem::FKTaperedCapsuleElem ( const FKTaperedCapsuleElem )
default

◆ ~FKTaperedCapsuleElem()

FKTaperedCapsuleElem::~FKTaperedCapsuleElem ( )
default

Member Function Documentation

◆ CalcAABB()

FBox FKTaperedCapsuleElem::CalcAABB ( const FTransform BoneTM,
float  Scale 
) const

◆ DrawElemSolid() [1/2]

void FKTaperedCapsuleElem::DrawElemSolid ( class FPrimitiveDrawInterface PDI,
const FTransform ElemTM,
const FVector Scale3D,
const FMaterialRenderProxy MaterialRenderProxy 
) const

◆ DrawElemSolid() [2/2]

void FKTaperedCapsuleElem::DrawElemSolid ( class FPrimitiveDrawInterface PDI,
const FTransform ElemTM,
float  Scale,
const FMaterialRenderProxy MaterialRenderProxy 
) const
override

◆ DrawElemWire() [1/2]

void FKTaperedCapsuleElem::DrawElemWire ( class FPrimitiveDrawInterface PDI,
const FTransform ElemTM,
const FVector Scale3D,
const FColor  Color 
) const

◆ DrawElemWire() [2/2]

void FKTaperedCapsuleElem::DrawElemWire ( class FPrimitiveDrawInterface PDI,
const FTransform ElemTM,
float  Scale,
const FColor  Color 
) const
overridevirtual

Reimplemented from FKShapeElem.

◆ DrawTaperedCapsuleSides()

void FKTaperedCapsuleElem::DrawTaperedCapsuleSides ( FPrimitiveDrawInterface PDI,
const FTransform ElemTM,
const FVector InCenter0,
const FVector InCenter1,
float  InRadius0,
float  InRadius1,
const FColor Color,
bool  bInSplitTaperedCylinder = false 
)
static

Draws just the sides of a tapered capsule specified by provided Spheres that can have different radii. Does not draw the spheres, just the sleeve. Extent geometry endpoints not necessarily coplanar with sphere origins (uses hull horizon) Otherwise uses the great-circle cap assumption.

◆ GetElemSolid()

void FKTaperedCapsuleElem::GetElemSolid ( const FTransform ElemTM,
const FVector Scale3D,
const FMaterialRenderProxy MaterialRenderProxy,
int32  ViewIndex,
FMeshElementCollector Collector 
) const

◆ GetFinalScaled()

FKTaperedCapsuleElem FKTaperedCapsuleElem::GetFinalScaled ( const FVector Scale3D,
const FTransform RelativeTM 
) const

◆ GetScaledCylinderLength()

float FKTaperedCapsuleElem::GetScaledCylinderLength ( const FVector Scale3D) const

Returns the scaled length of the cylinder part of the Sphyl

◆ GetScaledHalfLength()

float FKTaperedCapsuleElem::GetScaledHalfLength ( const FVector Scale3D) const

Returns half of the total scaled length of the Sphyl, which includes the scaled top and bottom caps

◆ GetScaledRadii()

void FKTaperedCapsuleElem::GetScaledRadii ( const FVector Scale3D,
float OutRadius0,
float OutRadius1 
) const

Returns the scaled radius for this Sphyl, which is determined by the Max scale on X/Y and clamped by half the total length

◆ GetTransform()

virtual FTransform FKTaperedCapsuleElem::GetTransform ( ) const
inlinefinaloverridevirtual

Reimplemented from FKShapeElem.

◆ ScaleElem()

void FKTaperedCapsuleElem::ScaleElem ( FVector  DeltaSize,
float  MinSize 
)

◆ SetTransform()

void FKTaperedCapsuleElem::SetTransform ( const FTransform InTransform)
inline

Friends And Related Symbol Documentation

◆ operator==

bool operator== ( const FKTaperedCapsuleElem LHS,
const FKTaperedCapsuleElem RHS 
)
friend

Member Data Documentation

◆ bOneSidedCollision

bool FKTaperedCapsuleElem::bOneSidedCollision = false

(Cloth-only) Treat as one-sided collider, where all collisions are pushed to the +x side.

◆ Center

FVector FKTaperedCapsuleElem::Center

Position of the capsule's origin

◆ Length

float FKTaperedCapsuleElem::Length

Length of line-segment. Add Radius0 and Radius 1 to find total length.

◆ Radius0

float FKTaperedCapsuleElem::Radius0

Radius of the capsule start point

◆ Radius1

float FKTaperedCapsuleElem::Radius1

Radius of the capsule end point

◆ Rotation

FRotator FKTaperedCapsuleElem::Rotation

Rotation of the capsule

◆ StaticShapeType

EAggCollisionShape::Type FKTaperedCapsuleElem::StaticShapeType = EAggCollisionShape::TaperedCapsule
static

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