none
Absolut coordinates from Tablet/Digitizer RRS feed

  • Question

  • Hi,

    I am currently working on a project where we need to be able to get the absolute coordinates of the the pen on the digitizer with high resolution. In other words I need the coordinate of the point where the pen hit the digitizer area.
    A tip I got from another forum was that I need to read Raw Input from the HID-device of the digitizer. I have however not been able to find much information on how to achieve this. If anyone have any info or tips I would be very grateful.
    Tuesday, July 10, 2007 10:23 AM

Answers

  • Have you considered using a full-screen window that has an InkCollector (or InkOverlay, or RealtimeStylus or InkCanvas) attached to it for this scenario? Would this not satisfy your requirements?

     

    Thanks,

    Stefan Wick

     

    Microsoft - Windows Experience

    Thursday, July 12, 2007 2:35 PM

All replies

  • Hi Andreas,

     

    can you explain a bit what your scenario is? There might be better ways to accomplish it without having to read the raw input from the HID stream.

     

    Thanks,

    Stefan Wick

     

    Microsoft - Windows Experience

    Wednesday, July 11, 2007 2:54 PM
  • The application will be used to measure samples of manufactured products. Our customer already has (legacy) software to do this.
    The user simply puts the sample on the digitizer and then uses the pen to mark some predefined spots(points) on the sample. The software reads the coordinates and then exports the data for analysis.

    To do this the software needs to know as exactly as possible where on the digitizer the user pressed the pen.

    If something is unclear  I'll try to elaborate.
    thanks
    Andreas Lindmark
    Thursday, July 12, 2007 2:03 PM
  • Have you considered using a full-screen window that has an InkCollector (or InkOverlay, or RealtimeStylus or InkCanvas) attached to it for this scenario? Would this not satisfy your requirements?

     

    Thanks,

    Stefan Wick

     

    Microsoft - Windows Experience

    Thursday, July 12, 2007 2:35 PM
  • Thanks for the help!

    I've have considered the different options and a fullscreen application with an RealTimeStylus seems to be a good option. There is however one problem, if I put another control on top of the window form (which I have attached to the RealTimeStylus ) the area occupied by the control becomes a "grey" area where the RealTimeStylus-plugin wont recieve any datapackets. One way to solve this would be to put an invisible component on top of all the other components and attach this to the RealTimeStylus. Is there perhaps a better way of achieving this?
    Tuesday, September 11, 2007 2:23 PM
  • Hi Andreas,

     

    There are a couple of other options:

     

    1) If you used an InkOverlay instead of RealTimeStylus, then you could set the AttachMode property [1] to 'InFront' in order to collect the stylus data on top of any child controls

     

    2) If switching to WPF is an option, then you could use the InkCanvas element [2], which by default collects stylus data on top of any child elements (and behind any sibling elements).

     

    Thanks,

    Stefan Wick

     

    Microsoft - Windows Experience

     

    [1] http://msdn2.microsoft.com/en-us/library/microsoft.ink.inkoverlay.attachmode.aspx

    [2] http://msdn2.microsoft.com/en-us/library/system.windows.controls.inkcanvas.aspx

    Wednesday, September 12, 2007 4:01 AM