Files
UnrealEngineUWP/Engine/Source/Runtime/Datasmith/DirectLink/Public/DirectLinkElementSnapshot.h
Marc Audy 68150e0be7 Merge UE5/Release-Engine-Staging to UE5/Main @ 14611496
This represents UE4/Main @ 14594913

[CL 14612291 by Marc Audy in ue5-main branch]
2020-10-29 13:38:15 -04:00

62 lines
1.1 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "DirectLinkCommon.h"
#include "DirectLinkParameterStore.h"
namespace DirectLink
{
enum class ESerializationStatus
{
Ok,
StreamError,
VersionMinNotRespected,
VersionMaxNotRespected,
};
struct DIRECTLINK_API FReferenceSnapshot
{
void Serialize(FArchive& Ar);
FElementHash Hash() const;
struct FReferenceGroup
{
FName Name;
TArray<FSceneGraphId> ReferencedIds;
};
TArray<FReferenceGroup> Groups;
};
class DIRECTLINK_API FElementSnapshot
{
public:
FElementSnapshot() = default;
FElementSnapshot(const class ISceneGraphNode& Node);
friend FArchive& operator<<(FArchive& Ar, FElementSnapshot& This);
ESerializationStatus Serialize(FArchive& Ar);
FElementHash GetHash() const;
FElementHash GetDataHash() const; // #ue_directlink_sync: serialize hashs
FElementHash GetRefHash() const;
public:
FSceneGraphId NodeId;
mutable FElementHash DataHash = InvalidHash;
mutable FElementHash RefHash = InvalidHash;
FParameterStoreSnapshot DataSnapshot;
FReferenceSnapshot RefSnapshot;
};
} // namespace DirectLink