43 const IOobjectList cloudObjs
51 IOField<Type> newField(*obj);
52 return tmp<Field<Type>>(
new Field<Type>(move(newField)));
56 <<
"error: cloud field name " <<
name <<
" not found"
59 return Field<Type>::null();
68 const IOobjectList& cloudObjs
79 IOField<Type> newField(*obj);
95 os << value.component(0);
96 for (
label i=1; i<pTraits<Type>::nComponents; i++)
98 os <<
' ' << value.component(i);
112 label step =
max(floor(8/pTraits<Type>::nComponents), 1);
118 os << nl << fieldNames[fieldi] << ' ' << pTraits<Type>::nComponents
119 <<
' ' << values[fieldi].size() <<
" float" <<
nl;
125 List<Type> data(UIndirectList<Type>(values[fieldi], ids));
126 label nData = data.size() - 1;
129 writeVTK<Type>(os, data[i]);
130 if (((i + 1) % step == 0) || (i == nData))
150 const IOobjectList& cloudObjs
160 IOobject* obj =
objects.lookup(userFieldNames[i]);
169 readFields<Type>(values,
fieldNames, cloudObjs);
#define forAll(list, i)
Loop across all elements in list.
void append(const T &)
Append an element at the end of the list.
void size(const label)
Override size to be inconsistent with allocated storage.
Motion of the mesh specified as a list of pointMeshMovers.
A class for managing temporary objects.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
static List< word > fieldNames
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
tmp< Field< Type > > readParticleField(const word &name, const IOobjectList cloudObjs)
String typeName(const std::type_info &info)
Return the un-mangled name given the standard type info.
void readFields(const typename GeoFieldType::Mesh &mesh, const IOobjectList &objects, const HashSet< word > &selectedFields, LIFOStack< regIOobject * > &storedObjects)
Read the selected GeometricFields of the specified type.
errorManip< error > abort(error &err)
bool fieldOk(const IOobjectList &cloudObjs, const word &name)
void processFields(OFstream &os, const List< List< label >> &addr, const List< word > &userFieldNames, const IOobjectList &cloudObjs)
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.
void writeVTK(OFstream &os, const Type &value)
void writeVTKFields(OFstream &os, const PtrList< List< Type >> &values, const List< List< label >> &addr, const List< word > &fieldNames)
dimensioned< Type > max(const DimensionedField< Type, GeoMesh, PrimitiveField > &df)