| Virtual city is an important means of applying virtual reality technology to urban planning and design,and the automatic building layout in the block is an important process to reflect its authenticity and immersion in the simulation generation of the virtual city.To achieve a better layout effect,it usually requires architects to spend a lot of energy,after repeated trial and error and exploration to design the layout plan.This paper starts with two parts of automatic building layout.At the stage of forming the initial layout of buildings in the block,a method that uses less relevant data to generate a more reasonable block building layout that meets the constraints is proposed.In the optimization stage of building layout in the block,in the process of using genetic algorithm to optimize the initial layout of buildings in the block based on the influence of sunlight,the control method of optimization factors is improved,thereby increasing the effect and efficiency of layout optimization.The main research work of this paper includes the following:(1)In the stage of forming the initial layout of buildings in the block,this paper proposes a method to use less relevant data to generate a more reasonable and constrained block building layout.This method first analyzes the characteristics of the block and combines the actual provisions,and uses appropriate layout methods to generate the corresponding initial layout for different block types.For residential buildings,use a determinant layout that is more friendly to sunlight;for commercial areas Buildings,according to the characteristics of promoting benefits and competition between commercial buildings,use force-directed algorithms to generate the initial layout of the commercial area;for the school area,divide the functional area,use the template to generate other learning areas according to the linear mapping of floor area.(2)This paper improves the control method of optimization factors in the optimization stage of building layout in the block.The method includes two aspects:One is to combine the rotation transformation control of the same type of building as a control method for the rotation of the building.The second is to control the movement of buildings by generating random points on the curved surface as the position of the center point of the building.This method improves the efficiency and effect of using genetic algorithm to optimize the layout of buildings in the block based on the influence of sunlight.On the basis of improving the sunlight conditions of the block group,it retains certain block characteristics and increases the realism and immersion of the building layout. |