The system of rail abrasion real2time detection needs a linear laser source which has an even and big power. In this paper, the theory of scanning the rail orbit and obtainning the rail cross-section image are introduced. The way of design thatwe can dispersive the light by the cylinder of glassmaterial is given, and theory analysis and experimental test are presented, including its app lication to catch the picture of the rail cross-section.