included helper files into processImg

processImg now uses the helper functions that are independent
algorithms.