This is a strange question, I know.
I am working on an art project right now and we are disappointed that when we arbitrarily seek around files we don’t see any compression artifacts. The source files are a mix of mostly mp4 and avi files. The application will need to jump between files and randomly seek to different offsets in the timeline.
Should I just build custom pipelines and tweak the buffers down to nothing? Is there a way to tell decodebin2 to seek directly and to ignore keyframes?
I am open to non-gstreamer options but I’d prefer to stick to python.
Simplest way is to introduce errors in the stream. Random bit / burst errors will lead to unpredictable glitches! If you are open to a modifying a plugin like identity, insert it before the decoder and change it to insert random errors with some probability. Change the probability to your liking. If you can avoid destroying headers of frames but then you may get fancier glitches.
Simpler solution. Take your files.. randomly insert errors into with a program that reads them and writes new versions. Feed these versinos to your program.
The first method is for dynamic random effects and later method static effects [the file when run again will give same artifacts] 🙂