Code structure changed: edgeDetection as separate class