Skip to content

Commit

Permalink
--xpra: add --encodings=rgb --video-encoders=none --csc-modules=none …
Browse files Browse the repository at this point in the history
…--opengl=yes #167
  • Loading branch information
mviereck committed Jun 29, 2019
1 parent fa1e6cc commit a3269eb
Showing 1 changed file with 14 additions and 7 deletions.
21 changes: 14 additions & 7 deletions x11docker
Original file line number Diff line number Diff line change
Expand Up @@ -418,13 +418,13 @@ verbose() { # show verbose messages
# only logfile notes here, terminal output is done with tail in part:verbose
# if $1 = -d then show debug note, too
[ "$1" = "-d" ] && shift && debugnote "$*"
logentry "x11docker[$(date +%s.%2N | cut -c8-)]: $*
logentry "x11docker[$(timestamp)]: $*
"
}
debugnote() { # show debug output $*
[ "$Debugmode" = "yes" ] && {
logentry "DEBUGNOTE[$(date +%s.%2N | cut -c8-)]: $*"
[ "$Verbose" = "no" ] && echo "${Colblue}DEBUGNOTE[$(date +%s.%2N | cut -c8-)]:${Colnorm} $*" >&3
logentry "DEBUGNOTE[$(timestamp)]: $*"
[ "$Verbose" = "no" ] && echo "${Colblue}DEBUGNOTE[$(timestamp)]:${Colnorm} $*" >&3
} ||:
}
logentry() { # write into logfile
Expand Down Expand Up @@ -795,6 +795,9 @@ download() { # download file at URL $1 and store it in file $
curl) curl -L "${1:-}" --output "${2:-}" ;;
esac
}
timestamp() { # print HH:MM:SS,NNN
date +%T,%N | cut -c1-12
}
makecookie() { # bake a cookie
mcookie 2>/dev/null || echo $RANDOM$RANDOM$RANDOM$RANDOM$RANDOM$RANDOM | cut -b1-32
}
Expand Down Expand Up @@ -2641,15 +2644,18 @@ create_xcommand() { # create command to start X server and/or Waylan
--xpra|--xpra-xwayland)

Xpraoptions="$(check_xpraoption --start-via-proxy=no) \\
$(check_xpraoption --csc-modules=none) \\
$(check_xpraoption --clipboard-direction=both) \\
$(check_xpraoption --encodings=rgb) \\
$(check_xpraoption --microphone=no) \\
$(check_xpraoption --notifications=no) \\
$(check_xpraoption --pulseaudio=no) \\
$(check_xpraoption --socket-dirs="'$Cachefolder'") \\
$(check_xpraoption --speaker=no) \\
$(check_xpraoption --video-encoders=none) \\
$(check_xpraoption --webcam=no) \\
$(check_xpraoption --xsettings=no)"

# disable --dpi for buggy versions
[ -n "$Dpi" ] && verlt "$Xpraversion" "xpra v2.1-r16547" && ! verlt "$Xpraversion" "xpra v2.1" && Dpi=""

Expand Down Expand Up @@ -2684,6 +2690,7 @@ create_xcommand() { # create command to start X server and/or Waylan
$Xpraoptions \\
$(check_xpraoption --clipboard=$Shareclipboard) \\
$(check_xpraoption --compress=0) \\
$(check_xpraoption --opengl=yes) \\
$(check_xpraoption --quality=100) \\
$(check_xpraoption --modal-windows=no)"
[ "$Fullscreen" = "yes" ] && Xpraclientcommand="$Xpraclientcommand \\
Expand Down Expand Up @@ -5313,10 +5320,10 @@ $(tail $Xpraserverlogfile)"
mkfile $Xpraserverlogfile # clear logfile to remove "xpra is ready" message
}
verbose -d "Starting Xpra server"
echo "x11docker [$(date)]: Starting Xpra server" >> $Xpraserverlogfile
echo "x11docker [$(timestamp)]: Starting Xpra server" >> $Xpraserverlogfile
$Mksu "env $Newxenv XPRA_OPENGL_DOUBLE_BUFFERED=1 $Xpraservercommand" >> $Xpraserverlogfile 2>&1 &
Xpraserverpid=$! && storepid $Xpraserverpid xpraserver
waitforlogentry "xpra server" $Xpraserverlogfile 'xpra is ready' && verbose "Xpra server is ready" || {
waitforlogentry "xpra server" $Xpraserverlogfile 'xpra is ready' || {
rocknroll && error "Xpra server startup failed.
Last lines of Xpra server log:
$(tail $Xpraserverlogfile)"
Expand All @@ -5328,7 +5335,7 @@ $(tail $Xpraserverlogfile)"
checkpid $Xpraclientpid && kill $Xpraclientpid
[ -n "$Xpraclientpid" ] && note "Restarting Xpra client."
verbose -d "Starting Xpra client"
echo "x11docker [$(date)]: Starting Xpra client" >> $Xpraclientlogfile
echo "x11docker [$(timestamp)]: Starting Xpra client" >> $Xpraclientlogfile
$Mksu "env $Hostxenv $Xpraclientcommand" >> $Xpraclientlogfile 2>&1 &
Xpraclientpid=$! && storepid $Xpraclientpid xpraclient
checkpid $Xpraclientpid && {
Expand Down

0 comments on commit a3269eb

Please sign in to comment.