Git Product home page Git Product logo

weylus's Introduction

Weylus

Build

Weylus turns your tablet or smart phone into a graphic tablet/touch screen for your computer!

Weylus in action with Xournal++:

Weylus in action

Table of Contents

Features

  • Control your mouse with your tablet
  • Mirror your screen to your tablet
  • Send keyboard input using physical keyboards
  • Hardware accelerated video encoding

The above features are available on all Operating Systems but Weylus works best on Linux. Additional features on Linux are:

  • Support for a stylus/pen (supports pressure and tilt)
  • Multi-touch: Try it with software that supports multi-touch, like Krita, and see for yourself!
  • Capturing specific windows and only drawing to them
  • Faster screen mirroring
  • Tablet as second screen

Installation

Just grab the latest release for your OS from the releases page and install it on your computer. No apps except a modern browser (Firefox 80+, iOS/iPadOS 13+) are required on your tablet. If you run Linux make sure to follow the instructions described here to enable uinput for features like pressure sensitivity and multitouch!

Packages

AUR packages for Weylus are available here:

Running

Start Weylus, preferably set an access code in the access code box and press the Start button. This will start a webserver running on your computer. To control your computer with your tablet you need to open the url http://<address of your computer>:<port set in the menu, default is 1701>, if possible Weylus will display to you the url you need to open and show a QR code with the encoded address. If you have a firewall running make sure to open a TCP port for the webserver (1701 by default) and the websocket connection (9001 by default).

On many Linux distributions this is done with ufw:

sudo ufw allow 1701/tcp
sudo ufw allow 9001/tcp

Please only run Weylus in networks you trust as there is no encryption to enable minimal latencies.

Fullscreen

You may want to add a bookmark to your home screen on your tablet as this enables running Weylus in full screen mode (on iOS/iPadOS this needs to be done with Safari). If you are not on iOS/iPadOS there is a button to toggle full screen mode.

Keyboard Input

Weylus supports keyboard input for physical keyboards, so if you have a Bluetooth keyboard, just connect it to your tablet and start typing. Due to technical limitations onscreen keyboards are not supported.

Automation

Weylus provides some features to make automation as convenient as possible. There is a command-line interface; --no-gui for example starts Weylus in headless mode without a gui. For more options see weylus --help. If you want to run a specific script e.g., once a client connects to your computer you can do so by parsing the log Weylus generates. You may want to enable more verbose logging by setting the environment variable WEYLUS_LOG_LEVEL to DEBUG or TRACE as well as WEYLUS_LOG_JSON to true to enable easily parseable JSON logging.

Linux

Weylus uses the uinput interface to simulate input events on Linux. To enable stylus and multi-touch support /dev/uinput needs to be writable by Weylus. To make /dev/uinput permanently writable by your user, run:

sudo groupadd -r uinput
sudo usermod -aG uinput $USER
echo 'KERNEL=="uinput", MODE="0660", GROUP="uinput", OPTIONS+="static_node=uinput"' \
| sudo tee /etc/udev/rules.d/60-weylus.rules

Then, either reboot, or run

sudo udevadm control --reload
sudo udevadm trigger

then log out and log in again. To undo this, run:

sudo rm /etc/udev/rules.d/60-weylus.rules

This allows your user to synthesize input events system-wide, even when another user is logged in. Therefore, untrusted users should not be added to the uinput group.

Wayland

Weylus offers experimental support for Wayland. Installing pipewire and xdg-desktop-portal as well as one of:

  • xdg-desktop-portal-gtk for GNOME
  • xdg-desktop-portal-kde for KDE
  • xdg-desktop-portal-wlr for wlroots-based compositors like Sway is required.

There are still some things that do not work:

  • input mapping for windows
  • displaying proper window names
  • capturing the cursor

Hardware Acceleration

On Linux Weylus supports hardware accelerated video encoding through the Video Acceleration API (VAAPI) or Nvidia's NVENC. By default hardware acceleration is disabled as quality and stability of the hardware encoded video stream varies widely among different hardware and sufficient quality can not be guaranteed. If VAAPI is used it is possible to select a specific driver by setting the environment variable LIBVA_DRIVER_NAME. You can find possible values with the command ls /usr/lib/dri/ | sed -n 's/^\(\S*\)_drv_video.so$/\1/p'. On some distributions the drivers may not reside in /usr/lib/dri but for example in /usr/lib/x86_64-linux-gnu/dri and may not be found by Weylus. To force Weylus to search another directory for drivers, the environment variable LIBVA_DRIVERS_PATH can be set. Additionally you can specify the VAAPI device to use by setting WEYLUS_VAAPI_DEVICE; by default devices can be found in /dev/dri. On some systems this is not optional and this variable must be set. If VAAPI doesn't work out of the box for you, have a look into /dev/dri, often setting WEYLUS_VAAPI_DEVICE=/dev/dri/renderD129 is already the solution. Note that you may need to install the driver(s) first.

Nvidias NVENC is very fast but delivers a video stream of noticeably lower quality (at least on my GeForce GTX 1050 Mobile GPU) but more recent GPUs should provide higher quality. For this to work nvidia drivers need to be installed.

Weylus as Second Screen

There are a few possibilities to use Weylus to turn your tablet into a second screen.

Intel GPU on Xorg with Intel drivers

Intel's drivers support creating virtual outputs that can be configured via xrandr.

But first a word of warning: The following configuration may break starting the X server. This means you might end up without a graphical login or X may get stuck and just display a black screen. So make sure you know what you are doing or are at least able to recover from a broken X server.

You will need to install the xf86-video-intel driver and create the file /etc/X11/xorg.conf.d/20-intel.conf with the following contents:

Section "Device"
    Identifier "intelgpu0"
    Driver "intel"

    # this adds two virtual monitors / devices
    Option "VirtualHeads" "2"

    # if your screen is flickering one of the following options might help
    # Option "TripleBuffer" "true"
    # Option "TearFree"     "true"
    # Option "DRI"          "false"
EndSection

After a reboot xrandr will show two additional monitors VIRTUAL1 and VIRTUAL2 and can be used to configure them. To activate VIRTUAL1 with a screen size of 1112x834 and a refresh rate of 60 fps the following commands can be used:

