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

Method LoadCoordinateVariable

IO/NetCDF/vtkNetCDFCFReader.cxx:563–580  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

561
562//------------------------------------------------------------------------------
563int vtkNetCDFCFReader::vtkDependentDimensionInfo::LoadCoordinateVariable(
564 int ncFD, int varId, vtkDoubleArray* coords)
565{
566 int dimIds[2];
567 CALL_NETCDF_GW(this->Accessor->inq_vardimid(ncFD, varId, dimIds));
568
569 size_t dimSizes[2];
570 for (int i = 0; i < 2; i++)
571 {
572 CALL_NETCDF_GW(this->Accessor->inq_dimlen(ncFD, dimIds[i], &dimSizes[i]));
573 }
574
575 coords->SetNumberOfComponents(static_cast<int>(dimSizes[1]));
576 coords->SetNumberOfTuples(static_cast<vtkIdType>(dimSizes[0]));
577 CALL_NETCDF_GW(this->Accessor->get_var_double(ncFD, varId, coords->GetPointer(0)));
578
579 return 1;
580}
581
582//------------------------------------------------------------------------------
583int vtkNetCDFCFReader::vtkDependentDimensionInfo::LoadBoundsVariable(

Callers 1

LoadMetaDataMethod · 0.95

Calls 6

inq_vardimidMethod · 0.45
inq_dimlenMethod · 0.45
SetNumberOfComponentsMethod · 0.45
SetNumberOfTuplesMethod · 0.45
get_var_doubleMethod · 0.45
GetPointerMethod · 0.45

Tested by

no test coverage detected