TeamNewPipe / TeamNewPipe/NewPipeExtractor
Improve handling of HLS/DASH/Progressive HTTP streaming data
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 2k
- Forks
- 602
- Avg merge
- 3d 6h
- Merged PRs (30d)
- 6
Description
Followup issue of #810
Currently
Streamis dependent on service specific stuff (like YT's itag). This is a big problem because sooner or later this class will blow up. It's already confusing enough and this PR makes it worse by adding stuff for the delivery/transmission-method (currently the Stream class can only contain progressive HTTP streaming data).It's also currently hard to say which service uses which type of streaming and it's not possible to use different delivery methods for the same stream (not sure if this is possible/useful in the first place...).
Also when looking at the PR for NewPipe: We can't just create a specific playbackresolver/mediasource foreach stream type or service, that will be unmaintainable in the long run.
My ideas how to resolve these problems:
What should be fixed anyway
- isVideoOnly inside VideoStream should be removed. It's either a
VideoStreamor aAudioStreamor aVideoAudioStreamwhich contains the data of both.- Move the YT specific stuff out of the stream classes. Example resolution could be a
YouTubeVideoStreamwhich extendsVideoStream. However this may be solved (see below) in an even better way.- I'm not sure how SubtitleStream is supposed to fit into the below constructs, there may be changes required. As far as I have seen subtitles can be delivered e.g. via DASH or in other ways.
Idea 1
Move everything that is delivery specific from
Stream-like classes to a separateStreamDeliveryData-like classes:
Example proposal:
Idea 2
If - due to currently unknown reasons to me - it's not possible to do Idea 1 we could - instead of nesting (as done in Idea 1)
StreamDeliveryDataintoStream- simply create them side by side and derive the corresponding implementations from them.
Example proposal:
Overview how the delivery methods work:

Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the existing Stream, VideoStream, AudioStream, VideoAudioStream, and SubtitleStream classes, starting with the concerns described in PR #810. Compare the two proposed StreamDeliveryData designs and the delivery-method overview before choosing an architecture. Done means service-specific data and delivery-method handling are separated without breaking the supported streaming types.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100

