12-23-2008 09:54 AM - edited 12-23-2008 09:56 AM
Right now, I have chosen door #1 but will at least try to put the equivalent together with door#2.
Thanks for great ideas.
Sincerely,
Don
12-23-2008 12:17 PM - edited 12-23-2008 12:20 PM
I think I misunderstood the problem. In your example, the XY graph is overlaid on the intensity graph and the XY scales are hidden. While I keep the XY graph scales and hide the corresponding intensity graph scales !
I have done a quick modification of my vi to retrieve the specific properties of the intensity graph. There is some additionnal work to match the XY graph scales with those of the intensity graph.
12-23-2008 04:08 PM
Yes, now you are understanding correctly.
But to incorporate the movement and resizing of the XY graph within the Intensity Graph by drawing the XY graph using plot.images property may not be quite as straightforward or efficient as the first method. It was the plot.images property that I was first considering using when I talked of doing draws on the intensity graph.
Sincerely,
Don
12-23-2008 04:17 PM - edited 12-23-2008 04:19 PM
Personally, I would use the existing intensitiy chart and plot the line over it using "plot images" feature. No overlapping controls needed.
(Here's a very rough draft (LV8.5). You probably want to use DBL for the v-scaling and convert inside the loop to I16. Some of the math is currently ugly, so modify as needed :)))
12-23-2008 04:33 PM
Sorry, the defaults for the attached image is different to the defaults in the attached VI. For the image I used:
HScale = 204
HPos = 286
VScale = -4
VPos = 133
12-24-2008 03:03 PM
12-24-2008 03:31 PM
Overlapping/transparent controls are a horrible pain during editing and also probably impair FP redraw speed during running.
smercurio_fc wrote:
It has the advantage of not requiring one to have to go through and redraw a curve that the XY graph does automatically.
The plot images method is equally permanent. Once you draw the line, you can redraw (change) the data of the intensity graph and the line will remain. Similarly, you can redraw the line without updating the intensity data. 🙂 (Sorry, maybe you had something else in mind with the above sentence?)
12-24-2008 06:20 PM
altenbach wrote:(Sorry, maybe you had something else in mind with the above sentence?)
I did. I was referring to not needing the code that's required in order to draw the picture. I'm not really advocating the overlapping/transparent controls as a superior solution. It's an alternate solution which, in my opinion, is a perfectly viable one. As long as the OP is aware of the advantages and disadvantages of the various methods I'm sure they can choose the method most appropriate for them.
12-25-2008 09:49 AM
I have always been fond of the graph draw capability since it was introduced. It has really come in handy, allowing me to do tricks with graphs that before I needed to do with the picture control. Before this capability, I was at one time drawing on graphs using dot cursors! So the option that Christian presents is quite a good solution and probably similar to what I would have arrived at as noted in my original post.
But for this application, the spectrogram recalcuation will not be drastically affected by an overlying transparent control and I like it as a brute force solution. One thing it does prevent is the ability to change the maximum and minimum values on the Y-scale of the spectrogram since the XY graph is on top of the spectrogram. I suspect Christian also discovered this. The workaround for this is to just use controls on the front panel to allow graph range editing. Of course for some this would immediately rule out the XY graph overlay as a plausible solution. For my application, I need these controls anyway because I also have an option for the user to display the spectrogram as a 3D surface where the only way to customize the X, Y, Z ranges is thru front panel controls (at least as far as I know).
Sincerely,
Don
12-25-2008 10:10 AM