| In recent years,with the rapid development of computer graphics,rendering technology based on its theory has been widely used.However,for large-scale scenes,due to the large scale and high precision of the model objects,it is difficult to implement interactive level scene rendering on a single machine due to hardware limitations.As a BIM(Building Information Modeling)digitization project applied to engineering design and construction,it includes multiple building models,steel frame structure models,pipeline models,etc.Each model has complex and fine geometric information,geometric data scale.It is generally too large,and real-time rendering of such scenes is a very challenging problem.In view of the problem,this paper studies the real-time rendering problem of large-scale scenes,especially for the BIM scene,which greatly improves the rendering efficiency and realizes the interactive level rendering effect.The specific work is as follows:(1)Based on the Master-Slave structure,a distributed 3D model rendering framework based on OpenGL is implemented.According to the particularity of BIM scene,an interactive task scheduling strategy based on scene content distribution is proposed.By dividing the BIM model into individual sub-scenarios that can be rendered by a single rendering node,the strategy distributes the scene tasks evenly to the rendering nodes to avoid load imbalance.The master and the slave implement a distributed rendering network connection through the TCP/IP protocol.When the user interacts,the sub-scenes are scheduled to be processed on the rendering node.The rendering result of the sub-scene and the corresponding depth image are sent to the main end,and are synthesized according to the scene depth information to obtain a final rendering result.Throughout the process,the interaction generated by the primary end is notified by the network node message to the rendering node of the slave end,and the rendering result is updated.(2)Based on the distributed rendering framework for BIM,the rendering process of the rendered intermediate image obtained by the rendering node and the synthesis process of the final rendered image are optimized and improved.The rendering intermediate result obtained from the rendering node and the corresponding depth image need to be transmitted to the main end for splicing and compositing.To improve the transmission rate and save the network bandwidth,the Snappy compression algorithm is used to compress and transmit the relevant image data,which reduces the transmission response time.In the synthesis process of the final rendered image of the primary end,the color image data from each slave end is synthesized according to the depth information and the final rendering result is obtained,thereby preserving the efficiency of image data transmission and ensuring the final rendering precision.(3)Comparing the performance of the BIM-oriented distributed rendering system proposed in this paper with the single-machine rendering,it can be concluded that the distributed rendering system is used for large-scale scene rendering,which not only reduces the scene loading time and rendering time,but also reduces the system interaction delay.The time required for the entire distributed rendering system to interact interactively is much less than the single-machine rendering time,which greatly improves the rendering efficiency.And the interactive performance of the system is tested.Experiments show that the distributed rendering system proposed in this paper can perform smooth interaction on the master side. |