MCPcopy Create free account
hub / github.com/Kitware/VTK / WriteInlinePiece

Method WriteInlinePiece

IO/XML/vtkXMLUnstructuredDataWriter.cxx:487–522  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

485
486//------------------------------------------------------------------------------
487void vtkXMLUnstructuredDataWriter::WriteInlinePiece(vtkIndent indent)
488{
489 vtkPointSet* input = this->GetPointSetInput();
490
491 // Split progress among point data, cell data, and point arrays.
492 float progressRange[2] = { 0, 0 };
493 this->GetProgressRange(progressRange);
494 float fractions[4];
495 this->CalculateDataFractions(fractions);
496
497 // Set the range of progress for the point data arrays.
498 this->SetProgressRange(progressRange, 0, fractions);
499
500 // Write the point data arrays.
501 this->WritePointDataInline(input->GetPointData(), indent);
502 if (this->ErrorCode == vtkErrorCode::OutOfDiskSpaceError)
503 {
504 return;
505 }
506
507 // Set the range of progress for the cell data arrays.
508 this->SetProgressRange(progressRange, 1, fractions);
509
510 // Write the cell data arrays.
511 this->WriteCellDataInline(input->GetCellData(), indent);
512 if (this->ErrorCode == vtkErrorCode::OutOfDiskSpaceError)
513 {
514 return;
515 }
516
517 // Set the range of progress for the point specification array.
518 this->SetProgressRange(progressRange, 2, fractions);
519
520 // Write the point specification array.
521 this->WritePointsInline(input->GetPoints(), indent);
522}
523
524//------------------------------------------------------------------------------
525void vtkXMLUnstructuredDataWriter::WriteAppendedPieceAttributes(int index)

Callers 1

WriteInlineModeMethod · 0.95

Calls 10

GetPointSetInputMethod · 0.95
WritePointDataInlineMethod · 0.80
WriteCellDataInlineMethod · 0.80
WritePointsInlineMethod · 0.80
GetProgressRangeMethod · 0.45
SetProgressRangeMethod · 0.45
GetPointDataMethod · 0.45
GetCellDataMethod · 0.45
GetPointsMethod · 0.45

Tested by

no test coverage detected