UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster Class Reference

#include <ViewBasedTransformAdjusters.h>

+ Inheritance diagram for UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster:

Classes

struct  FSettings
 

Public Member Functions

 FSubGizmoTransformAdjuster (const FTransform &GizmoOriginToComponent=FTransform::Identity, const FSettings &SettingsIn=FSettings())
 
INTERACTIVETOOLSFRAMEWORK_API void SetGizmoOriginTransform (const FTransform &GizmoOriginToComponent)
 
void SetMirrorBasedOnOctant (bool bOn)
 
void SetSettings (const FSettings &SettingsIn)
 
virtual INTERACTIVETOOLSFRAMEWORK_API FTransform GetAdjustedComponentToWorld (const UE::GizmoRenderingUtil::ISceneViewInterface &View, const FTransform &CurrentComponentToWorld) override
 
virtual INTERACTIVETOOLSFRAMEWORK_API FTransform GetAdjustedComponentToWorld_RenderThread (const ISceneViewInterface &View, const FTransform &CurrentComponentToWorld) override
 
virtual void UpdateWorldLocalState (bool bWorldIn) override
 
virtual INTERACTIVETOOLSFRAMEWORK_API FBoxSphereBounds GetViewIndependentBounds (const FTransform &LocalToWorld, const FBoxSphereBounds &OriginalBounds) override
 
- Public Member Functions inherited from UE::GizmoRenderingUtil::IViewBasedTransformAdjuster
virtual ~IViewBasedTransformAdjuster ()
 
- Public Member Functions inherited from TSharedFromThis< FSubGizmoTransformAdjuster, ESPMode::ThreadSafe >
TSharedRef< FSubGizmoTransformAdjuster, Mode > AsShared ()
 
TSharedRef< FSubGizmoTransformAdjuster const, Mode > AsShared () const
 
TSharedRef< SubobjectType, Mode > AsSharedSubobject (SubobjectType *SubobjectPtr) const
 
TWeakPtr< FSubGizmoTransformAdjuster, Mode > AsWeak ()
 
TWeakPtr< FSubGizmoTransformAdjuster const, Mode > AsWeak () const
 
TWeakPtr< SubobjectType, Mode > AsWeakSubobject (SubobjectType *SubobjectPtr) const
 
void UpdateWeakReferenceInternal (TSharedPtr< SharedPtrType, SharedPtrMode > const *InSharedPtr, OtherType *InObject) const
 
void UpdateWeakReferenceInternal (TSharedRef< SharedRefType, SharedPtrMode > const *InSharedRef, OtherType *InObject) const
 
UE_FORCEINLINE_HINT bool DoesSharedInstanceExist () const
 

Static Public Member Functions

static INTERACTIVETOOLSFRAMEWORK_API TSharedPtr< FSubGizmoTransformAdjusterAddTransformAdjuster (UViewAdjustedStaticMeshGizmoComponent *ComponentIn, USceneComponent *GizmoRootComponent, bool bMirrorBasedOnOctant)
 
static INTERACTIVETOOLSFRAMEWORK_API TSharedPtr< FSubGizmoTransformAdjusterAddTransformAdjuster (UViewAdjustedStaticMeshGizmoComponent *ComponentIn, USceneComponent *GizmoRootComponent, TFunction< bool()> ShouldMirrorBasedOnOctant)
 

Additional Inherited Members

- Protected Member Functions inherited from TSharedFromThis< FSubGizmoTransformAdjuster, ESPMode::ThreadSafe >
 TSharedFromThis ()
 
 TSharedFromThis (TSharedFromThis const &)
 
UE_FORCEINLINE_HINT TSharedFromThisoperator= (TSharedFromThis const &)
 
 ~TSharedFromThis ()
 
- Static Protected Member Functions inherited from TSharedFromThis< FSubGizmoTransformAdjuster, ESPMode::ThreadSafe >
static UE_FORCEINLINE_HINT TSharedRef< OtherType, Mode > SharedThis (OtherType *ThisPtr)
 
static UE_FORCEINLINE_HINT TSharedRef< OtherType const, Mode > SharedThis (const OtherType *ThisPtr)
 

