MCPcopy Create free account
hub / github.com/OGRECave/ogre / writeContentsToTimestampedFile

Method writeContentsToTimestampedFile

OgreMain/src/OgreRenderTarget.cpp:404–419  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

402 }
403 //-----------------------------------------------------------------------
404 String RenderTarget::writeContentsToTimestampedFile(const String& filenamePrefix, const String& filenameSuffix)
405 {
406 auto t = std::time(nullptr);
407 auto pTime = std::localtime(&t);
408
409 // use ISO 8601 order
410 StringStream oss;
411 oss << filenamePrefix
412 << std::put_time(pTime, "%Y%m%d_%H%M%S")
413 << std::setw(3) << std::setfill('0') << (mTimer->getMilliseconds() % 1000)
414 << filenameSuffix;
415 String filename = oss.str();
416 writeContentsToFile(filename);
417 return filename;
418
419 }
420 //-----------------------------------------------------------------------
421 void RenderTarget::writeContentsToFile(const String& filename)
422 {

Callers 2

keyPressedMethod · 0.80
keyPressedMethod · 0.80

Calls 1

getMillisecondsMethod · 0.80

Tested by 1

keyPressedMethod · 0.64