Skip to content

SubPixel Interaction

Izzatbek Mukhanov edited this page Sep 26, 2016 · 2 revisions

Choose the level of precision you need.

The high sensitivity of current input devices can be harnessed to enable precise direct manipulation “in between” pixels, called subpixel interaction.

Why pixels are not enough?

One of the simplest examples is a Video Player with a fixed timeline slider. Moving this slider by 1 pixel may skip a video for a significant amount of time. However, allowing subpixel interaction, we can not only scroll second by second, but also frame by frame, if parameters are set properly.

There are a myriad of other examples where there are not enough pixels to provide the required precision: picking a particular item in a large list using a slider; image navigation and editing (e.g. accurately cropping a megapixel image, picking a precise location on a map); resizing a calendar event to minute precision (e.g. when booking flight departures or lawyers tracking billing time); high precision vector drawing tasks (e.g. drawing a structural wall to centimeter precision or aligning objects in vertex-dense areas); or manipulating objects in 3D applications.

Cardinality and widget size

Cardinality is the number of elements which users expect to select from, i.e. proportional to tht level of precision.

Widget size is the size of the widget in pxs. Those two parameters are required to define a transfer function necessary to handle a given task.

  • N ≤ P: all values of the model can be addressed with a standard integer pointer, subpixel interaction is unnecessary but compatible;
  • P < N ≤ N1: all values of the model can only be addressed with subpixel interaction, but a standard transfer function is compatible without any change in pointer behavior;
  • N1 < N ≤ N2: to address all model values with subpixel interaction, a custom transfer function like those described earlier is required;
  • N > N2: all model values cannot be addressed with subpixel interaction.

Four zones of applicability for subpixel and custom transfer functions

Read more in Giving a hand to the eyes: leveraging input accuracy for subpixel interaction by N. Roussel, G. Casiez, J. Aceituno and D. Vogel.

How to use?

Subpixel functionality can be used with the libpointing transfer functions. In order to create a Subpixel transfer function, one needs to use transfer function scheme subpixel:, as well as the following query arguments:

  • cardinality - resolution level (the number of elements to select from)
  • widgetSize - widget size in pxs
  • resHuman - The smallest target size that users can acquire with an ordinary amount of effort using a particular device. It is optional, by default equals to 400 CPI.

In order to use subpixel functionality SubPixelFunction object must be created. There are two constructors that can be used:

  1. SubPixelFunction(uri, input, output) - Where uri is transfer function uri with subpixel scheme containing transFunc query argument defining original transfer function, upon which the Subpixel functionality is built. In order to use another uri as a query argument in a existing uri the first one must be encoded using URI::encode.
  2. SubPixelFunction(uri, originalUri, input, output) can be used to avoid uri nesting, in this case, the original transfer function uri can be given directly.

Subpixeling can be turned on/off using the setSubPixeling(subpixeling) method.