Archive for February, 2006

Direct3D PictureBox

Here is a video of a direct 3d PictureBox in C#. I’d like to see a lot more details like antialiasing (multisampling in microsoft speak). But this is a good start. I’ll probably only scratch the surface of Direct3D. The next task is to get a point/mesh to render so that I can feed coordinates from the polhemus device. Today has been a good day between talking with polhemus (see the old story) and getting this render to work.

Comments off

CPolhemus ActiveX Relaying Events to Render

polhemus_prototype2.JPGUsing the techniques described earlier, I have the activex object recieving polhemus events and then firing them to the C# application as custom events. I’m only recieving one event from the polhemus WM_PI_RAWDATA_READY which is fired for each sample at 60Hz. I use every 20th frame (3Hz) to fire a “realtime” event. Then if the stylus button is depressed and it’s been more than 15 frames since the last stylus depress I fire a “stylus button” event. Both events send the XYZ cartesian coordinates as part of the event. Then I use some real simple bitmap double buffering and a Graphics object to render the coordinates as a string. You can watch the video by clicking on the thumbnail on the right. Next, get a 3D toolkit (likely Direct3D) to use the coordinates to render a scene.

Comments off

TreeView Control with Icons

treeview_with_icons.jpgI’m making good progress with the hardware and GUI. I can customize the motion frames I get from the polhemus and detect stylus presses. One problem though is that it sends multiple frames during a single stylus button depress because the cycle rate is so fast. Have to think about that. I also now no how to add icons to the TreeView. You can see the icons I whipped up in the attached prototype screenshot.

Comments off

« Previous entries