> # this generates all input parameters xrandr needs
> #from a given screen resolution and refresh rate
> gtf 1112 834 60

  # 1112x834 @ 60.00 Hz (GTF) hsync: 51.78 kHz; pclk: 75.81 MHz
  Modeline "1112x834_60.00"  75.81  1112 1168 1288 1464  834 835 838 863  -HSync +Vsync
> # setup the monitor
> xrandr --newmode "1112x834_60.00"  75.81  1112 1168 1288 1464  834 835 838 863  -HSync +Vsync
> xrandr --addmode VIRTUAL1 1112x834_60.00
> xrandr --output VIRTUAL1 --mode 1112x834_60.00
> # check if everything is in order
> xrandr

Now you should be able to configure this monitor in your system setting like a regular second monitor and for example set its position relative to your primary monitor.

After setting up the virtual monitor start Weylus and select it in the capture menu. You may want to enable displaying the cursor in this case. That is it!

Dummy Plugs

Weylus detects if you use multiple monitors and you can select the one you want to mirror. So if you want to use Weylus as a second screen you could just buy another monitor. Obviously this is pointless as if you already bought that monitor, there is no need to use Weylus! This is where so called HDMI/Displayport/VGA Dummy Plugs come in handy. These are small devices that pretend to be a monitor but only cost a fraction of the price of an actual monitor.

Once you have bought one and plugged it into your computer you can configure an additional screen just like you would do with an actual one and then use Weylus to mirror this virtual screen.

Other Options

The following is untested/incomplete, feel free to do more research and open a pull request to expand documentation on this!

Encryption

By default Weylus comes without encryption and should only be run on networks you trust. If this is not the case it's strongly advised to set up a TLS proxy. One option is to use hitch, an example script that sets up encryption is located at weylus_tls.sh. But any TLS proxy should work just fine.

Note that the mentioned script works by creating a self-signed certificate. This means your browser will most likely display a scary looking but completely unfounded message telling you how incredibly dangerous it is to trust the certificate you yourself just created; this can be safely ignored!

In case you are using Firefox: There is a bug that prevents users from accepting self-signed certificates for websocket connections. A workaround is to directly open the websocket connection via the URL bar and accept the certificate there. After accepting the connection will of course fail as the browser expects https and not wss as protocol.

Sadly this solution is anything but frictionless and I am unhappy with the current state of affairs. This is also another reason why encryption is not enabled by default, self-signed certificates are just too painful to handle nowadays. I'd gladly welcome any proposals to improve the situation!

macOS

Weylus needs some permissions to work properly, make sure you enable:

  • Incoming connections
  • Screen capturing
  • Controlling your desktop

Hardware Acceleration

Weylus can make use of the Videotoolbox framework on macOS for hardware acceleration. In my tests the video quality has been considerably worse than that using software encoding and thus Videotoolbox is disabled by default.

Windows

Hardware Acceleration

Weylus can make use of Nvidias NVENC as well as Microsoft's MediaFoundation for hardware accelerated video encoding. Due to widely varying quality it is disabled by default.

Building

To build Weylus you need to install Rust, Typescript, make, git, a C compiler, nasm and bash. cargo build builds the project. By default Weylus is build in debug mode, if you want a release build run cargo build --release. On Linux some additional dependencies are required to build Weylus. On Debian or Ubuntu they can be installed via:

apt-get install -y libx11-dev libxext-dev libxft-dev libxinerama-dev libxcursor-dev libxrender-dev \
libxfixes-dev libxtst-dev libxrandr-dev libxcomposite-dev libxi-dev libxv-dev autoconf libtool-bin \
nvidia-cuda-dev pkg-config libdrm-dev libpango1.0-dev libgstreamer1.0-dev \
libgstreamer-plugins-base1.0-dev libdbus-1-dev

Note that building for the first time may take a while as by default ffmpeg needs to be build. On Windows only msvc is supported as C compiler; it is, however, possible to cross compile on Linux for Windows using minGW.

In case you do not want to build ffmpeg and libx264 via the supplied build script you can create the directory deps/dist yourself and copy static ffmpeg libraries built with support for libx264 and a static version of libx264 into deps/dist/lib. Additional deps/dist/include needs to be filled with ffmpeg's include header files. For hardware acceleration to work ffmpeg needs to be built with additional flags depending on your OS: Consult the variable FFMPEG_EXTRA_ARGS in deps/build.sh for details. Furthermore, for VAAPI on Linux a static version of libva is required as well.

The build script will only try to build ffmpeg if the directory deps/dist does not exist.

Alternatively passing --features ffmpeg-system to cargo will build Weylus using the system's version of ffmpeg. This is disabled by default for compatibility reasons, on newer systems this should not pose a problem and using the system libraries is advised.

Docker

It is also possible to build the Linux version inside a docker container. The Dockerfile used is located at docker/Dockerfile. This is also how the official release is built. Building works like this:

docker run -it hhmhh/weylus_build bash
root@f02164dbfa18:/# git clone https://github.com/H-M-H/Weylus
Cloning into 'Weylus'...
remote: Enumerating objects: 10, done.
remote: Counting objects: 100% (10/10), done.
remote: Compressing objects: 100% (7/7), done.
remote: Total 827 (delta 1), reused 6 (delta 0), pack-reused 817
Receiving objects: 100% (827/827), 5.38 MiB | 7.12 MiB/s, done.
Resolving deltas: 100% (431/431), done.
root@f02164dbfa18:/# cd Weylus/
root@f02164dbfa18:/Weylus# cargo deb
   Compiling
   ...

Once the build is finished you can for example copy the binary from the container to your file system like this:

docker cp f02164dbfa18:/Weylus/target/release/weylus ~/some/path/weylus

The .deb is located at /Weylus/target/debian/. Please note that the container ID will most likely not be f02164dbfa18 if you run this yourself, replace it accordingly.

How does this work?

Stylus/Touch

Modern browsers expose so called PointerEvents that can convey not only mouse but additionally stylus/pen and touch information. Weylus sets up a webserver with the corresponding javascript code to capture these events. The events are sent back to the server using websockets. Weylus then processes these events using either the generic OS independent backend, which only supports controlling the mouse or on Linux the uinput backend can be used. It makes use of the uinput Linux kernel module which supports creating a wide range of input devices including mouse, stylus and touch input devices.

Screen mirroring & window capturing

