Issues in adding Pen Tablet support?

I was just wondering if I could get an idea of what Issues would be
involved in getting sdl to support Pen Tablets such as wacom. (for
something like say a 3d paint app)…

There doesn’t seem to be any portable way, and in fact, I’m not even sure
there are device independent solutions for all systems!

At least, Wacom has a specific SDK for Windows applications that want to
take advantage of any features beyond the “standard” stuff. They did
indeed make it sound like that was the only way to get at the interesting
stuff… Either Wacom is being slightly evil, or Windows lacks a suitable
infrastructure and/or API - or maybe I just failed to see the whole point
with Wacom’s SDK.

Anyway, on Linux, tablets use the rather nice event interface - as you
would expect any such device to do. All you need to do is to map events
the way you want. “Channels” like X, Y, Z, X tilt, Y tilt, pressure etc
are standardized, so you can pretty much figure out what to do by looking
at what you get. Making the mapping user configurable is probably still a
very good idea, though.

As to SDL supporting this, I’m not sure if it would fit in the current
API. Something with “practically unlimited” number of axis/channels would
be needed to do it in any remotely clean way.

Hints: "Mouse wheel"
1.3

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Wednesday 03 April 2002 15:44, Danni Coy wrote:

I was just wondering if I could get an idea of what Issues would be
involved in getting sdl to support Pen Tablets such as wacom. (for
something like say a 3d paint app)…

In Windows look for wintab32.dll interface (should be wintab.h from
www.wacom.org), dunno how to use tablets in Linux :wink:

Pavel Kanzelsberger> ----- Original Message -----

From: Danni Coy [mailto:rgcoy@midcoast.com.au]
Sent: Wednesday, April 03, 2002 3:45 PM
To: sdl at libsdl.org
Subject: [SDL] Issues in adding Pen Tablet support ?

I was just wondering if I could get an idea of what Issues would be
involved in getting sdl to support Pen Tablets such as wacom. (for
something like say a 3d paint app)…


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

Under Linux w/ XFree86, use XInput. Here’s a sample code:

http://www.gimp.org/~otaylor/gsumi/gsumi.html

I haven’t looked at the source – I just use it :slight_smile: though not anymore
since I haven’t found the tablet to be all that useful.

For the most part, in both Windows and Linux, tablets function just like a
mouse. Tablet-specific codes would allow you to read pressure and tilt
sensitivity… is this something we want in SDL? (I’m really asking, not
saying it out of sarcasm or anything like that.)

What’s tablet support like under Mac and BeOS?

-MarkOn Thu, 4 Apr 2002, Kanzelsberger Pavel wrote:

In Windows look for wintab32.dll interface (should be wintab.h from
www.wacom.org), dunno how to use tablets in Linux :wink:

Pavel Kanzelsberger

-----Original Message-----
From: Danni Coy [mailto:rgcoy at midcoast.com.au]
Sent: Wednesday, April 03, 2002 3:45 PM
To: sdl at libsdl.org
Subject: [SDL] Issues in adding Pen Tablet support ?

I was just wondering if I could get an idea of what Issues would be
involved in getting sdl to support Pen Tablets such as wacom. (for
something like say a 3d paint app)…


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


Mark K. Kim
http://www.cbreak.org/
PGP key available upon request.

Mark K. Kim wrote:

Under Linux w/ XFree86, use XInput. Here’s a sample code:

http://www.gimp.org/~otaylor/gsumi/gsumi.html

I haven’t looked at the source – I just use it :slight_smile: though not anymore
since I haven’t found the tablet to be all that useful.

For the most part, in both Windows and Linux, tablets function just like a
mouse. Tablet-specific codes would allow you to read pressure and tilt
sensitivity… is this something we want in SDL? (I’m really asking, not
saying it out of sarcasm or anything like that.)

Why, it can be useful as a programmed keypad assuming one can ‘draw’ on it with fingers and
it can withstand some amount of player rage and frustration :slight_smile: .
There I think was a discussion on the Slashdot some time ago on this subject.

It would be useful for the app I am currently working on which is dependant
on SDL.
I think it would make a lot more sense to add this functionality at the SDL
level.
So projects don’t have to worry about the platform specific details when
adding tablet support.

Since SDL makes a good platform for OpenGL apps I can see a demand for this
type of support.
Danni

At 01:02 PM 4/04/2002 +0400, you wrote:>Mark K. Kim wrote:

Under Linux w/ XFree86, use XInput. Here’s a sample code:
http://www.gimp.org/~otaylor/gsumi/gsumi.html
I haven’t looked at the source – I just use it :slight_smile: though not anymore
since I haven’t found the tablet to be all that useful.
For the most part, in both Windows and Linux, tablets function just like a
mouse. Tablet-specific codes would allow you to read pressure and tilt
sensitivity… is this something we want in SDL? (I’m really asking, not
saying it out of sarcasm or anything like that.)

Why, it can be useful as a programmed keypad assuming one can ‘draw’ on it
with fingers and
it can withstand some amount of player rage and frustration :slight_smile: .
There I think was a discussion on the Slashdot some time ago on this subject.


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

Under Linux w/ XFree86, use XInput. Here’s a sample code:

http://www.gimp.org/~otaylor/gsumi/gsumi.html

I haven’t looked at the source – I just use it :slight_smile: though not anymore
since I haven’t found the tablet to be all that useful.

I find it rather useful for graphics (pressure sensitivity alone adds a
whole range of “new” ways of using the tools in PhotoShop or GIMP) - and
I found it rather interesting as a musical controller as well. :slight_smile:

