[gst-devel] problem with seeking in 0.9

Vincent Torri Vincent.Torri at iecn.u-nancy.fr
Sun Nov 6 04:00:23 CET 2005


Hello,

I try to do what I have done with gstreamer 0.8 : with a filesrc, a
decodebin and a fakesink, seek to some frame number, get the frame data
and then display it.

Thanks to Ronald, I have managed to use threads so that the seek finishes
its stuff. It's not perfect, but it works. If you have better solution,
don't hesitate to tell me how to do.

So, the handoff signal is sent from the fakesink, and I get the data. Then
I display it. But I have several problems. I have tested the program with
3 video files (you can find them here :
http://www.iecn.u-nancy.fr/~torri/files/gstreamer_pb/
the main.c file is useless), that is 3 types of container. The video
stream has been encoded with xvid.

1) With the avi file :
  a) When I change the state of the pipeline to PAUSED, I get lots of
messages like :

ERROR (0x80f8b78 - 0:00:00.496073000)               ffmpeg(14323) (0)::
get_buffer() failed (-1 0 0 (nil))

ERROR (0x80f8b78 - 0:00:00.496309000)               ffmpeg(14323)
gstffmpegdec.c(905):gst_ffmpegdec_frame:<ffdec_mpeg40> ffdec_mpeg4:
decoding error (len: -1, have_data: 0)

  b) when I seek to some frames, It seems that the planes are not
correctly taken from the data. For example, seek to frame 120. I don't
think that my code that takes and displays the frame is wrong, as I have
taken it from my program that uses gstreamer 0.8 (and which works).

2) With the ogm file, i can't pause the pipeline :
  gst_element_set_state (pipeline, GST_STATE_PAUSED); returns
GST_STATE_CHANGE_FAILURE

3) with the mkv file
  a) I have the errors messages of gst-ffmpeg, like with the avi file

  b) it seeks to a wrong timestamp. For example, when seeking to frame
120, the timestamp should be equal to 4.8s. With the mkv, the timestamp is
9.08, and the offset of the buffer is -1.

I have attached the program that I use. Usage : seek my_file my_frame_nbr

any ideas about these problems ?

thank you

Vincent
-------------- next part --------------
A non-text attachment was scrubbed...
Name: seek.c
Type: text/x-csrc
Size: 8133 bytes
Desc: 
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20051106/63dff7f3/attachment.c>


More information about the gstreamer-devel mailing list