mcpp index

compat.mtdev

#include

mtdev 1.1.7 — kernel multitouch protocol A to B translation, for libinput

#include <mtdev.h>
mcpp add compat.mtdev@1.1.7

Usage

From this repository's own test project — built and run by CI, not written for the website.

// compat.mtdev — behavioral test, no input device required.
//
// mtdev translates kernel multitouch protocol A into protocol B. The test
// exercises the translator's own state machine rather than a device: the
// interesting failure is a package that links but whose slot machinery was
// compiled out, and that shows up here rather than on a touchscreen.

#ifdef __linux__

#include <mtdev.h>
#include <mtdev-plumbing.h>
#include <linux/input.h>

#include <cstdio>
#include <cstring>

namespace {
int failures = 0;
void check(bool ok, const char *what)
{
    std::printf("%-58s %s\n", what, ok ? "ok" : "FAILED");
    if (!ok) ++failures;
// …

tests/examples/mtdev/tests/mtdev.cpp · project tests/examples/mtdev

Build

targets
mtdev (lib)
language
c++23
C standard
c11
import std
no
include dirs
*/include, */src

Sources (5)

  • */src/caps.c
  • */src/core.c
  • */src/iobuf.c
  • */src/match.c
  • */src/match_four.c

Versions

VersionPlatforms Mirrorssha256
1.1.7 latest Linux GLOBAL CN a55bd02a9af4…