Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
689d4b28
Commit
689d4b28
authored
Feb 17, 2010
by
Mark Olesen
Browse files
ENH: provide operator[] for accessing argList options.
- operator[] with label -> get args at index - operator[] with word -> get named option
parent
b61537bd
Changes
29
Hide whitespace changes
Inline
Side-by-side
applications/test/List/ListTest.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -90,7 +90,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"flag"
))
{
Info
<<
"-flag:"
<<
args
.
option
(
"flag"
)
<<
endl
;
Info
<<
"-flag:"
<<
args
[
"flag"
]
<<
endl
;
}
if
(
args
.
optionReadIfPresent
<
scalar
>
(
"float"
,
xxx
))
...
...
applications/test/mvBak/mvBakTest.C
View file @
689d4b28
...
...
@@ -58,7 +58,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"ext"
))
{
if
(
mvBak
(
srcFile
,
args
.
option
(
"ext"
)
))
if
(
mvBak
(
srcFile
,
args
[
"ext"
]
))
{
ok
++
;
}
...
...
applications/test/tokenizeTest/tokenizeTest.C
View file @
689d4b28
...
...
@@ -94,11 +94,11 @@ int main(int argc, char *argv[])
{
for
(
label
count
=
0
;
count
<
repeat
;
++
count
)
{
IFstream
is
(
args
.
option
(
"file"
)
);
IFstream
is
(
args
[
"file"
]
);
if
(
count
==
0
)
{
Info
<<
"tokenizing file: "
<<
args
.
option
(
"file"
)
<<
nl
;
Info
<<
"tokenizing file: "
<<
args
[
"file"
]
<<
nl
;
}
while
(
is
.
good
())
...
...
applications/utilities/mesh/advanced/refineWallLayer/refineWallLayer.C
View file @
689d4b28
...
...
@@ -101,20 +101,17 @@ int main(int argc, char *argv[])
// List of cells to refine
//
bool
useSet
=
args
.
optionFound
(
"useSet"
);
if
(
useSet
)
word
setName
;
if
(
args
.
optionReadIfPresent
(
"useSet"
,
setName
))
{
word
setName
(
args
.
option
(
"useSet"
));
Info
<<
"Subsetting cells to cut based on cellSet"
<<
setName
<<
endl
<<
endl
;
Info
<<
"Subsetting cells to cut based on cellSet"
<<
setName
<<
nl
<<
endl
;
cellSet
cells
(
mesh
,
setName
);
Info
<<
"Read "
<<
cells
.
size
()
<<
" cells from cellSet "
<<
cells
.
instance
()
/
cells
.
local
()
/
cells
.
name
()
<<
end
l
<<
endl
;
<<
n
l
<<
endl
;
for
(
...
...
@@ -125,8 +122,8 @@ int main(int argc, char *argv[])
{
cutCells
.
erase
(
iter
.
key
());
}
Info
<<
"Removed from cells to cut all the ones not in set "
<<
setName
<<
end
l
<<
endl
;
Info
<<
"Removed from cells to cut all the ones not in set "
<<
setName
<<
n
l
<<
endl
;
}
// Mark all meshpoints on patch
...
...
@@ -180,9 +177,9 @@ int main(int argc, char *argv[])
allCutEdges
.
shrink
();
allCutEdgeWeights
.
shrink
();
Info
<<
"Cutting:"
<<
end
l
<<
" cells:"
<<
cutCells
.
size
()
<<
end
l
<<
" edges:"
<<
allCutEdges
.
size
()
<<
end
l
Info
<<
"Cutting:"
<<
n
l
<<
" cells:"
<<
cutCells
.
size
()
<<
n
l
<<
" edges:"
<<
allCutEdges
.
size
()
<<
n
l
<<
endl
;
// Transfer DynamicLists to straight ones.
...
...
applications/utilities/mesh/advanced/splitCells/splitCells.C
View file @
689d4b28
...
...
@@ -552,7 +552,7 @@ int main(int argc, char *argv[])
<<
"edge snapping tol : "
<<
edgeTol
<<
nl
;
if
(
readSet
)
{
Info
<<
"candidate cells : cellSet "
<<
args
.
option
(
"set"
)
<<
nl
;
Info
<<
"candidate cells : cellSet "
<<
args
[
"set"
]
<<
nl
;
}
else
{
...
...
@@ -580,7 +580,7 @@ int main(int argc, char *argv[])
if
(
readSet
)
{
// Read cells to cut from cellSet
cellSet
cells
(
mesh
,
args
.
option
(
"set"
)
);
cellSet
cells
(
mesh
,
args
[
"set"
]
);
cellsToCut
=
cells
;
}
...
...
applications/utilities/mesh/conversion/kivaToFoam/kivaToFoam.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -68,15 +68,12 @@ int main(int argc, char *argv[])
# include "createTime.H"
fileName
kivaFileName
(
"otape17"
);
if
(
args
.
optionFound
(
"file"
))
{
kivaFileName
=
args
.
option
(
"file"
);
}
args
.
optionReadIfPresent
(
"file"
,
kivaFileName
);
kivaVersions
kivaVersion
=
kiva3v
;
if
(
args
.
optionFound
(
"version"
))
{
word
kivaVersionName
=
args
.
option
(
"version"
)
;
const
word
kivaVersionName
=
args
[
"version"
]
;
if
(
kivaVersionName
==
"kiva3"
)
{
...
...
applications/utilities/mesh/conversion/writeMeshObj/writeMeshObj.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -463,7 +463,7 @@ int main(int argc, char *argv[])
}
if
(
doCellSet
)
{
word
setName
(
args
.
option
(
"cellSet"
))
;
const
word
setName
=
args
[
"cellSet"
]
;
cellSet
cells
(
mesh
,
setName
);
...
...
@@ -475,7 +475,7 @@ int main(int argc, char *argv[])
}
if
(
doFaceSet
)
{
word
setName
(
args
.
option
(
"faceSet"
))
;
const
word
setName
=
args
[
"faceSet"
]
;
faceSet
faces
(
mesh
,
setName
);
...
...
applications/utilities/mesh/generation/blockMesh/blockMeshApp.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -110,7 +110,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"dict"
))
{
fileName
dictPath
(
args
.
option
(
"dict"
))
;
const
fileName
dictPath
=
args
[
"dict"
]
;
meshDictIoPtr
.
set
(
...
...
applications/utilities/mesh/manipulation/setSet/setSet.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -835,15 +835,14 @@ int main(int argc, char *argv[])
# include "createTime.H"
instantList
timeDirs
=
timeSelector
::
select0
(
runTime
,
args
);
bool
writeVTK
=
!
args
.
optionFound
(
"noVTK"
);
bool
loop
=
args
.
optionFound
(
"loop"
);
bool
batch
=
args
.
optionFound
(
"batch"
);
const
bool
writeVTK
=
!
args
.
optionFound
(
"noVTK"
);
const
bool
loop
=
args
.
optionFound
(
"loop"
);
const
bool
batch
=
args
.
optionFound
(
"batch"
);
if
(
loop
&&
!
batch
)
{
FatalErrorIn
(
args
.
executable
())
<<
"Can only loop
when
in batch mode."
<<
"Can only loop in batch mode."
<<
exit
(
FatalError
);
}
...
...
@@ -885,7 +884,7 @@ int main(int argc, char *argv[])
if
(
batch
)
{
fileName
batchFile
(
args
.
option
(
"batch"
))
;
const
fileName
batchFile
=
args
[
"batch"
]
;
Info
<<
"Reading commands from file "
<<
batchFile
<<
endl
;
...
...
applications/utilities/mesh/manipulation/splitMeshRegions/splitMeshRegions.C
View file @
689d4b28
...
...
@@ -1326,9 +1326,8 @@ int main(int argc, char *argv[])
const
word
oldInstance
=
mesh
.
pointsInstance
();
word
blockedFacesName
;
if
(
args
.
option
Found
(
"blockedFaces"
))
if
(
args
.
option
ReadIfPresent
(
"blockedFaces"
,
blockedFacesName
))
{
blockedFacesName
=
args
.
option
(
"blockedFaces"
);
Info
<<
"Reading blocked internal faces from faceSet "
<<
blockedFacesName
<<
nl
<<
endl
;
}
...
...
@@ -1882,7 +1881,7 @@ int main(int argc, char *argv[])
if
(
insidePoint
)
{
point
insidePoint
(
args
.
option
Lookup
(
"insidePoint"
)
())
;
const
point
insidePoint
=
args
.
option
Read
<
point
>
(
"insidePoint"
);
label
regionI
=
-
1
;
...
...
applications/utilities/mesh/manipulation/subsetMesh/subsetMesh.C
View file @
689d4b28
...
...
@@ -174,7 +174,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"patch"
))
{
word
patchName
(
args
.
option
(
"patch"
))
;
const
word
patchName
=
args
[
"patch"
]
;
patchI
=
mesh
.
boundaryMesh
().
findPatchID
(
patchName
);
...
...
applications/utilities/mesh/manipulation/transformPoints/transformPoints.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -210,7 +210,9 @@ int main(int argc, char *argv[])
)
);
const
bool
doRotateFields
=
args
.
optionFound
(
"rotateFields"
);
// this is not actually stringent enough:
if
(
args
.
options
().
empty
())
{
FatalErrorIn
(
args
.
executable
())
...
...
@@ -219,18 +221,20 @@ int main(int argc, char *argv[])
<<
exit
(
FatalError
);
}
if
(
args
.
optionFound
(
"translate"
))
vector
v
;
if
(
args
.
optionReadIfPresent
(
"translate"
,
v
))
{
vector
transVector
(
args
.
optionLookup
(
"translate"
)())
;
Info
<<
"Translating points by "
<<
v
<<
endl
;
Info
<<
"Translating points by "
<<
transVector
<<
endl
;
points
+=
transVector
;
points
+=
v
;
}
if
(
args
.
optionFound
(
"rotate"
))
{
Pair
<
vector
>
n1n2
(
args
.
optionLookup
(
"rotate"
)());
Pair
<
vector
>
n1n2
(
args
.
optionLookup
(
"rotate"
)()
);
n1n2
[
0
]
/=
mag
(
n1n2
[
0
]);
n1n2
[
1
]
/=
mag
(
n1n2
[
1
]);
tensor
T
=
rotationTensor
(
n1n2
[
0
],
n1n2
[
1
]);
...
...
@@ -239,20 +243,17 @@ int main(int argc, char *argv[])
points
=
transform
(
T
,
points
);
if
(
args
.
optionFound
(
"r
otateFields
"
)
)
if
(
doR
otateFields
)
{
rotateFields
(
args
,
runTime
,
T
);
}
}
else
if
(
args
.
option
Found
(
"rollPitchYaw"
))
else
if
(
args
.
option
ReadIfPresent
(
"rollPitchYaw"
,
v
))
{
vector
v
(
args
.
optionLookup
(
"rollPitchYaw"
)());
Info
<<
"Rotating points by"
<<
nl
<<
" roll "
<<
v
.
x
()
<<
nl
<<
" pitch "
<<
v
.
y
()
<<
nl
<<
" yaw "
<<
v
.
z
()
<<
endl
;
<<
" yaw "
<<
v
.
z
()
<<
nl
;
// Convert to radians
v
*=
pi
/
180
.
0
;
...
...
@@ -262,20 +263,17 @@ int main(int argc, char *argv[])
Info
<<
"Rotating points by quaternion "
<<
R
<<
endl
;
points
=
transform
(
R
,
points
);
if
(
args
.
optionFound
(
"r
otateFields
"
)
)
if
(
doR
otateFields
)
{
rotateFields
(
args
,
runTime
,
R
.
R
());
}
}
else
if
(
args
.
option
Found
(
"yawPitchRoll"
))
else
if
(
args
.
option
ReadIfPresent
(
"yawPitchRoll"
,
v
))
{
vector
v
(
args
.
optionLookup
(
"yawPitchRoll"
)());
Info
<<
"Rotating points by"
<<
nl
<<
" yaw "
<<
v
.
x
()
<<
nl
<<
" pitch "
<<
v
.
y
()
<<
nl
<<
" roll "
<<
v
.
z
()
<<
endl
;
<<
" roll "
<<
v
.
z
()
<<
nl
;
// Convert to radians
v
*=
pi
/
180
.
0
;
...
...
@@ -291,21 +289,19 @@ int main(int argc, char *argv[])
Info
<<
"Rotating points by quaternion "
<<
R
<<
endl
;
points
=
transform
(
R
,
points
);
if
(
args
.
optionFound
(
"r
otateFields
"
)
)
if
(
doR
otateFields
)
{
rotateFields
(
args
,
runTime
,
R
.
R
());
}
}
if
(
args
.
option
Found
(
"scale"
))
if
(
args
.
option
ReadIfPresent
(
"scale"
,
v
))
{
vector
scaleVector
(
args
.
optionLookup
(
"scale"
)());
Info
<<
"Scaling points by "
<<
scaleVector
<<
endl
;
Info
<<
"Scaling points by "
<<
v
<<
endl
;
points
.
replace
(
vector
::
X
,
scaleVector
.
x
()
*
points
.
component
(
vector
::
X
));
points
.
replace
(
vector
::
Y
,
scaleVector
.
y
()
*
points
.
component
(
vector
::
Y
));
points
.
replace
(
vector
::
Z
,
scaleVector
.
z
()
*
points
.
component
(
vector
::
Z
));
points
.
replace
(
vector
::
X
,
v
.
x
()
*
points
.
component
(
vector
::
X
));
points
.
replace
(
vector
::
Y
,
v
.
y
()
*
points
.
component
(
vector
::
Y
));
points
.
replace
(
vector
::
Z
,
v
.
z
()
*
points
.
component
(
vector
::
Z
));
}
// Set the precision of the points data to 10
...
...
applications/utilities/miscellaneous/foamInfoExec/foamInfoExec.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -66,7 +66,7 @@ int main(int argc, char *argv[])
{
fileName
dictFileName
(
args
.
rootPath
()
/
args
.
caseName
()
/
args
.
option
(
"dictionary"
)
args
.
rootPath
()
/
args
.
caseName
()
/
args
[
"dictionary"
]
);
IFstream
dictFile
(
dictFileName
);
...
...
@@ -103,7 +103,7 @@ int main(int argc, char *argv[])
true
// wildcards
);
for
(
int
i
=
1
;
i
<
entryNames
.
size
();
i
++
)
for
(
int
i
=
1
;
i
<
entryNames
.
size
();
++
i
)
{
if
(
entPtr
->
dict
().
found
(
entryNames
[
i
]))
{
...
...
@@ -118,7 +118,7 @@ int main(int argc, char *argv[])
{
FatalErrorIn
(
args
.
executable
())
<<
"Cannot find sub-entry "
<<
entryNames
[
i
]
<<
" in entry "
<<
args
.
option
(
"entry"
)
<<
" in entry "
<<
args
[
"entry"
]
<<
" in dictionary "
<<
dictFileName
;
FatalError
.
exit
(
3
);
}
...
...
@@ -131,7 +131,7 @@ int main(int argc, char *argv[])
{
FatalErrorIn(args.executable())
<< "Cannot find entry "
<< args
.option(
"entry"
)
<< args
[
"entry"
]
<< " in dictionary " << dictFileName
<< " is not a sub-dictionary";
FatalError.exit(4);
...
...
applications/utilities/postProcessing/dataConversion/foamToEnsight/ensightMesh.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -80,7 +80,10 @@ Foam::ensightMesh::ensightMesh
if
(
args
.
optionFound
(
"patches"
))
{
wordList
patchNameList
(
args
.
optionLookup
(
"patches"
)());
wordList
patchNameList
(
args
.
optionLookup
(
"patches"
)()
);
if
(
patchNameList
.
empty
())
{
...
...
applications/utilities/postProcessing/dataConversion/foamToTecplot360/foamToTecplot360.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -215,9 +215,8 @@ int main(int argc, char *argv[])
word
cellSetName
;
string
vtkName
;
if
(
args
.
option
Found
(
"cellSet"
))
if
(
args
.
option
ReadIfPresent
(
"cellSet"
,
cellSetName
))
{
cellSetName
=
args
.
option
(
"cellSet"
);
vtkName
=
cellSetName
;
}
else
if
(
Pstream
::
parRun
())
...
...
@@ -738,7 +737,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"faceSet"
))
{
// Load the faceSet
word
setName
(
args
.
option
(
"faceSet"
))
;
const
word
setName
=
args
[
"faceSet"
]
;
labelList
faceLabels
(
faceSet
(
mesh
,
setName
).
toc
());
// Filename as if patch with same name.
...
...
applications/utilities/postProcessing/dataConversion/foamToVTK/foamToVTK.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -329,9 +329,8 @@ int main(int argc, char *argv[])
word
cellSetName
;
string
vtkName
=
runTime
.
caseName
();
if
(
args
.
option
Found
(
"cellSet"
))
if
(
args
.
option
ReadIfPresent
(
"cellSet"
,
cellSetName
))
{
cellSetName
=
args
.
option
(
"cellSet"
);
vtkName
=
cellSetName
;
}
else
if
(
Pstream
::
parRun
())
...
...
@@ -423,7 +422,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"faceSet"
))
{
// Load the faceSet
faceSet
set
(
mesh
,
args
.
option
(
"faceSet"
)
);
faceSet
set
(
mesh
,
args
[
"faceSet"
]
);
// Filename as if patch with same name.
mkDir
(
fvPath
/
set
.
name
());
...
...
@@ -446,7 +445,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"pointSet"
))
{
// Load the pointSet
pointSet
set
(
mesh
,
args
.
option
(
"pointSet"
)
);
pointSet
set
(
mesh
,
args
[
"pointSet"
]
);
// Filename as if patch with same name.
mkDir
(
fvPath
/
set
.
name
());
...
...
applications/utilities/postProcessing/miscellaneous/execFlowFunctionObjects/execFlowFunctionObjects.C
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-200
9
OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-20
1
0 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -59,7 +59,7 @@ namespace Foam
(
IOobject
(
args
.
option
(
"dict"
)
,
args
[
"dict"
]
,
runTime
.
system
(),
runTime
,
IOobject
::
MUST_READ
...
...
applications/utilities/preProcessing/mapFields/setTimeIndex.H
View file @
689d4b28
...
...
@@ -2,7 +2,7 @@
label
sourceTimeIndex
=
runTimeSource
.
timeIndex
();
if
(
args
.
optionFound
(
"sourceTime"
))
{
if
(
args
.
option
(
"sourceTime"
)
==
"latestTime"
)
if
(
args
[
"sourceTime"
]
==
"latestTime"
)
{
sourceTimeIndex
=
sourceTimes
.
size
()
-
1
;
}
...
...
applications/utilities/surface/surfaceAdd/surfaceAdd.C
View file @
689d4b28
...
...
@@ -71,7 +71,7 @@ int main(int argc, char *argv[])
<<
nl
<<
endl
;
Info
<<
"Surface : "
<<
inFileName1
<<
nl
<<
"Points : "
<<
args
.
option
(
"points"
)
<<
nl
<<
"Points : "
<<
args
[
"points"
]
<<
nl
<<
"Writing : "
<<
outFileName
<<
nl
<<
endl
;
}
else
...
...
@@ -113,7 +113,7 @@ int main(int argc, char *argv[])
if
(
addPoint
)
{
IFstream
pointsFile
(
args
.
option
(
"points"
)
);
IFstream
pointsFile
(
args
[
"points"
]
);
pointField
extraPoints
(
pointsFile
);
Info
<<
"Additional Points:"
<<
extraPoints
.
size
()
<<
endl
;
...
...
applications/utilities/surface/surfaceFeatureExtract/surfaceFeatureExtract.C
View file @
689d4b28
...
...
@@ -136,7 +136,7 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"set"
))
{
fileName
setName
(
args
.
option
(
"set"
))
;
const
fileName
setName
=
args
[
"set"
]
;
Info
<<
"Reading existing feature set from file "
<<
setName
<<
endl
;
...
...
@@ -151,7 +151,7 @@ int main(int argc, char *argv[])
set
=
surfaceFeatures
(
surf
,
includedAngle
);
Info
<<
end
l
<<
"Writing initial features"
<<
endl
;
Info
<<
n
l
<<
"Writing initial features"
<<
endl
;
set
.
write
(
"initial.fSet"
);
set
.
writeObj
(
"initial"
);
}
...
...
@@ -210,7 +210,10 @@ int main(int argc, char *argv[])
if
(
args
.
optionFound
(
"subsetBox"
))
{
treeBoundBox
bb
(
args
.
optionLookup
(
"subsetBox"
)());
treeBoundBox
bb
(
args
.
optionLookup
(
"subsetBox"
)()
);
Info
<<
"Removing all edges outside bb "
<<
bb
<<
endl
;
dumpBox
(
bb
,
"subsetBox.obj"
);
...
...
@@ -225,7 +228,10 @@ int main(int argc, char *argv[])
}
else
if
(
args
.
optionFound
(
"deleteBox"
))
{
treeBoundBox
bb
(
args
.
optionLookup
(
"deleteBox"
)());
treeBoundBox
bb
(
args
.
optionLookup
(
"deleteBox"
)()
<