The mtif Reference Manual

This is the mtif Reference Manual, version 0.1.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 07:07:14 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 mtif

An interface to the MacOS MultiTouch framework

Author

Ric da Silva <>

License

MIT

Version

0.1.0

Dependency

cffi (system).

Source

mtif.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 mtif/mtif.asd

Source

mtif.asd.

Parent Component

mtif (system).

ASDF Systems

mtif.


3.1.2 mtif/package.lisp

Source

mtif.asd.

Parent Component

mtif (system).

Packages

3.1.3 mtif/mtif-ffi.lisp

Source

mtif.asd.

Parent Component

mtif (system).

Internals

3.1.4 mtif/mtif.lisp

Source

mtif.asd.

Parent Component

mtif (system).

Public Interface
Internals

4 Packages

Packages are listed by definition order.


4.1 mtif

Source

package.lisp.

Use List
  • cffi.
  • common-lisp.
Used By List

mtif-user.

Public Interface
Internals

4.2 mtif-user

Source

package.lisp.

Use List
  • common-lisp.
  • mtif.

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Special variables

Special Variable: *frame-count*

The number of frames received since last call to ‘start’

Package

mtif.

Source

mtif.lisp.

Special Variable: *mtif-started*

Whether we have started using a device or not

Package

mtif.

Source

mtif.lisp.


5.1.2 Ordinary functions

Reader: finger-ellipse-angle (instance)
Writer: (setf finger-ellipse-angle) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

ellipse-angle.

Reader: finger-ellipse-major-axis (instance)
Writer: (setf finger-ellipse-major-axis) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

ellipse-major-axis.

Reader: finger-ellipse-minor-axis (instance)
Writer: (setf finger-ellipse-minor-axis) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

ellipse-minor-axis.

Reader: finger-id (instance)
Writer: (setf finger-id) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

id.

Reader: finger-pos-x (instance)
Writer: (setf finger-pos-x) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

pos-x.

Reader: finger-pos-y (instance)
Writer: (setf finger-pos-y) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

pos-y.

Reader: finger-size (instance)
Writer: (setf finger-size) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

size.

Reader: finger-state (instance)
Writer: (setf finger-state) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

state.

Reader: finger-vel-x (instance)
Writer: (setf finger-vel-x) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

vel-x.

Reader: finger-vel-y (instance)
Writer: (setf finger-vel-y) (instance)
Package

mtif.

Source

mtif.lisp.

Target Slot

vel-y.

Function: print-all-touches (finger-data timestamp frame)

Example callback which just prints all touches to *standard-output*

Package

mtif.

Source

mtif.lisp.

Function: start (callback &optional frame-limit)

Start the MT interface with ‘callback’ receiving the data

Package

mtif.

Source

mtif.lisp.

Function: stop ()

Stop the MT interface

Package

mtif.

Source

mtif.lisp.


5.1.3 Standalone methods

Method: translate-from-foreign (ptr (type c-finger))

‘ptr’ is to c-finger type

Package

cffi.

Source

mtif.lisp.


5.1.4 Conditions

Condition: err-already-started
Package

mtif.

Source

mtif.lisp.

Direct superclasses

simple-error.

Condition: err-not-started
Package

mtif.

Source

mtif.lisp.

Direct superclasses

simple-error.


5.2 Internals


5.2.1 Special variables

Special Variable: *frame-limit*

Maximum number of frames to process (ignored if nil)

Package

mtif.

Source

mtif.lisp.

Special Variable: *init-complete*

Signal whether things have been setup

Package

mtif.

Source

mtif.lisp.

Special Variable: *mtif-callback*

User callback to call with the touchpad data

Package

mtif.

Source

mtif.lisp.

Special Variable: *mtif-handle*

Handle to the MT device, used for stopping/starting

Package

mtif.

Source

mtif.lisp.


5.2.2 Ordinary functions

Function: copy-finger (instance)
Package

mtif.

Source

mtif.lisp.

Function: finger-p (object)
Package

mtif.

Source

mtif.lisp.

Function: get-readout (mtreadout slot1 slot2)
Package

mtif.

Source

mtif.lisp.

Function: init-device ()

Initial setup - create device, register callback

Package

mtif.

Source

mtif.lisp.

Function: make-finger (&key id state size pos-x pos-y vel-x vel-y ellipse-angle ellipse-major-axis ellipse-minor-axis)
Package

mtif.

Source

mtif.lisp.

Function: mtdevicecreatedefault ()
Package

mtif.

Source

mtif-ffi.lisp.

Function: mtdevicestart (device unused)
Package

mtif.

Source

mtif-ffi.lisp.

Function: mtdevicestop (device)
Package

mtif.

Source

mtif-ffi.lisp.

Function: mtregistercontactframecallback (device callback)
Package

mtif.

Source

mtif-ffi.lisp.

Function: mtunregistercontactframecallback (device callback)
Package

mtif.

Source

mtif-ffi.lisp.

Function: reset ()

Reset the device

Package

mtif.

Source

mtif.lisp.


5.2.3 Structures

Structure: finger

Finger data

Package

mtif.

Source

mtif.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: id
Initform

"numeric identifier for this finger"

Readers

finger-id.

Writers

(setf finger-id).

Slot: state
Initform

"the finger state"

Readers

finger-state.

