I3DHGeometry.h Source File

I3DHGeometry.h Source File#

instant3Dhub: I3DHGeometry.h Source File
instant3Dhub
I3DHGeometry.h
Go to the documentation of this file.
1
5
6#pragma once
7
8#include "CoreMinimal.h"
9
10#include "I3DHDataTypes.h"
11#include "I3DHVersion.h"
12
13#include "GameFramework/Actor.h"
14#include "Misc/EngineVersionComparison.h"
15
16#if UE_VERSION_OLDER_THAN(5, 5, 0)
17#include "StructView.h"
18#else
19#include "StructUtils/StructView.h"
20#endif
21
22#include "I3DHGeometry.generated.h"
23
24class AI3DHConnector;
25
26class INSTANT3DHUB_EXPERIMENTAL(1.0.0, "Working with the I3DH Geometry class is only necessary for advanced use-cases. How we expose geometry data is suspected to change in the future.") AI3DHGeometry;
27
64UCLASS(NotPlaceable, MinimalAPI, Experimental, meta = (DisplayName = "I3DH Geometry (Experimental)"))
65class AI3DHGeometry : public AActor
66{
67 GENERATED_BODY()
68
69public:
70 INSTANT3DHUB_API AI3DHGeometry();
71
72protected:
73 // Begin Actor Interface
74 INSTANT3DHUB_API virtual void BeginPlay() override;
75 // End Actor Interface
76
77public:
78 // ----------------------------------------------------------
79 // Geometry Public API
80 // ----------------------------------------------------------
81
86 UFUNCTION(BlueprintCallable, Category = "{instant3Dhub}|Geometry")
87 INSTANT3DHUB_API AI3DHConnector* GetHubConnector() const;
88
93 UFUNCTION(BlueprintCallable, Category = "{instant3Dhub}|Geometry")
94 INSTANT3DHUB_API int32 GetNodeId() const;
95
100 UFUNCTION(BlueprintCallable, Category = "{instant3Dhub}|Geometry")
101 INSTANT3DHUB_API bool IsSelectedNode() const;
102
103 INSTANT3DHUB_DEPRECATED(1.0.0, "Replaced by HoverAPI. Use GetHubConnector()->GetAPI()->GetHoverAPI()->SetHoveredNode(GetNodeId()) instead.")
104 UFUNCTION(BlueprintCallable, Category = "{instant3Dhub}|Geometry", meta = (DisplayName = "On Hover Start (Deprecated)", DeprecatedFunction, DeprecationMessage = "Replaced by HoverAPI. Use SetHoveredNode(NodeId) instead."))
105 INSTANT3DHUB_API void OnHoverStart();
106
107 INSTANT3DHUB_DEPRECATED(1.0.0, "Replaced by HoverAPI. Use GetHubConnector()->GetAPI()->GetHoverAPI()->ClearHoveredNodes() instead.")
108 UFUNCTION(BlueprintCallable, Category = "{instant3Dhub}|Geometry", meta = (DisplayName = "On Hover End (Deprecated)", DeprecatedFunction, DeprecationMessage = "Replaced by HoverAPI. Use ClearHoveredNodes() instead."))
109 INSTANT3DHUB_API void OnHoverEnd();
110
111protected:
112 INSTANT3DHUB_DEPRECATED(1.4.0, "Geometry materials must now be assigned on AI3DHConnector.")
113 UPROPERTY()
115
116 INSTANT3DHUB_DEPRECATED(1.4.0, "Geometry materials must now be assigned on AI3DHConnector.")
117 UPROPERTY()
119
120 INSTANT3DHUB_DEPRECATED(1.4.0, "Geometry materials must now be assigned on AI3DHConnector.")
121 UPROPERTY()
123
124 INSTANT3DHUB_DEPRECATED(1.4.0, "Geometry materials must now be assigned on AI3DHConnector.")
125 UPROPERTY()
127
128public:
130 // ----------------------------------------------------------
131 // Internal
132 // ----------------------------------------------------------
133
134 void SetInstance(FConstStructView InInstanceView);
135 void ResetInstance();
136
137private:
139 FConstStructView InstanceView;
140
142};
The HubConnector is the central actor for communication with an instant3Dhub instance in your network...
Definition I3DHConnector.h:214
Actor containing mesh components used to represent instant3Dhub geometry.
Definition I3DHGeometry.h:66
void OnHoverStart()
int32 GetNodeId() const
Returns the RootNodeId of the instance represented by this actor.
bool IsSelectedNode() const
Returns whether the actor corresponds to a selected node.
void OnHoverEnd()
UMaterialInterface * GeometryAppearanceHighlightMaterial_DEPRECATED
Definition I3DHGeometry.h:126
AI3DHConnector * GetHubConnector() const
Returns the hub connector this geometry belongs to.
UMaterialInterface * GeometryDefaultMaterial_DEPRECATED
Definition I3DHGeometry.h:114
UMaterialInterface * GeometryHighlightMaterial_DEPRECATED
Definition I3DHGeometry.h:122
UMaterialInterface * GeometryAppearanceMaterial_DEPRECATED
Definition I3DHGeometry.h:118
#define INSTANT3DHUB_DEPRECATED(Version, Message)
Macro for marking up deprecated code, functions and types.
Definition I3DHVersion.h:203
#define INSTANT3DHUB_EXPERIMENTAL(Version, Message)
Macro for marking up experimental code, functions and types.
Definition I3DHVersion.h:246