Cesium for Unreal 2.12.0
Loading...
Searching...
No Matches
CesiumMetadataEncodingDetails.h
Go to the documentation of this file.
1// Copyright 2020-2024 CesiumGS, Inc. and Contributors
2
3#pragma once
4
6#include <cstdlib>
7#include <type_traits>
8
9#include "CesiumMetadataEncodingDetails.generated.h"
10
16UENUM()
18
22UENUM()
23enum class ECesiumEncodedMetadataType : uint8 {
24 None,
25 Scalar,
26 Vec2,
27 Vec3,
28 Vec4
29};
30
35UENUM()
56
61USTRUCT()
63 GENERATED_USTRUCT_BODY()
64
69
74 : Type(InType),
75 ComponentType(InComponentType),
76 Conversion(InConversion) {}
77
81 UPROPERTY(EditAnywhere, Category = "Cesium")
83
89 UPROPERTY(EditAnywhere, Category = "Cesium")
91
97 UPROPERTY(EditAnywhere, Category = "Cesium")
99
100 inline bool operator==(const FCesiumMetadataEncodingDetails& Info) const {
101 return Type == Info.Type && ComponentType == Info.ComponentType &&
102 Conversion == Info.Conversion;
103 }
104
105 inline bool operator!=(const FCesiumMetadataEncodingDetails& Info) const {
106 return Type != Info.Type || ComponentType != Info.ComponentType ||
107 Conversion != Info.Conversion;
108 }
109
110 bool HasValidType() const {
111 return Type != ECesiumEncodedMetadataType::None &&
113 }
114};
ECesiumEncodedMetadataConversion
Indicates how a property value from EXT_structural_metadata should be converted to a GPU-accessible t...
@ ParseColorFromString
Attempt to parse a color from a string property value.
@ Coerce
Coerce the components of a property value to the specified component type.
ECesiumEncodedMetadataType
The type that a metadata property's values will be encoded as.
ECesiumEncodedMetadataComponentType
The component type that a metadata property's values will be encoded as.
Describes how a property from EXT_structural_metadata will be encoded for access in Unreal materials.
FCesiumMetadataEncodingDetails(ECesiumEncodedMetadataType InType, ECesiumEncodedMetadataComponentType InComponentType, ECesiumEncodedMetadataConversion InConversion)
ECesiumEncodedMetadataConversion Conversion
The method of conversion used for this property.
ECesiumEncodedMetadataComponentType ComponentType
The GPU-compatible component type that this property's values will be encoded as.
bool operator!=(const FCesiumMetadataEncodingDetails &Info) const
ECesiumEncodedMetadataType Type
The GPU-compatible type that this property's values will be encoded as.