This also applies to `saver_mplayer`, hence the more generic name.
Unified · Split
| @@ -411,6 +411,8 @@ Options to XSecureLock can be passed by environment variables: · 410 unmodified lines | ||
| 411 | 411 | `Ctrl-Alt-O` are pressed (think "_other_ user"). Typical values could be |
| 412 | 412 | `lxdm -c USER_SWITCH`, `dm-tool switch-to-greeter`, `gdmflexiserver` or |
| 413 | 413 | `kdmctl reserve`, depending on your desktop environment. |
| 414 | +* `XSECURELOCK_VIDEOS_FLAGS`: flags to append when invoking mpv/mplayer with | |
| 415 | + `saver_mpv` or `saver_mplayer`. Defaults to empty. | |
| 414 | 416 | * `XSECURELOCK_WAIT_TIME_MS`: Milliseconds to wait after dimming (and before |
| 415 | 417 | locking) when above xss-lock command line is used. Should be at least as |
| 416 | 418 | large as the period time set using "xset s". Also used by `wait_nonidle` to |
| @@ -15,6 +15,7 @@ · 14 unmodified lines | ||
| 15 | 15 | # limitations under the License. |
| 16 | 16 | |
| 17 | 17 | : ${XSECURELOCK_LIST_VIDEOS_COMMAND:=find ~/Videos -type f} |
| 18 | +: ${XSECURELOCK_VIDEOS_FLAGS:=} | |
| 18 | 19 | |
| 19 | 20 | sh -c "$XSECURELOCK_LIST_VIDEOS_COMMAND" | shuf | head -n 256 |\ |
| 20 | 21 | @path_to_mplayer@ \ |
| @@ -26,4 +27,5 @@ sh -c "$XSECURELOCK_LIST_VIDEOS_COMMAND" | shuf | head -n 256 |\ · 5 unmodified lines | ||
| 26 | 27 | -fixed-vo \ |
| 27 | 28 | -nosound \ |
| 28 | 29 | -shuffle \ |
| 30 | + ${XSECURELOCK_VIDEOS_FLAGS} \ | |
| 29 | 31 | -playlist - |
| @@ -16,6 +16,7 @@ · 15 unmodified lines | ||
| 16 | 16 | |
| 17 | 17 | : ${XSECURELOCK_LIST_VIDEOS_COMMAND:=find ~/Videos -type f} |
| 18 | 18 | : ${XSECURELOCK_IMAGE_DURATION_SECONDS:=1} |
| 19 | +: ${XSECURELOCK_VIDEOS_FLAGS:=} | |
| 19 | 20 | |
| 20 | 21 | # Run mpv in a loop so we can quickly restart mpv in case it exits (has shown |
| 21 | 22 | # the last picture/video). |
| @@ -30,6 +31,7 @@ while true; do · 8 unmodified lines | ||
| 30 | 31 | --image-display-duration="${XSECURELOCK_IMAGE_DURATION_SECONDS}" \ |
| 31 | 32 | --shuffle \ |
| 32 | 33 | --loop-playlist=inf \ |
| 34 | + ${XSECURELOCK_VIDEOS_FLAGS} \ | |
| 33 | 35 | --playlist=- & |
| 34 | 36 | # Avoid spinning if mpv exits immediately, but don't wait to restart mpv in |
| 35 | 37 | # the common case. |