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

Function getFileNameNumberIndex

IO/EnSight/core/EnSightFile.cxx:71–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71int getFileNameNumberIndex(double actualTimeValue, std::shared_ptr<TimeSetInfo> info)
72{
73 int idx = 0;
74
75 double timeVal = info->TimeValues[0];
76 for (size_t i = 1; i < info->TimeValues.size(); ++i)
77 {
78 double newTime = info->TimeValues[i];
79 if (newTime <= actualTimeValue && newTime > timeVal)
80 {
81 timeVal = newTime;
82 idx++;
83 }
84 }
85 return idx;
86}
87
88int getFileSetIndex(int tsIdx, std::shared_ptr<FileSetInfo> info)
89{

Callers 1

SetTimeStepToReadMethod · 0.85

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected