35 const char* Foam::vtk::legacyRawFormatter::legacyName_ =
"BINARY";
38 Foam::vtk::legacyRawFormatter::opts_(formatType::LEGACY_BINARY);
109 #ifdef WM_LITTLE_ENDIAN 110 # if WM_LABEL_SIZE == 32 112 write(reinterpret_cast<const char*>(&swapped),
sizeof(uint32_t));
113 # elif WM_LABEL_SIZE == 64 115 write(reinterpret_cast<const char*>(&swapped),
sizeof(uint64_t));
118 write(reinterpret_cast<const char*>(&val),
sizeof(label));
127 #ifdef WM_LITTLE_ENDIAN 132 const uint32_t* ptr =
reinterpret_cast<const uint32_t*
>(&val);
134 write(reinterpret_cast<const char*>(&swapped),
sizeof(uint32_t));
136 write(reinterpret_cast<const char*>(&val),
sizeof(
float));
151 else if (val <= std::numeric_limits<float>::lowest())
153 write(std::numeric_limits<float>::lowest());
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
static uint32_t swap32(uint32_t)
Byte endian swapping for 32-bits.
Help with architecture-specific aspects.
Encapsulated combinations of output format options. This is primarily useful when defining the output...
void write(vtk::formatter &fmt, const Type &val, const label n=1)
Component-wise write of a value (N times)
OBJstream os(runTime.globalPath()/outputName)
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
static uint64_t swap64(uint64_t)
Byte endian swapping for 64-bits.