How to stop the pipe immediately when the filesrc had finished reading source file?

The follow can stop pipe immediately when the filesrc had finished reading source file.
" gst-launch-1.0 filesrc location=test.h265 ! ‘video/x-h265,stream-format=(string)byte-stream, alignment=(string)au’ ! h265parse ! filesink location=test2.h265 -e"

But when I replaced filesink with Appsink,the pipe will be delayed several seconds after filesRC finishes reading the file,appsink’s callback does no time-consuming operations.
How to stop the pipe immediately when the filesrc had finished reading source file?

Hi,
It looks like appsink in gst-launch-1.0 is not a valid use-case, so it does not handle EoS properly. Please try it in C code and check if the issue is still present.

May see if other users has experience about using appsink in gst-launch-1.0.

I’ve already test with the C code before I asked the question,It was same result.

Sorry for the late response, is this still an issue to support?

Thanks

Hello,kayccc
Please help me if you have time

Hi,
Please check if you can run like this sample:
Gstreamer decode live video stream with the delay difference between gst-launch-1.0 command and appsink callback - #6 by DaneLLL

Register a EoS callback to appsink and once you receive the EoS, you can terminate the gstreamer pipeline.

1 Like

Thank you for your answer,I’ll verify it out later.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.