We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e26012c commit 987b4feCopy full SHA for 987b4fe
src/torchcodec/decoders/_core/VideoDecoder.cpp
@@ -881,6 +881,10 @@ VideoDecoder::AudioFramesOutput VideoDecoder::getFramesPlayedInRangeAudio(
881
AVFrameStream avFrameStream = decodeAVFrame([startPts](AVFrame* avFrame) {
882
return startPts < avFrame->pts + getDuration(avFrame);
883
});
884
+ // TODO: it's not great that we are getting a FrameOutput, which is
885
+ // intended for videos. We should consider bypassing
886
+ // convertAVFrameToFrameOutput and directly call
887
+ // convertAudioAVFrameToFrameOutputOnCPU.
888
auto frameOutput = convertAVFrameToFrameOutput(avFrameStream);
889
firstFramePtsSeconds =
890
std::min(firstFramePtsSeconds, frameOutput.ptsSeconds);
0 commit comments