99namespace PCGExDetails
1010{
1111 template <EPCGExDistance Source, EPCGExDistance Target>
12- FVector TDistances<Source, Target>::GetSourceCenter(const PCGExData::FConstPoint & FromPoint, const FVector& FromCenter, const FVector& ToCenter) const
12+ FVector TDistances<Source, Target>::GetSourceCenter(const PCGExData::FPoint & FromPoint, const FVector& FromCenter, const FVector& ToCenter) const
1313 {
1414 return GetSpatializedCenter<Source>(FromPoint, FromCenter, ToCenter);
1515 }
1616
1717 template <EPCGExDistance Source, EPCGExDistance Target>
18- FVector TDistances<Source, Target>::GetTargetCenter(const PCGExData::FConstPoint & FromPoint, const FVector& FromCenter, const FVector& ToCenter) const
18+ FVector TDistances<Source, Target>::GetTargetCenter(const PCGExData::FPoint & FromPoint, const FVector& FromCenter, const FVector& ToCenter) const
1919 {
2020 return GetSpatializedCenter<Target>(FromPoint, FromCenter, ToCenter);
2121 }
2222
2323 template <EPCGExDistance Source, EPCGExDistance Target>
24- void TDistances<Source, Target>::GetCenters(const PCGExData::FConstPoint & SourcePoint, const PCGExData::FConstPoint & TargetPoint, FVector& OutSource, FVector& OutTarget) const
24+ void TDistances<Source, Target>::GetCenters(const PCGExData::FPoint & SourcePoint, const PCGExData::FPoint & TargetPoint, FVector& OutSource, FVector& OutTarget) const
2525 {
2626 const FVector TargetOrigin = TargetPoint.GetLocation ();
2727 OutSource = GetSpatializedCenter<Source>(SourcePoint, SourcePoint.GetLocation (), TargetOrigin);
2828 OutTarget = GetSpatializedCenter<Target>(TargetPoint, TargetOrigin, OutSource);
2929 }
3030
3131 template <EPCGExDistance Source, EPCGExDistance Target>
32- double TDistances<Source, Target>::GetDistSquared(const PCGExData::FConstPoint & SourcePoint, const PCGExData::FConstPoint & TargetPoint) const
32+ double TDistances<Source, Target>::GetDistSquared(const PCGExData::FPoint & SourcePoint, const PCGExData::FPoint & TargetPoint) const
3333 {
3434 const FVector TargetOrigin = TargetPoint.GetLocation ();
3535 const FVector OutSource = GetSpatializedCenter<Source>(SourcePoint, SourcePoint.GetLocation (), TargetOrigin);
3636 return FVector::DistSquared (OutSource, GetSpatializedCenter<Target>(TargetPoint, TargetOrigin, OutSource));
3737 }
3838
3939 template <EPCGExDistance Source, EPCGExDistance Target>
40- double TDistances<Source, Target>::GetDistSquared(const PCGExData::FProxyPoint& SourcePoint, const PCGExData::FConstPoint& TargetPoint) const
41- {
42- const FVector TargetOrigin = TargetPoint.GetLocation ();
43- const FVector OutSource = GetSpatializedCenter<Source>(SourcePoint, SourcePoint.GetLocation (), TargetOrigin);
44- return FVector::DistSquared (OutSource, GetSpatializedCenter<Target>(TargetPoint, TargetOrigin, OutSource));
45- }
46-
47- template <EPCGExDistance Source, EPCGExDistance Target>
48- double TDistances<Source, Target>::GetDist(const PCGExData::FConstPoint& SourcePoint, const PCGExData::FConstPoint& TargetPoint) const
40+ double TDistances<Source, Target>::GetDist(const PCGExData::FPoint& SourcePoint, const PCGExData::FPoint& TargetPoint) const
4941 {
5042 const FVector TargetOrigin = TargetPoint.GetLocation ();
5143 const FVector OutSource = GetSpatializedCenter<Source>(SourcePoint, SourcePoint.GetLocation (), TargetOrigin);
5244 return FVector::Dist (OutSource, GetSpatializedCenter<Target>(TargetPoint, TargetOrigin, OutSource));
5345 }
5446
5547 template <EPCGExDistance Source, EPCGExDistance Target>
56- double TDistances<Source, Target>::GetDistSquared(const PCGExData::FConstPoint& SourcePoint, const PCGExData::FConstPoint& TargetPoint, bool & bOverlap) const
57- {
58- const FVector TargetOrigin = TargetPoint.GetLocation ();
59- const FVector SourceOrigin = SourcePoint.GetLocation ();
60- const FVector OutSource = GetSpatializedCenter<Source>(SourcePoint, SourceOrigin, TargetOrigin);
61- const FVector OutTarget = GetSpatializedCenter<Target>(TargetPoint, TargetOrigin, OutSource);
62-
63- bOverlap = FVector::DotProduct ((TargetOrigin - SourceOrigin), (OutTarget - OutSource)) < 0 ;
64- return FVector::DistSquared (OutSource, OutTarget);
65- }
66-
67- template <EPCGExDistance Source, EPCGExDistance Target>
68- double TDistances<Source, Target>::GetDistSquared(const PCGExData::FProxyPoint& SourcePoint, const PCGExData::FConstPoint& TargetPoint, bool & bOverlap) const
48+ double TDistances<Source, Target>::GetDistSquared(const PCGExData::FPoint& SourcePoint, const PCGExData::FPoint& TargetPoint, bool & bOverlap) const
6949 {
7050 const FVector TargetOrigin = TargetPoint.GetLocation ();
7151 const FVector SourceOrigin = SourcePoint.GetLocation ();
@@ -77,7 +57,7 @@ namespace PCGExDetails
7757 }
7858
7959 template <EPCGExDistance Source, EPCGExDistance Target>
80- double TDistances<Source, Target>::GetDist(const PCGExData::FConstPoint & SourcePoint, const PCGExData::FConstPoint & TargetPoint, bool & bOverlap) const
60+ double TDistances<Source, Target>::GetDist(const PCGExData::FPoint & SourcePoint, const PCGExData::FPoint & TargetPoint, bool & bOverlap) const
8161 {
8262 const FVector TargetOrigin = TargetPoint.GetLocation ();
8363 const FVector SourceOrigin = SourcePoint.GetLocation ();
0 commit comments