Either the generic backend is used which is less efficient and only captures the whole screen or on Linux xlib is used to connect to the X-server and do the necessary work of getting window information and capturing the window/screen. To make things fast the "MIT-SHM - The MIT Shared Memory Extension" is used to create shared memory images using XShmCreateImage. If Wayland instead of X11 is running, PipeWire and GStreamer is used to capture the screen. The images captured are then encoded to a video stream using ffmpeg. Fragmented MP4 is used as container format to enable browsers to play the stream via the Media Source Extensions API. The video codec used is H.264 as this is widely supported and allows very fast encoding as opposed to formats like AV1. To minimize dependencies ffmpeg is statically linked into Weylus.

FAQ

Q: Why does the page not load on my tablet and instead I get a timeout?
A: There probably is some kind of firewall running, make sure the ports Weylus uses are opened.

Q: Why do I get the error ERROR Failed to create uinput device: CError: code...?
A: uinput is probably misconfigured, have you made sure to follow all instructions and logged out and in again? You may also be running a very old kernel that does not support the required features. In that case try to upgrade your system or use a newer one.

Q: Why is the "Capture" drop down empty and the screen not mirrored?
A: It is possible that only the port for the webserver but not the websocket has been opened, check that both ports have been opened.

Q: Why can I not select any windows in the "Capture" drop down and only see the whole screen.
A: If you are running Weylus on MacOS or Windows this feature is unfortunately not implemented. On Linux it is possible that your window manager does not support Extended Window Manager Hints or that you need to activate them first, like for XMonad.

Q: Do I have to follow the instructions to setup Weylus as second screen too?
A: No, this is strictly optional.

Q: Why am I unable to connect my tablet to the URL displayed by Weylus?
A: It is possible that your computer and WiFi connected tablet are on different networks, make sure they are on the same network.

Q: Why does this not run on Firefox for Android?
A: Actually it does, just make sure Firefox version 80+ is installed.

Q: Why does this not run under Chrome on my iPad?
A: Chrome lacks some features for video streaming on iPadOS/iOS, try Firefox or Safari.

Q: Why won't my cursor move in osu! ?
A: Try disabling raw input.

Q: Can I use Weylus even if there is no WiFi?
A: Probably yes! Most tablets permit setting up a WiFi hotspot that can be used to connect your computer and tablet. Alternatively there is USB tethering too, which can be used to setup a peer to peer connection between your tablet and computer over USB. Another method for Android devices is to setup a socket connection with adb:

adb reverse tcp:1701 tcp:1701
adb reverse tcp:9001 tcp:9001

Like that you can connect from your Android device to Weylus with the URL: http://127.0.0.1:1701.

Weylus only requires that your devices are connected via the Internet Protocol and that doesn't necessarily imply WiFi.


Packaging status

weylus's People

Contributors

danielrutz avatar dependabot[bot] avatar h-m-h avatar hello71 avatar newbytee avatar rschroll avatar schctl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

weylus's Issues

VA-API not working by default

First of all thanks for the awesome software!

My Laptop is a rather old Thinkpad T440s with an Intel i5 4300U and HD Graphics 4400. VA-API doesn't work out of the box as it seems, only the /usr/lib/dri directory is searched for the driver. But on my install (Linux Mint 19.3 based on Ubuntu 18.04) the driver was located in /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so. I was able to solve the problem by creating a symlink by executing sudo mkdir /usr/lib/dri and sudo ln -s /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so /usr/lib/dri.

Should I create a pull request and add this information to the README?

Ignore touch input

Drawing on my tablet would be way easier if I could rest my hand on the screen and the app ignored the touch events. Several drawing apps for android support this more or less (I still have to watch out not to touch system UI elements). I think Weylus could also support this by filtering on event type, and having a setting to ignore touch events either on the Rust (probably easier) or on the TypeScript (transmits less unnecessary data) side.

I do not get any window listed in the "Capture Window" drop down botton

Hi,
I installed the release 0.8.0 because the 0.9.0 failed. See #33
I can reach the server config but the drop down button called "Capture window" is empty.
On the server side I think everything is okay:
`

weylus
Aug 11 18:57:49.643 INFO weylus::gui: Found more than one IP address for browsers to connect to,
Aug 11 18:57:49.643 INFO weylus::gui: other urls are:
Aug 11 18:57:49.643 INFO weylus::gui: http://192.168.178.185:1701
Aug 11 18:57:49.643 INFO weylus::gui: http://172.19.0.1:1701
Aug 11 18:57:49.643 INFO weylus::gui: http://172.17.0.1:1701
Aug 11 18:57:49.643 INFO weylus::gui: http://192.168.178.179:1701?password=XXXXXX
Aug 11 18:57:49.643 INFO weylus::web: Webserver listening at 0.0.0.0:1701...
Aug 11 19:01:23.942 INFO weylus::web: Client authenticated: 192.168.178.174:44884.
Aug 11 19:01:23.942 INFO weylus::web: Client connected: 192.168.178.174:44884
`
I also do not understand how connection with my laptop will happen.
When the connection is established every cursor movements on the table will be replicated on the laptop?
Thanks

Compatibility with macOS Mojave(10.14)

This app looks amazing and I downloaded it for a trial.
When I open it, it displays "You have macOS 10.14.6. The application requires macOS 10.15 or later.".
I'd prefer to stay at this version, but I would also like to use Weylus.
If it doesn't use some features that are provided in macOS 10.15 only, can you re-compile it for lower versions of macOS for compatibility?
Thanks

release 0.9.0 fails to install

Hi,
I tried to install the latest release on Ubuntu 18.04 and I get the follow error:
/tmp# dpkg -i ./Weylus_0.9.0_amd64.deb dpkg: error processing archive ./Weylus_0.9.0_amd64.deb (--install): parsing file '/var/lib/dpkg/tmp.ci/control' near line 9 package 'weylus': 'Depends' field, syntax error after reference to package 'diversion' Errors were encountered while processing: ./Weylus_0.9.0_amd64.deb
Please can you help?

Not working Xubuntu 20.04

I have tried before installing Weylus_0.7.2_amd64.deb and I couldn't get it to work. I'm trying now the new 0.8.0 version, but still no luck. I'm running Xubuntu 20.04:
Linux version 5.4.0-40-generic (buildd@lcy01-amd64-011) (gcc version 9.3.0 (Ubuntu 9.3.0-10ubuntu2)) #44-Ubuntu SMP Tue Jun 23 00:01:04 UTC 2020