Writers

(setf finger-state).

Slot: size
Initform

"measure of the area covered by the finger"

Readers

finger-size.

Writers

(setf finger-size).

Slot: pos-x
Initform

"normalised x position"

Readers

finger-pos-x.

Writers

(setf finger-pos-x).

Slot: pos-y
Initform

"normalised y position"

Readers

finger-pos-y.

Writers

(setf finger-pos-y).

Slot: vel-x
Initform

"normalised x velocity"

Readers

finger-vel-x.

Writers

(setf finger-vel-x).

Slot: vel-y
Initform

"normalised y velocity"

Readers

finger-vel-y.

Writers

(setf finger-vel-y).

Slot: ellipse-angle
Initform

"angle of the finger ellipsoid"

Readers

finger-ellipse-angle.

Writers

(setf finger-ellipse-angle).

Slot: ellipse-major-axis
Initform

"major axis of the finger ellipsoid"

Readers

finger-ellipse-major-axis.

Writers

(setf finger-ellipse-major-axis).

Slot: ellipse-minor-axis
Initform

"minor axis of the finger ellipsoid"

Readers

finger-ellipse-minor-axis.

Writers

(setf finger-ellipse-minor-axis).


5.2.4 Classes

Class: c-finger
Package

mtif.

Source

mtif-ffi.lisp.

Direct superclasses
  • foreign-struct-type.
  • translatable-foreign-type.
Direct methods

translate-from-foreign.

Class: mtpoint-tclass
Package

mtif.

Source

mtif-ffi.lisp.

Direct superclasses
  • foreign-struct-type.
  • translatable-foreign-type.
Class: mtreadout-tclass
Package

mtif.

Source

mtif-ffi.lisp.

Direct superclasses
  • foreign-struct-type.
  • translatable-foreign-type.

Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   (  
C   F   G   I   M   P   R   S   T  
Index Entry  Section

(
(setf finger-ellipse-angle): Public ordinary functions
(setf finger-ellipse-major-axis): Public ordinary functions
(setf finger-ellipse-minor-axis): Public ordinary functions
(setf finger-id): Public ordinary functions
(setf finger-pos-x): Public ordinary functions
(setf finger-pos-y): Public ordinary functions
(setf finger-size): Public ordinary functions
(setf finger-state): Public ordinary functions
(setf finger-vel-x): Public ordinary functions
(setf finger-vel-y): Public ordinary functions

C
copy-finger: Private ordinary functions

F
finger-ellipse-angle: Public ordinary functions
finger-ellipse-major-axis: Public ordinary functions
finger-ellipse-minor-axis: Public ordinary functions
finger-id: Public ordinary functions
finger-p: Private ordinary functions
finger-pos-x: Public ordinary functions
finger-pos-y: Public ordinary functions
finger-size: Public ordinary functions
finger-state: Public ordinary functions
finger-vel-x: Public ordinary functions
finger-vel-y: Public ordinary functions
Function, (setf finger-ellipse-angle): Public ordinary functions
Function, (setf finger-ellipse-major-axis): Public ordinary functions
Function, (setf finger-ellipse-minor-axis): Public ordinary functions
Function, (setf finger-id): Public ordinary functions
Function, (setf finger-pos-x): Public ordinary functions
Function, (setf finger-pos-y): Public ordinary functions
Function, (setf finger-size): Public ordinary functions
Function, (setf finger-state): Public ordinary functions
Function, (setf finger-vel-x): Public ordinary functions
Function, (setf finger-vel-y): Public ordinary functions
Function, copy-finger: Private ordinary functions
Function, finger-ellipse-angle: Public ordinary functions
Function, finger-ellipse-major-axis: Public ordinary functions
Function, finger-ellipse-minor-axis: Public ordinary functions
Function, finger-id: Public ordinary functions
Function, finger-p: Private ordinary functions
Function, finger-pos-x: Public ordinary functions
Function, finger-pos-y: Public ordinary functions
Function, finger-size: Public ordinary functions
Function, finger-state: Public ordinary functions
Function, finger-vel-x: Public ordinary functions
Function, finger-vel-y: Public ordinary functions
Function, get-readout: Private ordinary functions
Function, init-device: Private ordinary functions
Function, make-finger: Private ordinary functions
Function, mtdevicecreatedefault: Private ordinary functions
Function, mtdevicestart: Private ordinary functions
Function, mtdevicestop: Private ordinary functions
Function, mtregistercontactframecallback: Private ordinary functions
Function, mtunregistercontactframecallback: Private ordinary functions
Function, print-all-touches: Public ordinary functions
Function, reset: Private ordinary functions
Function, start: Public ordinary functions
Function, stop: Public ordinary functions

G
get-readout: Private ordinary functions

I
init-device: Private ordinary functions

M
make-finger: Private ordinary functions
Method, translate-from-foreign: Public standalone methods
mtdevicecreatedefault: Private ordinary functions
mtdevicestart: Private ordinary functions
mtdevicestop: Private ordinary functions
mtregistercontactframecallback: Private ordinary functions
mtunregistercontactframecallback: Private ordinary functions

P
print-all-touches: Public ordinary functions

R
reset: Private ordinary functions

S
start: Public ordinary functions
stop: Public ordinary functions

T
translate-from-foreign: Public standalone methods