For the most part, in both Windows and Linux, tablets function just
like a mouse. Tablet-specific codes would allow you to read pressure
and tilt sensitivity… is this something we want in SDL? (I’m really
asking, not saying it out of sarcasm or anything like that.)

I’m sure someone can come up with ways of using it, but I’d think it’s
pretty much limited to graphics applications… I can’t really see how
you could implement a game control system that makes use of a tablet
without actually making it require a tablet. (Mouse + joystick could
theoretically emulate position + tilt, but it wouldn’t feel the same in
any way…)

What’s tablet support like under Mac and BeOS?

No idea, but I’d assume it’s pretty good on Mac at least, as that’s still
the real platform for serious PhotoShop users.

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Thursday 04 April 2002 10:24, Mark K. Kim wrote:

Mark K. Kim wrote:

Under Linux w/ XFree86, use XInput. Here’s a sample code:

http://www.gimp.org/~otaylor/gsumi/gsumi.html

I haven’t looked at the source – I just use it :slight_smile: though not anymore
since I haven’t found the tablet to be all that useful.

For the most part, in both Windows and Linux, tablets function just
like a mouse. Tablet-specific codes would allow you to read pressure
and tilt sensitivity… is this something we want in SDL? (I’m
really asking, not saying it out of sarcasm or anything like that.)

Why, it can be useful as a programmed keypad assuming one can ‘draw’ on
it with fingers and it can withstand some amount of player rage and
frustration :slight_smile: .

It can probably do the latter (at least the “professional” series seem
rather solid), but the former would be a problem, as the technology used
is based on inductive reading of a “passive” pen, puck, mouse or
whatever. Also, only the larger professional versions support more than
one tool at once - and that’s limited to two tools, AFAIK.

There I think was a discussion on the Slashdot some
time ago on this subject.

Any conclusions? (I very rarely read Slashdot. Too much noise…)

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Thursday 04 April 2002 11:02, Alexander Sabourenkov wrote:

Why, it can be useful as a programmed keypad assuming one can ‘draw’ on
it with fingers and it can withstand some amount of player rage and
frustration :slight_smile: .

It can probably do the latter (at least the “professional” series seem
rather solid), but the former would be a problem, as the technology used
is based on inductive reading of a “passive” pen, puck, mouse or
whatever. Also, only the larger professional versions support more than
one tool at once - and that’s limited to two tools, AFAIK.

There I think was a discussion on the Slashdot some
time ago on this subject.

Any conclusions? (I very rarely read Slashdot. Too much noise…)

Puff and smoke, as usual. But the topic was raised.

I think that with the restrictions you outlined they’re pretty useless
for games. However, they may be of some use for, well… some other apps.
Like drawing programs :slight_smile: Now let’s sit and wait while some ingenious
drawing app writer will submit the patches. :slight_smile: That’s my conclusion.

./lxnt

At 07:13 PM 5/04/2002 +0400, you wrote:

However, they may be of some use for, well… some other apps.
Like drawing programs :slight_smile: Now let’s sit and wait while some ingenious
drawing app writer will submit the patches. :slight_smile: That’s my conclusion.

I am currently writing plugins for Wings3d (check the apps page at
libsdl.org. Although It is not needed yet, I can see a real use for pen
tablet support in Wings3d eventually so I am preempting. I am willing to
put some time and energy towards implementing but I am not Ingenious and
would appreciate any help I can get.
Danni

At 04:12 PM 5/04/2002 +0200, you wrote:

I can’t really see how
you could implement a game control system that makes use of a tablet
without actually making it require a tablet.

Any place where you are using keyboard + mouse you can map tilt, pressure
to different keys…
You don’t necessarily have to use the full range. eg. in a 3d shooter
pressure below 128 means the character is walking - above = running.
Nice If you have the tablet, Easy to have a keyboard switch if you don’t.

     Danni

I have a Wacom Intous tablet + working XFree86/Linux setup. I also have
some simple working code lying around, and I can at least test stuff on
Linux. (Well, I can “test” on Windows as well, but I don’t have any
serious development tools for Win32 native…)

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Saturday 06 April 2002 03:06, Danni Coy wrote:

At 07:13 PM 5/04/2002 +0400, you wrote:

However, they may be of some use for, well… some other apps.
Like drawing programs :slight_smile: Now let’s sit and wait while some ingenious
drawing app writer will submit the patches. :slight_smile: That’s my conclusion.

I am currently writing plugins for Wings3d (check the apps page at
libsdl.org. Although It is not needed yet, I can see a real use for pen
tablet support in Wings3d eventually so I am preempting. I am willing
to put some time and energy towards implementing but I am not Ingenious
and would appreciate any help I can get.
Danni

Hmm… Yeah, you’re right. I’m smelling some “analog PC joystick” feel
here (urgh!!!), but then again, a tablet + stylus is more accurate and
much lighter… I found it rather nice as a musical instrument controller
(mapping X to pitch, Y and tilt to various modulation targets and
pressure to volume), so it might work. :slight_smile:

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Saturday 06 April 2002 03:39, Danni Coy wrote:

At 04:12 PM 5/04/2002 +0200, you wrote:

I can’t really see how
you could implement a game control system that makes use of a tablet
without actually making it require a tablet.

Any place where you are using keyboard + mouse you can map tilt,
pressure to different keys…
You don’t necessarily have to use the full range. eg. in a 3d shooter
pressure below 128 means the character is walking - above = running.
Nice If you have the tablet, Easy to have a keyboard switch if you
don’t.