Bellow the steps I've followed. They were pretty much the instructions found on Weylus project Main Page.
sudo apt install ./Weylus_0.8.0_amd64.deb

Output:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'weylus' instead of './Weylus_0.8.0_amd64.deb'
The following NEW packages will be installed:
weylus
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/7.897 kB of archives.
After this operation, 24,0 MB of additional disk space will be used.
Get:1 /home/rafobr/Downloads/Weylus_0.8.0_amd64.deb weylus amd64 0.8.0 [7.897 kB]
Selecting previously unselected package weylus.
(Reading database ... 215475 files and directories currently installed.)
Preparing to unpack .../Weylus_0.8.0_amd64.deb ...
Unpacking weylus (0.8.0) ...
Setting up weylus (0.8.0) ...

Then I set
sudo groupadd -r uinput
sudo usermod -aG uinput $USER
echo 'KERNEL=="uinput", MODE="0660", GROUP="uinput", OPTIONS+="static_node=uinput"' | sudo tee /etc/udev/rules.d/60-weylus.rules

No error message. I checked there is a 60-weylus.rules file and the content is
'KERNEL=="uinput", MODE="0660", GROUP="uinput", OPTIONS+="static_node=uinput"'

Then I ran
sudo udevadm control --reload
sudo udevadm trigger

Logged out and logged in again.
Opened weylus, pressed start. Log says:
INFO Webserver listening at 0.0.0.0:1701...

However, I got no luck accessing via Safari on my Ipad (iPadOS). The request to open the page timed out.
I found strange the log said listening at 0.0.0.0:1701 . So I've tried changing the bind address to 192.168.0.100. Log then said:
INFO Webserver listening at 192.168.0.100:1701...

But there was no luck either. What is the purpose of the bind adress by the way?
I did not install the intel driver for screen mirroring. I haven't found it. Is that required for just using as a stylus table?
In summary, what am I missing here? Thanks for your help!

Pointer geometry wrong with multiple displays

If I launch Weylus with multiple displays active, the geometry calculation for the pointer is wrong. It appears that the total desktop size is being mixed up with a single display size. Both my primary and secondary monitors have the same resolution. If I have these set up side-by-side, Weylus positions the cursor at half the x position that it should. This happens regardless of whether I am capturing the whole desktop, a single display, or a single window. If I have the displays set up vertically, the cursor is placed at half the y position that it should.

Interestingly, only the display geometry at Weylus's start matters. If adjust the displays after Weylus is running, the problem remains. Or if I start Weylus with only a single display active, it works perfectly when I add another display.

This is seen running 0.7.1 on Ubuntu 20.04 with the Gnome DE on X.

Please let me know if there's additional debugging I can provide.

Using Bluetooth instead of wifi?

Hello,

I would like to use Weylus in a room that has only a wired connection, so it'd be great if it were possible to use bluetooth instead of regular TCP/UDP communications.

I tried to setup an IP over bluetooth connexion to reach this end (using only open-source softwares), but failed. Maybe all I need is a link in the doc to the right tutorial?

Thanks for this great software,
Mt

ERROR Failed to create uinput device: CError: code: 1 message: error: failed to open /dev/uinput

Hi, I am trying to use this with Linux and Ipad. The error message is shown as the title. Just wondering what this means, and how to debug this. Here is how I set the Access code and etc.
image

First, I installed the package with .deb file, and then, I did

sudo groupadd -r uinput
sudo usermod -aG uinput $USER
echo 'KERNEL=="uinput", MODE="0660", GROUP="uinput", OPTIONS+="static_node=uinput"' \
| sudo tee /etc/udev/rules.d/60-weylus.rules

and

sudo udevadm control --reload
sudo udevadm trigger

Capture dropdown empty on Chrome/Opera

(I checked that the websocket is open by using a different device - it is)

As the title says. Samsung Galaxy Tab 2, Chrome 42.0. and Opera 50.6. (Apparently neither Safari nor Firefox are available on the device).

[Feature] Add icon

The input-tablet icon would be a good fit for this app, which could be added as a potential taskbar/dock icon, and for a potential application menu entry if packaged.

Adwaita:

image

Papirus:

image

Having trouble setting up NVENC hardware acceleration

Hi,

I have just installed Weylus on my Linux Mint machine. It is nice to see it working and it is just about fast enough to play with, but not really for serious use, as the refresh rate seem to be only a few frames a second at best. I would like to set up hardware acceleration but I am having trouble with this. My graphics card is a GeForce GTX 970. I have tried installing two of the libnvidia-encode libraries that are listed in the repository. With the -435 version, a message comes up in the weylus error messages saying that the driver does not support NVENC. With the -450 version, this message does not appear, so I assume that this is the right version. There is no specific message to say that NVENC has been enabled though. Installing this doesn't seem to increase the frame rate of the mirrored screen, which lags up to a second or two behind the desktop screen when I am drawing freely.

Do you know how I can check if NVENC has been enabled, and if it is not, what I need to do to get it working?

Error installing Weylus_0.7.0_amd64.deb on Debian stable

Hello,

The .deb fails to install on Debian stable. Is it maybe intended for Ubuntu, or Debian testing/unstable?

`sudo apt install ./Weylus_0.7.0_amd64.deb
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'weylus' instead of './Weylus_0.7.0_amd64.deb'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
weylus : Depends: libgcc1 (>= 1:8.4.0) but 1:8.3.0-6 is to be installed
Depends: libstdc++6 (>= 8.4.0) but 8.3.0-6 is to be installed
E: Unable to correct problems, you have held broken packages.`

When connecting to server: XShmExtension does not support shared memory pixmaps

After upgrading to v0.7.0, Weylus does not work anymore and won't start any video stream. Trying to connect with the server, the logs give:

ERROR weylus::websocket: Failed to create stream handler: CError: code: 1 message: This version of XShmExtension does not support shared memory pixmaps!

v0.6.2 works fine so there was a change between these versions that broke it.

System: Manjaro Linux
GPU: Nvidia GTX 1070

Screen Mirroring not working on chrome for android

First of all thank you very much for this awesome software!

I wanted to test it using my Android phone and my quite old Samsung tablet. However, on both devices, I can not any video feed. I tested it in a browser window on my PC, which seems to work. So it seems to be an issue with the client device.

Do you have any idea about the minimum requirements for the clients?

Thanks in advance!

Feature request: Ability to disable stretched video

