* [FFmpeg-devel] Working on an LTC source filter - can this be made seekable?
@ 2023-08-31 19:35 Johannes Maibaum
0 siblings, 0 replies; only message in thread
From: Johannes Maibaum @ 2023-08-31 19:35 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Hello,
as my first dive into the ffmpeg source, I am working on an
Linear/Longitudinal Time Code (LTC) source filter for ffmpeg using
https://github.com/x42/libltc here:
https://git.sr.ht/~jmaibaum/ffmpeg/log/ltc
The basics are working fine and turned out to be fairly easy to achieve,
even though I am still missing essential features, major refactorings,
and proper testing, before I would consider it ready for inclusion into
ffmpeg. I am planning to get there eventually once my free time allows.
Yet, I am now facing an issue where I am unsure if the plan to add the
ltcsrc as a libav source filter was correct in the first place?
One of the use-cases I have in mind for the ltcsrc filter involves
having it generate an LTC signal while playing another audio or video
file in sync, i.e. the LTC signal should of course always match the
current position of the audio/video file's playback position. It should
be possible to seek arbitrarily inside the video player, thus. the LTC
timecode being generated after a seek event signal must always stay in
sync to the new playback position of the audio/video file.
But apparently libav-filters are by design not supporting seek events at
all though, at least not from ffplay, where running
ffplay -f lavfi -i ltcsrc
and then trying to seek results in "error while seeking". This error
also happens with all other filters I tried using in the ffplay command
line above. Similar quick checks trying to use the filter from within
mpv resulted in an unseekable playback.
I can successfully send commands (via asendcmd) to change the timecode
being generated on the fly, but this feels like a bad workaround for the
use-case described above.
I took a brief look into other ffmpeg modules (codecs, formats,
devices), but from my current understanding a (source) filter is the
correct way to implement ltcsrc.
Thus, my question is: Can this use-case even be solved by implementing
ltcsrc as a filter? If not, how can I implement an ltcsrc that can be
used "like" a filter (i.e. supporting things like receiving commands to
change other parameters on the fly) in my use-case, but also supporting
seek events?
Cheers,
Johannes
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-08-31 19:35 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-31 19:35 [FFmpeg-devel] Working on an LTC source filter - can this be made seekable? Johannes Maibaum
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git