Docs & move scripts

This commit is contained in:
Damontecres 2025-11-06 19:53:32 -05:00
parent dbb37012f3
commit 803167a43f
No known key found for this signature in database
4 changed files with 22 additions and 4 deletions

View file

@ -14,12 +14,13 @@ runs:
with:
path: |
app/libs
key: ${{ runner.os }}-ffmpeg-${{ hashFiles('**/libs.versions.toml', '**/build_ffmpeg_decoder.sh') }}
key: ${{ runner.os }}-ffmpeg-${{ hashFiles('**/libs.versions.toml', '**/scripts/ffmpeg/build_ffmpeg_decoder.sh') }}
- name: Build ffmpeg decoder
id: ffmpeg-decoder
if: steps.cache_ffmpeg_module.outputs.cache-hit != 'true'
shell: bash
run: |
cd scripts/ffmpeg
./build_ffmpeg_decoder.sh "${{ env.ANDROID_SDK_ROOT }}/ndk/${{ env.NDK_VERSION }}"
- name: Save ffmpeg module cache
id: cache_ffmpeg_module_save

View file

@ -25,10 +25,24 @@ After forking and cloning your fork, you can import the project into Android Stu
You need a compatible Android Studio version for the configured AGP. This is generally `Narwhal 3 Feature Drop | 2025.1.3` or newer. See https://developer.android.com/build/releases/gradle-plugin and [`libs.versions.toml](./gradle/libs.versions.toml).
### FFmpeg decoder module
### Native components
The app ships with [media3 ffmpeg decoder module](https://github.com/androidx/media/blob/release/libraries/decoder_ffmpeg/README.md).
Wholphin includes some optional native components that are compiled outside of the normal Android gradle build process.
These components are not generally required to build or test the app during development.
If you want to build any of them locally, you must have the [Android NDK](https://developer.android.com/ndk) installed.
#### FFmpeg decoder module
Wholphin ships with [media3 ffmpeg decoder module](https://github.com/androidx/media/blob/release/libraries/decoder_ffmpeg/README.md).
It is not required to build the extension in order to build the app locally.
You can build the module on MacOS or Linux with the [`./build_ffmpeg_decoder.sh`](./build_ffmpeg_decoder.sh) script. You must have the [Android NDK](https://developer.android.com/ndk) installed.
You can build the module on MacOS or Linux with the [`build_ffmpeg_decoder.sh`](./scripts/ffmpeg/build_ffmpeg_decoder.sh) script.
#### MPV player backend
Wholphin has a playback engine that uses [`libmpv`](https://github.com/mpv-player/mpv). The app uses JNI code from [`mpv-android`](https://github.com/mpv-android/mpv-android) and has an implementation of `androidx.media3.common.Player` to swap out for `ExoPlayer`.
See the [build scripts](scripts/mpv/) for details on building this component.

3
scripts/ffmpeg/README.md Normal file
View file

@ -0,0 +1,3 @@
# FFmpeg ExoPlayer decoder extension module
Builds the ffmpeg decoder extension module for `ExoPlayer` which supports extra codecs during playback.