| 166 | |
| 167 | |
| 168 | void Foam::ensightPart::writeGeometry |
| 169 | ( |
| 170 | ensightGeoFile& os, |
| 171 | const pointField& points |
| 172 | ) const |
| 173 | { |
| 174 | if (size()) |
| 175 | { |
| 176 | const localPoints ptList = calcLocalPoints(); |
| 177 | const labelUList& pointMap = ptList.list; |
| 178 | |
| 179 | writeHeader(os, true); |
| 180 | |
| 181 | // write points |
| 182 | os.writeKeyword("coordinates"); |
| 183 | os.write(ptList.nPoints); |
| 184 | os.newline(); |
| 185 | |
| 186 | for (direction cmpt=0; cmpt < point::nComponents; ++cmpt) |
| 187 | { |
| 188 | forAll(pointMap, ptI) |
| 189 | { |
| 190 | if (pointMap[ptI] > -1) |
| 191 | { |
| 192 | os.write(points[ptI].component(cmpt)); |
| 193 | os.newline(); |
| 194 | } |
| 195 | } |
| 196 | } |
| 197 | |
| 198 | // write parts |
| 199 | forAll(elementTypes(), elemI) |
| 200 | { |
| 201 | if (elemLists_[elemI].size()) |
| 202 | { |
| 203 | writeConnectivity |
| 204 | ( |
| 205 | os, |
| 206 | elementTypes()[elemI], |
| 207 | elemLists_[elemI], |
| 208 | pointMap |
| 209 | ); |
| 210 | } |
| 211 | } |
| 212 | } |
| 213 | } |
| 214 | |
| 215 | |
| 216 | void Foam::ensightPart::writeScalarField |
nothing calls this directly
no test coverage detected