------------------------------------------------------------------------------
| 168 | |
| 169 | //------------------------------------------------------------------------------ |
| 170 | int vtkXMLPStructuredDataReader::ReadPrimaryElement(vtkXMLDataElement* ePrimary) |
| 171 | { |
| 172 | if (!this->Superclass::ReadPrimaryElement(ePrimary)) |
| 173 | { |
| 174 | return 0; |
| 175 | } |
| 176 | |
| 177 | // Get the whole extent attribute. |
| 178 | int extent[6]; |
| 179 | if (ePrimary->GetVectorAttribute("WholeExtent", 6, extent) == 6) |
| 180 | { |
| 181 | // Set the output's whole extent. |
| 182 | vtkInformation* outInfo = this->GetCurrentOutputInformation(); |
| 183 | outInfo->Set(vtkStreamingDemandDrivenPipeline::WHOLE_EXTENT(), extent, 6); |
| 184 | |
| 185 | // Check each axis to see if it has cells. |
| 186 | for (int a = 0; a < 3; ++a) |
| 187 | { |
| 188 | this->AxesEmpty[a] = (extent[2 * a + 1] > extent[2 * a]) ? 0 : 1; |
| 189 | } |
| 190 | } |
| 191 | else |
| 192 | { |
| 193 | vtkErrorMacro(<< this->GetDataSetName() << " element has no WholeExtent."); |
| 194 | return 0; |
| 195 | } |
| 196 | |
| 197 | return 1; |
| 198 | } |
| 199 | |
| 200 | //------------------------------------------------------------------------------ |
| 201 | void vtkXMLPStructuredDataReader::CopyOutputInformation(vtkInformation* outInfo, int port) |
nothing calls this directly
no test coverage detected