fix several bugs in extracting integer lines,TODO:accelerate extracting mesh