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

Remove non-profile usages of DeviceUtils #3425

Merged
merged 1 commit into from
Mar 3, 2024

Conversation

nielsvanvelzen
Copy link
Member

We've been getting too comfortable using device identifiers to run specific code paths. This is a bad practice (just like user agent testing) and we should use feature testing instead.

Changes

  • Always use downmix to stereo as default audio behavior (previously only on GTV)
  • Always enable AC3 by default (previously only on everything except fire tv stick gen 1)
  • Remove Android 6 check for refresh rate switching. It is disabled by default anyway so just don't use it (if you're one of our ten users running this old Android version)
  • Remove some Fire TV specific behavior for initializing LibVLC

Issues

Fixes #3418

@nielsvanvelzen nielsvanvelzen added the enhancement New feature or request label Mar 3, 2024
@nielsvanvelzen nielsvanvelzen added this to the v0.17.0 milestone Mar 3, 2024
@@ -98,7 +97,7 @@ class UserPreferences(context: Context) : SharedPreferenceStore(
/**
* Preferred behavior for audio streaming.
*/
var audioBehaviour = enumPreference("audio_behavior", defaultAudioBehavior)
var audioBehaviour = enumPreference("audio_behavior", AudioBehavior.DOWNMIX_TO_STEREO)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this default to direct stream?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've opted to enable downmixing by default as it basically just a fancy toggle for a bunch of audio codecs that a lot of devices do not support. Ideally we'd query the system whether each of them is supported or not but I'm not maintaining the old profile code, if someone else comes in to fix that I'll glady accept the PR.

@MichaelRUSF
Copy link
Contributor

  • Always use downmix to stereo as default audio behavior (previously only on GTV)

This will cause unnecessary transcoding as the default behavior. IMO it should be kept the way it is.

@nielsvanvelzen nielsvanvelzen merged commit 35f274f into jellyfin:master Mar 3, 2024
5 checks passed
@nielsvanvelzen nielsvanvelzen deleted the reduce-device-utils branch March 3, 2024 18:55
@nathansmeal
Copy link

  • Always use downmix to stereo as default audio behavior (previously only on GTV)

This will cause unnecessary transcoding as the default behavior. IMO it should be kept the way it is.

AFAIK this would only require audio remuxing, which is not resource intensive as video transcoding, and even integrated CPU graphics can handle this with ease.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Request to change the default Android TV audio output setting to "Downmix to Stereo"
4 participants