On Tue, 2 Apr 2024 00:18:04 GMT, Alexander Matveev <[email protected]> wrote:
> - Added support for #EXT-X-MEDIA tag to HTTP Live Streaming.
> - Following audio renditions via #EXT-X-MEDIA tag will be supported (see CSR
> for more details):
> - MP2T streams with one H.264/AVC video track and elementary AAC audio
> stream via #EXT-X-MEDIA tag.
> - fMP4 streams with one H.264/AVC or H.265/HEVC video track and elementary
> AAC audio stream via #EXT-X-MEDIA tag.
> - fMP4 streams with one H.264/AVC or H.265/HEVC video track and fMP4
> streams with one AAC audio track via #EXT-X-MEDIA tag.
> - Separate audio stream will be playback via separate chain of GStreamer
> elements inside one pipeline. Which means two "javasource" elements will be
> used inside one pipeline and they will be reading data independently of each
> other via two separate HLSConnectionHolders. GStreamer will handle audio and
> video synchronization based on PTS as for other streams. Other solutions were
> considered such as one "javasource" with multiple source pads, but such
> implementation will be more complex and does not provide any benefits.
> - HLSConnectionHolder which handles video stream will also parse all
> information for separate audio stream and then create child
> HLSConnectionHolder for separate audio stream which will be responsible for
> downloading audio segments and seek of audio streams.
> - Parser in HLSConnectionHolder was reworked to make it more readable and
> easy to maintain and extend.
> - JavaDoc updated to point to latest HLS implementation vs old draft. It also
> updated with information on #EXT-X-MEDIA tag. Also, added missing information
> on AAC elementary streams and fMP4 from previous fixes.
> - Fixed and improved debug output in Linux AV plugins.
> - Added new property to "dshowwrapper" to disable PTS reset for each new
> segment, since with #EXT-X-MEDIA tag audio and video segments are not align
> and they can start at different time.
> - Fixed missing PTS on first buffer after seek in MP2T demuxer in
> "dshowwrapper". Without it audio and video synchronization breaks with two
> separate streams.
> - Removed dead code from MediaManager.
> - Added handling for GST_MESSAGE_LATENCY. Based on GStreamer doc we need to
> call gst_bin_recalculate_latency() when such message received. Not sure if we
> really need to do this, but with separate video and audio streams we do
> receive this message when seek is done. Most likely due to video and audio is
> not align perfectly when we seek. For other streams this message is not
> received in most cases.
This will need testing on all platforms.
While testing on Linux, I ran into a compilation error on an older Ubuntu 16.04
system (using the production gcc 13.2 compilers). This suggests that you are
missing an include that, in some cases, matters:
../../platform/gstreamer/GstAudioPlaybackPipeline.cpp:1069:21: error: 'strstr'
was not declared in this scope
1069 | if (strstr(mimetype, "audio/unsupported") != NULL)
| ^~~~~~
../../platform/gstreamer/GstAudioPlaybackPipeline.cpp:36:1: note: 'strstr' is
defined in header '<cstring>'; did you forget to '#include <cstring>'?
35 | #include <fxplugins_common.h>
+++ |+#include <cstring>
36 |
Makefile:173: recipe for target
'jfx/modules/javafx.media/build/native/linux/Release/obj/jfxmedia/platform/gstreamer/GstAudioPlaybackPipeline.o'
failed
make: ***
[jfx/modules/javafx.media/build/native/linux/Release/obj/jfxmedia/platform/gstreamer/GstAudioPlaybackPipeline.o]
Error 1
make: *** Waiting for unfinished jobs....
../../platform/gstreamer/GstAVPlaybackPipeline.cpp:184:21: error: 'strstr' was
not declared in this scope
184 | if (strstr(mimetype, "video/x-h264") != NULL) // H.264
| ^~~~~~
../../platform/gstreamer/GstAVPlaybackPipeline.cpp:37:1: note: 'strstr' is
defined in header '<cstring>'; did you forget to '#include <cstring>'?
36 | #include <fxplugins_common.h>
+++ |+#include <cstring>
37 |
make: ***
[jfx/modules/javafx.media/build/native/linux/Release/obj/jfxmedia/platform/gstreamer/GstAVPlaybackPipeline.o]
Error 1
Makefile:173: recipe for target
'jfx/modules/javafx.media/build/native/linux/Release/obj/jfxmedia/platform/gstreamer/GstAVPlaybackPipeline.o'
failed
-------------
PR Comment: https://git.openjdk.org/jfx/pull/1435#issuecomment-2075846696