visibility segment graph working