02-20-2024 04:44 AM - edited 02-20-2024 04:45 AM
I am struggling to match the data plane size with with the PanelImage.Front.
I fail to draw circles on specific data points as seen in the code.
My premise is that I set the Graph's Plotarea to 640/480 pixels.
I expect that the PanelImage.Front has the same pixel size.
Unfortunately when trying to encircle data points the circle deviates uncosistently.
It encircles 0,0, then deviates to the top left for 39,79 and then deviates to the bottom right for 439/599
but comes back again a little for 479,639.
02-21-2024 01:37 AM
I haven't opened the code, but the graph classes have a couple of useful features for this:
You can then use this to convert the graph XY coordinates to pixel coordinates for the plot image regardless of the size and position of the graph.
02-21-2024 04:50 AM
By using Map XY to Coords the encirclements can be done correctly, which is good. Nevertheless the PlotImages.Front seems to have 2 pixels more than the plot area, which could still be a bug in my opinion.