Skip to content

Provide ForwardingMediaSource to simplify custom implementations #7279

Closed
@stari4ek

Description

@stari4ek

[REQUIRED] Use case description

Current implementation of HlsMediaSource starts with default position:

We attempt to set the default start position to be at least twice the target duration behind the live edge.

So, if HLS has lots of segments or they are long enough - default start position will be pretty far from it's 0. This is desired behavior when playing "live" media.
But, for example, "catchup" of IPTV services is implemented in the way, when url identifies specific time (wall clock), and when player starts playback - it should start from 0 instead of "live edge" to match target wall clock.

Alternatives considered

I have tried:

Proposed solution

I have tried:

I think that some functionality can be provided by library itself:

  • fully functional CustomStartPositionSource
  • or at least easy-to-extend delegating media source. Otherwise CompositeMediaSource should be used (the same as it's used by ClippingMediaSource), which looks a bit of overkill.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions