digital straight segment recognition