------------------------------------------------------------------------------
| 638 | |
| 639 | //------------------------------------------------------------------------------ |
| 640 | int vtkNetCDFCFReader::vtkDependentDimensionInfo::LoadUnstructuredBoundsVariable( |
| 641 | int ncFD, int varId, vtkDoubleArray* coords) |
| 642 | { |
| 643 | int dimIds[2]; |
| 644 | CALL_NETCDF_GW(this->Accessor->inq_vardimid(ncFD, varId, dimIds)); |
| 645 | |
| 646 | size_t dimSizes[2]; |
| 647 | for (int i = 0; i < 2; i++) |
| 648 | { |
| 649 | CALL_NETCDF_GW(this->Accessor->inq_dimlen(ncFD, dimIds[i], &dimSizes[i])); |
| 650 | } |
| 651 | |
| 652 | int numVertPerCell = static_cast<int>(dimSizes[1]); |
| 653 | vtkIdType numCells = static_cast<vtkIdType>(dimSizes[0]); |
| 654 | |
| 655 | coords->SetNumberOfComponents(numVertPerCell); |
| 656 | coords->SetNumberOfTuples(numCells); |
| 657 | CALL_NETCDF_GW(this->Accessor->get_var_double(ncFD, varId, coords->GetPointer(0))); |
| 658 | |
| 659 | return 1; |
| 660 | } |
| 661 | |
| 662 | //------------------------------------------------------------------------------ |
| 663 | class vtkNetCDFCFReader::vtkDependentDimensionInfoVector |
no test coverage detected