Cesium for Unreal 2.12.0
|
#include <CesiumFeatureIdTexture.h>
Static Public Member Functions | |
static PRAGMA_DISABLE_DEPRECATION_WARNINGS const FString & | GetFeatureTableName (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture) |
Gets the name of the feature table corresponding to this feature ID texture. | |
static PRAGMA_ENABLE_DEPRECATION_WARNINGS ECesiumFeatureIdTextureStatus | GetFeatureIDTextureStatus (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture) |
Gets the status of the feature ID texture. | |
static int64 | GetGltfTextureCoordinateSetIndex (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture) |
Gets the glTF texture coordinate set index used by the feature ID texture. | |
static int64 | GetUnrealUVChannel (const UPrimitiveComponent *Component, UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture) |
Gets the UV channel containing the texture coordinate set that is used by the feature ID texture on the given component. | |
static PRAGMA_DISABLE_DEPRECATION_WARNINGS int64 | GetFeatureIDForTextureCoordinates (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture, float U, float V) |
Gets the feature ID corresponding to the pixel specified by the texture coordinates. | |
static PRAGMA_ENABLE_DEPRECATION_WARNINGS int64 | GetFeatureIDForUV (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture, const FVector2D &UV) |
Gets the feature ID corresponding to the pixel specified by the UV texture coordinates. | |
static int64 | GetFeatureIDForVertex (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture, int64 VertexIndex) |
Gets the feature ID associated with the given vertex. | |
static int64 | GetFeatureIDFromHit (UPARAM(ref) const FCesiumFeatureIdTexture &FeatureIDTexture, const FHitResult &Hit) |
Gets the feature ID from a given line trace hit on the primitive containing this feature ID texture. | |
Definition at line 89 of file CesiumFeatureIdTexture.h.
|
static |
Gets the feature ID corresponding to the pixel specified by the texture coordinates.
The feature ID can be used with a FCesiumPropertyTable to retrieve the per-pixel metadata.
This assumes the given texture coordinates are from the appropriate texture coordinate set as indicated by GetTextureCoordinateSetIndex. If the feature ID texture is invalid, this returns -1.
|
static |
Gets the feature ID corresponding to the pixel specified by the UV texture coordinates.
The feature ID can be used with a FCesiumPropertyTable to retrieve the per-pixel metadata.
If the feature ID texture is invalid, this returns -1.
|
static |
Gets the feature ID associated with the given vertex.
The feature ID can be used with a FCesiumPropertyTable to retrieve the per-vertex metadata.
This works if the vertex contains texture coordinates for the relevant texture coordinate set as indicated by GetGltfTextureCoordinateSetIndex. If the vertex has no such coordinates, or if the feature ID texture itself is invalid, this returns -1.
|
static |
Gets the feature ID from a given line trace hit on the primitive containing this feature ID texture.
The feature ID can be used with a FCesiumPropertyTable to retrieve the corresponding metadata.
If the feature ID texture is invalid, this returns -1.
|
static |
Gets the status of the feature ID texture.
If this texture is invalid in any way, this will briefly indicate why.
|
static |
Gets the name of the feature table corresponding to this feature ID texture.
The name can be used to fetch the appropriate FCesiumPropertyTable
from the FCesiumMetadataModel.
|
static |
Gets the glTF texture coordinate set index used by the feature ID texture.
This is the index N corresponding to the "TEXCOORD_N" attribute on the glTF primitive that samples this texture.
If the texture contains the KHR_texture_transform
extension, the original texture coordinate set index can be overridden by the one provided by the extension.
If the feature ID texture is invalid, this returns -1.
|
static |
Gets the UV channel containing the texture coordinate set that is used by the feature ID texture on the given component.
This refers to the UV channel it uses on the primitive's static mesh, which is not necessarily equal to value of GetGltfTextureCoordinateSetIndex.
This function may be used with FindCollisionUV to get the feature ID from a line trace hit. However, in order for this function to work, the feature ID texture should be listed under the CesiumFeaturesMetadataComponent of the owner Cesium3DTileset. Otherwise, its texture coordinate set may not be included in the Unreal mesh data. To avoid using CesiumFeaturesMetadataComponent, use GetFeatureIDFromHit instead.
This returns -1 if the feature ID texture is invalid, or if the specified texture coordinate set is not present in the component's mesh data.