Merge pull request #31 from linuxserver/nightly-hwdecode

enable rpi hw decode, readme updates
This commit is contained in:
aptalca
2020-04-11 16:35:23 -04:00
committed by GitHub
8 changed files with 21 additions and 9 deletions

1
.github/FUNDING.yml vendored
View File

@@ -1 +1,2 @@
open_collective: linuxserver
custom: ["https://opencollective.com/jellyfin",]

2
Jenkinsfile vendored
View File

@@ -55,7 +55,7 @@ pipeline {
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
env.PULL_REQUEST = env.CHANGE_ID
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE.md ./.github/PULL_REQUEST_TEMPLATE.md'
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE.md ./.github/PULL_REQUEST_TEMPLATE.md ./root/donate.txt'
}
script{
env.LS_RELEASE_NUMBER = sh(

View File

@@ -83,6 +83,7 @@ docker create \
-v /path/to/movies:/data/movies \
-v /opt/vc/lib:/opt/vc/lib `#optional` \
--device /dev/dri:/dev/dri `#optional` \
--device /dev/vc-mem:/dev/vc-mem `#optional` \
--device /dev/vchiq:/dev/vchiq `#optional` \
--device /dev/video10:/dev/video10 `#optional` \
--device /dev/video11:/dev/video11 `#optional` \
@@ -118,6 +119,7 @@ services:
- 8920:8920 #optional
devices:
- /dev/dri:/dev/dri #optional
- /dev/vc-mem:/dev/vc-mem #optional
- /dev/vchiq:/dev/vchiq #optional
- /dev/video10:/dev/video10 #optional
- /dev/video11:/dev/video11 #optional
@@ -142,6 +144,7 @@ Container images are configured using parameters passed at runtime (such as thos
| `-v /data/movies` | Media goes here. Add as many as needed e.g. `/data/movies`, `/data/tv`, etc. |
| `-v /opt/vc/lib` | Path for Raspberry Pi OpenMAX libs *optional*. |
| `--device /dev/dri` | Only needed if you want to use your Intel GPU for hardware accelerated video encoding (vaapi). |
| `--device /dev/vc-mem` | Only needed if you want to use your Raspberry Pi MMAL video decoding (Enabled as OpenMax H264 decode in gui settings). |
| `--device /dev/vchiq` | Only needed if you want to use your Raspberry Pi OpenMax video encoding (Bellagio). |
| `--device /dev/video10` | Only needed if you want to use your Raspberry Pi V4L2 video encoding. |
| `--device /dev/video11` | Only needed if you want to use your Raspberry Pi V4L2 video encoding. |
@@ -198,18 +201,19 @@ https://github.com/NVIDIA/nvidia-docker
We automatically add the necessary environment variable that will utilise all the features available on a GPU on the host. Once nvidia-docker is installed on your host you will need to re/create the docker container with the nvidia container runtime `--runtime=nvidia` and add an environment variable `-e NVIDIA_VISIBLE_DEVICES=all` (can also be set to a specific gpu's UUID, this can be discovered by running `nvidia-smi --query-gpu=gpu_name,gpu_uuid --format=csv` ). NVIDIA automatically mounts the GPU and drivers from your host into the jellyfin docker container.
### OpenMAX (Raspberry Pi)
### MMAL/OpenMAX (Raspberry Pi)
Hardware acceleration users for Raspberry Pi OpenMAX will need to mount their /dev/vchiq video device inside of the container and their system OpenMax libs by passing the following options when running or creating the container:
Hardware acceleration users for Raspberry Pi MMAL/OpenMAX will need to mount their `/dev/vc-mem` and `/dev/vchiq` video devices inside of the container and their system OpenMax libs by passing the following options when running or creating the container:
```
--device=/dev/vc-mem:/dev/vc-mem
--device=/dev/vchiq:/dev/vchiq
-v /opt/vc/lib:/opt/vc/lib
```
### V4L2 (Raspberry Pi)
Hardware acceleration users for Raspberry Pi V4L2 will need to mount their /dev/video1X devices inside of the container by passing the following options when running or creating the container:
Hardware acceleration users for Raspberry Pi V4L2 will need to mount their `/dev/video1X` devices inside of the container by passing the following options when running or creating the container:
```
--device=/dev/video10:/dev/video10
--device=/dev/video11:/dev/video11
@@ -287,6 +291,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
## Versions
* **11.04.20:** - Enable hw decode (mmal) on Raspberry Pi, update readme instructions, add donation info, create missing default transcodes folder.
* **11.03.20:** - Add v4l2 support on Raspberry Pi; remove optional transcode mapping (location is selected in the gui, defaults to path under `/config`).
* **30.01.20:** - Add nightly tag.
* **09.01.20:** - Add Pi OpenMax support.

View File

@@ -25,3 +25,5 @@ repo_vars:
- CI_DOCKERENV='TZ=US/Pacific'
- CI_AUTH='user:password'
- CI_WEBPATH=''
sponsor_links:
- { name: "Jellyfin", url: "https://opencollective.com/jellyfin" }

View File

@@ -43,6 +43,7 @@ opt_param_volumes:
opt_param_device_map: true
opt_param_devices:
- { device_path: "/dev/dri", device_host_path: "/dev/dri", desc: "Only needed if you want to use your Intel GPU for hardware accelerated video encoding (vaapi)." }
- { device_path: "/dev/vc-mem", device_host_path: "/dev/vc-mem", desc: "Only needed if you want to use your Raspberry Pi MMAL video decoding (Enabled as OpenMax H264 decode in gui settings)." }
- { device_path: "/dev/vchiq", device_host_path: "/dev/vchiq", desc: "Only needed if you want to use your Raspberry Pi OpenMax video encoding (Bellagio)." }
- { device_path: "/dev/video10", device_host_path: "/dev/video10", desc: "Only needed if you want to use your Raspberry Pi V4L2 video encoding." }
- { device_path: "/dev/video11", device_host_path: "/dev/video11", desc: "Only needed if you want to use your Raspberry Pi V4L2 video encoding." }
@@ -77,18 +78,19 @@ app_setup_block: |
We automatically add the necessary environment variable that will utilise all the features available on a GPU on the host. Once nvidia-docker is installed on your host you will need to re/create the docker container with the nvidia container runtime `--runtime=nvidia` and add an environment variable `-e NVIDIA_VISIBLE_DEVICES=all` (can also be set to a specific gpu's UUID, this can be discovered by running `nvidia-smi --query-gpu=gpu_name,gpu_uuid --format=csv` ). NVIDIA automatically mounts the GPU and drivers from your host into the jellyfin docker container.
### OpenMAX (Raspberry Pi)
### MMAL/OpenMAX (Raspberry Pi)
Hardware acceleration users for Raspberry Pi OpenMAX will need to mount their /dev/vchiq video device inside of the container and their system OpenMax libs by passing the following options when running or creating the container:
Hardware acceleration users for Raspberry Pi MMAL/OpenMAX will need to mount their `/dev/vc-mem` and `/dev/vchiq` video devices inside of the container and their system OpenMax libs by passing the following options when running or creating the container:
```
--device=/dev/vc-mem:/dev/vc-mem
--device=/dev/vchiq:/dev/vchiq
-v /opt/vc/lib:/opt/vc/lib
```
### V4L2 (Raspberry Pi)
Hardware acceleration users for Raspberry Pi V4L2 will need to mount their /dev/video1X devices inside of the container by passing the following options when running or creating the container:
Hardware acceleration users for Raspberry Pi V4L2 will need to mount their `/dev/video1X` devices inside of the container by passing the following options when running or creating the container:
```
--device=/dev/video10:/dev/video10
--device=/dev/video11:/dev/video11
@@ -97,6 +99,7 @@ app_setup_block: |
# changelog
changelogs:
- { date: "11.04.20:", desc: "Enable hw decode (mmal) on Raspberry Pi, update readme instructions, add donation info, create missing default transcodes folder." }
- { date: "11.03.20:", desc: "Add v4l2 support on Raspberry Pi; remove optional transcode mapping (location is selected in the gui, defaults to path under `/config`)." }
- { date: "30.01.20:", desc: "Add nightly tag." }
- { date: "09.01.20:", desc: "Add Pi OpenMax support." }

1
root/donate.txt Normal file
View File

@@ -0,0 +1 @@
Jellyfin: https://opencollective.com/jellyfin

View File

@@ -2,7 +2,7 @@
# create directories
mkdir -p \
/config/{log,data,cache} \
/config/{log,data/transcodes,cache} \
/data \
/transcode

View File

@@ -1,6 +1,6 @@
#!/usr/bin/with-contenv bash
FILES=$(find /dev/dri /dev/dvb /dev/vchiq /dev/video1? -type c -print 2>/dev/null)
FILES=$(find /dev/dri /dev/dvb /dev/vchiq /dev/vc-mem /dev/video1? -type c -print 2>/dev/null)
for i in $FILES
do