MCPcopy Create free account
hub / github.com/IENT/YUView / seekToDTS

Method seekToDTS

YUViewLib/src/filesource/FileSourceFFmpegFile.cpp:599–616  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

597}
598
599bool FileSourceFFmpegFile::seekToDTS(int64_t dts)
600{
601 if (!this->isFileOpened)
602 return false;
603
604 int ret = this->ff.seekFrame(this->formatCtx, this->video_stream.getIndex(), dts);
605 if (ret != 0)
606 {
607 DEBUG_FFMPEG("FFmpegLibraries::seekToDTS Error DTS %ld. Return Code %d", dts, ret);
608 return false;
609 }
610
611 // We seeked somewhere, so we are not at the end of the file anymore.
612 this->endOfFile = false;
613
614 DEBUG_FFMPEG("FFmpegLibraries::seekToDTS Successfully seeked to DTS %d", (int)dts);
615 return true;
616}
617
618bool FileSourceFFmpegFile::seekFileToBeginning()
619{

Callers 1

seekToPositionMethod · 0.80

Calls 2

seekFrameMethod · 0.80
getIndexMethod · 0.80

Tested by

no test coverage detected