get("#348") -- rgb and bright w, h = img.width, img.height sumx, sumy, sumdensity = 0, 0, 0 for y=0, h-1 do for x=0, w-1 do density = 1-bright(rgb(img.getInt(x,y))) sumdensity = sumdensity+density sumx = sumx+density*x sumy = sumy+density*y end end sumx, sumy = sumx/sumdensity, sumy/sumdensity px, py = math.floor(sumx+0.5), math.floor(sumy+0.5) return "Schwerpunkt: "..px..", "..py