After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 747000 - multifilesink: doesn't post file message for last file
multifilesink: doesn't post file message for last file
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other All
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-03-30 07:23 UTC by Ben
Modified: 2015-04-04 16:42 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
multifilesink: post file message on EOS (2.51 KB, patch)
2015-03-30 15:21 UTC, Thiago Sousa Santos
committed Details | Review

Description Ben 2015-03-30 07:23:43 UTC
hlssink creates all the segments but the last segment is missing from the playlist.

This creates 4 segments:

gst-launch-1.0 -v uridecodebin uri=http://mirror.cessen.com/blender.org/peach/trailer/trailer_iphone.m4v name=decbin ! video/x-raw ! x264enc ! mpegtsmux name=muxer ! hlssink target-duration=10 decbin. ! audioconvert ! audio/x-raw !  
voaacenc ! aacparse ! muxer.

segment00003.ts is missing is missing from the generated playlist.m3u8:

#EXTM3U
#EXT-X-VERSION:3
#EXT-X-ALLOW-CACHE:NO
#EXT-X-MEDIA-SEQUENCE:1
#EXT-X-TARGETDURATION:10

#EXTINF:10.079999923706055,
segment00000.ts
#EXTINF:10.079999923706055,
segment00001.ts
#EXTINF:10.079999923706055,
segment00002.ts
Comment 1 Thiago Sousa Santos 2015-03-30 15:21:07 UTC
Created attachment 300603 [details] [review]
multifilesink: post file message on EOS

When multifilesink is operating in any mode other than one file
per buffer, the last file created won't have a file message posted
as multifilesink doesn't handle the EOS event.

This patch fixes it by using the last position to post a file
message when EOS is received. This should ensure at least the
time related data and the filename are posted to the application
or other elements
Comment 2 Thiago Sousa Santos 2015-03-30 21:50:09 UTC
The problem here is that upon EOS, multifilesink doesn't post a GstMultiFileSink message and hlssink doesn't write the last entry in the file.
Comment 3 Ben 2015-03-31 10:31:26 UTC
With the patch, the last segment is included in the playlist.

When playing the playlist with playbin, it looks like one or more frames are missing from the end of the last segment.
In the original video, the movie ends with a white frame.
When converted to hls, the last frame is not completely white and show some text.

Is it a problem with playbin or mpegtsmux or hlssink?
Is this a separate issue?
Comment 4 Ben 2015-04-04 08:42:18 UTC
Created a separate issue for the missing frames
https://bugzilla.gnome.org/show_bug.cgi?id=747319
Comment 5 Thiago Sousa Santos 2015-04-04 15:09:20 UTC
commit e00f0de4f3e863c993af3137e7f75e364e3f6ac6
Author: Thiago Santos <thiagoss@osg.samsung.com>
Date:   Mon Mar 30 11:14:09 2015 -0300

    multifilesink: post file message on EOS
    
    When multifilesink is operating in any mode other than one file
    per buffer, the last file created won't have a file message posted
    as multifilesink doesn't handle the EOS event.
    
    This patch fixes it by using the last position to post a file
    message when EOS is received. This should ensure at least the
    time related data and the filename are posted to the application
    or other elements
    
    https://bugzilla.gnome.org/show_bug.cgi?id=747000