All Projects → jahnf → Projecteur

jahnf / Projecteur

Licence: mit
Linux Desktop Application for the Logitech Spotlight device (and similar devices) - Digital Laser Pointer

Projects that are alternatives of or similar to Projecteur

Tbe
The Butterfly Effect, a realistic physics simulation game
Stars: ✭ 63 (-68.34%)
Mutual labels:  qt5, qml
Autoannotationtool
A label tool aim to reduce semantic segmentation label time, rectangle and polygon annotation is supported
Stars: ✭ 113 (-43.22%)
Mutual labels:  qt5, qml
Kaidan
[Replaced by https://invent.kde.org/network/kaidan] Kaidan, a simple and user-friendly Jabber/XMPP client for every device and platform.
Stars: ✭ 67 (-66.33%)
Mutual labels:  qt5, qml
Ipconnect
P2P Chat and File Transfer Desktop Application
Stars: ✭ 53 (-73.37%)
Mutual labels:  qt5, qml
Shell
🐚 QtQuick and Wayland shell for convergence
Stars: ✭ 168 (-15.58%)
Mutual labels:  qt5, qml
Osgqtquick
Intergation OpenSceneGraph to Qt Quick
Stars: ✭ 53 (-73.37%)
Mutual labels:  qt5, qml
Jagcs
Just another ground control station
Stars: ✭ 99 (-50.25%)
Mutual labels:  qt5, qml
Workspace
🚀 Base applications and settings for Liri OS
Stars: ✭ 9 (-95.48%)
Mutual labels:  qt5, qml
Haruna
Open source video player built with Qt/QML and libmpv.
Stars: ✭ 147 (-26.13%)
Mutual labels:  qt5, qml
Pan Light
百度网盘不限速客户端, golang + qt5, 跨平台图形界面
Stars: ✭ 11,706 (+5782.41%)
Mutual labels:  qt5, qml
Spix
UI test automation library for QtQuick/QML Apps
Stars: ✭ 48 (-75.88%)
Mutual labels:  qt5, qml
Browser
🌍 Cross-platform Material design web browser
Stars: ✭ 184 (-7.54%)
Mutual labels:  qt5, qml
Beamerpresenter
Simple dual screen pdf presentation software
Stars: ✭ 30 (-84.92%)
Mutual labels:  presentation, qt5
Awesome Qt Qml
A curated list of awesome Qt and QML libraries, resources, projects, and shiny things.
Stars: ✭ 1,118 (+461.81%)
Mutual labels:  qt5, qml
Progressbarcollection
I create this application to show up the demonstration for the collection of progress bars
Stars: ✭ 21 (-89.45%)
Mutual labels:  qt5, qml
Kindd
A kindful dd, written in qt-quick.
Stars: ✭ 93 (-53.27%)
Mutual labels:  qt5, qml
Scihubeva
A Cross Platform Sci-Hub GUI Application
Stars: ✭ 683 (+243.22%)
Mutual labels:  qt5, qml
Virtscreen
Make your iPad/tablet/computer into a secondary monitor on Linux.
Stars: ✭ 887 (+345.73%)
Mutual labels:  qt5, qml
Qmlnotify
Awesome notification server in QML
Stars: ✭ 114 (-42.71%)
Mutual labels:  qt5, qml
Qt5.cr
Qt5 bindings for Crystal, based on Bindgen
Stars: ✭ 182 (-8.54%)
Mutual labels:  qt5, desktop-application

Projecteur

develop: Build Status develop master: Build Status master

Linux/X11 application for the Logitech Spotlight device (and similar devices).
See Download section for binary packages.

Motivation

I saw the Logitech Spotlight device in action at a conference and liked it immediately. Unfortunately as in a lot of cases, software is only provided for Windows and Mac. The device itself works just fine on Linux, but the cool spotlight feature is only available using additional software.

So here it is: a Linux application for the Logitech Spotlight.

Table of Contents

Features

  • Configurable desktop spotlight
    • shade color, opacity, cursor, border, center dot and different shapes
    • Zoom (magnifier) functionality
  • Multiple screen support
  • Support of devices beyond the Logitech Spotlight (see Device Support)
  • Button mapping:
    • Map any button on the device to (almost) any keyboard combination.
    • Switch between (cycle through) custom spotlight presets.
  • Vibration (Timer) Support for the Logitech Spotlight (USB)
  • Usable without a presenter device (e.g. for online presentations)

Screenshots

Planned features

  • Support for more customizable button mapping actions.
  • Support of more proprietary features of the Logitech Spotlight and other devices.

Supported Environments

The application was mostly tested on Ubuntu 18.04, Ubuntu 20.04 (GNOME) and OpenSuse 15 (GNOME) but should work on almost any Linux/X11 Desktop. In case you are building the application yourself, make sure you have the correct udev rules installed (see pre-requisites section).

How it works

With a connection via the USB Dongle Receiver or via Bluetooth, the Logitech Spotlight device will be detected by Linux as a HID device with mouse and keyboard events. As mouse events, the device sends relative cursor movements and left button presses. Acting as a keyboard, the device basically just sends left and right arrow key press events when forward or back is pressed on the device.

The mouse move events of the device are what we are mainly interested in. Since the device is already detected as a mouse input device and able to move the cursor, we simply detect if the Spotlight device is sending mouse move events. If it is sending mouse events, we will 'turn on' the desktop spot (virtual laser).

For more details: Have a look at the source code ;)

