From 207c893a378fc5a55c442f0f71683a3cbe3d8f78 Mon Sep 17 00:00:00 2001 From: laurence Date: Thu, 30 May 2013 16:44:20 +0100 Subject: [PATCH] ENH: surfaceFeatures: Add feature points with 2 edges given the angle --- .../surfaceFeatures/surfaceFeatures.C | 50 +++++++++++++++---- .../surfaceFeatures/surfaceFeatures.H | 19 +++++-- 2 files changed, 56 insertions(+), 13 deletions(-) diff --git a/src/meshTools/triSurface/surfaceFeatures/surfaceFeatures.C b/src/meshTools/triSurface/surfaceFeatures/surfaceFeatures.C index 800d3cf39e..c26315e08b 100644 --- a/src/meshTools/triSurface/surfaceFeatures/surfaceFeatures.C +++ b/src/meshTools/triSurface/surfaceFeatures/surfaceFeatures.C @@ -118,7 +118,11 @@ Foam::List Foam::surfaceFeatures::toStatus() // Set from value for every edge -void Foam::surfaceFeatures::setFromStatus(const List& edgeStat) +void Foam::surfaceFeatures::setFromStatus +( + const List& edgeStat, + const scalar includedAngle +) { // Count @@ -170,20 +174,24 @@ void Foam::surfaceFeatures::setFromStatus(const List& edgeStat) } } - // Calculate consistent feature points - calcFeatPoints(edgeStat); + const scalar minCos = Foam::cos(degToRad(180.0 - includedAngle)); + + calcFeatPoints(edgeStat, minCos); } //construct feature points where more than 2 feature edges meet void Foam::surfaceFeatures::calcFeatPoints ( - const List& edgeStat + const List& edgeStat, + const scalar minCos ) { DynamicList