Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] Codec selection instead of format #3159

Open
1 task done
opusforlife2 opened this issue Feb 29, 2020 · 24 comments
Open
1 task done

[Feature request] Codec selection instead of format #3159

opusforlife2 opened this issue Feb 29, 2020 · 24 comments
Labels
feature request Issue is related to a feature in the app player Issues related to any player (main, popup and background) requires extractor change This issue requires a change to the extractor

Comments

@opusforlife2
Copy link
Collaborator

  • I checked if the issue/feature exists in the latest version.

What matters is that the user should be able to select the most efficient codec if they have the required hardware decoder, or a battery friendly/non-CPU-intensive codec if they don't. The container format doesn't really matter.

So I think it would be better to offer these options in order from most efficient to least:

Video:

  • AV1 (if Android 10+)
  • VP9
  • AVC/H.264

Audio:

  • Opus
  • AAC

Can Newpipe query the OS for available hardware decoders? If so, it should select the most efficient codec by default whose hardware decoder is available.

@wb9688
Copy link
Contributor

wb9688 commented Feb 29, 2020

Our video playback should be really improved. I don't know anything about the ExoPlayer side of things though. What we should do is add all the Itags to NewPipeExtractor (i.e. TeamNewPipe/NewPipeExtractor#71, which I opened years ago, e.g. we don't extract AV1 streams at all), and properly implement DASH support. We should also indeed automatically detect what codec to use, instead of having a setting that defaults to MPEG-4

@wb9688 wb9688 added feature request Issue is related to a feature in the app requires extractor change This issue requires a change to the extractor player Issues related to any player (main, popup and background) labels Feb 29, 2020
@opusforlife2
Copy link
Collaborator Author

Any progress on this, @wb9688? I'm also interested in seeing if this possibly solves the #2934 weirdness as well.

@opusforlife2
Copy link
Collaborator Author

I don't know anything about the ExoPlayer side of things though.

@Redirion does. What say, Red?

@Redirion
Copy link
Member

I need to check, if we can obtain the name of the decoder or, probably more meaningful, the extractor score of each decoder and then select the one with the highest score as this most likely indicates an efficient decoder.

@wb9688
Copy link
Contributor

wb9688 commented Sep 10, 2020

@Redirion: While of course also keeping in mind what codecs a device supports (preferably hardware accelerated)…

@Stypox
Copy link
Member

Stypox commented Sep 30, 2020

Closing in favour of #4358

@Stypox Stypox closed this as completed Sep 30, 2020
@opusforlife2
Copy link
Collaborator Author

Reopening after discussion.

@opusforlife2 opusforlife2 reopened this Sep 30, 2020
@shockergit

This comment was marked as resolved.

@opusforlife2

This comment was marked as resolved.

@shockergit

This comment was marked as resolved.

@opusforlife2

This comment was marked as resolved.

@shockergit

This comment was marked as resolved.

@opusforlife2

This comment was marked as resolved.

@shockergit

This comment was marked as resolved.

@opusforlife2

This comment was marked as resolved.

@shockergit

This comment was marked as resolved.

@opusforlife2

This comment was marked as resolved.

@n-ce
Copy link

n-ce commented Jan 25, 2022

@opusforlife2
Can you discuss about this?

  1. Setting for UltraLow Bandwidth Audio Mode for 50kbps Opus Background Playback, I use vanced only for this one reason.
  2. Setting for Forced AV1/VP9/AVC mode , if the desired codec is not available switch to available one.

@opusforlife2
Copy link
Collaborator Author

@n-ce The app already falls back to the available container format when the default one isn't available. I don't see why this behaviour wouldn't be retained for codec selection. Regarding your second point, see #1583 (comment). ;)

@n-ce
Copy link

n-ce commented Jan 26, 2022

Reasoning is clear
For no. 1.
Data speed reduces to theoretical 64kbps (actual 55kbps), currently no other app than the youtube app itself can stream audio smoothly at that speed.
Audio playing smoothness : Youtube Background Play > Spotify data saver > Ymusic compact mode > Newpipe background play.

For no. 2.
Some people want highest quality codec playing in their phones and not care about hw support so theyd likely want av1 always. Some people want to conserve battery and hardware support in old phones theyd want AVC.

@opusforlife2
Copy link
Collaborator Author

This is implemented in Piped.

@SyCoREAPER

This comment was marked as duplicate.

@tsilvs

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Issue is related to a feature in the app player Issues related to any player (main, popup and background) requires extractor change This issue requires a change to the extractor
Projects
None yet
Development

No branches or pull requests

9 participants