Button mapping

Button mapping works by grabbing all device events of connected devices and forwarding them to a virtual 'uinput' device if not configured differently by the button mapping configuration. If a mapped configuration for a button exists, Projecteur will inject the mapped keyboard events instead. (You can still disable device grabbing with the --disable-uinput command line option - button mapping will be disabled then.)

Download

The latest binary packages for some Linux distributions are available for download on cloudsmith. Currently binary packages for Ubuntu, Debian, Fedora, OpenSuse, CentOS and Arch Linux are automatically built. For release version downloads you can also visit the project's github releases page.

  • Latest release:
    • on cloudsmith: cloudsmith-rel-badge
    • on secondery server: projecteur-rel-badge
  • Latest development version:
    • on cloudsmith: cloudsmith-dev-badge
    • on secondary server: projecteur-dev-badge

See also the list of Linux repositories where Projecteur is available.

Building

Requirements

  • C++14 compiler
  • CMake 3.6 or later
  • Qt 5.7 and later

Build Example

    git clone https://github.com/jahnf/Projecteur
    cd Projecteur
    mkdir build && cd build
    cmake ..
    make

Building against other Qt versions, than the default one from your Linux distribution can be done by setting the QTDIR variable during CMake configuration.

Example: QTDIR=/opt/Qt/5.9.6/gcc_64 cmake ..

Installation/Running

Pre-requisites

When building Projecteur yourself

The input devices detected from the Spotlight device must be readable to the user running the application. To make this easier there is a udev rule template file in this repository: 55-projecteur.rules.in

  • During the CMake run, the file 55-projecteur.rules will be created from this template in your build directory. Copy that generated file to /lib/udev/rules.d/55-projecteur.rules
  • Most recent systems (using systemd) will automatically pick up the rule. If not, run sudo udevadm control --reload-rules and sudo udevadm trigger to load the rules without a reboot.
  • After that, the input devices from the Logitech USB Receiver (but also the Bluetooth device) in /dev/input should be readable/writable by you. (See also about device detection)
  • When building against the Qt version that comes with your distribution's packages, you might need to install some additional QML module packages. For example this is the case for Ubuntu, where you need to install the packages qml-module-qtgraphicaleffects, qml-module-qtquick-window2, qml-modules-qtquick2 and qtdeclarative5-dev to satisfy the application's run time dependencies.

Application Menu

The application menu is accessible via the system tray icon. There you will find the preferences and the menu entry to exit the application. If the system tray icon is missing, see the Troubleshooting section.

Command Line Interface

Additional to the standard --help and --version options, there is an option to send commands to a running instance of Projecteur and the ability to set properties.

Usage: projecteur [OPTION]...

<Options>
  -h, --help             Show command line usage.
  --help-all             Show complete command line usage with all properties.
  -v, --version          Print application version.
  -f, --fullversion      Print extended version info.
  --cfg FILE             Set custom config file.
  -d, --device-scan      Print device-scan results.
  -l, --log-level LEVEL  Set log level (dbg,inf,wrn,err), default is 'inf'.
  --show-dialog          Show preferences dialog on start.
  -m, --minimize-only    Only allow minimizing the preferences dialog.
  -D DEVICE              Additional accepted device; DEVICE=vendorId:productId
  -c COMMAND|PROPERTY    Send command/property to a running instance.

<Commands>
  spot=[on|off|toggle]   Turn spotlight on/off or toggle.
  settings=[show|hide]   Show/hide preferences dialog.
  quit                   Quit the running instance.

A complete list the properties that can be set via the command line, can be listed with the --help-all option or can also be found on the man pagers with newer versions of Projecteur (man projecteur).

Scriptability

Projecteur allows you to set almost all aspects of the spotlight via the command line for a running instance.

Example:

# Set showing the border to true
projecteur -c border=true
# Set the border color to red
projecteur -c border.color=#ff0000

