Files
UnrealEngineUWP/Engine/Plugins/Runtime/MeshModelingToolset/Source/ModelingComponents/Public/Selection/BoundarySelectionMechanic.h
T
tyson brochu 9efcc70606 ModelingComponents/Selection:
- create a new MeshTopologySelector base class. The existing GroupTopologySelector class now inherits from it, as does a new BoundarySelector class
- likewise, create a new MeshTopologySelectionMehchanic base class and have (existing) PolygonSelectionMechanic and (new) BoundarySelectionMechanic inherit from it
- the new Boundary classes use FMeshBoundary loops to define selectable loops rather than FGroupTopology

HoleFillTool:
- change to using BoundarySelectionMechanic instead of GroupTopologySelector

Misc:
- allow FMeshBoundaryLoops to fail untangling a loop with bowties but still continue processing other loops


#jira UE-144821
#rb jimmy.andrews
#preflight 63222176e93a80888cb7d3df

[CL 22013854 by tyson brochu in ue5-main branch]
2022-09-14 15:25:19 -04:00

30 lines
785 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "PolygonSelectionMechanic.h"
#include "BoundarySelectionMechanic.generated.h"
namespace UE::Geometry { class FMeshBoundaryLoops; }
class FBoundarySelector;
UCLASS()
class MODELINGCOMPONENTS_API UBoundarySelectionMechanic : public UMeshTopologySelectionMechanic
{
GENERATED_BODY()
public:
void Initialize(
const FDynamicMesh3* MeshIn,
FTransform3d TargetTransformIn,
UWorld* WorldIn,
const UE::Geometry::FMeshBoundaryLoops* BoundaryLoopsIn,
TFunction<FDynamicMeshAABBTree3* ()> GetSpatialSourceFuncIn);
virtual bool UpdateHighlight(const FRay& WorldRay) override;
virtual bool UpdateSelection(const FRay& WorldRay, FVector3d& LocalHitPositionOut, FVector3d& LocalHitNormalOut) override;
};