diff --git a/configs/weston.ini b/configs/weston.ini index 8d968c395e004a9c853dbe3b7f124ce91a6b9df0..88f072608acca8fb766cf6ecc0fc5720a345ef89 100644 --- a/configs/weston.ini +++ b/configs/weston.ini @@ -6,6 +6,10 @@ renderer=gl require-input=false xwayland=false +[shell] +background-type=scale +background-image=/opt/voc/assets/bg1080.png + [output] name=HDMI-A-5 transform=normal diff --git a/install.sh b/install.sh index f3dad3e7bea4d1f4e89d737d1243440fd1f1b38d..44569ae7eccf4ec68e7849c7e178c98e56b9e69e 100644 --- a/install.sh +++ b/install.sh @@ -27,12 +27,15 @@ apt install -y \ usermod -aG audio voc usermod -aG render voc usermod -aG video voc +usermod -aG weston-launch voc ln -s /opt/voc/configs/udev.rules /etc/udev/rules.d/v4l2-voc.rules ln -s /opt/voc/services/voctomix2-recording-sink.service /etc/systemd/system/voctomix2-recording-sink.service ln -s /opt/voc/services/voctomix2-streaming-sink.service /etc/systemd/system/voctomix2-streaming-sink.service ln -s /opt/voc/services/voctomix2-voctocore.service /etc/systemd/system/voctomix2-voctocore.service +ln -s /opt/voc/services/weston.service /etc/systemd/system/weston.service systemctl enable voctomix2-recording-sink.service systemctl enable voctomix2-streaming-sink.service systemctl enable voctomix2-voctocore.service +systemctl enable weston.service \ No newline at end of file diff --git a/services/voctomix2-voctocore.service b/services/voctomix2-voctocore.service index eb49c75e282ca97862dbf0033df3f54e7db56bdc..c9a54cf025c103ea396a47a1b3f011836bb19dd7 100644 --- a/services/voctomix2-voctocore.service +++ b/services/voctomix2-voctocore.service @@ -1,13 +1,15 @@ [Unit] Description=voctomix2 core -After=network.target +After=weston.service network.target [Service] User=voc Group=voc Type=notify WorkingDirectory=/opt/voc/voctomix -ExecStart=/opt/voc/voctomix/voctocore/voctocore.py --ini-file /opt/voc/configs/voctocore-cam2.ini -vv +Environment=WAYLAND_DISPLAY=/run/user/1000/wayland-1 +Environment=XDG_RUNTIME_DIR=/run/user/1000 +ExecStart=/opt/voc/voctomix/voctocore/voctocore.py --ini-file /opt/voc/configs/voctocore-cam2.ini --pipeline -vv Restart=always RestartSec=1s StartLimitInterval=0 diff --git a/services/weston.service b/services/weston.service new file mode 100644 index 0000000000000000000000000000000000000000..e4d3b6c0ef7dbb22c36c0625d8c80d1918e00cca --- /dev/null +++ b/services/weston.service @@ -0,0 +1,21 @@ +[Unit] +Description=Weston Wayland compositor startup +After=systemd-user-sessions.service + +[Service] +Type=simple +Environment=XDG_SESSION_TYPE=wayland +User=voc +PAMName=login +TTYPath=/dev/tty7 +TTYReset=yes +TTYVHangup=yes +TTYVTDisallocate=yes +StandardInput=tty-fail +StandardError=journal +UtmpIdentifier=tty7 +UtmpMode=user +ExecStart=/usr/bin/weston --config /opt/voc/configs/weston.ini + +[Install] +WantedBy=multi-user.target