# Questions Regarding hlscmafsink Latency Optimization

**URL:** <https://discourse.gstreamer.org/t/questions-regarding-hlscmafsink-latency-optimization/3590>\
**Category:** Application Development\
**Created:** [November 17, 2024, 11:48am UTC](https://discourse.gstreamer.org/t/questions-regarding-hlscmafsink-latency-optimization/3590 "2024-11-17T11:48:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Apandey007](https://discourse.gstreamer.org/letter_avatar_proxy/v4/letter/a/aeb1de/32.png) [@Apandey007](https://discourse.gstreamer.org/u/Apandey007)\
**Post date:** [November 17, 2024, 11:48am UTC](https://discourse.gstreamer.org/t/questions-regarding-hlscmafsink-latency-optimization/3590/1 "2024-11-17T11:48:38Z")

</div>

Hello GStreamer Community,

I’m exploring `hlscmafsink` for my HLS live streaming setup, aiming for ultra-low latency. I have a few questions:

1. How does `hlscmafsink` help reduce startup latency compared to `hlssink`? Are there specific features that optimize for faster playback start times?

2. Since CMAF packets can be sent during segment creation, how can we configure `hlscmafsink` to start streaming CMAF fragments immediately as they are generated? Are there specific parameters or pipeline setups required to enable this?

3. What is the minimal startup latency achievable using `hlscmafsink`, assuming segments and playlists are configured optimally (e.g., 1-second segment duration, low buffer size)?

Any insights or best practices for using `hlscmafsink` effectively for low-latency streaming would be greatly appreciated.

Thank you!

---

<div class="post-metadata">

**Author:** ![sudanix](https://discourse.gstreamer.org/letter_avatar_proxy/v4/letter/s/ed8c4c/32.png) [@sudanix](https://discourse.gstreamer.org/u/sudanix)\
**Post date:** [November 19, 2024, 8:32am UTC](https://discourse.gstreamer.org/t/questions-regarding-hlscmafsink-latency-optimization/3590/2 "2024-11-19T08:32:11Z")

</div>

as I understand `hlscmafsink` produce normal HLS manifest (not LL-HLS) with CMAF fmp4 fragments instead of MPEG-TS (.ts)

for LL-HLS you might need to generate the manifest yourself using `cmafmux` which support chunked fragments.

There is an example of generate HLS manifest using `cmafmux` might help. [link](https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/blob/main/mux/fmp4/examples/hls_live.rs)