In many cases, I would prefer to have the aspect ratio of the video maintained, even if that means dead space around the video. Simply disabling the transformations on the video element is enough. I made a simple test where the stretching could be disabled via a location hash. Either way, all of the video is visible and the touch registration is correct. This works both when the video is too tall and too wide, so there's no math updates needed.

The thing that's blocking me for making a PR is that I don't know how the UI should work. Providing a separate URL, or just a different hash, for the two options would be easiest to implement, and it would make on-the-fly changes easy. This isn't particularly user friendly. A HTML UI would not be too hard, but it would either always take up space, or it would need some way to be triggered and then hidden. An option in the server GUI would make sense, in that all of the other options are there already. But this would either need a server restart to take effect, or a communication channel to the client to update the state.

I'm happy to work on a PR, if you let me know your preference.

BUilt Docker image... not sure what to do next

Hi. Long-time Linux user, Docker newbie. I'm running Solus, and there's no pre-built executable. My son recommended using the Docker version. I ran the command and docker ground things up for a bit and I got a root bash shell in the docker image. Now what? Can I set this up to run on my computer at startup? How do I do the uinput settings?

I'm just not sure what happens next.

Thanks in advance!
Vic

Cannot capture window contents if window not fully on screen

If Weylus is attempting to capture a single window, and that window is not fully on screen, it fails to capture any window contents. The video output will freeze, or be completely black if just starting up, and the message

XRequest.130: BadMatch (invalid parameter attributes) 0x4a0000a

