Open lukepighetti opened 4 years ago
Reclassifying as a feature request.
There is currently no feature to test whether the current item is a live stream.
We will include this as metadata along with the URL when setting up a track. Feel free to close if you feel this is reasonable.
I'll keep this open for now since I think it would be a useful API to add some time down the line.
This seems to work for me on Android:
StreamBuilder<Duration>(
stream: _player.durationStream,
builder: (context, snapshot) {
final isLive = (snapshot?.data ?? Duration.zero) == Duration.zero;
On iOS, when you add a livestream url, the duration is null. But on Android it's 1 minute. How do we detect if the current url is a livestream or not?