10-24-2013 04:01 AM
hi,
I am developing a simple point track application, it is not the same as the traditional mouse cursor tracking problem and i get really confused.
there are two pictures to describe my application:
the first one descirbes the default state of my application:
1.red circle is the point that user can move;
2.white cross is the original point;
3.blue circle is the range of red circle motion
the second one describes the track process of my application:
1.user can move the red circle with a click of mouse button in any place within blue circle;
2.application should show coordinates of red circle relative to white circle in real time;
3.once user release the red circle(or the button of mouse), the application should return to its default state.
I realy do not know how to realise the key parts of this application, like showing a circle in panel and connecting the points within it to the labview code? can anybody give me some suggestions? thanks a lot
11-09-2013 02:44 PM
Attached is a very rough implementation of what you're looking for. Add a "draw (white) line" after the "draw circle" function to make the crosshairs persist when the circle is near the center. Prob want to delete the crosshairs from the blue circle picture (currently contained in a constant) to avoid drawing them twice and them not quite lining up. All of the constants are empirically determined and need slight adjustments (e.g. centering of the red circle when mouse is up, etc.). They will need further adjustment if you resize the blue circle picture.
Not sure what you mean by connecting the points within the LV code. I suspect you're using the eyeball to drive an XY stage or such and need to use the red circle coordinates to moderate the travel speed?