Buildings 3-D view display platform and application system thereof
Technical field
The invention belongs to infotech, particularly relate to buildings 3-D view display platform and application system thereof.
Background technology
AutoCAD (Drawing Interchange Format or Drawing Exchange Format) drawing swap file.DXF is the cad data file form for carrying out cad data exchange between AutoCAD and other software of autodesk, inc.'s exploitation.DXF is a kind of vector data form of opening, can be divided into two classes: ASCII fromat and binary format; ASCII has readable good, but it is larger to occupy space; Binary format occupies that space is little, reading speed is fast.Because Autocad is most popular cad system now, DXF is also widely used, the standard on coming true.The basic composition of DXF file is as follows:
The overall information of HEADER part-Tu.Each parameter has a variable name and corresponding value.The information of class of CLASSES part-comprise application program definition, these examples will be presented at BLOCKS, ENTITIES and OBJECTS part.Usually do not comprise for abundant for the information mutual with other application program.TABLES part-this part comprises the definition of naming items.Application ID (APPID) table, Block Recod (BLOCK_RECORD) table, Dimension Style (DIMSTYPE) table, Layer (LAYER) table, Linetype (LTYPE) table, Text style (STYLE) table, User Coordinate System (UCS) table, View (VIEW) table, Viewport configuration (VPORT) show BLOCKS part, and this part comprises Block Definition entity for defining the composition of each Block.ENTITIES part, this part is mapping entity, comprises Block References.OBJECTS part--comprise the data of nongraphical objects, for AutoLISP and ObjectARX application program institute.THUMBNAILIMAGE part--comprise the preview graph of DXF file.END?OF?FILE。
The structural design of Building class all uses the DXF drawing of two dimension usually, and it is neither intuitively also unfavorable for follow-up further exploitation, such as many 3D application relating to building, as Decoration Design etc.
How the DXF file of two dimension " being read " out and converted three-dimensional plot to, is one of object of studying of the present invention; After converting 3-D view to, if show this 3-D view; And utilize whole buildings figure in above-mentioned technique construction region, area, city, thus make user can check the constructure inner structure of specifying at any time, so that the system such as fire-fighting, public security uses, these are all the technical issues that need to address of the present invention.
Summary of the invention
In order to solve the problem, the invention provides a kind of by seldom operation can buildings 3-D view display platform, display platform and application system thereof.
Technical scheme of the present invention is to provide a kind of buildings 3-D view display platform, its be read buildings 3 D image file and show the platform of this 3-D view, it is characterized in that, it comprises with lower module:
Data importing module, is responsible for reading in line by line and resolving 3 D image file, to obtain buildings three-dimensional geometry data;
3-D display module, is responsible for, according to the buildings three-dimensional geometry data obtained, realizing the display of buildings 3-D view, and the display engine of described 3-D display module adopts visualization tools function storehouse VTK technology to realize.VTK: visualization tools function storehouse.
Preferably, described 3-D display module adopts the Depth Peeling technology in visualization tools function storehouse to realize the display transparence of each entity of buildings, can regulate its transparency when each entity of buildings is shown.DEPTH PEELING: Depth Peeling, it is the algorithm following the tracks of each pixel depth on screen based on z-buffer(mono-kind) multilayer play up, it is that the depth value basis of playing up based on last layer is carried out that every one deck is played up.
Preferably, described 3-D display module also provide human-computer interaction interface to realize each entity of buildings amplification, reduce, rotate, translation, decomposition, show or hide operation.
The present invention also provides the application system of the buildings 3-D view display platform described in a kind of basis, and it comprises with lower module:
Document management module, is responsible for building and manages the 3 D image file of the buildings in one or more region;
User management module, is responsible for maintenance customer and user right, makes the user specified have the authority of access appointment buildings;
Described buildings 3-D view display platform is responsible for providing human-computer interaction interface to show the 3-D view of buildings.
Preferably, described document management module adopts a kind of method based on DXF file generated 3-D view to obtain the 3 D image file of buildings, and the method comprises the following steps:
1) pre-service, the map data mining platform corresponding to building element different in artificial setting DXF file, identifies with the title set;
2) import process, from each layer, identify the information of building element according to the title of setting, the layer in DXF file is imported successively;
3) identifying processing, the line by line data of reading DXF file, take out the geological information of building element and preserve respectively, the geological information of building element comprises the basic geometric data obtaining counter structure from DXF file: point, straight line, circular arc, circle, rectangle; According to obtained geometric data information, building element is converted to closed contour, thus obtains building the two dimensional surface data needed for three-dimensional building data;
4) aftertreatment, according to drawing geometric relativity, by giving expression to wall, the sandwich construction of thickness of window is converted into single layer structure;
5) display and human-edited's process, the various building elements that display imports, provide human-computer interaction interface to supply operator manually to modify to the mistake produced in importing process and perfect;
6) stretch processing, carries out stretched operation to the two dimensional surface data of the various building elements imported, and generates the three-dimensional data that building element is corresponding, and saves as three dimensional image format, to be applied to 3-D display.
Preferably, in described step 1), if the building in DXF file is sandwich construction, and every layer of drawing difference, then by the drawing corresponding to every layer separately, to import respectively.
Preferably, in described step 3), if there is block message in drawing, then in advance block message is all converted to the basic figure information of point, line, circle, circular arc composition.
Preferably, also comprise model bank module, be responsible for the 3 D image file automatically generating non-universal parts in buildings.
Preferably, also comprise the high in the clouds file server based on internet cloud network, be responsible for storing the 3 D image file of buildings and the geographic position of corresponding buildings and title.
Buildings 3-D view display platform of the present invention and application system thereof can automatic analysis DXF files, and generate corresponding two dimensional surface data drawing in software and generate three-dimensional building data, thus the buildings three-dimensional plot constructed based on cloud network, make user can check the inner structure of arbitrary buildings in region quickly and easily.
Embodiment
Below the specific embodiment of the present invention is described in further detail.
A kind of buildings 3-D view display platform of the present invention, first it have employed a kind of method based on DXF file generated 3-D view, so that from the most common and build the 3-D view of buildings the two-dimentional DXF file easily obtained, the method comprises the following steps:
1) pre-service, the map data mining platform corresponding to building element that artificial setting DXF file Zhong Qiang, door, window, pillar etc. are different, identifies with the title set; If the building in DXF file is sandwich construction, and every layer of drawing difference, then by the drawing corresponding to every layer separately, to import respectively;
2) import process, from each layer, identify the information of building element according to the title of setting, the layer in DXF file is imported successively;
3) identifying processing, the line by line data of reading DXF file, take out the geological information of building element and preserve respectively, the geological information of building element comprises the basic geometric data obtaining counter structure from DXF file: point, straight line, circular arc, circle, rectangle; According to obtained geometric data information, building element is converted to closed contour, thus obtains building the two dimensional surface data needed for three-dimensional building data; If there is block message in drawing, then in advance block message is all converted to the basic figure information of point, line, circle, circular arc composition.Block is term conventional in autocad, refers to and textural association general for part is become an entirety, be called block, so that move integrally, copy;
4) aftertreatment, according to drawing geometric relativity, by giving expression to wall, the sandwich construction of thickness of window is converted into single layer structure;
5) display and human-edited's process, the various building elements that display imports, provide human-computer interaction interface to supply operator manually to modify to the mistake produced in importing process and perfect;
6) stretch processing, carries out stretched operation to the two dimensional surface data of the various building elements imported, and generates the three-dimensional data that building element is corresponding, and saves as VTK data layout, to be applied to 3-D display.
A kind of buildings 3-D view display platform of the present invention comprises with lower module:
Data importing module, is responsible for reading in line by line and resolving 3 D image file, to obtain buildings three-dimensional geometry data;
3-D display module, is responsible for, according to the buildings three-dimensional geometry data obtained, realizing the display of buildings 3-D view, and the display engine of 3-D display module adopts visualization tools function storehouse VTK technology to realize.Display engine adopts and builds based on three-dimensional visualization in scientific computing engine VTK leading in the world.Programming language adopts Python.Python is as object-oriented and processor-oriented cross-platform higher level lanquage while at present popular, and contain a large amount of standards and third party library function to realize various function, comprise scientific algorithm, GUI designs, database and hardware mutual.VTK:visualization toolkit, vtk are a software libraries of increasing income, and are mainly used in three dimensional computer graphics, image procossing and visual, can use VTK formatted data, STL formatted data etc.
3-D display module adopts the Depth Peeling technology in visualization tools function storehouse to realize the display transparence of each entity of buildings, can regulate its transparency when each entity of buildings is shown.Type for various architectural entity (wall, door, window) has carried out careful adjustment to its display characteristic, such as reflective, transparency, texture etc., and the Depth Peeling technology leading in the industry utilizing VTK to provide correctly solve multi-layer body superposition after Transparence Display problem, make the structure of whole building be able to clearly show truly.Compared with the building software for display of Vehicles Collected from Market, the building software for display of Vehicles Collected from Market, usually only with opaque form display outline structure, namely can only be seen the profile of building, and can not see building interior structure.Our building 3-D display have employed transparent processing, namely can see building interior structure with having an X-rayed from building, provide user selection function, i.e. Transparence Display or opaque display outline simultaneously.
The amplification that 3-D display module also provides human-computer interaction interface to realize each entity of buildings, reduce, rotate, translation, decomposition, show or hide operation.
Display module must can allow user's freely Scalable, and rotate, translation monolithic architecture model, carries out careful checking to a certain floor, display or hide some floor or entity.Can, by whole entity translation of single floor and rotation, make user non-blockedly can check single layer structure to the direct control in each provider location and direction in addition.Compared with other softwares currently marketed, our display provides building sandwich construction and decomposes display, can by explosive display between each floor of building (being about to pull open a relative distance to observe more clearly between the every first floor of building), our display provides user and can go out one deck and show separately by arbitrary extracting from whole building in addition, and provides interactive operation function.
The present invention also provides a kind of application system of buildings 3-D view display platform of basis, and it comprises with lower module:
Document management module, is responsible for building and manages the 3 D image file of the buildings in one or more region;
User management module, is responsible for maintenance customer and user right, makes the user specified have the authority of access appointment buildings;
Buildings 3-D view display platform is responsible for providing human-computer interaction interface to show the 3-D view of buildings.
Also comprise model bank module, be responsible for the 3 D image file automatically generating non-universal parts in buildings.For the decorative element of the various non-universal comprised in building, such as desk, hose saddle etc., modeling dynamic base Parasolid kernel the most advanced is at present utilized automatically to generate various CAD Spline Model, again they are converted into stl file form, these models can at random be copied and adjust size and orientation, have processed the problem that batch adds 3D solid this technique to high-efficiency.
Parasolid kernel is a dynamic software storehouse that market provides, for setting up structural model, and structure as various in desk, chair, stair etc.STL formatted data: a kind of general structure representation data layout.
Because building three-dimensional data only includes the foundation construction structural informations such as door, window, wall, and when using to user, more detailed building interior is usually also needed to construct, as hose saddle, tables and chairs etc. are put.Providing and editing these structures conveniently, adopts Parasolid kernel dynamic modeling storehouse, builds model bank.Operating personnel can automatically generate various model by Parasolid kernel and save as STL formatted data.
Also comprise the high in the clouds file server based on internet cloud network, be responsible for storing the 3 D image file of buildings and the geographic position of corresponding buildings and title.User obtains required building three-dimensional data according to respective user right from high in the clouds file server, thus display is checked in this locality.User builds based on leading distributed real-time search engine Elastic Search the function of search of three-dimensional data, and user inputs relevant geographical location information, and this platform will return the location index of relevant building on file server in real time.Such as: when user needs to search certain building data, by inputting the positioning position information of this building and title etc., as " Hefei Swan Lake WanDa Plaza ", platform will return the data of this building according to user right.As some susceptibility building just can only be may have access to by fixed personnel.
Above embodiment is only the present invention's a kind of embodiment wherein, and it describes comparatively concrete and detailed, but therefore can not be interpreted as the restriction to the scope of the claims of the present invention.It should be pointed out that for the person of ordinary skill of the art, without departing from the inventive concept of the premise, can also make some distortion and improvement, these all belong to protection scope of the present invention.Therefore, the protection domain of patent of the present invention should be as the criterion with claims.