Measuring laser markings distance

I want to measure distances between the center of the markings and relative to the center point (6,6) in a calibration plate for a laser scanner, however i am having some difficulties in automatizing the process with the analyze particle.
My main problem is that i can’t define the coordinate system to be 0,0 in the center of the markings. So when i run the the analyze particle it does not give me the coordinates that i want. What should i do?

Good day,

in which order do you like to see the distances listed?

With the slightly counter-cockwise rotated point-array of the sample image, the sequence given by the “Analyze Particles” would be top-right to bottom-left. If however the rotation would be clockwise, the sequence given by the “Analyze Particles” would be top-left to bottom-right.



Here is an ImageJ-macro that does what you want (optimized code: 23. Dec. 2018):

// imagej-macro "distances2central" (Herbie G., 22./23. Dec. 2018)
requires( "1.52i" );
run("Set Measurements...", "centroid redirect=None decimal=2");
setOption("BlackBackground", true);
run("Duplicate...", "title=temp");
setAutoThreshold("Default dark");
run("Convert to Mask");
doWand(0, 0.5*getHeight());
run("Select None");
run("Fill Holes");
run("Analyze Particles...", "size=400-Infinity circularity=0.90-1.00 display clear");
for (i=0;i<nResults;i++) setResult("Distance", i, dist(getResult("X",c),getResult("Y",c),getResult("X",i),getResult("Y",i)));
function dist(x1, y1, x2, y2) {return sqrt(pow(x1-x2, 2)+pow(y1-y2, 2));}
// imagej-macro "distances2central" (Herbie G., 22./23. Dec. 2018)

Paste the above macro code to an empty macro window (Plugins >> New >> Macro) and run it with the image open in ImageJ.

The Results table shows the center coordinates of all dots and the distance of every dot center to the center of the central dot in pixels.

Please report if it works for you.