Considering the rapid acquisition and detection task of building enclosure damage information and the natural environment characteristics of building enclosure, a new unmanned aerial vehicle (UAV) track planning framework considering image detection and UAV dynamic characteristics is proposed. Firstly, considering the position of UAV in the task space for track planning, combined with the characteristics of the sensor detection equipment carried by UAV, and the task requirements of extracting and identifying the damage edge features and texture features on the shell of the building; the detection efficiency and detection safety of UAV are improved to the maximum extent. Secondly, the Improved Circle Chaos Initialization Strategy, Adaptive Weight Strategy and Elite Perturbation Mechanism are introduced to solve the problem that the traditional honey badger algorithm (HBA) is easy to fall into local optimal solution and to ensure that the designed algorithm is more in line with the inspection planning requirements of the outer surface of the building. Furthermore, improved honey badger algorithm (IHBA) is compared with particle swarm optimization (PSO), whale optimization algorithm (WOA) and traditional badger algorithm in multi-dimensional horizontal through design simulation experiments, which shows that the design algorithm in this paper is efficient in solving the damage information collection of building enclosure.