made sdl2 working, iteration method now finds first root