Skip to content

Commit 987b4fe

Browse files
committed
Add TODO
1 parent e26012c commit 987b4fe

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/torchcodec/decoders/_core/VideoDecoder.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -881,6 +881,10 @@ VideoDecoder::AudioFramesOutput VideoDecoder::getFramesPlayedInRangeAudio(
881881
AVFrameStream avFrameStream = decodeAVFrame([startPts](AVFrame* avFrame) {
882882
return startPts < avFrame->pts + getDuration(avFrame);
883883
});
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.
884888
auto frameOutput = convertAVFrameToFrameOutput(avFrameStream);
885889
firstFramePtsSeconds =
886890
std::min(firstFramePtsSeconds, frameOutput.ptsSeconds);

0 commit comments

Comments
 (0)