Confusion regarding SEGMENT in GStreamer

Edward Hervey bilboed at gmail.com
Fri May 10 07:08:47 PDT 2013


On Fri, 2013-05-10 at 12:34 +0530, Deepak Jain wrote:
> Thanks Edward for second question.
>  
> however u missed my first question below...
>  
> Suppose I am having a file of say 1 hour duration. How many segments
> will be present in it?

  The answer is "It depends, you can't be sure of it, you shouldn't care
about that".
  ... which is why you should not care and just use GstSegment.

    Edward

>  
> Thx
> Deepak
>  
> 
> 
> On Fri, May 10, 2013 at 12:18 PM, Edward Hervey <bilboed at gmail.com>
> wrote:
>         Hi,
>         
>           If the stop position is unspecified in a segment, then any
>         buffer
>         timestamp (greater than the specified start position) is
>         valid.
>         
>           An easier solution is to use GstSegment and gst_segment_clip
>         to figure
>         out if a buffer timestamp is valid or not. Just feed the
>         incoming
>         segment events into GstSegment and let it handle the logic for
>         you :)
>         
>            Edward
>         
>         On Fri, 2013-05-10 at 11:31 +0530, Deepak Jain wrote:
>         > Hi,
>         >
>         > I am having some confusion regarding segment.
>         >
>         > Suppose I am having a file of say 1 hour duration. How many
>         segment
>         > will be present in it?
>         >
>         >
>         >
>         > Or in other words, if one segment is only present, which I
>         > think...then for live sources, segments's stop time will be
>         undefined.
>         >
>         > In that case, how we will determine that whether a
>         particular buffer
>         > falls in our range or not since we dont have segment's stop
>         value.
>         >
>         > Thanks,
>         > Deepak
>         
>         > _______________________________________________
>         > gstreamer-devel mailing list
>         > gstreamer-devel at lists.freedesktop.org
>         >
>         http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>         
>         
>         _______________________________________________
>         gstreamer-devel mailing list
>         gstreamer-devel at lists.freedesktop.org
>         http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
> 
> 
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel




More information about the gstreamer-devel mailing list