will be printed out repeatedly (I'm guessing once per frame). When the window is moved back on screen, the video picks up correctly. Input continues to work correctly, although the cursor is restricted to stay on the screen.

Admittedly, I don't know what the right behavior is here. I don't know if the offscreen portion of the window is actually rendered, so there may be no data to capture. I'd be fine with a message informing me that it can't work until the window is fully on screen. But if you don't notice that a window is hanging a few pixels over the edge, it can be confusing to figure out why nothing's working.

This is seen on Ubuntu 20.04 with the Gnome DE running on X.

Please let me know if there's additional troubleshooting I can do.

Screen mirroring not working in Chrome on iPad

I can't see anything in the browser window when I connect. I can write, but the window is empty. I'm on Linux -- I initially thought it was a Wayland issue (I saw that open issue), but I logged into an Xorg session and it's the same. Help please! Happy to give any info needed.

Add hardware video encoding

The latency can probably be improved via hardware encoding videos.

Things that need to be done / you can help me with:

thread '<unnamed>' panicked at 'index out of bounds - Windows 10

Setup:

- Windows 10 LTSC 1809 (17763.1217)
- Intel Core i5 - 8250U
- Intel UHD Graphics 620 (deactivated dGPU)
- Weylus v0.7.1

Steps:

  1. Execute weylus.exe
  2. Allow weylus on Windows Firewall, start listening
  3. Once connected on client, receive error:
�[2mJun 15 17:01:46.289�[0m �[32m INFO�[0m weylus::web: Webserver listening at 0.0.0.0:1701...
�[2mJun 15 17:02:00.762�[0m �[32m INFO�[0m weylus::web: Client connected: 127.0.0.1:50340
[libx264 @ 000001BD3CCCA5C0] MB rate (3600000000) > level limit (16711680)
[libx264 @ 000001BD3CCCA5C0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 000001BD3CCCA5C0] profile Constrained Baseline, level 6.2, 4:2:0, 8-bit
[libx264 @ 000001BD3CCCA5C0] 264 - core 159 r2999 296494a - H.264/MPEG-4 AVC codec - Copyleft 2003-2020 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=8 lookahead_threads=8 sliced_threads=1 slices=8 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=12 keyint_min=1 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=0
Output #0, mp4, to '(null)':
    Stream #0:0: Video: h264, yuv420p, 1280x720, q=2-31
thread '<unnamed>' panicked at 'index out of bounds: the len is 921600 but the index is 921600', src\screen_capture\generic.rs:47:17
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

The list "Capture" is empty

Hi there,
I installed the bin file for Linux. It runs well, no error/warning. I can connect from my iPad. However the list in "Capture" is empty. When I click on "Refresh list", nothing happens.

Video feed is so slow

The input feed speed is fine but the video feed is slow.
I'm using i3 and Ipad pro 12.9.

Create a postinstall script in the .deb package

It would be great if a postinstall script in the .deb package automatically configures Weylus by entering the commands in https://github.com/H-M-H/Weylus#linux, and prints a message like "restart your computer and enter the command weylus to start using Weylus"
Not every computer can use hardware accelerations, so those commands does not need to be executed by default in the postinstall script.

This can also be done in the AUR.

error ultima versão

Hy guy, im get problem to install the last version on ubuntu 19.10

`fmachado@machado:/Downloads$ sudo dpkg -i Weylus_0.9.0_amd64.deb
[sudo] senha para fmachado:
dpkg: erro ao processar o arquivo Weylus_0.9.0_amd64.deb (--install):
a interpretar o ficheiro '/var/lib/dpkg/tmp.ci/control' perto da linha 9 pacote 'weylus':
campo 'Depends', erro de sintaxe após referência a pacote 'diversion'
Erros foram encontrados durante o processamento de:
Weylus_0.9.0_amd64.deb
fmachado@machado:
/Downloads$

`

doesn't work for me, Ubuntu 18.04

Hi, I installed Weylus_0.8.0_amd64.deb. Actually, I did have the same issue as in #24 which I could fix by opening port 1701 in ufw. Now I can connect to Weylus fom my tablet (tried Firefox, Opera, Chrome). Nothing appears in the "capture window" box. (When I connect to Weylus from my computer, the "capture window" box offers a bunch of windows open in my computer, and lets me select a window.) Am I missing something obvious? Thanks for your help!

Improve latency for screen mirroring

Currently every time the screen is captured it is encoded as PNG and then converted to base64 to send it over websockets and load it to an image tag as data url.
It should be possible to improve this:

Use this as a second monitor?

Would it be possible to use make this send the output of a virtual monitor (a la what you can do with vnc)? I've been looking for something that can do that well, and vnc leaves what to be desired.

cannot draw on powerpoint

Hi,
Working on windows10, I can draw on Paint, but sadly, on PowerPoint, it draws only a point at the location I started to touch the tablet with the stylus.

Build error (Ubuntu 18.04.4 LTS)

Hi,

Apologies if this is not the preferred way to get help for this kind of problem. I am unable to build Weylus on my fairly standard Ubuntu 18 LTS box, due to the following error:

The following warnings were emitted during compilation:

warning: tsc failed with exitcode: 2

error: failed to run custom build command for `weylus v0.8.0 (/home/$USER/build/weylus)`

Caused by:
  process didn't exit successfully: `/home/$USER/build/weylus/target/debug/build/weylus-b728f48f484f9563/build-script-build` (exit code: 2)
--- stdout
cargo:rerun-if-changed=ts/lib.ts
tsconfig.json(3,15): error TS6046: Argument for '--target' option must be: 'es3', 'es5', 'es6', 'es2015', 'es2016', 'es2017', 'es2018', 'esnext'.
tsconfig.json(4,13): error TS6046: Argument for '--lib' option must be: 'es5', 'es6', 'es2015', 'es7', 'es2016', 'es2017', 'es2018', 'esnext', 'dom', 'dom.iterable', 'webworker', 'scripthost', 'es2015.core', 'es2015.collection', 'es2015.generator', 'es2015.iterable', 'es2015.promise', 'es2015.proxy', 'es2015.reflect', 'es2015.symbol', 'es2015.symbol.wellknown', 'es2016.array.include', 'es2017.object', 'es2017.sharedmemory', 'es2017.string', 'es2017.intl', 'es2017.typedarrays', 'esnext.array', 'esnext.asynciterable', 'esnext.promise'.
ts/lib.ts(26,64): error TS2339: Property 'forEach' does not exist on type 'NodeListOf<Element>'.
ts/lib.ts(87,35): error TS2495: Type 'IterableIterator<[string, HTMLInputElement]>' is not an array type or a string type.
ts/lib.ts(99,39): error TS2495: Type 'IterableIterator<[string, HTMLInputElement]>' is not an array type or a string type.
ts/lib.ts(190,28): error TS2339: Property 'twist' does not exist on type 'PointerEvent'.
ts/lib.ts(210,31): error TS2339: Property 'includes' does not exist on type 'string[]'.
ts/lib.ts(260,42): error TS2339: Property 'onerror' does not exist on type 'SourceBuffer'.
ts/lib.ts(261,42): error TS2339: Property 'onerror' does not exist on type 'SourceBuffer'.
cargo:warning=tsc failed with exitcode: 2

warning: build failed, waiting for other jobs to finish...
error: build failed

I have previously installed all the dependencies mentioned in the readme file, but I'm not familiar enough with this buil pipeline to understand what is going on. Can you please advise on how to fix this ?

Thanks

Stylus and touch support on windows

Right now only the mouse can be controlled, things like pressure or touch events are not handled. I do not run windows myself and thus will most likely not implement this, but if someone else is up to the task here is what needs to be done:

Implement the InputDevice trait: https://github.com/H-M-H/Weylus/blob/master/src/input/device.rs, send_event is called on every PointerEvent sent from the browser. The PointerEvent type is defined in https://github.com/H-M-H/Weylus/blob/master/src/protocol.rs. x and y coordinates of the events are normalized to a range between 0 and 1, have a look at https://github.com/H-M-H/Weylus/blob/master/ts/lib.ts.

Once a struct that implements this trait is done (should be in its own file in https://github.com/H-M-H/Weylus/blob/master/src/input/), it has to be instantiated in https://github.com/H-M-H/Weylus/blob/master/src/websocket.rs setup.

Probably useful:

Enable ability to disable video?

I'm sorry if this feature already exists but I'd like to have a way to disable the video / screen capture so that I can use my phone as a graphics tablet with just a blank screen on it

Wayland support?

Does this project support Wayland? I'm running the latest on https://aur.archlinux.org/packages/weylus-bin/ and while I have input working, I'm getting a black screen on the iPad browser I'm using it from.

Input also seems to be smooth in Xwayland apps, but jumpy in Wayland native apps.

Update: See recording of this at https://www.youtube.com/watch?v=GrJXqqLKas4. All input is made via Apple Pencil on an iPad. Notice that the input is smooth when over xeyes, but jumpy over Alacritty (which is a Wayland app).

Show mouse cursor

As a follow up to #5 it would be a huge plus to have the mouse cursor be visible (optionally) in stream.

Unable to install on Ubuntu 20.04 ,dependency error

Cannot install the Weylus_0.6.1_amd64.deb in Ubuntu 20.04 .

Selecting previously unselected package weylus.
(Reading database ... 268289 files and directories currently installed.)
Preparing to unpack Weylus_0.6.1_amd64.deb ...
Unpacking weylus (0.6.1) ...
dpkg: dependency problems prevent configuration of weylus:
 weylus depends on libstdc++6 (>= 10.1.0); however:
  Version of libstdc++6:amd64 on system is 10-20200411-0ubuntu1.
 weylus depends on libgcc-s1 (>= 10.1.0); however:
  Version of libgcc-s1:amd64 on system is 10-20200411-0ubuntu1.
 weylus depends on libssl1.1 (>= 1.1.1g); however:
  Version of libssl1.1:amd64 on system is 1.1.1f-1ubuntu2.

dpkg: error processing package weylus (--install):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 weylus

iPad: [Workaround inside] Some stylus strokes not registered

When I try to use Weylus to write words, some of the strokes are not registered:

For example, when writing an H, most of the time I get an |- instead of an |-|.

Trying to write Hello results in |-e lo

This makes it extremely hard to write using noncursive handwriting.

I'm using Weylus on an iPad and Apple Pencil.

Workaround: Disable the scribble feature in your settings

Settings > Apple Pencil > Scribble

Failed to initialize VAAPI connection

I'm getting this on my Ryzen 5 3500U:

[AVHWDeviceContext @ 0x7fd50c001a40] libva: dlopen of /usr/lib/dri/radeonsi_drv_video.so failed: /usr/lib/dri/radeonsi_drv_video.so: wrong ELF class: ELFCLASS32
[AVHWDeviceContext @ 0x7fd50c001a40] Failed to initialise VAAPI connection: -1 (unknown libva error).

CPU: AMD Ryzen 5 3500U with Radeon Vega Mobile Gfx (8) @ 2.100GHz
GPU: AMD ATI 03:00.0 Picasso

It has happened to me on both Ubuntu (20.04 and 20.10) and Fedora (33)

Edit: it doesn't really happen on an Ubuntu live CD, I probably remembered wrong

Fails to bulid in Docker container

I was trying to build Weylus in the weylus_build docker container, and it was failing. This doesn't make a whole lot of sense, because it's obviously passing in CI. I don't know if there's some caching coming into play, or if the underlying OS is leaking through. (I'm running on Ubuntu 20.04 x86_64.)

I saw that the Dockerfile had been uploaded, so I downloaded the new latest image ([edit] digest 0eddf6b9efdc). When I tried to build (cargo deb), I got a linking error:

   Compiling weylus v0.8.0 (/Weylus)
error: linking with `cc` failed: exit code: 1
  |
  = note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/Weylus/target/release/deps/weylus-c688d45ee6f0b6cd.weylus.8gngyolx-cgu.15.rcgu.o" "-o" "/Weylus/target/release/deps/weylus-c688d45ee6f0b6cd" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "-L" "/Weylus/target/release/deps" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "deps/dist/lib" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/build" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/lib" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/lib/Release" "-L" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,-Bstatic" "-Wl,--whole-archive" "-lerror" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lvideo" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavcodec" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavdevice" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavfilter" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavformat" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavutil" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lpostproc" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lswresample" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lswscale" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lx264" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-llinux" "-Wl,--no-whole-archive" "-Wl,-Bdynamic" "-lX11" "-lXext" "-lXrandr" "-lXfixes" "-lXcomposite" "-lXi" "-Wl,-Bstatic" "-Wl,--whole-archive" "-lva" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-drm" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-glx" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-x11" "-Wl,--no-whole-archive" "-Wl,-Bdynamic" "-ldrm" "-Wl,-Bstatic" "/tmp/rustcKGVS53/libfltk_sys-7019b68ba31ee00d.rlib" "-Wl,--start-group" "/tmp/rustcKGVS53/libbacktrace_sys-5db30a83f5489d12.rlib" "-Wl,--end-group" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-f7cd12d3ecd59a89.rlib" "-Wl,-Bdynamic" "-lssl" "-lcrypto" "-lX11" "-lXtst" "-lstdc++" "-lpthread" "-lX11" "-lXext" "-lXinerama" "-lXcursor" "-lXrender" "-lXfixes" "-lXft" "-lfontconfig" "-lGL" "-lGLU" "-lutil" "-ldl" "-lutil" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-ldl" "-lutil"
  = note: /usr/bin/ld: cannot find -lva
          /usr/bin/ld: cannot find -lva-drm
          /usr/bin/ld: cannot find -lva-glx
          /usr/bin/ld: cannot find -lva-x11
          collect2: error: ld returned 1 exit status
          

error: aborting due to previous error

error: could not compile `weylus`.

To learn more, run the command again with --verbose.
cargo-deb: build failed

This persisted even after I cleaned the deps directory, so I don't think it was a caching issue. I was able to solve this by running apt-get install libva-dev, which must have provided the correct SO files. However, building still failed:

   Compiling weylus v0.8.0 (/Weylus)
error: linking with `cc` failed: exit code: 1
  |
  = note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/Weylus/target/release/deps/weylus-c688d45ee6f0b6cd.weylus.8gngyolx-cgu.15.rcgu.o" "-o" "/Weylus/target/release/deps/weylus-c688d45ee6f0b6cd" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-Wl,-O1" "-nodefaultlibs" "-L" "/Weylus/target/release/deps" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "deps/dist/lib" "-L" "/Weylus/target/release/build/weylus-02150d7e72176edb/out" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/build" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/lib" "-L" "/Weylus/target/release/build/fltk-sys-25930115e1cb7a2f/out/lib/Release" "-L" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,-Bstatic" "-Wl,--whole-archive" "-lerror" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lvideo" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavcodec" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavdevice" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavfilter" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavformat" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lavutil" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lpostproc" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lswresample" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lswscale" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lx264" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-llinux" "-Wl,--no-whole-archive" "-Wl,-Bdynamic" "-lX11" "-lXext" "-lXrandr" "-lXfixes" "-lXcomposite" "-lXi" "-Wl,-Bstatic" "-Wl,--whole-archive" "-lva" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-drm" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-glx" "-Wl,--no-whole-archive" "-Wl,--whole-archive" "-lva-x11" "-Wl,--no-whole-archive" "-Wl,-Bdynamic" "-ldrm" "-Wl,-Bstatic" "/tmp/rustcjy6GZP/libfltk_sys-7019b68ba31ee00d.rlib" "-Wl,--start-group" "/tmp/rustcjy6GZP/libbacktrace_sys-5db30a83f5489d12.rlib" "-Wl,--end-group" "/usr/local/rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-f7cd12d3ecd59a89.rlib" "-Wl,-Bdynamic" "-lssl" "-lcrypto" "-lX11" "-lXtst" "-lstdc++" "-lpthread" "-lX11" "-lXext" "-lXinerama" "-lXcursor" "-lXrender" "-lXfixes" "-lXft" "-lfontconfig" "-lGL" "-lGLU" "-lutil" "-ldl" "-lutil" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-ldl" "-lutil"
  = note: deps/dist/lib/libavformat.a(network.o): In function `ff_socket':
          network.c:(.text+0x255): undefined reference to `fcntl64'
          deps/dist/lib/libavformat.a(os_support.o): In function `ff_socket_nonblock':
          os_support.c:(.text+0x12): undefined reference to `fcntl64'
          os_support.c:(.text+0x31): undefined reference to `fcntl64'
          os_support.c:(.text+0x26): undefined reference to `fcntl64'
          deps/dist/lib/libavutil.a(file_open.o): In function `avpriv_open':
          file_open.c:(.text+0x5f): undefined reference to `fcntl64'
          collect2: error: ld returned 1 exit status
          

error: aborting due to previous error

error: could not compile `weylus`.

To learn more, run the command again with --verbose.
cargo-deb: build failed

It appears that the docker container has a too-old version of glibc. fcntl64 was introduced in glibc 2.28, but stretch has glibc 2.24. I tried changing the Dockerfile from debian:stretch to debian:buster, and this time everything built fine. This is undoing part of 90991fd. I presume there was a reason for that, so I'm probably breaking something else by doing this.

As I said, the weirdest thing about this to me is that it builds just fine in CI using the same Docker image, so I'm more than willing to believe it's an error on my end. It's building find on my modified image. But in case anyone else runs into the same issue, I thought I note it here.

Windows, MacOS, Linux issues

I have an iPad from 5th, so it doesn't support the Apple Pencil and I did the following tests with an touch stylus flat-tipped (Rather accurate.).

Windows 10 (20H2):

I tried to make it work even though I knew what I was getting into, and the remote touchscreen does not work (Even if the option is enabled.) but mirroring screen does (Except that it does not show the pointer.).
Running as administrator or changing parameters does not change the result. I can't even select hardware acceleration, I don't use proxy or VPN, maybe it's the DNS? I don't think so, because I use it on all my devices.

MacOS 10.15 (in VM):

Executed on the same machine and identical problem. 🤷‍♂️

Linux Mint 20:

Tried it on my old laptop and it's really lightweight, ignoring those small defects due to control remote works very well. (It will be possible to connect via USB to reduce latency?)
The first test I did was to go on skribble.io to do some sketches and in drawing a circle, I get an D.
IMG_8491 20-11-09 03_48_41
I tried again later on GIMP and it was most close an circle.
Prova

I noticed that the first time I run on each OS from this error:
ERROR Failed binding to socket: Required address not valid in your context. (os error 10049)
After that no longer appears.

That's all~

Doesn't seem to work (Solved).

Hello. I followed the instructions in the readme. I installed the .deb package, and followed the instructions for uinput. The program runs on my computer, but when I connect to the ip address given by the program on my phone, I am greeted with a settings screen, and nothing changes from there. It says the device makes a connection, but it doesn't appear to do anything afterward. Am I doing something wrong, perhaps?

v0.7.1 can't start on Ubuntu 18.04 (bionic)

Start-up error message is:

weylus: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by weylus)

~$ ldd -r $(which weylus)

/opt/bin/weylus: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by /opt/bin/weylus)
        linux-vdso.so.1 (0x00007ffd92ac1000)
        libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f5167997000)
        libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f5167785000)
        libXrandr.so.2 => /usr/lib/x86_64-linux-gnu/libXrandr.so.2 (0x00007f516757a000)
        libXfixes.so.3 => /usr/lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007f5167374000)
        libXtst.so.6 => /usr/lib/x86_64-linux-gnu/libXtst.so.6 (0x00007f516716e000)
        libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f5166de5000)
        libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f5166bc6000)
        libXinerama.so.1 => /usr/lib/x86_64-linux-gnu/libXinerama.so.1 (0x00007f51669c3000)
        libXcursor.so.1 => /usr/lib/x86_64-linux-gnu/libXcursor.so.1 (0x00007f51667b9000)
        libXrender.so.1 => /usr/lib/x86_64-linux-gnu/libXrender.so.1 (0x00007f51665af000)
        libXft.so.2 => /usr/lib/x86_64-linux-gnu/libXft.so.2 (0x00007f516639a000)
        libfontconfig.so.1 => /usr/lib/x86_64-linux-gnu/libfontconfig.so.1 (0x00007f5166155000)
        libGL.so.1 => /home/user/opt/blender/lib/libGL.so.1 (0x00007f5163fdf000)
        libGLU.so.1 => /home/user/opt/blender/lib/libGLU.so.1 (0x00007f5163d34000)
        libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f5163b30000)
        librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f5163928000)
        libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f5163710000)
        libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f516331f000)
        libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f5162f81000)
        libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f5162d59000)
        /lib64/ld-linux-x86-64.so.2 (0x00007f5169b31000)
        libfreetype.so.6 => /usr/lib/x86_64-linux-gnu/libfreetype.so.6 (0x00007f5162aa5000)
        libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007f5162873000)
        libglapi.so.0 => /home/user/opt/blender/lib/libglapi.so.0 (0x00007f5162641000)
        libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f5162424000)
        libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f5162220000)
        libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f516201a000)
        libpng16.so.16 => /usr/lib/x86_64-linux-gnu/libpng16.so.16 (0x00007f5161de8000)
        libbsd.so.0 => /lib/x86_64-linux-gnu/libbsd.so.0 (0x00007f5161bd3000)
