Java and OpenCV: Calculate Median / Mean / Stdev value of MAT (Gray-Image)
try this:
double d = mu.get(0,0)[0]
mu.get(0,0)
returns a double[]
, so you can just get the first element - it's equivalent to the C++ version of:
mu.val[0]
Hope it helps.