Friday, May 01, 2009

Wacom Bamboo Tablet and The Gimp - Best of friends

The Bamboo - A Quick Review

A big thanks to my mother in law for getting me a Wacom Bamboo Tablet for my birthday. Here are some initial thoughts on the device:

  • Whoohoo! It worked out of the box on Windows Vista without doing anything special
  • It's worth taking the time to go through the tutorial. The controls are fundamentally different than a mouse and I'm glad I didn't try to figure this out through trial and error.
  • How cool is that you move the mouse by hovering the pen over the tablet? It's like magic.
  • The notion that the tablet represents a scaled down version of your screen (the center of the tablet is the center of your screen) takes some getting used to, especially when compared to a mouse which has no reference to your screen.
  • The general feel of the hardware is nice and solid. And the pen more or less feels like I'm holing a pen.
  • I fiddled with the handwriting recognition. Amazingly, it could recognize my scribble - I was amazed. Me hand writing text is about 100x slower than typing it, but still, it's remarkable how good the handwriting engine is.

Overall, I'm pleased. So far, it feels far from a natural replacement for the mouse, but I think it's worth sticking with.

Putting the Tablet To Use

One use of the tablet I want to try is to augment the plain paper steno pad I have by my desk. I use it for daily TODO lists, notes, drawings, and pretty much anything else that comes at me throughout the day. A digital version of this could be really handy.

To accomplish this, I decided to use The Gimp. The Gimp is a good choice because it has great support for the tablet and allows for quick scribbling, importing images and many other image related tasks. The main issue with The Gimp is that it's too customizable - having to start from a new image every time would be a hassle. Luckily, I could write some script-fu to take care of a lot of this customization for me. I ended up writing a plugin that does the following:

  • Creates a new image of a standard size
  • Adds a white background layer
  • Adds a layer with a light blue grid (think: graph paper)
  • Adds a time stamp in the lower left hand corner
  • Adds a new blank layer, ready to be drawin on
  • Saves the image with a standard name using the current date and time in a standard directory

Here's a note page in use:

I've linked this plug-in the key sequence Control + Alt + N and now with a single keystroke I can have a new note page ready to go.

Here's the script-fu code. Note, you'll need to grab utils.scm to make this run, as that file contains various helper functions.

(define (notepad-base-dir)

(define (notepad-page-size)
  '(1024 600))

(define (bs-notepad-new-page)
  (define (add-layer img name ops)
    (let ((layer (car (gimp-layer-new img (first (notepad-page-size)) (second (notepad-page-size))
                                      RGBA-IMAGE name 100 NORMAL-MODE))))
      (gimp-image-add-layer img layer 0)
      (ops img layer)
  (let ((img (car (gimp-image-new (first (notepad-page-size)) (second (notepad-page-size)) RGB)))
        (file-name (string-append (notepad-base-dir) "/" (time->timestamp-string (time)) ".xcf")))
    (gimp-image-undo-group-start img)
    (gimp-context-set-foreground '(0 0 0))
    (gimp-context-set-brush "Circle (07)")
    (add-layer img "Background" (lambda (img layer)
                                  (gimp-context-set-background '(255 255 255))
                                  (gimp-edit-fill layer BACKGROUND-FILL)))
    (add-layer img "Grid" (lambda (img layer)
                            (define c '(19 146 236))
                            (plug-in-grid RUN-NONINTERACTIVE
                                          img layer  
                                          1 20 0 c 50
                                          1 20 0 c 50
                                          1 20 0 c 50)))
    (gimp-text-fontname img -1 
                        10 (- (second (notepad-page-size)) 16)
                        (string-append "Created: " (formatted-time (time)))
                        -1 TRUE 12 PIXELS  "Arial")
    (add-layer img "Pad" (lambda (img layer)))

    (gimp-display-new img)
    (gimp-image-set-filename img file-name)
    (gimp-file-save  RUN-NONINTERACTIVE img (car (gimp-image-get-active-layer img)) file-name file-name)
    (gimp-image-clean-all img)
    (gimp-image-undo-group-end img)))

(script-fu-register "bs-notepad-new-page"
                    "Notepad: New Page"
                    "Create an image to be used as notepad canvas"
                    "Ben Simon"
                    "Copyright 2009, ideas2executables"
                    "April, 2008"

(script-fu-menu-register "bs-notepad-new-page"
                         "<Image>/File/Create/Notepad Page")

Now if the tablet could just improve my handwriting, we'd be all set.


  1. I've been using a Bamboo for now six months instead of a mouse. I decided to buy one because
    1/ I used to own a tablet (now broken) and to draw a lot
    2/ I've had some wrists injuries for a year that hinder me from using a mouse (resp. keyboard) for more than 60 minutes (resp 5 minutes).

    It works great under FreeBSD and Linux as expected (also, in gimp, don't forget to set another virtual pointer for the eraser!)

  2. Axio -

    I'm glad my general take on the Bamboo matches up to yours. It's really cool technology.

    The eraser-virtual-pointer tip is a really good one. Thanks for reminding me about it.

    I haven't figure out how to set the different virtual pointers from Script-Fu - any ideas?


  3. I'm jealous.....

  4. i had some problems with my wrists also. since i got my wacom bamboo i have suffered no problems at all.

    i got my wacom bamboo from

    am very pleased with the wacom bamboo

    top quality!

  5. Anonymous9:47 AM

    I just received my Bamboo Fun yesterday, and you're right about how easily it loads in Vista. I didn't even do any configurations in Gimp and it worked instantly. I've already done a small drawing. I'm curious about this 'virtual eraser' feature, because the eraser was the one thing that seemed to require more work.

    I got my tablet on sale from Amazon - $84 - free shipping if you wait, which I did, but I was impatient. No plug, just saying.

  6. Anonymous9:31 AM

    I have also not been able to get the eraser to work. Gimp has its own eraser function, maybe that is why. But, for me, the eraser just acts as a fat pointer.

  7. Anonymous7:10 PM

    How well does the Bamboo Fun work with GIMP on an XP? Does anyone know?