Coal is an important energy source in China. The separation of coal and gangue is a key link in coal mining, and the realization of the intelligent separation of coal and gangue provides technical support to promote the intelligent development of coal mines. To solve the problem of difficult to sort coal and gangue quickly and accurately caused by the fast running speed of belt, the different shapes and sizes of gangue and so on, an online flexible sorting model based on multi-information fusion is proposed. We use a near-infrared camera to identify coal and gangue, and combine it with a depth camera to obtain the height and pose information of gangue. According to the information obtained by the camera, the flexible sorting of coal and gangue can be realized. We also analyzed the different factors that affect the trajectory of gangue before and after pneumatic separation, deduced the theoretical formula of horizontal movement distance of gangue pneumatic separation, established the mathematical model of gangue flexible sorting, and carried out experiments of pneumatic separation with different shapes and sizes of gangue. The error compensation of the model is carried out by using experimental data. Through experimental verification, the proposed gangue flexible sorting model can effectively improve the accuracy of gangue sorting and can still accurately sort gangue of different shapes and sizes despite the high-speed movement of the belt.