symbol fcntl64 version GLIBC_2.28 not defined in file libc.so.6 with link time reference        (/opt/bin/weylus)

I used linux.zip distribution, thinking of it as static build. Unfortunately it isn't. Checking size and checksums for both zip and deb distributions showed that both are same.
Version after v0.7.0 cannot be used or installed on Ubuntu 18.04.

Do not send password as query

tl;dr: please remove password feature because it's making the app even more unsecure

First of all, THANK YOU so much for publishing this Amazing software for free!
It works well enough for me on my ancient ThinkPad T420 with Ubuntu 20.04 OS. (Although I haven't tested "use as second monitor" thingy)

However, it seems you've added in a feature that's in my opinion not really a feature but rather a security threat. You've added in a password feature using query in the URL. However, the UR location nor the address bar in modern browsers should be used for any secure information. I'm no expert but the least, URLs are stored in browser history which anyone using the computer can easily get access to, and the content in the address bar is sent to a search engine for autocomplete. This is especially unsecure if the user's browser is slightly compromised so that the autocomplete search engine is redirected onto a malicious server (which is the case for my parents' laptop currently). The password is also visible in the unencrypted packet of HTTP which this program uses.

As virtually everyone knows, HTTP is by nature unsecure and naming a feature named "password" may give the user the impression of security while using this application. If the user thus uses their password which they use for other uses on Weylus, this could be another security threat.

As of now, I believe it's better for security to remove password feature as is. So I suggest you do.

Again, THANK YOU SOOO MUCH for this masterpiece!

p.s. It would be nice if you could afford to add in a fullscreen feature.

Works on computer but not iPad/iPhone

I'm using weylus 0.9.1 on Pop!_os 20.10, and for some reason it isn't working correctly on my iOS devices but seems to work fine on another computer. I have an iPad mini on iOS 12.4.9 and when I try to access weylus from safari the page is white, the capture list is empty, and I don't have any control over the computer. The same thing happened when I tried Brave browser so I don't think it's a browser issue. On my iPhone running iOS 14.1, I get a grey screen and I have control of the computer, but there's no video feed so I can't see what I'm doing. Everything worked as expected when I tested it on chromebook in google chrome, so the only devices I'm having problems with are the iOS ones. Is there something I'm doing wrong or does this program not fully support iOS devices?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.