generalisation of lines works, need fix one bug with white lines