Commit graph

46 commits

Author SHA1 Message Date
Damontecres
271cb0ca20
Merge branch 'main' into fea/libass-android-support 2026-03-05 20:39:21 -05:00
Ray
0004701296
Dev: add simple automated UI test setup (#1027)
## Description
This PR is mostly a proof-of-concept for setting up automated UI
testing. The tests use Roboelectric so they can run without an emulator.
There is also a sample instrumented test for running on emulators or
devices for future tests.

It adds two basic automated UI tests for adding a server. These are sort
integration tests because they use the actual implementations for the
view model and services like `ServerRepository` and `JellyfinServerDao`.

Also, moves the bulk of `MainActivity`'s compose code into a function
for future tests.

### Related issues
N/A

### Testing
Local testing

## Screenshots
N/A

## AI or LLM usage
None
2026-03-03 13:46:46 -05:00
Ray
7424f812d8
Dev: add CI to build app store releases (#468)
Adding GHA workflows to build the app store releases

Also cleans up gradle build script a bit
2026-02-23 22:04:08 -05:00
Ray
aa69646b2d
Upgrade AGP to 9.x (#892)
## Description
This PR has no user facing changes.

Upgrade AGP to 9.x and Gradle to 9.x. Also updates some dependencies as
well.

Note: still using deprecated `android.newDsl=false` because the protobuf
plugin is not yet compatible:
https://github.com/google/protobuf-gradle-plugin/issues/793.

### Related issues
N/A

### Testing
Emulator

## Screenshots
N/A

## AI or LLM usage
None
2026-02-13 14:49:19 -05:00
Ray
b06761eaa5
Rewrite SuggestionsCache & limit parallelism (#851)
## Description
A rewrite of the `SuggestionsCache` to simplify it as a read-through
cache. The downside of this is that updated suggestions won't be
reflected in the UI unless the user reloads the page, but I think that's
an okay trade off.

Also adds parallelism limits to fetching suggestions to reduce the
number of simultaneous API calls. And moved the combining logic to use
the `Default` dispatcher to free up an IO one.

Also adds an initial delay to both the suggestions & tv provider
workers, so a cold start of the app isn't starved.

### Related issues
Related to #849

### Testing
Emulator & unit testing

## Screenshots
N/A

## AI or LLM usage
None
2026-02-09 17:39:40 -05:00
Justin Caveda
aeaecc0f59
Fix suggestions mixing content from different libraries and update recommendation logic (#644)
## Description
This PR aims to fix #638 where the "Suggestions" row was mixing up
content from different libraries that shared the same library type. For
example you were in the Anime library, you'd see regular TV shows
showing up, as the TV Shows and Anime libraries would both be "Show"
libraries.

As @damontecres mentioned in the issue discussion, the
`/Items/Suggestions` endpoint Wholphin is using just returns random
items from the same library type, with no special logic or
recommendation algorithm.

I also looked at how the official WebUI handles this. It basically just
mixes "Resume," "Next Up," and "Latest Items" together. That felt a bit
redundant since we usually have dedicated rows for those things anyway;
I wanted to try something that helps discover new content.

I replaced the broken endpoint with a few custom `GetItemsRequest`
calls. These work correctly with the `ParentId` filter, so we only get
results from the library we are actually looking at. Additionally, I
added in some logic that takes into account what the user has been
watching to tailor the suggestions a little bit.

The new logic uses a 40/30/30 mix (this can of course be tweaked as
needed)

- Tailored (40%): Grabs your recently watched items from this library,
checks their genres, and returns items from the same genre.

- Random (30%): Random unwatched stuff from this library.

- New (30%): Recently added items.

This is implemented using only `GetItemsRequest` API calls using
filters, rather than any specialized endpoints like the
`/Items/Suggestions` endpoint. This means the feature should be
predictable and stable. If Jellyfin ever adds an actual recommendation
algorithm and endpoint to call it, I imagine we would want to switch to
that in the future though.

I also added some failsafe logic to make sure there will be diversity in
the "recently watched" items that get pulled, in case a user might have
recently binged a TV show. We wouldn't want every single recommendation
to be based off of that one show.

To fix this, I changed the query to fetch the last 20 history items
instead of just the top 3. Then, we filter that list client-side to find
unique Series IDs. If the user watched 10 episodes of One Piece in a
row, the logic collapses them into a single "One Piece" entry and moves
on to the next distinct show they watched. This guarantees we get
variety in the source material for recommendations.

This is a work in progress right now, mainly due to performance. For my
server it takes about 10-15 seconds to load the Suggestions row when I
tested. This is unacceptable in my opinion, especially if we ever intend
to add a Suggestions row like this to the home page like Plex does. I
have some ideas on how to improve performance, but I'm open to
suggestions.

### Related issues
Resolves #638 

### Screenshots

Before:

<img width="1953" height="1162" alt="suggestions1"
src="https://github.com/user-attachments/assets/6e301c67-1a46-46b5-8184-3adb9e52b330"
/>


After:

<img width="1937" height="1108" alt="suggestions3"
src="https://github.com/user-attachments/assets/b9563865-4055-40b6-b452-f94c26c8b6e9"
/>


### AI/LLM usage
I used Claude Code to help write the Kotlin Coroutines so the API calls
run at the same time. I also used it to write the tests in
`TestSuggestionsLogic.kt`.

---------

Co-authored-by: Damontecres <damontecres@gmail.com>
2026-02-04 20:50:29 -05:00
Ray
d9d5ab02e8
Add support for viewing photos in photo albums (#703)
## Description
Add support for viewing photos in photo albums

### Features
- Browse and view albums & photos
- View an album as a slideshow
- Show overlay with photo details and controls
- Rotate, zoom, & pan photos
- Apply basic filters to photos or albums such as contrast, saturation,
red/green/blue, etc
- Setting to include video clips during slideshows

### Controls
- D-Pad left or right: scroll between photos in album
- Hold D-Pad up or down: zoom in or out of the current photo
- D-Pad left/right/up/down, while zoomed: pan around photo
- Back, while zoomed: revert the zoom
- Otherwise: show photo overlay

### Related issues
Closes #458
Closes #634

### Screenshots
#### Overlay
![photo_overlay
Large](https://github.com/user-attachments/assets/b44ed876-d8bd-4f75-aa1e-4106c2edb2f7)

#### Applying filters
![photo_filters
Large](https://github.com/user-attachments/assets/1379978a-b27c-47ac-80af-f7bb6a2177df)
2026-02-04 20:04:46 -05:00
Damontecres
6f17abce3a
Merge branch 'main' into fea/libass-android-support 2026-01-18 19:16:18 -05:00
Ray
4dd44b935c
Add optional AV1 software decoding via dav1d for ExoPlayer (#721)
## Description
Adds the [`dav1d` decoder
module](https://github.com/androidx/media/tree/release/libraries/decoder_av1)
for ExoPlayer as an option. It can be enabled in advanced settings.

Performance will vary between devices.

### Related issues
Closes #103

### Dev notes

As with the ffmpeg module, this one is not required to build the entire
app so it's easier for developers to get started.

This also introduces a customized `DefaultRenderersFactory` for
ExoPlayer, but its largely copied from the super class's implementation.
2026-01-18 18:35:41 -05:00
Justin Caveda
d725821011
[FEAT] Add voicesearch button to search page (#637)
## Description
This PR is a rewrite of a previously submitted PR for this same feature.
It implements native Voice Search for Android TV using Android's
SpeechRecognizer API.

Key Changes

  New Files:
- VoiceInputManager.kt - Handles SpeechRecognizer lifecycle, permission
management, and audio level normalization
- VoiceSearchButton.kt - Composable button with audio-reactive pulse and
full-screen listening dialog

  UI/UX:
  - Audio-reactive microphone button that pulses based on input volume
  - Full-screen listening overlay with animated states:
- Listening - Pulsing bubble with ripple rings, shows partial
transcription
    - Processing - Animated dots while waiting for final result
- Error - Red bubble with localized error message, auto-dismisses after
3s

### Related issues
Resolves https://github.com/damontecres/Wholphin/issues/515

### AI/LLM usage
The initial draft of this change from the prior PR was created with the
assistance of Claude Code, which was heavily leaned on for the overlay.
I have taken the initial draft, gone through it, and re-implemented by
hand to clean it up, narrow the scope (AI loves to touch and change
things unrelated to what you're working on) and make it more readable.
AI was used in the last stage to assist with finding any logic
errors/bugs I may have missed (by looking through code and also by
looking over ADB logs from testing on Nvidia Shield).. AI was also used
to create the tests found in TestVoiceInputManager.kt. Lastly, I fed the
diffs to an AI to help summarize the changes for this PR in an easy to
read manner.

---------

Co-authored-by: Damontecres <damontecres@gmail.com>
2026-01-14 17:06:22 -05:00
Ray
4c7c465c67
Add integration with Jellyseerr/Seerr (#558)
## Description
This PR add the ability to integrate with a [Jellyseerr/Seerr
server](https://github.com/seerr-team/seerr).

### Features
- Login to the Seerr server using API Key, Jellyfin credentials, or
local Seerr credentials
    - Separate Seerr logins per user profile
- Search Seerr from the search page
- Discover media from Seerr on the nav drawer `Discover` page
    - Also from movie, series, or person pages
- Seamless integration with existing media, i.e. selecting media found
from Seerr that already exists on the Jellyfin server, will go directly
to the regular media page
- Mostly consistent UI between Jellyfin media & Seerr media
- Submit requests to Seerr
- Cancel submitted requests

### Screenshots

![discover](https://github.com/user-attachments/assets/f830b48f-e2f1-43f4-9680-9c6d4e071765)

### Related issues
Closes #54

## Acknowledgements

The `app/src/main/seerr/seerr-api.yml` file is copied & modified from
https://github.com/seerr-team/seerr/blob/develop/seerr-api.yml. I hope
to try to upstream some of the changes in the future.
2026-01-12 16:35:27 -05:00
Ray
b78f5fcc77
Better support for remote media (HLS/DASH) (#675)
## Description
Check if playback is for a remote source and, if so, play that remote
URL directly. Works for both ExoPlayer & MPV.

Also adds support for direct playback for DASH in ExoPlayer.

### Related issues
Closes #471
Closes #666
2026-01-11 19:43:21 -05:00
Ray
49740c47cf
Create media session during playback allowing for external control (#640)
## Description
Creates a `MediaSession` during playback which allows for external
control such as via smart speakers, Google Home app, etc

Note: one limitation is that seeking previous/next items in the playlist
isn't supported. This is because Wholphin manages that independent of
the `Player`, so additional dev work is needed for this.

### Related issues
Closes #622
Might help with #415
2026-01-07 12:49:43 -05:00
Ray
9ae4965c2a
Add resume/continue watching items to Android TV watch next row (#372)
## Details

Adds resume and continue watching items for the logged in user to the
Android TV OS level watch next "channel"
(https://developer.android.com/training/tv/discovery/watch-next-add-programs).

## Issues
Closes #206
Related to #581
2025-12-27 15:40:45 -05:00
Ray
494ff07b72
Fix smart & default subtitle selection logic (#579)
## Description
Fixes the logic for subtitle selection when using `Smart` or `Default`
server modes. Also takes into account unknown languages.

This is heavily inspired by [the server selection
logic](https://github.com/jellyfin/jellyfin/blob/release-10.11.z/Emby.Server.Implementations/Library/MediaStreamSelector.cs).
For better or for worse, Wholphin implements this client side.

### Related issues
Fixes #570
2025-12-27 14:22:40 -05:00
Damontecres
09ae259887
Integrate with libass-android 2025-12-24 17:48:29 -05:00
Justin Caveda
bcc7e660ea
Allow debug builds to to be installed alongside the stable app (#565)
## Description

This PR updates the debug build config to allow side by side
installation with the mainline/stable release by changing the app name
and app ID.

This is a convenience change to allow contributors to test debug builds
on their personal devices without overwriting the existing stable
version of the app
2025-12-24 13:31:06 -05:00
Ray
bbfbc13532
Backdrop improvements (#476)
## Description

The backdrop image shown on most pages is now configurable in advanced
settings:
* Image w/ dynamic color - Shows the backdrop with dynamic color filling
the entire space (new default)
* Image only - Shows only the backdrop image (current Wholphin behavior)
* None - Don't show any backdrops

Additionally, the backdrop is retained between page loads for the same
items.

## Acknowledgements

Big thanks to @YogiBear12 from which the idea and implementation for the
dynamic color was adapted from!

Code adapted from
https://github.com/YogiBear12/Halfin/blob/main/COLOR_EXTRACTION_AND_BACKDROP.md#backdrop-fading-and-transitions

## Issues

Closes #221
Closes #461
Closes #442



https://github.com/user-attachments/assets/1acbc487-c697-44d7-89ed-e7e4c9169360
2025-12-17 11:18:57 -05:00
Damontecres
d0bfdac3bd
Fix version name from #350 2025-11-30 22:24:34 -05:00
damontecres
258c50a95e
Add support for Android TV 6 & 7.0 (#350)
Adds support for Android TV 6.0 & 7.0 by reduce the min SDK to 23. Going
below 23 isn't practical since new releases of Jetpack libs require 23+.

Also includes some clean up for better gradle syncs & actually use the
datetime APIs available from desugaring on older versions.

Needs more testing before merge

Closes #341
2025-11-30 20:26:42 -05:00
damontecres
78e6304571
Prep work for play store distribution (#301)
Allows for disabling in-app updates and more flexible tag/version codes
2025-11-22 12:57:47 -05:00
damontecres
6be2662d4e
Add experimental MPV player backend (#161)
Experimental MPV player backend

Related to #14, #22, & #85

You can switch to MPV in advanced settings and toggle using hardware
decoding or not.

This uses code and buildscripts from
https://github.com/mpv-android/mpv-android, plus other third party
libraries to build MPV
2025-11-16 18:46:25 -05:00
damontecres
4945bef008
Cache ffmpeg build (#115)
Speed up PR builds by caching the ffmpeg module build artifact
2025-10-30 14:32:07 -04:00
damontecres
3f7c2ac730
UI Updates & Fixes (#114)
Fixes #113 

- Ensures all audio and subtitle options are shown during playback
- Fix home rows not being at top when going back
- Show error message when background home page refresh fails

Also shows more details for login failures and adds a link to the debug
page (with log info) after multiple login failure attempts. Hopefully
this can help diagnose #112 and #18
2025-10-30 13:41:46 -04:00
damontecres
b1275ae210
Include ffmpeg extensions for some audio formats (#109)
Related to #103

Adds ffmpeg decoder module to support a few extra audio formats such as
AC3, EAC3, DTS, & TrueHD.

This increases the apk size by about 5.4mb (release 17.4mb->22.8mb), but
definitely worth it for the added support.
2025-10-29 20:34:41 -04:00
damontecres
06f2c1260d
Add slf4j-simple (#101)
Fixes #99 

While not an actual error, it does look like a transitive dependency of
the Jellyfin Kotlin SDK may log using slf4j, so it would be good to
include an slf4j implementation just in case.
2025-10-28 19:28:54 -04:00
damontecres
2667090485
Send crash reports to the server (#65)
Adds ability to send app crash reports to the last connected server. The
app prompts you before sending. There is an advanced settings to disable
this as well.

Additionally, there is an advanced settings button to send the app logs
to the current server.

The resulting reports can be found on the server's web UI under
Dashboard->Logs

If sharing the logs, make sure there's no private information present!
2025-10-26 07:35:42 -04:00
damontecres
05f3811149
Add Live TV & DVR Support (#49)
Closes #1 

Adds support for Live TV & DVR functionality.

TODO:
- [x] EPG / TV Guide
- [x] View DVR schedule
- [x] Play live TV channel
- [x] Record program
- [x] Record Series
- [x] Cancel recordings
- [x] Access previously recorded content
2025-10-23 22:46:16 -04:00
damontecres
177e009f8c
Format changelog in app (#51)
Formats the in-app changelog when updating

Also allows for force updating to allow for switching develop tags.
2025-10-21 19:48:19 -04:00
damontecres
e2db5ab4f3
Enable minify/proguard (#29) 2025-10-17 19:44:36 -04:00
damontecres
6194eba8c5
Remember playback choices & fix some track selection issues (#26)
Remembers changes in playback tracks across playbacks. So, if you change
the audio track, quit the app, and return to the same id, the app will
play the audio track previously chosen.

Additionally, this PR fixes a UI inconsistency when there are multiple
versions of a item. Previously sometimes the audio/subtitle tracks for
wrong version would be shown during playback.
2025-10-17 17:19:44 -04:00
Damontecres
d39ed721d5
Rebrand 2025-10-15 15:27:30 -04:00
Damontecres
d4b3c554f8
Show loading/error for large seasons 2025-10-15 13:27:48 -04:00
Damontecres
730a578117
Move NavigationManager to hilt 2025-10-08 18:13:28 -04:00
Damontecres
b63e933386
Simplify grid focus, handle items w/ missing images 2025-10-08 15:49:31 -04:00
Damontecres
c642636da7
Updates to build config for signing 2025-10-07 15:44:29 -04:00
Damontecres
8cda98d6aa
Updates to series detail page 2025-10-07 14:46:37 -04:00
Damontecres
de36eb7072
Add dependency license info 2025-10-03 19:31:50 -04:00
Damontecres
b6f9aee5d4
Dependency bumps 2025-10-02 12:15:45 -04:00
Damontecres
3e7f11c588
Minimal playback 2025-09-22 17:02:32 -04:00
Damontecres
80070f4174
Basic navigation 2025-09-22 12:09:41 -04:00
Damontecres
51ad92f539
Basic home page & images 2025-09-21 22:16:42 -04:00
Damontecres
76d78246db
Basics for user prefs, logging in, etc 2025-09-21 19:56:40 -04:00
Damontecres
763521aabf
Add hilt 2025-09-20 17:42:09 -04:00
Damontecres
b0fa3be520
Add dependencies 2025-09-20 17:06:40 -04:00
Damontecres
2d02ff4cbe
Initial app creation 2025-09-20 16:36:38 -04:00