heavily modified engine2.py. will be migrating code between teh two for a commit or so, but have finally set on edge detection... for now