The interfacial structure has an important effect on the mechanical properties and safety of the energetic material. In this work, a mesostructure model reflecting the real internal structure of PBX is established through image digital modeling and vectorization processing technology. The microscopic molecular structure model of PBX is constructed by molecular dynamics, and the interface bonding energy is calculated and transferred to the mesostructure model. Numerical simulations are used to study the influence of the interface roughness on the dynamic compression and impact ignition response of PBX, and to regulate and optimize the mechanical properties and safety of the explosive to obtain the optimal design of the surface roughness of the explosive crystal. The results show that the critical hot spot density of PBX ignition under impact loading is 0.68 mm-2. The improvement of crystal surface roughness can improve the mechanical properties of materials, but at the same time it can improve the impact ignition sensitivity and reduce the safety of materials. The optimal friction coefficient range for the crystal surface that satisfies both the mechanical properties and safety of PBX is 0.06–0.12. This work can provide a reference basis for the formulation design and production processing of energetic materials.