UI3DHUtilities Class Reference

instant3Dhub: UI3DHUtilities Class Reference
instant3Dhub
UI3DHUtilities Class Reference

#include "I3DHUtilities.h"

+ Inheritance diagram for UI3DHUtilities:
+ Collaboration diagram for UI3DHUtilities:

Detailed Description

Utility functions for using Unreal Engine with Instant3DHub.

Static Public Member Functions

static float GetOriginalToUnrealScale ()
 
static const FMatrix & GetOriginalToUnrealMatrix ()
 
static const FMatrix & GetUnrealToOriginalMatrix ()
 
static const FMatrix & GetOriginalToUnrealNormalMatrix ()
 
static const FMatrix & GetUnrealToOriginalNormalMatrix ()
 
static FMatrix ConvertTransformOriginalToUnreal (const FMatrix &OriginalTransform)
 
static FMatrix ConvertTransformUnrealToOriginal (const FMatrix &UnrealTransform)
 
static FMatrix ConvertTransformOriginalToUnrealPure (const FMatrix &OriginalTransform)
 
static FMatrix ConvertTransformUnrealToOriginalPure (const FMatrix &UnrealTransform)
 
static FBox ConvertVolumeOriginalToUnreal (const FBox &OriginalVolume)
 
static FBox ConvertVolumeUnrealToOriginal (const FBox &UnrealVolume)
 
static FBox ConvertVolumeOriginalToUnrealPure (const FBox &OriginalVolume)
 
static FBox ConvertVolumeUnrealToOriginalPure (const FBox &UnrealVolume)
 
static FString UEColorToWebvisAppearanceURI (const FLinearColor &Color, EAppearanceURIMode Mode)
 
static bool WebvisAppearanceURIToUEColor (const FString &InURI, FLinearColor &OutColor, EAppearanceURIMode &OutMode)
 
static bool AnalyzeHitResult (const struct FHitResult &HitResult, FI3DHHitResult &OutI3DHHitResult)
 
static FPlane MakePlaneFromClipPlaneActor (const AActor *ClipPlaneActor)
 
static bool ClipLineSegmentByPlane (FVector &Start, FVector &End, const FPlane &Plane)
 
static bool ClipLineSegmentByMainClipPlane (AI3DHConnector *HubConnector, FVector &Start, FVector &End)
 
static bool ClipLineSegmentByClipPlanes (AI3DHConnector *HubConnector, FVector &Start, FVector &End)
 
static bool IsWithEditor ()
 
static bool IsEditorStandaloneGame (const UObject *WorldContextObject)
 
static TMap< FString, FStringGetURLQueryParams (const FString &URL)
 
static void FindFirstUnselectedAncestor (TSharedPtr< class FI3DHConnectorAPI > API, int NodeId, TUniqueFunction< void(int AncestorId, EI3DHErrorCode ErrorCode)> OnComplete)
 

Member Function Documentation

◆ AnalyzeHitResult()

static bool UI3DHUtilities::AnalyzeHitResult ( const struct FHitResult & HitResult,
FI3DHHitResult & OutI3DHHitResult )
static

Analyzes a hit result to check if and what instant3Dhub geometry was hit.

Parameters
HitResultOriginal hit result from e.g. a regular line trace.
OutI3DHHitResultinstant3Dhub-specific hit information. If no instant3Dhub geometry was hit, the value is not changed.
Returns
true if instant3Dhub geometry was hit.

◆ FindFirstUnselectedAncestor()

static void UI3DHUtilities::FindFirstUnselectedAncestor ( TSharedPtr< class FI3DHConnectorAPI > API,
int NodeId,
TUniqueFunction< void(int AncestorId, EI3DHErrorCode ErrorCode)> OnComplete )
static

Finds the first ancestor node that is not selected, excluding the root node.

Parameters
APIThe instant3Dhub API.
NodeIdIdentifier of the node.
OnCompleteCallback called on completion:

◆ GetURLQueryParams()

static TMap< FString, FString > UI3DHUtilities::GetURLQueryParams ( const FString & URL)
static

Parse the provided URL and retrieve its URL query parameters.

Remarks
This is not BlueprintPure to prevent the user from accidentally re-parsing every time the output map is used directly without storing it in a local variable first.
Parameters
URLURL of the resource.
Returns
Map of the URL query parameters.

◆ IsEditorStandaloneGame()

static bool UI3DHUtilities::IsEditorStandaloneGame ( const UObject * WorldContextObject)
static

Query if the current build is an Editor build of the engine and the provided 'WorldContextObject' is part of a game world.

Parameters
WorldContextObjectThe world context object.
Returns
True if object is part of editor standalone game world, false if not.

◆ IsWithEditor()

static bool UI3DHUtilities::IsWithEditor ( )
static

Query if the current build is an Editor build of the engine.

Returns
True if with editor, false if not.

◆ UEColorToWebvisAppearanceURI()

static FString UI3DHUtilities::UEColorToWebvisAppearanceURI ( const FLinearColor & Color,
EAppearanceURIMode Mode )
static

Converts color to the matching WebVis appearanceURI.

Parameters
ColorThe color.
ModeThe appearanceURI Mode.
Returns
A WebVis appearanceURI String, e.g. urn:X-l3d:color:rgba:983BC0D3.

◆ WebvisAppearanceURIToUEColor()

static bool UI3DHUtilities::WebvisAppearanceURIToUEColor ( const FString & InURI,
FLinearColor & OutColor,
EAppearanceURIMode & OutMode )
static

Converts a WebVis appearanceURI (e.g.

"") to the matching color.

Parameters
InURIWebVis appearanceURI String, e.g. urn:X-l3d:color:rgba:983BC0D3.
OutColorThe color obtained from the appearanceURI string.
OutModeThe appearanceURI Mode as obtained from the appearanceURI string.
Returns
True if the input is and output values are matching WebVis, false otherwise.

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