gst_element_seek() is failing !!
satish pattar
satish.pattar at gmail.com
Wed May 4 04:41:04 PDT 2011
I have also tried with playbin2 instead of pipeline, still the results are
same.
Appreciate your inputs.
Thanks ,
Satish P
On Fri, Apr 29, 2011 at 7:33 PM, Wim Taymans <wim.taymans at gmail.com> wrote:
> On 04/29/2011 03:10 PM, satish pattar wrote:
>
>> Hello All,
>>
>>
>> I am trying play a mp3 from constructing a pipeline using an application.
>> It works fine as expected on my desktop. when I cross compile for ARM v7 ,
>> the seek is not happening.
>>
> Check the type of the cur_pos variable and also the printf format
> specifiers, they
> are likely wrong.
>
> Wim
>
>>
>> I am constructing pipeline using filesrc ! decodebin2 ! autoaudiosink
>>
>> my code snippet for seek is like this..
>>
>> ---------------------------------------------------------------------------------------
>> if (!(gst_element_query_position (pipeline, &fmt, &cur_pos)))
>> printf("[player] : gst_element_query_position failed \n");
>>
>> printf("current position before seek = %u\n", cur_pos);
>>
>> printf("GST_SECOND = %u\n", GST_SECOND);
>>
>> double new_pos_sec = cur_pos * (1.0 / GST_SECOND) + 10; // seek for 10
>> sec
>>
>> gint64 new_pos = new_pos_sec * GST_SECOND ;
>>
>> if(!(gst_element_seek (pipeline, 1.0, GST_FORMAT_TIME,
>> GST_SEEK_FLAG_FLUSH, GST_SEEK_TYPE_SET,
>> new_pos , GST_SEEK_TYPE_NONE, GST_CLOCK_TIME_NONE)))
>> printf("[player] Seek failed!! \n");
>>
>>
>> --------------------------------------------------------------------------------
>>
>> output is :
>>
>> current position before seek = 0
>> GST_SECOND = 0
>> [player] Seek failed!!
>>
>> ---------------------------------------------------------
>> What could be the reason for GST_SECOND = 0 , on my desktop I am getting
>> this value as 1000000000 & seek is happening as expected.
>>
>>
>>
>> --
>> Thanks & Regards,
>>
>> Satish Pattar
>>
>>
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>>
>
>
--
Thanks & Regards,
Satish Pattar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20110504/aad7d273/attachment-0001.htm>
More information about the gstreamer-devel
mailing list