Wacom api docs

It took me way more effort than i expected to find Wacom’s developer docs and code samples, so maybe it’ll help somebody out to link up


I’m struggling a bit at the moment to get things working under osx but you’re probably smarter than I am! :slight_smile:


good luck with that -

on the win32 side there is bbtablet (a dll / lib for tablet coding) http://www.billbaxter.com/projects/bbtablet/index.html

also this is useful to know about for older tablets / mac:

  • z


I’m trying to hook up a wacom intuous 3 A5 usb tablet and basically just be able to use it as a tablet to draw on a fullscreen app. For Windows, probably.

I also need to save what’s drawn to file - I’m hoping to be able to use the buttons on the tablet to control some basic operations (clear the board, save the file, basically - the filename will be generated for you). The ideas is to hide the regular mouse and keyboard so people don’t get funny ideas in an exhibition setting… :wink:

I’ve looked at doing it in Processing and sort of got it working, but it’s horribly slow when running in higher (window) resolutions. Openframeworks to the rescue! I might still go for Java with JOGL instead, we’ll see.

I’ll let you know how it goes… for starters, here are my live bookmarks on this:


cool !

the windows stuff is really easy, as I remember…

in testApp.h:

#include "bbTablet.h"  

in setup():

HWND wnd = WindowFromDC(wglGetCurrentDC());  
bbTabletDevice &td = bbTabletDevice::getInstance( );  
td.initTablet( wnd, bbTabletDevice::SYSTEM_POINTER );  

then, to get info for pressure, etc, in something like mouseDrag, you can do this:

void testApp::mouseDrag( float x, float y, int button){  
bbTabletDevice &td = bbTabletDevice::getInstance();  
bbTabletEvent evt;  
if (td.getNextEvent(evt)){  
       pressure = 1.0f + 20.0f * powf(evt.pressure, 3.0f);  

evt.pressure is a float (between 0 and 1) so I think I was shaping it a bit with the powf to make it so you had to press harder to get a thick line.

I think that you can access buttons, etc from the wintab lib –

I hope that helps!


May be this can help… is for processing/java but working in JNI so is cocoa or c code involved



I know it’s a little lame to give old topics a bump, but has anyone had any ideas on working with Wacom on OSX? I got the tableeventdemo from http://www.wacomeng.com/devsupport/mac/downloads.html which looks ok, but is pretty old, and I don’t even have a wacom to test with so it’s all academic at this point. bbTablet looks really great, wish there was a C++ OSX version of it…I glanced at the infostuka stuff but the src for the JNI library that he’s using isn’t in the source, so I’m wondering if anyone else has done anything semi-similar. Thanks,


I’ll let you know how it goes…

Oops, I never did follow up on this. How rude. One possible excuse is that I never actually used oF with the wacom board, I ended up doing it in Processing with JTablet (see http://sketchstudio.cellosoft.com/). Turns out it was fast enough after all.

I wrote a little about the piece (made for artist Ulrika Sparre) at http://bridell.com/mental-radio/ but I never posted any code, if you need it just e-mail me at fredrik@bridell.com.


hei hei…

i’ve found this thread, and i was wondering if anyone has got a wacom tablet fully working with openframeworks and mac os x…ofw mouse events do not capture all wacom buttons, have a big delay in mouse movements and of course do not capture tablet’s pressure and additional parameters…

the info at http://www.wacomeng.com/devsupport/mac/downloads.html seems very low-level and quite hard to deal with, and i’ve contacted a former wacom programmer who told me:

"I’m don’t know if OF is built on top of carbon or cocoa, so it kinda depends on that.

The easiest thing to to may be to just get the current event and pull the tablet data out of that. In Cocoa, you would have to make sure you code file is a .mm file (Objective-C++) so you can mix Obj-C and c++ in the same source file. Then in your mouse handler, do NSEvent *event = [NSApp currentEvent]. Now that you have a native event, you can do things like [event pressure]. You can even wrap all the Obj-C into a c++ wrapper class that the rest of your code accesses.

You could do a polling mechanism with event taps. Register for event taps with some singleton c++ object. This object constantly updates its internal state with the current tablet data from the event tap. Then you query your singleton for the tablet data on an as needed basis.

OS X coalesces mouse events, and tablet data is embedded in mouse events. This means that you may lose some tablet data. You can turn off mouse coalescing via the Carbon SetMouseCoalescingEnabled() call. (You can also use this call from Cocoa.) If you do this, you will need to optimize your app to operate on more than one piece of mouse/tablet data before updating the screen or else you will have very laggy performance.

If you wan to disassociate the tablet data from the cursor, then you will need to contact Wacom for more support."

so…that’s a bit too much for me…any cocoa/carbon events and C++/objective C expert around? or anyone can shed some light on this??

million thanks!!!

Fwiw, (and sorry this probably isn’t a lot of help in OF projects) tablet events are pretty easy to work with in Cocoa - there’s good sample code on he Apple developer site, too


hey hey,

just wondering if anybody has made any progress with developing a wacom addon for osx.

i’ve been looking through the apple tablet examples, but hit a wall when trying to connect the event callbacks to a WindowRef reference. apparently, GLUT windows don’t have these!



In the end, I found an easier route than developing Wacom support myself, which might be interesting for your application too:


From the blurb

“OSCulator is a software that links your controllers to your music and video software. (via OSC)”

It’s not free, but there’s a 30 day demo. In particular, I’m finding it’s support for a wide range of input peripherals unexpectedly useful (up to 6 wiimotes!)

Supported devices:

iPhone applications:
Rob Hexl3r’s TouchOSC
Joshua Minor’s OSCemote
and more OSC compatible applications

JazzMutant Lemur
Super smooth Wiimote support
Perfect Pairing technology (helps fixing a problem with Mac OS X and Wiimote connection)
Wide extensions support
Classic Controller
Balance Board
Guitar Hero World Tour Guitar
Guitar Hero World Tour Drums
Guitar Hero 3 Guitar
Guitar Hero 3 and Guitar Hero World Tour
Up to 6 connected Wiimotes at the same time
Raw IR Mode: 4 tracked points with coordinates and sizes
LEDs & Vibration Control
Space Navigator
Wacom Tablets. Bamboo and Intuos 3 tablets are supported with touch strips and express keys.
Symbolic Sound Corporation’s Kyma sound design workstation hi precision driver
MIDI I/O : Ableton Live, Apple Logic Studio, Traktor, virtually all MIDI enabled software and devices
reacTIVision / TUIO protocol support with custom interpretation for greater ease of use.
Mutliple Wacom tablet input with support for Touch Strips and Express Keys.
HID Joystick Emulator
Mouse / Keyboard control

Best regards,


ok, thanks to theo and memo’s cocoa window developments , i was able to get the data from the wacom tablet in oF on a mac. i created the ofWacomApp addon, which is more like a modified version of ofBaseApp, so the oF application needs to be structured in a slightly different manner.

in main.mm, you’ll need to call ofRunAppWithWacomTablet( ofWacomApp * appName ) instead of ofRunApp.

#include "ofAppCocoaWindow.h"  
#include "ofMain.h"  
#include "testApp.h"  
#include "ofWacomApp.h"  
int main(int argc, char *argv[])  
	ofAppCocoaWindow window;  
   ofSetupOpenGL(&window, 1280, 720, OF_WINDOW);  
	ofRunAppWithWacomTablet( new testApp() );  

this version sends pen coordinates and pressure, and also differentiates between the eraser and pen button. it could easily be modified to send tilt data as well. here’s a demo application.


Note that ofWacomApp uses a modified version of Memo’s ofxMacOSX addon. this new version listens for tablet events in addition to mouse and keyboard events.


let me know if you run into any problems with the addon or the project file.




hm, compiling gives me

/Applications/of_preRelease_v0.06_xcode_FAT/apps/neues_gebastel/WacomAppCocoa/src/ofxMacOSX/src/GLView.mm:33: error: invalid conversion from ‘int’ to ‘NSOpenGLPixelFormatAttribute’

greetings ascorbin

compiling under 10.5 | Release | i386

i get:

/Applications/of_preRelease_v0.06_xcode_FAT/apps/neues_gebastel/WacomAppCocoa/src/ofxMacOSX/src/ofAppCocoaWindow.mm:75: error: ‘ofGetAppPtr’ was not declared in this scope


cp: /Applications/of_preRelease_v0.06_xcode_FAT/apps/neues_gebastel/WacomAppCocoa/bin//WacomApp.app/Contents/MacOS/libfmodex.dylib: No such file or directory

hey hey ascorbin,

i believe that variable came from theo’s version of ofAppRunner.h.

you can add it in yourself

in ofAppRunner.h

ofBaseApp *	ofGetAppPtr();  

and in ofAppRunner.cpp

ofBaseApp *	ofGetAppPtr(){  
	return OFSAptr;  

i believe that you should still be compiling in 10.4.

all the best,


Ya! Now its working! Thanks a lot!

Took a little tweeking with the latest version of OF from github, but once I got all the libs relinked and updated the run script in xCode it ran great!

There needs to be some interpolation for fast brush strokes that leave gaps between frames. Also it would be great to see this as it’s own addon and example, independent or piggybacking MSA libs.

Is there any update on the use of Wacom products? From what I read ofxWacomFeelMultiTouch (https://github.com/andreasmuller/ofxWacomFeelMultiTouch) seems to be limited to the use of basic model CTH470 and CTH670. But I would like to interface with tablets from the Wacom Cintiq serie (http://www.bhphotovideo.com/c/buy/Cintiq-Tablets/ci/14317/N/4232861545) . Is there any known solution for OSX?