I've played around with using GlovePIE (which adapts a lot of
interesting controllers including wiimotes;
http://carl.kenner.googlepages.com/glovepie_download)
and SketchUp together. I set it up to work more as a mouse with tool
controls on the nunchuk, making it kind of like playing Trauma Center.
Pretending the input is from the mouse is by far the easiest
technique.
Other ways to send data to your ruby script:
* Have your ruby script watch output.txt in the GlovePIE directory,
then in the glovepie script, use the outputotfile command to output
data. This isn't quite as elegant as option 2:
* Use GlovePIE's OSC functionality to send messages to your ruby
script. OSC is a simple network interface, so you can SendOsc
("localhost", my_port, "/anything/here", target.x, target.y, roll).
You'd set your Ruby script up to listen to the OSC commands.. you can
do this with rosc (
http://hans.fugal.net/src/rosc/) or a home-brew
ruby server.
GlovePIE also has functionality to scroll the desktop, which is
intended for head-mounted displays. It might be an interesting trick
to handle Question 2.
I think it will be hard to change the center of vision with the way
SketchUp manages its camera (target, eye, up instead of an arbitrary
projection matrix).
There may be other ways to get the wiimote data without using GlovePIE
(which is windows-only).
Patrick
On Dec 11, 3:30 pm, miket <
jmtalb...@gmail.com> wrote:
> Situation: I would like to write a plugin to do head tracking in
> sketchup with the use of the miimote similar to the demonstration by
> Johny Leehttp://
www.cs.cmu.edu/~johnny/projects/wii/