2025-03-10 09:43:27 +08:00
// Copyright® 2015-2023 PICO Technology Co., Ltd. All rights reserved.
// This plugin incorporates portions of the Unreal® Engine. Unreal® is a trademark or registered trademark of Epic Games, Inc. in the United States of America and elsewhere.
// Unreal® Engine, Copyright 1998 – 2023, Epic Games, Inc. All rights reserved.
# pragma once
# include "CoreMinimal.h"
2025-07-21 10:22:56 +08:00
# include "ProceduralMeshComponent.h"
2025-03-10 09:43:27 +08:00
# include "PICO_MRTypes.h"
# include "PICO_SpatialMeshComponent.generated.h"
UCLASS ( hidecategories = ( Object , LOD ) , meta = ( BlueprintSpawnableComponent ) , ClassGroup = Rendering )
2025-07-21 10:22:56 +08:00
class USpatialMeshComponentPICO : public UProceduralMeshComponent
2025-03-10 09:43:27 +08:00
{
GENERATED_BODY ( )
public :
USpatialMeshComponentPICO ( const FObjectInitializer & ObjectInitializer ) ;
UFUNCTION ( BlueprintPure , Category = " PICO|MR " )
ESemanticLabelPICO GetSemanticByIndex ( int32 Index ) ;
2025-07-21 10:22:56 +08:00
void AddIndexToSemanticLabel ( int32 Index , ESemanticLabelPICO SceneLabel ) ;
2025-03-10 09:43:27 +08:00
void SetUpdateTime ( uint64 Time ) ;
int64 GetUpdateTime ( ) const ;
2025-07-21 10:22:56 +08:00
TArray < int32 > GetCachedIndices ( ) { return CachedIndices ; } ;
bool IsEqualWithCached ( TArray < int32 > & Indices ) ;
void SetCachedIndices ( const TArray < int32 > & Indices ) { CachedIndices = Indices ; } ;
2025-03-10 09:43:27 +08:00
protected :
TMap < int32 , ESemanticLabelPICO > IndexToAnchorSceneLabelMap ; //Index ->SceneLabel
uint64 LastUpdateTime = 0 ;
2025-07-21 10:22:56 +08:00
TArray < int32 > CachedIndices ;
2025-03-10 09:43:27 +08:00
} ;