With the acceleration of urbanization, the problem of building energy consumption has become increasingly prominent, and the construction of low energy consumption and high comfort building environment has become a hot research field. The purpose of this study is to explore the use of computer vision technology for image acquisition, optimize the thermal energy management in the building environment through intelligent analysis, and improve the energy efficiency and comfort of interior design. Through the establishment of image acquisition system based on computer vision, the indoor and outdoor environment is monitored in real time. A deep learning algorithm is used to process the acquired images and extract the thermal energy characteristics of the buildings. Combined with virtual reality (VR) technology, a 3D model of interior design was constructed to simulate the impact of different design schemes on energy consumption. The experimental results show that the real-time data obtained by computer vision technology can effectively identify the heat energy distribution in the building, and provide optimization suggestions for interior design. Simulation results of different design options show that the optimized design reduces energy consumption while improving occupant comfort. Therefore, computer vision technology shows a good application prospect in the thermal energy optimization of building environment. By combining VR interior design simulation, the technology not only improves the accuracy of thermal management, but also provides architects with more information-based decision support and promotes the development of smart buildings.