While Projecteur does not provide global keyboard shortcuts, command line options can but utilized for that. For instance, if you like to use Projecteur as a tool while sharing your screen in a video call without additional presenter hardware, you can assign global shortcuts in your window manager (e.g. GNOME) to run the commands projecteur -c spot=on and projecteur -c spot=off or projecteur -c spot=toggle, and therefore turning the spot on and off with a keyboard shortcut.

Using Projecteur without a device

You can use Projecteur for your online presentations and video conferences without a presenter device. For this you can assign a global keyboard shortcut in your window manager (e.g. KDE, GNOME...) to run the command projecteur -c spot=toggle. You will then be able to turn the digital spot on and off with the assigned keyboard shortcut while sharing your screen in an online presentation or call.

Device Support

Besides the Logitech Spotlight, the following devices are currently supported out of the box:

  • AVATTO H100 / August WP200 (0c45:8101)
  • August LP315 (2312:863d)
  • AVATTO i10 Pro (2571:4109)

Compile Time

Besides the Logitech Spotlight, similar devices can be used and are supported. Additional devices can be added to devices.conf. At CMake configuration time, the project will be configured to support these devices and also create entries for them in the generated udev-rule file.

Runtime

Projecteur will also accept devices as supported when added via the -D command line option.

Example: projecteur -D 04b3:310c

This will enable devices within Projecteur and the application will try to connect to that device if it is detected. It is, however, up to the user to make sure the device is accessible (via udev rules).

Troubleshooting

Opaque Spotlight / No Transparency

To be able to show transparent windows, a compositing manager is necessary. If there is no compositing manager running you will see the spotlight overlay as an opaque window.

  • On KDE it might be necessary to turn on Desktop effects to allow transparent windows.
  • Depending on your Linux Desktop and configuration there might not be a compositing manager running by default. You can run xcompmgr, compton or others manually.
    • Examples: xcompmgr -c -t-6 -l-6 -o.1 or xcompmgr -c

Missing System Tray

Projecteur was developed and tested on GNOME and KDE Desktop environments, but should work on most other desktop environments. If the system tray with the Application Menu is not showing, commands can be send to the application to bring up the preferences dialog, test the spotlight, quit the application or set spotlight properties. See Command Line Interface. There is also a command line option (-m) to prevent the preferences dialog from hiding, allowing it only to minimize - behaving more like a regular application window.

On some distributions that have a GNOME Desktop by default there is no system tray extensions installed (Fedora for example). You can install the KStatusNotifierItem/AppIndicator Support or the TopIcons Plus GNOME extension to have a system tray that can show the Projecteur tray icon (and also from other applications like Dropbox or Skype).

Zoom is not updated while spotlight is shown

Zoom does not update while spotlight is shown due to how the zoom currently works. A screenshot is taken shortly before the overlay window is shown, and then a magnified section is shown wherever the mouse/spotlight is. If the zoom would be updated while the overlay window is shown, the overlay window it self would show up in the magnified section. That is a general problem that other magnifier tools also face, although they get around the problem by showing the magnified content rectangle always in the same position on the screen.

Wayland

While not developed with Wayland in mind, users reported Projecteur works with Wayland. If you experience problems, you can try to set the QT_QPA_PLATFORM environment variable to wayland, example:

[email protected]:~/Projecteur/build$ QT_QPA_PLATFORM=wayland ./projecteur
Using Wayland-EGL

Wayland Zoom

On Wayland the Zoom feature is currently only implemented on KDE and GNOME. This is done with the help of their respective DBus interfaces for screen capturing. On other environments with Wayland, the zoom feature is not currently supported.

Device shows as not connected

If the device shows as not connected, there are some things you can do:

  • Check for devices with Projecteur's command line option -d or --device-scan option. This will show you a list of all supported and detected devices and also if they are readable/writable. If a detected device is not readable/writable, it is an indicator that there is something wrong with the installed udev rules.
  • Manually on the shell: Check if the device is detected by the Linux system: Run cat /proc/bus/input/devices | grep -A 5 "Vendor=046d"
    This should show one or multiple spotlight devices (among other Logitech devices)
    • Check that the corresponding /dev/input/event?? device file is readable by you.
      Example: test -r /dev/input/event19 && echo "SUCCESS" || echo "NOT readable"
  • Make sure you don't have conflicting udev rules installed, e.g. first you installed the udev rule yourself and later you used the automatically built Linux packages to install Projecteur.

Changelog

See CHANGELOG.md for a detailed changelog.

License

Copyright 2018-2021 Jahn Fuchs

This project is distributed under the MIT License, see LICENSE.md for more information.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].