diff --git a/src/conversion/ensight/part/ensightPart.C b/src/conversion/ensight/part/ensightPart.C index d87eb239bbde435b506889f61c0243dba153b982..303c417ac753e51caabd0beefd0ee5d23c0d44eb 100644 --- a/src/conversion/ensight/part/ensightPart.C +++ b/src/conversion/ensight/part/ensightPart.C @@ -45,11 +45,11 @@ bool Foam::ensightPart::isFieldDefined(const List<scalar>& field) const { forAll(elemLists_, elemI) { - const labelList& idList = elemLists_[elemI]; + const labelUList& idList = elemLists_[elemI]; forAll(idList, i) { - label id = idList[i]; + const label id = idList[i]; if (id >= field.size() || isnan(field[id])) { @@ -159,7 +159,7 @@ Foam::ensightPart::~ensightPart() // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // -void Foam::ensightPart::renumber(const labelList& origId) +void Foam::ensightPart::renumber(const labelUList& origId) { // transform to global values first if (offset_) diff --git a/src/conversion/ensight/part/ensightPart.H b/src/conversion/ensight/part/ensightPart.H index b2074f55b9c82f2e00ccf949ad2503ba9f5ab950..0d1770f4126544600e71ee56de0a9480e3a49e30 100644 --- a/src/conversion/ensight/part/ensightPart.H +++ b/src/conversion/ensight/part/ensightPart.H @@ -134,6 +134,7 @@ protected: void writeHeader(ensightFile&, bool withDescription=false) const; //- write a scalar field for idList + // A null reference for idList writes the perNode values void writeFieldList ( ensightFile& os, @@ -150,10 +151,10 @@ protected: //- write connectivities virtual void writeConnectivity ( - ensightGeoFile& os, + ensightGeoFile&, const word& key, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const {} @@ -287,7 +288,7 @@ public: // Edit //- renumber elements - void renumber(const labelList&); + void renumber(const labelUList&); //- write summary information about the object bool writeSummary(Ostream&) const; @@ -303,28 +304,34 @@ public: void writeGeometry(ensightGeoFile&, const pointField&) const; //- write scalar field + // optionally write data per node void writeScalarField ( ensightFile&, - const List<scalar>& field + const List<scalar>& field, + const bool perNode = false ) const; //- write vector field components + // optionally write data per node void writeVectorField ( ensightFile&, const List<scalar>& field0, const List<scalar>& field1, - const List<scalar>& field2 + const List<scalar>& field2, + const bool perNode = false ) const; //- write generalized field components + // optionally write data per node template<class Type> void writeField ( ensightFile&, - const Field<Type>& + const Field<Type>&, + const bool perNode = false ) const; diff --git a/src/conversion/ensight/part/ensightPartCells.C b/src/conversion/ensight/part/ensightPartCells.C index 8bd8465c41521f7023240595008d8dbf076af3ea..a05b70bcef68b36fda8eacbe38bcf33f98485565 100644 --- a/src/conversion/ensight/part/ensightPartCells.C +++ b/src/conversion/ensight/part/ensightPartCells.C @@ -52,7 +52,7 @@ const Foam::List<Foam::word> Foam::ensightPartCells::elemTypes_ void Foam::ensightPartCells::classify ( const polyMesh& mesh, - const labelList& idList + const labelUList& idList ) { // References to cell shape models @@ -203,7 +203,7 @@ Foam::ensightPartCells::ensightPartCells ( label partNumber, const polyMesh& mesh, - const labelList& idList + const labelUList& idList ) : ensightPart(partNumber, "cells", mesh.points()), @@ -259,13 +259,13 @@ Foam::ensightPart::localPoints Foam::ensightPartCells::calcLocalPoints() const forAll(elemLists_, typeI) { - const labelList& idList = elemLists_[typeI]; + const labelUList& idList = elemLists_[typeI]; // add all points from cells forAll(idList, i) { - label id = idList[i] + offset_; - const labelList& cFaces = mesh_.cells()[id]; + const label id = idList[i] + offset_; + const labelUList& cFaces = mesh_.cells()[id]; forAll(cFaces, cFaceI) { @@ -301,8 +301,8 @@ void Foam::ensightPartCells::writeConnectivity ( ensightGeoFile& os, const word& key, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const { os.writeKeyword(key); @@ -317,8 +317,8 @@ void Foam::ensightPartCells::writeConnectivity // write the number of faces per element forAll(idList, i) { - label id = idList[i] + offset_; - const labelList& cFace = mesh_.cells()[id]; + const label id = idList[i] + offset_; + const labelUList& cFace = mesh_.cells()[id]; os.write(cFace.size()); os.newline(); @@ -327,8 +327,8 @@ void Foam::ensightPartCells::writeConnectivity // write the number of points per element face forAll(idList, i) { - label id = idList[i] + offset_; - const labelList& cFace = mesh_.cells()[id]; + const label id = idList[i] + offset_; + const labelUList& cFace = mesh_.cells()[id]; forAll(cFace, faceI) { @@ -342,8 +342,8 @@ void Foam::ensightPartCells::writeConnectivity // write the points describing each element face forAll(idList, i) { - label id = idList[i] + offset_; - const labelList& cFace = mesh_.cells()[id]; + const label id = idList[i] + offset_; + const labelUList& cFace = mesh_.cells()[id]; forAll(cFace, faceI) { @@ -366,7 +366,7 @@ void Foam::ensightPartCells::writeConnectivity forAll(idList, i) { - label id = idList[i] + offset_; + const label id = idList[i] + offset_; const cellShape& cellPoints = cellShapes[id]; // convert global -> local index diff --git a/src/conversion/ensight/part/ensightPartCells.H b/src/conversion/ensight/part/ensightPartCells.H index bf6bf951a7979b991c650dc7d66c32bb23c5f232..cd79c029b6ca18177cdb98354a70ad03c7392df3 100644 --- a/src/conversion/ensight/part/ensightPartCells.H +++ b/src/conversion/ensight/part/ensightPartCells.H @@ -60,7 +60,7 @@ class ensightPartCells void classify ( const polyMesh&, - const labelList& idLabels = labelList::null() + const labelUList& idLabels = labelUList::null() ); //- track points used @@ -72,10 +72,10 @@ class ensightPartCells //- element connectivity virtual void writeConnectivity ( - ensightGeoFile& os, + ensightGeoFile&, const word& key, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const; @@ -121,7 +121,7 @@ public: ( label partNumber, const polyMesh&, - const labelList& + const labelUList& ); //- Construct from polyMesh and cellZone diff --git a/src/conversion/ensight/part/ensightPartFaces.C b/src/conversion/ensight/part/ensightPartFaces.C index 250be573c6689fb4881be0bf8576632ba9282484..c8bfaa00df39620f0c4c33c8a7ce486ef5004f43 100644 --- a/src/conversion/ensight/part/ensightPartFaces.C +++ b/src/conversion/ensight/part/ensightPartFaces.C @@ -217,12 +217,12 @@ Foam::ensightPart::localPoints Foam::ensightPartFaces::calcLocalPoints() const forAll(elemLists_, typeI) { - const labelList& idList = elemLists_[typeI]; + const labelUList& idList = elemLists_[typeI]; // add all points from faces forAll(idList, i) { - label id = idList[i] + offset_; + const label id = idList[i] + offset_; const face& f = faces_[id]; forAll(f, fp) @@ -255,8 +255,8 @@ void Foam::ensightPartFaces::writeConnectivity ensightGeoFile& os, const word& key, const faceList& faces, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const { os.writeKeyword(key); @@ -269,7 +269,7 @@ void Foam::ensightPartFaces::writeConnectivity // write the number of points per face forAll(idList, i) { - label id = idList[i] + offset_; + const label id = idList[i] + offset_; const face& f = faces[id]; os.write(f.size()); @@ -280,7 +280,7 @@ void Foam::ensightPartFaces::writeConnectivity // write the points describing the face forAll(idList, i) { - label id = idList[i] + offset_; + const label id = idList[i] + offset_; const face& f = faces[id]; // convert global -> local index @@ -298,8 +298,8 @@ void Foam::ensightPartFaces::writeConnectivity ( ensightGeoFile& os, const word& key, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const { writeConnectivity diff --git a/src/conversion/ensight/part/ensightPartFaces.H b/src/conversion/ensight/part/ensightPartFaces.H index 78d5cf6d16b33d38358972baabce2abee8bf0a7d..1b64688d9c56d3417b0b0dbf8450717cd06a2462 100644 --- a/src/conversion/ensight/part/ensightPartFaces.H +++ b/src/conversion/ensight/part/ensightPartFaces.H @@ -63,8 +63,8 @@ class ensightPartFaces ( ensightGeoFile&, const word& key, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const; @@ -104,8 +104,8 @@ protected: ensightGeoFile&, const word& key, const faceList&, - const labelList& idList, - const labelList& pointMap + const labelUList& idList, + const labelUList& pointMap ) const; diff --git a/src/conversion/ensight/part/ensightPartIO.C b/src/conversion/ensight/part/ensightPartIO.C index 7760b7b07f2441bc018bad733044d07f682e7572..bc893b84118a16645fd26a1d43cc3f8aa3b48021 100644 --- a/src/conversion/ensight/part/ensightPartIO.C +++ b/src/conversion/ensight/part/ensightPartIO.C @@ -59,22 +59,43 @@ void Foam::ensightPart::writeFieldList const labelUList& idList ) const { - forAll(idList, i) + if (&idList) { - if (idList[i] >= field.size() || isnan(field[idList[i]])) + forAll(idList, i) { - os.writeUndef(); + if (idList[i] >= field.size() || isnan(field[idList[i]])) + { + os.writeUndef(); + } + else + { + os.write(field[idList[i]]); + } + + os.newline(); } - else + } + else + { + // no idList => perNode + forAll(field, i) { - os.write(field[idList[i]]); - } + if (isnan(field[i])) + { + os.writeUndef(); + } + else + { + os.write(field[i]); + } - os.newline(); + os.newline(); + } } } + // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // void Foam::ensightPart::reconstruct(Istream& is) @@ -153,7 +174,7 @@ void Foam::ensightPart::writeGeometry if (size()) { const localPoints ptList = calcLocalPoints(); - const labelList& pointMap = ptList.list; + const labelUList& pointMap = ptList.list; writeHeader(os, true); @@ -195,21 +216,30 @@ void Foam::ensightPart::writeGeometry void Foam::ensightPart::writeScalarField ( ensightFile& os, - const List<scalar>& field + const List<scalar>& field, + const bool perNode ) const { if (size() && field.size() && (os.allowUndef() || isFieldDefined(field))) { writeHeader(os); - forAll(elementTypes(), elemI) + if (perNode) { - const labelList& idList = elemLists_[elemI]; - - if (idList.size()) + os.writeKeyword("coordinates"); + writeFieldList(os, field, labelUList::null()); + } + else + { + forAll(elementTypes(), elemI) { - os.writeKeyword(elementTypes()[elemI]); - writeFieldList(os, field, idList); + const labelUList& idList = elemLists_[elemI]; + + if (idList.size()) + { + os.writeKeyword(elementTypes()[elemI]); + writeFieldList(os, field, idList); + } } } } @@ -221,23 +251,34 @@ void Foam::ensightPart::writeVectorField ensightFile& os, const List<scalar>& field0, const List<scalar>& field1, - const List<scalar>& field2 + const List<scalar>& field2, + const bool perNode ) const { if (size() && field0.size() && (os.allowUndef() || isFieldDefined(field0))) { writeHeader(os); - forAll(elementTypes(), elemI) + if (perNode) { - const labelList& idList = elemLists_[elemI]; - - if (idList.size()) + os.writeKeyword("coordinates"); + writeFieldList(os, field0, labelUList::null()); + writeFieldList(os, field1, labelUList::null()); + writeFieldList(os, field2, labelUList::null()); + } + else + { + forAll(elementTypes(), elemI) { - os.writeKeyword(elementTypes()[elemI]); - writeFieldList(os, field0, idList); - writeFieldList(os, field1, idList); - writeFieldList(os, field2, idList); + const labelUList& idList = elemLists_[elemI]; + + if (idList.size()) + { + os.writeKeyword(elementTypes()[elemI]); + writeFieldList(os, field0, idList); + writeFieldList(os, field1, idList); + writeFieldList(os, field2, idList); + } } } } diff --git a/src/conversion/ensight/part/ensightPartTemplates.C b/src/conversion/ensight/part/ensightPartTemplates.C index 5bb80f962226d40461cf32c973539d7505616dc5..2f3f4a599455127a2b98fd8ba86f8da38b3d5077 100644 --- a/src/conversion/ensight/part/ensightPartTemplates.C +++ b/src/conversion/ensight/part/ensightPartTemplates.C @@ -34,29 +34,46 @@ template<class Type> void Foam::ensightPart::writeField ( ensightFile& os, - const Field<Type>& field + const Field<Type>& field, + const bool perNode ) const { if (this->size() && field.size()) { writeHeader(os); - forAll(elementTypes(), elemI) + if (perNode) { - const labelList& idList = elemLists_[elemI]; - - if (idList.size()) + os.writeKeyword("coordinates"); + for + ( + direction cmpt=0; + cmpt < pTraits<Type>::nComponents; + ++cmpt + ) + { + writeFieldList(os, field.component(cmpt), labelUList::null()); + } + } + else + { + forAll(elementTypes(), elemI) { - os.writeKeyword(elementTypes()[elemI]); + const labelUList& idList = elemLists_[elemI]; - for - ( - direction cmpt=0; - cmpt < pTraits<Type>::nComponents; - ++cmpt - ) + if (idList.size()) { - writeFieldList(os, field.component(cmpt), idList); + os.writeKeyword(elementTypes()[elemI]); + + for + ( + direction cmpt=0; + cmpt < pTraits<Type>::nComponents; + ++cmpt + ) + { + writeFieldList(os, field.component(cmpt), idList); + } } } } diff --git a/src/conversion/ensight/part/ensightParts.C b/src/conversion/ensight/part/ensightParts.C index 658f41b74cfdb598b5c4c74c9b1d22edffa15d67..240b9fb859f12829b65ef2d7ce449f1d0ad0bfa4 100644 --- a/src/conversion/ensight/part/ensightParts.C +++ b/src/conversion/ensight/part/ensightParts.C @@ -107,7 +107,7 @@ void Foam::ensightParts::recalculate(const polyMesh& mesh) forAll(mesh.cellZones(), zoneI) { - const labelList& idList = mesh.cellZones()[zoneI]; + const labelUList& idList = mesh.cellZones()[zoneI]; forAll(idList, i) { @@ -162,8 +162,8 @@ void Foam::ensightParts::recalculate(const polyMesh& mesh) void Foam::ensightParts::renumber ( - const labelList& origCellId, - const labelList& origFaceId + const labelUList& origCellId, + const labelUList& origFaceId ) { forAll(partsList_, partI) @@ -228,7 +228,8 @@ void Foam::ensightParts::writeScalarField ( ensightFile& os, const List<scalar>& field, - bool useFaceData + const bool useFaceData, + const bool perNode ) const { forAll(partsList_, partI) @@ -240,7 +241,7 @@ void Foam::ensightParts::writeScalarField : partsList_[partI].isCellData() ) { - partsList_[partI].writeScalarField(os,field); + partsList_[partI].writeScalarField(os, field, perNode); } } } @@ -252,7 +253,8 @@ void Foam::ensightParts::writeVectorField const List<scalar>& field0, const List<scalar>& field1, const List<scalar>& field2, - bool useFaceData + const bool useFaceData, + const bool perNode ) const { forAll(partsList_, partI) @@ -264,7 +266,12 @@ void Foam::ensightParts::writeVectorField : partsList_[partI].isCellData() ) { - partsList_[partI].writeVectorField(os, field0, field1, field2); + partsList_[partI].writeVectorField + ( + os, + field0, field1, field2, + perNode + ); } } } diff --git a/src/conversion/ensight/part/ensightParts.H b/src/conversion/ensight/part/ensightParts.H index 7ef409425902581ffcec5d07a0800808509b97a8..6b4f49eef9a1b79e3d19d86ae3db2dcccb9fc6e7 100644 --- a/src/conversion/ensight/part/ensightParts.H +++ b/src/conversion/ensight/part/ensightParts.H @@ -89,8 +89,8 @@ public: //- renumber elements void renumber ( - const labelList& origCellId, - const labelList& origFaceId + const labelUList& origCellId, + const labelUList& origFaceId ); //- number of parts @@ -108,26 +108,32 @@ public: //- write the lists void writeData(Ostream&) const; - //- write scalar field + //- write (volume) scalar field + // optionally write data for face parts + // optionally write data per node void writeScalarField ( ensightFile&, const List<scalar>& field, - bool useFaceData = false + const bool useFaceData = false, + const bool perNode = false ) const; - //- write vector field components + //- write (volume) vector field components + // optionally write data for face parts + // optionally write data per node void writeVectorField ( ensightFile&, const List<scalar>& field0, const List<scalar>& field1, const List<scalar>& field2, - bool useFaceData = false + const bool useFaceData = false, + const bool perNode = false ) const; - //- write generalized field components + //- write generalized volume field components template<class Type> void writeField ( diff --git a/src/sampling/sampledSurface/sampledSurfaces/sampledSurfaces.C b/src/sampling/sampledSurface/sampledSurfaces/sampledSurfaces.C index 97a753e596d79f871132d62843e3514027c75d3d..a4c341321410798df4753a820ee602e7d4f3d35d 100644 --- a/src/sampling/sampledSurface/sampledSurfaces/sampledSurfaces.C +++ b/src/sampling/sampledSurface/sampledSurfaces/sampledSurfaces.C @@ -221,10 +221,10 @@ void Foam::sampledSurfaces::read(const dictionary& dict) dict.lookup("interpolationScheme") >> interpolationScheme_; - word writeFormat(dict.lookup("surfaceFormat")); + word writeType(dict.lookup("surfaceFormat")); // define the surface formatter - formatter_ = surfaceWriter::New(writeFormat); + formatter_ = surfaceWriter::New(writeType); PtrList<sampledSurface> newList ( diff --git a/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.C b/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.C index 641e6a19b2c81cfca129ba7d3ca1afa23de893db..135d566db0944e5e03e79e20b40af69e385bd947 100644 --- a/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.C +++ b/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.C @@ -42,44 +42,6 @@ namespace Foam // * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // -namespace Foam -{ - - // Write scalarField in ensight format - template<> - inline void Foam::ensightSurfaceWriter::writeData - ( - Ostream& os, - const Field<scalar>& values - ) - { - forAll(values, i) - { - os << values[i] << nl; - } - } -} - - -// Write generic field in ensight format -template<class Type> -inline void Foam::ensightSurfaceWriter::writeData -( - Ostream& os, - const Field<Type>& values -) -{ - for (direction cmpt = 0; cmpt < vector::nComponents; ++cmpt) - { - scalarField v(values.component(cmpt)); - forAll(v, i) - { - os << v[i] << nl; - } - } -} - - template<class Type> void Foam::ensightSurfaceWriter::writeTemplate ( @@ -101,47 +63,35 @@ void Foam::ensightSurfaceWriter::writeTemplate // const scalar timeValue = Foam::name(this->mesh().time().timeValue()); const scalar timeValue = 0.0; - OFstream caseStr(outputDir/fieldName/surfaceName + ".case"); - ensightGeoFile geomStr + OFstream osCase(outputDir/fieldName/surfaceName + ".case"); + ensightGeoFile osGeom ( outputDir/fieldName/surfaceName + ".000.mesh", - IOstream::ASCII + writeFormat_ ); - ensightFile fieldStr + ensightFile osField ( outputDir/fieldName/surfaceName + ".000." + fieldName, - IOstream::ASCII + writeFormat_ ); if (verbose) { - Info<< "Writing case file to " << caseStr.name() << endl; + Info<< "Writing case file to " << osCase.name() << endl; } - caseStr + osCase << "FORMAT" << nl << "type: ensight gold" << nl << nl << "GEOMETRY" << nl - << "model: 1 " << geomStr.name().name() << nl + << "model: 1 " << osGeom.name().name() << nl << nl - << "VARIABLE" << nl; - if (isNodeValues) - { - caseStr - << pTraits<Type>::typeName << " per node:" << setw(10) << 1 - << " " << fieldName - << " " << surfaceName.c_str() << ".***." << fieldName << nl; - } - else - { - caseStr - << pTraits<Type>::typeName << " per element:" << setw(10) << 1 - << " " << fieldName - << " " << surfaceName.c_str() << ".***." << fieldName << nl; - } - - caseStr + << "VARIABLE" << nl + << pTraits<Type>::typeName << " per " + << word(isNodeValues ? "node:" : "element:") << setw(10) << 1 + << " " << fieldName + << " " << surfaceName.c_str() << ".***." << fieldName << nl << nl << "TIME" << nl << "time set: 1" << nl @@ -152,40 +102,12 @@ void Foam::ensightSurfaceWriter::writeTemplate << timeValue << nl << nl; - ensightPartFaces ensPart(0, geomStr.name().name(), points, faces, true); - geomStr << ensPart; + ensightPartFaces ensPart(0, osGeom.name().name(), points, faces, true); + osGeom << ensPart; // Write field - fieldStr - << pTraits<Type>::typeName << nl - << "part" << nl - << setw(10) << 1 << nl; - - if (isNodeValues) - { - fieldStr << "coordinates" << nl; - writeData(fieldStr, values); - } - else - { - // ensPart.writeField(fieldStr, values); - forAll(ensPart.elementTypes(), elemI) - { - if (ensPart.elemLists()[elemI].size()) - { - fieldStr.writeKeyword(ensPart.elementTypes()[elemI]); - writeData - ( - fieldStr, - Field<Type> - ( - values, - ensPart.elemLists()[elemI] - ) - ); - } - } - } + osField.writeKeyword(pTraits<Type>::typeName); + ensPart.writeField(osField, values, isNodeValues); } @@ -193,7 +115,8 @@ void Foam::ensightSurfaceWriter::writeTemplate Foam::ensightSurfaceWriter::ensightSurfaceWriter() : - surfaceWriter() + surfaceWriter(), + writeFormat_(IOstream::ASCII) {} @@ -219,28 +142,27 @@ void Foam::ensightSurfaceWriter::write mkDir(outputDir); } - //const scalar timeValue = Foam::name(this->mesh().time().timeValue()); + // const scalar timeValue = Foam::name(this->mesh().time().timeValue()); const scalar timeValue = 0.0; - - OFstream caseStr(outputDir/surfaceName + ".case"); - ensightGeoFile geomStr + OFstream osCase(outputDir/surfaceName + ".case"); + ensightGeoFile osGeom ( outputDir/surfaceName + ".000.mesh", - IOstream::ASCII + writeFormat_ ); if (verbose) { - Info<< "Writing case file to " << caseStr.name() << endl; + Info<< "Writing case file to " << osCase.name() << endl; } - caseStr + osCase << "FORMAT" << nl << "type: ensight gold" << nl << nl << "GEOMETRY" << nl - << "model: 1 " << geomStr.name().name() << nl + << "model: 1 " << osGeom.name().name() << nl << nl << "TIME" << nl << "time set: 1" << nl @@ -251,8 +173,8 @@ void Foam::ensightSurfaceWriter::write << timeValue << nl << nl; - ensightPartFaces ensPart(0, geomStr.name().name(), points, faces, true); - geomStr << ensPart; + ensightPartFaces ensPart(0, osGeom.name().name(), points, faces, true); + osGeom << ensPart; } diff --git a/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.H b/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.H index 4d2bf47b90b689aae555043b66512ad465bb1da8..891947ffb47e63a08732e459fa7c657d60bda297 100644 --- a/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.H +++ b/src/sampling/sampledSurface/writers/ensight/ensightSurfaceWriter.H @@ -52,18 +52,12 @@ class ensightSurfaceWriter { // Private data -// fileName caseFileName_; -// fileName surfaceName_; -// fileName geomName_; -// DynamicList<word> varNames_; -// DynamicList<fileName> varFileNames_; + //- Write option (default is IOstream::ASCII + IOstream::streamFormat writeFormat_; // Private Member Functions - template<class Type> - static inline void writeData(Ostream&, const Field<Type>&); - //- Templated write operation template<class Type> void writeTemplate diff --git a/src/sampling/sampledSurface/writers/surfaceWriter.H b/src/sampling/sampledSurface/writers/surfaceWriter.H index 1057a187bd7cb64ff2cf6af666448125d2336506..8e24418d3926f3064cfcbd47b9b3c701ccb9fd49 100644 --- a/src/sampling/sampledSurface/writers/surfaceWriter.H +++ b/src/sampling/sampledSurface/writers/surfaceWriter.H @@ -74,7 +74,7 @@ public: // Selectors //- Return a reference to the selected surfaceWriter - static autoPtr<surfaceWriter> New(const word& writeFormat); + static autoPtr<surfaceWriter> New(const word& writeType); // Constructors