MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/SPlisHSPlasH / convertFileName

Function convertFileName

Tools/MeshSkinning/main.cpp:553–568  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

551}
552
553std::string convertFileName(const std::string &inputFileName, const unsigned int currentFrame)
554{
555 std::string fileName = inputFileName;
556 std::string::size_type pos1 = fileName.find_first_of("#", 0);
557 if (pos1 == std::string::npos)
558 {
559 LOG_ERR << "# missing in file name.";
560 exit(1);
561 }
562 std::string::size_type pos2 = fileName.find_first_not_of("#", pos1);
563 std::string::size_type length = pos2 - pos1;
564
565 std::string numberStr = zeroPadding(currentFrame, (unsigned int)length);
566 fileName.replace(pos1, length, numberStr);
567 return fileName;
568}
569
570bool readFrame(std::vector<Vector3r>& x, const unsigned int frame)
571{

Callers 8

readFrameFunction · 0.70
meshSkinningFunction · 0.70
exportOBJFunction · 0.70
exportVTKFunction · 0.70
exportPLYFunction · 0.70
runMethod · 0.50
updateDataMethod · 0.50
imagesExistMethod · 0.50

Calls 1

zeroPaddingFunction · 0.70

Tested by

no test coverage detected