primitives/direction: Changed from "char" to "int8_t" and added IO operators
to avoid problems when writing "nComponents"
This commit is contained in:
@ -38,7 +38,7 @@ void Foam::patchWriter::write
|
||||
{
|
||||
const GeometricField<Type, fvPatchField, volMesh>& fld = flds[fieldi];
|
||||
|
||||
os_ << fld.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os_ << fld.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nFaces_ << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nFaces_);
|
||||
@ -74,7 +74,7 @@ void Foam::patchWriter::write
|
||||
const GeometricField<Type, pointPatchField, pointMesh>& fld =
|
||||
flds[fieldi];
|
||||
|
||||
os_ << fld.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os_ << fld.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nPoints_ << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nPoints_);
|
||||
@ -103,7 +103,7 @@ void Foam::patchWriter::write
|
||||
{
|
||||
const GeometricField<Type, fvPatchField, volMesh>& fld = flds[fieldi];
|
||||
|
||||
os_ << fld.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os_ << fld.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nPoints_ << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nPoints_);
|
||||
|
||||
@ -74,7 +74,7 @@ void Foam::writeFuns::write
|
||||
|
||||
label nValues = mesh.nCells() + superCells.size();
|
||||
|
||||
os << vvf.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os << vvf.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nValues << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nValues);
|
||||
@ -106,7 +106,7 @@ void Foam::writeFuns::write
|
||||
const labelList& addPointCellLabels = topo.addPointCellLabels();
|
||||
const label nTotPoints = mesh.nPoints() + addPointCellLabels.size();
|
||||
|
||||
os << pvf.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os << pvf.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nTotPoints << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nTotPoints);
|
||||
@ -139,7 +139,7 @@ void Foam::writeFuns::write
|
||||
const labelList& addPointCellLabels = topo.addPointCellLabels();
|
||||
const label nTotPoints = mesh.nPoints() + addPointCellLabels.size();
|
||||
|
||||
os << vvf.name() << ' ' << int(pTraits<Type>::nComponents) << ' '
|
||||
os << vvf.name() << ' ' << pTraits<Type>::nComponents << ' '
|
||||
<< nTotPoints << " float" << std::endl;
|
||||
|
||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nTotPoints);
|
||||
|
||||
Reference in New Issue
Block a user