Site Tools


Hotfix release available: 2024-02-06a "Kaos". upgrade now! [55.1] (what's this?)
New release available: 2024-02-06 "Kaos". upgrade now! [55] (what's this?)
piplus

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
piplus [2021/02/16 17:09] 46.223.163.46piplus [2022/03/11 21:11] (current) – old revision restored (2021/10/14 17:01) 216.244.66.242
Line 1: Line 1:
 +wayvnc needs pi repo
 +<code bash>
 +pacman -S weston wayvnc signal-desktop dmenu xorg-xwayland
 +WLR_BACKENDS=headless WLR_LIBINPUT_NO_DEVICES=1 sway
 +wayvnc 0.0.0.0
 +</code>
 +open vnc port
 +<code bash>
 +wf-recorder --muxer=v4l2 --codec=rawvideo --pixel-format=yuv420p --file=/dev/video0
 +wf-recorder --muxer=v4l2 -f /dev/video4 -c rawvideo -x yuyv422
 +</code>
  
 +<code bash>
 +ffmpeg -loop 1 -i image.jpg -i audio.mp3 -shortest -c:v libx264 -c:a copy result.mkv
 +ffmpeg -loop 1 -i image.jpg -i audio.mp3 -vf "drawtext=text='My text starting at 640x360':x=640:y=360:fontsize=24:fontcolor=white" -shortest -c:v libx264 -c:a copy result.mkv 
 +</code>
 +
 +<code bash>
 +pacman -S linux-headers v4l2loopback-dkms wf-recorder
 +modprobe v4l2loopback devices=1 max_buffers=2 exclusive_caps=1 card_label="VirtualCam"
 +gpasswd -a onny video
 +pactl load-module module-pipe-source source_name=virtmic file=/home/onny/virtmic format=s16le rate=16000 channels=1
 +pactl set-default-source virtmic
 +ffmpeg -re -i piplus/result.mkv -map 0:v -vf format=yuv420p -f v4l2 /dev/video0 -map 0:a -f s16le -ar 16000 -ac 1 - > virtmic
 +</code>
 +
 +  * https://github.com/signalapp/Signal-Desktop/blob/6e7930f7a983ff9a61ada1bd8feb32c57132c7b1/components/recorderjs/recorderWorker.js
 +  * ringRTC https://github.com/signalapp/Signal-Desktop/blob/a173a9b33ff8dccbe02b9ad2d5e268ca3b036563/ts/services/calling.ts
 +  * webrtc https://github.com/signalapp/webrtc/pull/47
 +  * https://github.com/signalapp/webrtc/search?q=CBR
 +  * https://github.com/signalapp/webrtc/pull/42/commits/4fcfb70705e71dfb86a343b5e31e90e2c675ae2a
 +
 +  - build https://github.com/signalapp/ringrtc
 +    - set max_bitrate_bps in https://github.com/signalapp/ringrtc/blob/653757074949f48ff1e4c1490550932cea3276ea/src/rust/src/webrtc/media.rs
 +  - somehow put binary into https://github.com/signalapp/signal-ringrtc-node/commits/master/build/linux/libringrtc.node
 +  - use custom signal-ringrtc-node in signal-desktop
 +
 +<code bash>
 +git clone https://github.com/signalapp/ringrtc.git
 +rustup toolchain install 1.49.0
 +rustup default 1.49.0
 +pacman -S depot-tools-git
 +export PATH="/opt/depot_tools:$PATH"
 +cd ringrtc
 +make electron PLATFORM=unix
 +</code>
 +<file>
 +diff --git a/src/rust/src/webrtc/media.rs b/src/rust/src/webrtc/media.rs
 +index ee1f3e0..8e5eadb 100644
 +--- a/src/rust/src/webrtc/media.rs
 ++++ b/src/rust/src/webrtc/media.rs
 +@@ -483,10 +483,10 @@ impl Default for AudioEncoderConfig {
 +         Self {
 +             packet_size_ms: 20,
 + 
 +-            bandwidth: AudioBandwidth::Auto,
 ++            bandwidth: AudioBandwidth::Wide,
 + 
 +             start_bitrate_bps: 40000,
 +-            min_bitrate_bps:   16000,
 ++            min_bitrate_bps:   40000,
 +             max_bitrate_bps:   40000,
 +             complexity:        9,
 +             enable_cbr:        true,
 +</file>
 +<code>
 +git clone https://github.com/signalapp/signal-ringrtc-node.git
 +cd signal-ringrtc-node
 +ln -s /home/onny/projects/ringrtc/src/node/build/linux/libringrtc.node build/linux/libringrtc.node
 +</code>
 +  * force high bitrate https://github.com/signalapp/ringrtc/blob/653757074949f48ff1e4c1490550932cea3276ea/src/rust/src/core/bandwidth_mode.rs#L84
 +  * stereo avg bitrate https://github.com/signalapp/ringrtc/blob/653757074949f48ff1e4c1490550932cea3276ea/src/rffi/src/peer_connection.cc
 +  * log: set max send bitrate to datarate, size_per_second, datasize, bits 1024
 +
 +===== new =====
 +<code bash>
 +sudo systemctl stop nftables
 +nft flush ruleset
 +export WLR_BACKENDS=headless
 +export WLR_LIBINPUT_NO_DEVICES=1
 +export WAYLAND_DISPLAY=wayland-1
 +export XDG_RUNTIME_DIR=/tmp
 +export XDG_SESSION_TYPE=wayland
 +sway &
 +wayvnc 0.0.0.0
 +pacman -Q signal-desktop sway-git wlroots-git
 +signal-desktop 5.19.0-1
 +sway-git r6794.f4db502d-1
 +wlroots-git 0.14.0.r293.gdc22a061-1
 +</code>
piplus.txt · Last modified: 2022/03/11 21:11 by 216.244.66.242