"Seek" not working, likely due to duration being detected improperly
Cameron
cameron.johnson at l-3com.com
Wed May 28 12:28:58 PDT 2014
I am attempting to make "Seek" work in a gstreamer-sharp application. It
consistently fails to seek, no matter what input value I give it.
Investigation has revealed that QueryDuration yields a duration of "-1." I
suspect this may be the source of the problem, but am not positive. It does
seem likely that it thinks I'm seeking beyond the end of the file when it
thinks the file ends before it begins, however.
I am unsure why it is returning this "-1" value. Searching online has not
found this as a problem others have written about facing, and hasn't yielded
any hint that it is some sort of specific error code. All documentation for
gstreamer and gstreamer-sharp seems to indicate that QueryDuration just
works.
I know the file is good, and I have - elsewhere in the code - detected the
correct length of the file. Unfortunately, I can't figure out how to pass
this properly-detected duration into the pipeline's context, and I can't
figure out what I might be doing wrong to detect the actual duration.
Perhaps I am attempting to query the wrong thing?
I am using:
Pipeline pipeline;
long duration;
Format curFor = Format.Time;
this.pipeline.QueryDuration(ref curFor, out duration);
"pipeline" is defined; I just have left out the steps in creating the
definition here for simplicity. I do know it is a valid pipeline; the file
streams just fine. It just won't seek, and starts at the beginning of the
file when told to play rather than starting at the point to which I had
hoped to seek.
Thanks for any advice or help!
--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Seek-not-working-likely-due-to-duration-being-detected-improperly-tp4667255.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
More information about the gstreamer-devel
mailing list