Detailed Description

An adjuster that can do various transformations common for sub gizmos, which are based off of the parent gizmo transform (in addition to the actual component transform).

Constructor & Destructor Documentation

◆ FSubGizmoTransformAdjuster()

UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::FSubGizmoTransformAdjuster ( const FTransform GizmoOriginToComponent = FTransform::Identity,
const FSettings SettingsIn = FSettings() 
)
inline

Member Function Documentation

◆ AddTransformAdjuster() [1/2]

TSharedPtr< UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster > UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::AddTransformAdjuster ( UViewAdjustedStaticMeshGizmoComponent ComponentIn,
USceneComponent *  GizmoRootComponent,
bool  bMirrorBasedOnOctant 
)
static

Static helper method to create and add this adjuster to a gizmo component for the common case of keeping a constant size gizmo.

Parameters
GizmoRootComponentThe distance relative to this component is kept constant, and this is the component whose rotation is considered to be 0 when using global mode.
bMirrorBasedOnOctantIf true, mirrors the component around the ComponentToKeepDistanceConstantTo depending on which octant of that component the view is located in.

◆ AddTransformAdjuster() [2/2]

static INTERACTIVETOOLSFRAMEWORK_API TSharedPtr< FSubGizmoTransformAdjuster > UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::AddTransformAdjuster ( UViewAdjustedStaticMeshGizmoComponent ComponentIn,
USceneComponent *  GizmoRootComponent,
TFunction< bool()>  ShouldMirrorBasedOnOctant 
)
static

◆ GetAdjustedComponentToWorld()

FTransform UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::GetAdjustedComponentToWorld ( const UE::GizmoRenderingUtil::ISceneViewInterface View,
const FTransform CurrentComponentToWorld 
)
overridevirtual

Given the component location and the view information, gives the desired transform of the component.

Implements UE::GizmoRenderingUtil::IViewBasedTransformAdjuster.

◆ GetAdjustedComponentToWorld_RenderThread()

FTransform UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::GetAdjustedComponentToWorld_RenderThread ( const ISceneViewInterface View,
const FTransform CurrentComponentToWorld 
)
overridevirtual

If an adjuster is used by a render proxy, it will use this endpoint for getting the transform. This allows an adjuster to be potentially shared between game and render threads. Of course, a component might instead choose to create a new adjuster whenever the render proxy is recreated, and recreate the proxy whenever any relevant parameters change.

Reimplemented from UE::GizmoRenderingUtil::IViewBasedTransformAdjuster.

◆ GetViewIndependentBounds()

FBoxSphereBounds UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::GetViewIndependentBounds ( const FTransform LocalToWorld,
const FBoxSphereBounds OriginalBounds 
)
overridevirtual

Returns the transform that should be returned by a USceneComponent CalcBounds method, which can't know about the view. Although the default is to return the original bounds, any adjuster that scales the mesh arbitrarily large will probably need to return infinite bounds, whereas an adjuster that only changes orienation must account for any possible orientation. Note that returning infinite bounds causes the relevant components to no longer be frustum-culled, but this is acceptible for gizmos, which are typically few and on-screen.

Reimplemented from UE::GizmoRenderingUtil::IViewBasedTransformAdjuster.

◆ SetGizmoOriginTransform()

void UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::SetGizmoOriginTransform ( const FTransform GizmoOriginToComponent)

Update the transform of the gizmo origin relative to this component. This is safe to do even if the adjuster is used by the render thread (the render-side update gets queued properly).

◆ SetMirrorBasedOnOctant()

void UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::SetMirrorBasedOnOctant ( bool  bOn)
inline

◆ SetSettings()

void UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::SetSettings ( const FSettings SettingsIn)
inline

◆ UpdateWorldLocalState()

virtual void UE::GizmoRenderingUtil::FSubGizmoTransformAdjuster::UpdateWorldLocalState ( bool  bWorldIn)
inlineoverridevirtual

Not every adjuster will care about the world/local setting, but it is useful for the a component that uses it to be able to blindly pass this information down without caring about the type of adjuster.

Reimplemented from UE::GizmoRenderingUtil::IViewBasedTransformAdjuster.


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