CN113763552A - Three-dimensional geographic model display method and device, computer equipment and storage medium - Google Patents

Three-dimensional geographic model display method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN113763552A
CN113763552A CN202111052344.3A CN202111052344A CN113763552A CN 113763552 A CN113763552 A CN 113763552A CN 202111052344 A CN202111052344 A CN 202111052344A CN 113763552 A CN113763552 A CN 113763552A
Authority
CN
China
Prior art keywords
priority
rendering
component group
target component
display
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111052344.3A
Other languages
Chinese (zh)
Inventor
赵志良
吴文祥
杨瀚洲
孙海旭
朱志新
姜明武
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Guangge Technology Co Ltd
Original Assignee
Suzhou Guangge Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Guangge Technology Co Ltd filed Critical Suzhou Guangge Technology Co Ltd
Priority to CN202111052344.3A priority Critical patent/CN113763552A/en
Publication of CN113763552A publication Critical patent/CN113763552A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/05Geographic models
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/005General purpose rendering architectures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/20Finite element generation, e.g. wire-frame surface description, tesselation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T19/00Manipulating 3D models or images for computer graphics
    • G06T19/20Editing of 3D images, e.g. changing shapes or colours, aligning objects or positioning parts

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computer Graphics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Geometry (AREA)
  • Remote Sensing (AREA)
  • Architecture (AREA)
  • Computer Hardware Design (AREA)
  • General Engineering & Computer Science (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The application relates to a display method, a display device, computer equipment and a storage medium of a three-dimensional geographic model, wherein the display priority comprises a first priority and a second priority, and the first priority is higher than the second priority; loading and rendering a target component group corresponding to the first priority by acquiring the incidence relation between a preset component group and a display priority and according to the incidence relation between the component group and the display priority; when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority. The method and the device realize the prior display of the component groups with high display priority, and load and render the component groups with low display priority in idle time, thereby improving the model rendering efficiency.

Description

Three-dimensional geographic model display method and device, computer equipment and storage medium
Technical Field
The present application relates to the field of three-dimensional geographic information technology, and in particular, to a method and an apparatus for displaying a three-dimensional geographic model, a computer device, and a storage medium.
Background
With the development of Geographic Information technology, Geographic Information Systems (GIS) have emerged. The GIS system is a computer information system mainly used to manage geospatially distributed data, which acquires, stores, manages, calculates, analyzes and displays various data related to the position of the earth's surface in an intuitive geographical graphical manner.
In the traditional technology, the size of the three-dimensional GIS related model is hundreds of millions, and the processing capacity and the network flow of the mobile equipment are greatly tested. The three-dimensional GIS related model can be displayed more lightly and more quickly by reducing the volume of the three-dimensional GIS related model through the format compression and conversion technology of the model.
However, the display manner of the three-dimensional GIS-related model in the conventional technology needs to be improved.
Disclosure of Invention
In view of the foregoing, it is necessary to provide a method and an apparatus for displaying a three-dimensional geographic model, a computer device, and a storage medium, which can improve the display effect of a three-dimensional GIS-related model.
A method of displaying a three-dimensional geographic model, the method comprising:
acquiring configuration information of a three-dimensional geographic model, wherein the three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises an incidence relation between the component groups and display priorities; the presentation priority comprises a first priority and a second priority, the first priority being higher than the second priority;
loading and rendering a target component group corresponding to the first priority according to the incidence relation between the component group and the display priority;
when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority.
In one embodiment, before the rendering the target component group corresponding to the first priority, the method further comprises:
acquiring the number of triangular patches grouped by the target part;
and when the number of the triangular patches is larger than the preset number, filtering the triangular patches in the target component group to obtain the target component group of which the number of the triangular patches is not more than the preset number.
In one embodiment, the association of the component grouping with the presentation priority is determined by the following method, including:
obtaining the three-dimensional geographic model, and carrying out model segmentation on the three-dimensional geographic model to obtain the plurality of component groups;
marking the display priority of each component group according to the preset display sequence of each component group, and generating the association relation between the component groups and the display priority.
In one embodiment, the presentation priorities further include a third priority, the third priority being higher than the second priority; the method further comprises the following steps:
when the time taken for rendering the target component group is not less than the preset time length, loading and rendering the component group corresponding to the third priority when the rendering of the target component group is completed.
In one embodiment, the configuration information further includes a component location; after the obtaining configuration information of the three-dimensional geographic model, the method further comprises:
and splicing the components in the target component group according to the component positions of the components in the target component group to obtain a partial three-dimensional geographic model.
In one embodiment, the loading and rendering the target component grouping corresponding to the first priority according to the association relationship between the component grouping and the presentation priority includes:
and according to the incidence relation between the component groups and the display priority, loading and rendering the target component groups corresponding to the first priority in a multi-thread parallel mode through a non-main thread of the browser.
In one embodiment, the target component grouping corresponding to the first priority is rendered through a timed loop operation interface;
rendering, by an idle period callback interface, the component packet corresponding to the second priority.
A display apparatus for a three-dimensional geographic model, the apparatus comprising:
the system comprises a configuration information acquisition module, a display priority acquisition module and a display priority management module, wherein the configuration information acquisition module is used for acquiring configuration information of a three-dimensional geographic model, the three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises the incidence relation between the component groups and the display priority; the presentation priority comprises a first priority and a second priority, the first priority being higher than the second priority;
the target rendering and loading module is used for loading and rendering the target component group corresponding to the first priority according to the incidence relation between the component group and the display priority;
and the grouping display and loading module is used for displaying the rendered target component grouping and loading and rendering the component grouping corresponding to the second priority at the same time when the rendering of the target component grouping is completed when the time length spent on rendering the target component grouping is less than the preset time length.
A computer device comprising a memory storing a computer program and a processor implementing the steps of the method described above when executing the computer program.
A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the above-mentioned method.
The display method, the display device, the computer equipment and the storage medium of the three-dimensional geographic model have the advantages that the display priority comprises a first priority and a second priority, and the first priority is higher than the second priority; loading and rendering a target component group corresponding to the first priority by acquiring the incidence relation between a preset component group and a display priority and according to the incidence relation between the component group and the display priority; when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority. The method and the device realize the prior display of the component groups with high display priority, and load and render the component groups with low display priority in idle time, thereby improving the model rendering efficiency.
Drawings
FIG. 1 is a diagram of an embodiment of an application environment of a method for displaying a three-dimensional geographic model;
FIG. 2 is a schematic flow chart diagram illustrating a method for displaying a three-dimensional geographic model in one embodiment;
FIG. 3 is a schematic flow chart diagram illustrating a method for displaying a three-dimensional geographic model in one embodiment;
FIG. 4 is a flow chart illustrating the determination of associations according to another embodiment;
FIG. 5 is a block diagram of a device for displaying a three-dimensional geographic model in one embodiment;
FIG. 6 is a diagram illustrating an internal structure of a computer device according to an embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
In the conventional art, a Geographic Information System (GIS) is a computer information system for managing geospatially distributed data, which acquires, stores, manages, calculates, analyzes and displays various data related to the position of the earth's surface in an intuitive geographic graphic manner. With the development of related industries, a geographic information system gradually develops from two dimensions to three dimensions, and starts to be integrated with a 3D model in a fusion manner, for example, a large number of application cases are born in the fields of buildings and engineering by combining with BIM, and the displayed effect is more closely related to the real space and more accords with the real cognition of common users.
Later, with the comprehensive popularization of smart phones and tablet computers, basic hardware conditions of mobile office work are met, the application requirements of users on related applications at mobile terminals are higher and higher, but 3D GIS related models are hundreds of millions, the processing capacity and network flow of mobile equipment are greatly tested, compared with a PC terminal with strong performance, the mobile terminal has more urgent and practical requirements on lightweight display, how to achieve lightweight display of the mobile terminal is achieved, and the users can conveniently and rapidly browse the model effect through geographical positioning at any time and any place, so that the problem of continuous research and overcoming is solved.
At present, the industry has some universal optimization technologies in related fields, the core problem is to reduce the model size to make the model lighter and faster, and the related purposes are generally achieved through model preprocessing, for example, the primitive merging technology of the model, the primitive number of the model is reduced through some similarity algorithms, the very obvious lightweight effect can be realized in the fields of basic engineering, structural engineering and the like, and the format compression and conversion technology of the model and the like.
In the conventional technology, in a rendering level, for example, multiple LOD (Levels of Detail) technology is adopted to improve model fluency of a terminal, and different Levels of geometric objects are used to represent an object, the more distant a loaded model is, the coarser the model is, the more close the loaded model is, the finer the model is, so that display efficiency is improved and storage occupation is reduced on the premise of not affecting visual effect. However, although the model is processed in a lightweight manner, the effect cannot be fully expected in the actual rendering process of the mobile-end scene, and further improvement is still needed.
The three-dimensional geographic model display method provided by the application can be applied to the application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The server 104 acquires a three-dimensional geographic model, and performs model segmentation on the three-dimensional geographic model to obtain a plurality of component groups; marking the display priority of each component group according to the preset display sequence of each component group, generating the association relationship between the component groups and the display priority, and storing the association relationship to the local server 104. When the terminal 102 views the three-dimensional geographic model, the user triggers the operation of viewing the three-dimensional geographic model. The terminal 102 responds to the viewing operation of the three-dimensional geographic model, and obtains configuration information of the three-dimensional geographic model from the server 104, wherein the three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises the incidence relation between the component groups and the display priority; the display priority comprises a first priority and a second priority, and the first priority is higher than the second priority; loading and rendering a target component group corresponding to the first priority according to the incidence relation between the component group and the display priority; when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority.
The terminal 102 may be, but not limited to, various personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices, and the server 104 may be implemented by an independent server or a server cluster formed by a plurality of servers.
In one embodiment, as shown in fig. 2, a method for displaying a three-dimensional geographic model is provided, which is described by taking the method as an example for being applied to the terminal in fig. 1, and includes the following steps:
s210, responding to the viewing operation of the three-dimensional geographic model, and obtaining configuration information of the three-dimensional geographic model.
Wherein the three-dimensional geographic model includes a number of component groupings, which may include at least one component. The number of groupings of parts may be a number of groupings that classify parts used by the three-dimensional geographic model. The plurality of component groups may also be a plurality of partial models obtained by dividing the three-dimensional geographic model according to actual needs. The configuration information includes an association of component groupings with presentation priorities. The presentation priorities include a first priority and a second priority, the first priority being higher than the second priority. The display priority may be a parameter that determines a grouping display order of each component in the three-dimensional geographic model when the terminal displays the three-dimensional geographic model. The presentation priority can be used for characterizing the preset precedence order of the presentation of each component group. The higher the presentation priority, the earlier the presentation time, and the lower the presentation priority, the later the presentation time. Before the terminal initiates the check of the three-dimensional geographic model to the server, the server sets the display sequence of each component group in advance, and generates configuration information according to the component group and the set display sequence. It should be noted that the configuration information may further include at least one of a model name, a model size, and component position information.
Specifically, the terminal responds to the checking operation of the three-dimensional geographic model, the terminal sends a checking request to the server, the server returns the configuration information of the three-dimensional geographic model to the terminal according to the checking request, and the terminal receives the configuration information of the three-dimensional geographic model.
S220, loading and rendering the target component group corresponding to the first priority according to the incidence relation between the component group and the display priority.
Wherein the target component group may be a core component or an important component of the three-dimensional geographic model. The target component group can also be a key component which needs to be viewed by a user in the three-dimensional geographic model firstly, for example, the three-dimensional geographic model can show a street view, and the street view comprises buildings, trees beside the street, roads and blue sky white clouds. The user's objects of interest may be buildings and roads, and the treelets and blue sky clouds around the roads appear unimportant. The display priority of buildings and roads can be set to be higher than that of the small trees beside the roads.
Specifically, the terminal obtains the association relationship between the component groups and the display priorities, determines the priorities of the component groups in the three-dimensional geographic model according to the association relationship between the component groups and the display priorities, and determines the target component groups of which the display priorities meet preset conditions. Target component groupings corresponding to the first priority are loaded and rendered from the server. The preconditions may be associated with a requirement to present a priority, such as presenting the highest priority, then presenting the highest priority component grouping as the target component grouping. The preconditions may also be set in conjunction with user behavior data.
And S230, when the duration spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and simultaneously loading and rendering the component group corresponding to the second priority.
After the target component group is loaded, consuming some time to render the target component group, acquiring the time spent on rendering the target component group, comparing the time spent on rendering the target component group with a preset time length, and when the time spent on rendering the target component group is smaller than the preset time length, indicating that the preset time length also has idle time, and loading and rendering the component group with low priority by using the idle time. Specifically, when the duration taken for rendering the target component group is less than the preset time length, when the rendering of the target component group is completed, the rendered target component group is displayed, and meanwhile, the component group corresponding to the second priority is loaded and rendered by using the idle time. The component packet corresponding to the second priority belongs to the component packet having the lower priority.
In some embodiments, the page of the browser is drawn frame by frame, when the number of frames drawn per second (FPS) reaches 60, the page is fluent, and higher frames are generally imperceptible to human eyes, so that 60 frames per second, that is, each frame is divided into 1000/60 milliseconds, and in order to achieve light and fluent display of the mobile terminal model, the workload of each frame needs to be as small as possible and does not exceed 16 milliseconds, and therefore, the preset time length can be 16 milliseconds.
In the display method of the three-dimensional geographic model, the display priority comprises a first priority and a second priority, and the first priority is higher than the second priority; loading and rendering a target component group corresponding to a first priority by acquiring the incidence relation between the preset component group and the display priority and according to the incidence relation between the component group and the display priority; when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority. The display method has the advantages that the display of the component groups with high display priority is realized, the loading and the rendering of the component groups with low display priority are carried out in idle time, the model rendering efficiency can be improved, the interface pause caused by the downloading of the complete model is prevented, the page smoothness during the loading of the model is effectively ensured, the page refresh frame rate is improved, and the display mode of the three-dimensional GIS related model is optimized.
In one embodiment, as shown in fig. 3, prior to rendering the target part grouping corresponding to the first priority, the method further comprises:
and S310, acquiring the number of triangular patches of the target part group.
And S320, when the number of the triangular patches is larger than the preset number, filtering the triangular patches in the target part group to obtain the target part group of which the number of the triangular patches is not more than the preset number.
Specifically, the surface of each three-dimensional geographic model is made up of a number of triangular patches. The method comprises the steps of separating parts of a three-dimensional geographic model, determining a target part group from a plurality of part groups, obtaining the number of triangular patches of the target part group by reading relevant information of the three-dimensional geographic model before rendering the target part group, wherein if the number of the triangular patches is larger, the structure of the target part group is more complex, the target part group is finer, the rendering workload is increased, and therefore the rendering work needs to occupy larger memory and causes the problem of blockage. Thus, the preset number may be set in connection with the actual situation, for example, the size of the preset number may be set in connection with the terminal capability. And comparing the number of the triangular patches with the preset number, and when the number of the triangular patches is larger than the preset number, filtering the triangular patches in the target component grouping by adopting some simplified algorithms to obtain the target component grouping of which the number of the triangular patches does not exceed the preset number. The simplified algorithm may be a median filtering algorithm.
In some embodiments, the preset number of different sizes is set according to different three-dimensional geographic models or different components of different three-dimensional geographic models. By flexibly setting the size of the preset number, the image quality of the three-dimensional geographic model displayed after rendering is ensured, and transition distortion is avoided.
In some embodiments, the number of triangular patches of the target part grouping is obtained. And when the number of the triangular patches is not more than the preset number, rendering the target part group corresponding to the first priority.
In this embodiment, when the number of the triangular patches is greater than the preset number, the triangular patches in the target component group are filtered to obtain a target component group whose number of the triangular patches is not greater than the preset number, so that the number of the triangular patches is reduced, and the loading speed and the rendering efficiency of the target component group are improved.
In one embodiment, as shown in fig. 4, the association of the component grouping with the presentation priority is determined in the following manner, including:
s410, obtaining an original three-dimensional geographic model, and carrying out model segmentation on the original three-dimensional geographic model to obtain a plurality of component groups.
Specifically, the original three-dimensional geographic model may be acquired from a computer device local to the server or connected to the server, and the original three-dimensional geographic model may be parsed and loaded, so that specific information of each component in the original three-dimensional geographic model may be visually displayed. The original three-dimensional geographic model can be subjected to model segmentation through geometric transformation and component separation to obtain the three-dimensional geographic model, and the three-dimensional geographic model is segmented into a plurality of component groups. Geometric transformation is one of the key steps of model lightweight, the volumes of some simple components can be obviously optimized by parameterizing geometric information describing a single component, and the size of the model is further reduced by reducing the number of model primitives through a triangular patch and a similarity algorithm. The part separation is mainly to facilitate checking the part quantity and details of the whole model and subsequent operation and configuration.
And S420, marking the display priority of each component group according to the preset display sequence of each component group, and generating the association relation between the component groups and the display priority.
The display order of each component group can be determined in advance, the order of some key components or some components which a user wants to see first is set to be the front, and the display priority of the components can be marked to be high. Some non-essential components may be marked with a low priority for presentation, with their order set back. Specifically, the service end divides the model, stores the model into a plurality of component groups, marks the display priority of each component group according to the preset display sequence of each component group, generates the association relationship between the component groups and the display priority and stores the association relationship.
In this embodiment, a plurality of component groups are obtained by segmenting the model, the display priorities of the component groups are marked, and the association relationship between the component groups and the display priorities is generated, so that a data premise is provided for improving the model rendering efficiency.
In one embodiment, the presentation priority further comprises a third priority, the third priority being higher than the second priority. The method further comprises the following steps: and when the time length taken for rendering the target component group is not less than the preset time length, loading and rendering the component group corresponding to the third priority when the rendering of the target component group is completed.
Specifically, the third priority is lower than the first priority, but the third priority is higher than the second priority. The presentation order of the component groups corresponding to the third priority is advanced. And when the time length taken for rendering the target component group is not less than the preset time length, loading and rendering the component group corresponding to the third priority when the rendering of the target component group is completed.
In some embodiments, when the duration taken to render the target component group is less than the preset time length, when the rendering of the target component group is completed, the rendered target component group is displayed, and the component group corresponding to the second priority is loaded and rendered in an idle time. When the component grouping corresponding to the second priority completes rendering, the component grouping corresponding to the third priority may also be loaded and rendered. It should be noted that the length of the idle time is equal to the difference between the preset time length and the time taken to render the target component group.
Illustratively, a browser is installed on the terminal, and the rendering process of each frame of the browser comprises the following six steps:
1) handling user interactions
Including touch events that can block pages, etc., and non-blocking click events, etc.
2) Resolution execution of JS codes
A timer task is included.
3) Frame start
Handling window size changes, page scrolling, etc.
4) rAF response
The rAF is a request animation frame interface of the browser, and the rAF informs the browser to call a specified callback function to update the animation before next redrawing. Meanwhile, in hidden or invisible elements, rAF will not be redrawn or reflowed, and the use amount of CPU, GPU and memory can be reduced.
5) Layout
Determining the position of each element on the page, etc.
6) Drawing
And determining the style of the page elements and displaying.
If the above 6 steps do not exceed the preset time length (for example, 16 ms, which indicates that there is a surplus in time, i.e., there is an idle time, the task registered in the browser requestIdleCallback is executed in the idle time.
According to the comparison of the requested configuration files, the high-priority component groups are executed in batches through the requestanimation frame, and the rendering tasks are fragmented, so that the user operation is continuously responded in the middle of the tasks, the phenomena of clicking, blocking and the like of the user can be avoided, the rendering effect of the key components is quickly shown to the user, and the user waiting time is avoided from being too long. The low-priority component grouping triggers a rendering and loading task through requestIdleCallback and offline.
In the embodiment, the rendering tasks are triggered by using different mechanisms for grouping the components with different priorities, so that the rendering efficiency can be greatly improved.
In one embodiment, the configuration information also includes the component location. After obtaining configuration information for the three-dimensional geographic model, the method further comprises: and splicing the components in the target component group according to the component positions of the components in the target component group to obtain a partial three-dimensional geographic model.
Wherein the component position is used to characterize the position of the component in the three-dimensional geographic model. Specifically, configuration information is obtained from a server, and the configuration information includes an association relationship between a component group and a display priority and a component position. And acquiring the part positions of all parts in the target part group from the configuration information, and splicing all parts in the target part group to obtain a partial three-dimensional geographic model. In some embodiments, the component group corresponding to the second priority may also be spliced with the target component group according to the component position, so as to obtain a spliced model.
In one embodiment, loading and rendering a target component group corresponding to a first priority according to the association relationship between the component group and the presentation priority comprises: and according to the incidence relation between the component groups and the display priority, loading and rendering the target component groups corresponding to the first priority in a multi-thread parallel mode through a non-main thread of the browser.
Specifically, the configuration information of the three-dimensional geographic model comprises the association relationship between the component grouping and the display priority, and the three-dimensional geographic model comprises a plurality of component groupings. And determining the target component group corresponding to the first priority according to the incidence relation, and loading and rendering the target component group corresponding to the first priority in a multi-thread parallel mode through a non-main thread of the browser, so that the model downloading speed can be remarkably improved.
In one embodiment, a target component grouping corresponding to a first priority is rendered by a timed loop operations interface; rendering, by the idle period callback interface, the component packet corresponding to the second priority.
Wherein the three-dimensional geographic model comprises a group of components exhibiting a high priority (such as a group of components corresponding to a third priority, a group of target components corresponding to a first priority) and a group of components exhibiting a low priority (such as a group of target components corresponding to a first priority). The first priority is higher than the third priority, the third priority is higher than the second priority, and these information are present in the configuration information. Specifically, the terminal downloads a target component packet corresponding to a first priority according to the configuration information, calls a timed circular operation interface (requestAnimationFrame) to render the target component packet corresponding to the first priority, displays the rendered target component packet when rendering of the target component packet is completed, loads a component packet corresponding to a second priority, calls an idle period callback interface (requestidlecllback) to render the component packet corresponding to the second priority, and loads a component packet corresponding to a third priority and calls the timed circular operation interface to render the component packet corresponding to the third priority when rendering of the component packet corresponding to the second priority is completed.
In the embodiment, the three-dimensional geographic model is progressively rendered while being downloaded in batches according to the priority, the time-sharing processing technology of the browser is fully utilized, the model rendering efficiency is improved, the display effect is improved, and the user experience is improved.
In one embodiment, the present application provides a method for displaying a three-dimensional geographic model, the method comprising the steps of:
and S502, responding to the viewing operation of the three-dimensional geographic model, and acquiring configuration information of the three-dimensional geographic model.
The three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises the incidence relation between the component groups and the display priority; the presentation priorities include a first priority, a second priority, and a third priority, the first priority being higher than the second priority, the third priority being higher than the second priority.
In some embodiments, the association of the component grouping with presentation priority is determined by: obtaining an original three-dimensional geographic model, and performing model segmentation on the original three-dimensional geographic model to obtain the plurality of component groups; marking the display priority of each component group according to the preset display sequence of each component group, and generating the association relation between the component groups and the display priority.
S504, loading the target component group corresponding to the first priority according to the incidence relation between the component group and the display priority.
S506, acquiring the number of triangular patches grouped by the target component;
and S508, when the number of the triangular patches is larger than the preset number, filtering the triangular patches in the target component group to obtain the target component group of which the number of the triangular patches is not more than the preset number.
And S510, grouping target parts of which the number of the rendering triangle patches does not exceed the preset number.
Specifically, according to the incidence relation between the component groups and the display priority, the target component groups corresponding to the first priority are loaded and rendered in a multi-thread parallel mode through a non-main thread of the browser.
S512, when the duration spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and simultaneously loading and rendering the component group corresponding to the second priority.
Wherein the target component grouping corresponding to the first priority is rendered by a timed loop operation interface; rendering, by an idle period callback interface, the component packet corresponding to the second priority.
And S514, when the time length spent on rendering the target component group is not less than the preset time length, loading and rendering the component group corresponding to the third priority when the rendering of the target component group is completed.
It should be understood that, although the steps in the above-described flowcharts are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a part of the steps in the above-mentioned flowcharts may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of performing the steps or the stages is not necessarily performed in sequence, but may be performed alternately or alternately with other steps or at least a part of the steps or the stages in other steps.
In one embodiment, as shown in FIG. 5, there is provided a presentation apparatus 500 of a three-dimensional geographic model, comprising: a configuration information acquisition module 510, a target rendering loading module 520, and a grouping presentation loading module 530, wherein:
a configuration information obtaining module 510, configured to obtain configuration information of a three-dimensional geographic model, where the three-dimensional geographic model includes a plurality of component groups, and the configuration information includes an association relationship between a component group and a display priority; the presentation priority comprises a first priority and a second priority, the first priority being higher than the second priority;
a first rendering and loading module 520, configured to load and render a target component group corresponding to the first priority according to an association relationship between the component group and a display priority;
a grouping display and loading module 530, configured to, when a duration taken for rendering the target component grouping is less than a preset time length, display the rendered target component grouping when the rendering of the target component grouping is completed, and simultaneously load and render the component grouping corresponding to the second priority.
In one embodiment, the device further comprises a patch number obtaining module and a triangular patch filtering module; wherein:
the patch quantity obtaining module is used for obtaining the quantity of the triangular patches grouped by the target part;
and the triangular patch filtering module is used for filtering the triangular patches in the target component group when the number of the triangular patches is greater than the preset number, so as to obtain the target component group of which the number of the triangular patches is not more than the preset number.
In one embodiment, the device further includes an association relation determining module, configured to obtain an original three-dimensional geographic model, perform model segmentation on the original three-dimensional geographic model, and obtain the plurality of component groups; marking the display priority of each component group according to the preset display sequence of each component group, and generating the association relation between the component groups and the display priority.
In one embodiment, the presentation priorities further include a third priority, the third priority being higher than the second priority; the device further comprises a second rendering and loading module, configured to load and render the component group corresponding to the third priority when rendering of the target component group is completed when a duration taken for rendering the target component group is not less than the preset time length.
In one embodiment, the configuration information further includes a component location; the device also comprises a splicing module used for splicing all the components in the target component grouping according to the component positions of all the components in the target component grouping to obtain a partial three-dimensional geographic model.
In an embodiment, the first rendering and loading module 520 is further configured to load and render the target component grouping corresponding to the first priority in a multi-thread parallel manner through a non-main thread of the browser according to the association relationship between the component grouping and the display priority.
In one embodiment, the target component grouping corresponding to the first priority is rendered through a timed loop operations interface; rendering, by an idle period callback interface, the component packet corresponding to the second priority.
For specific definition of the display device of the three-dimensional geographic model, reference may be made to the above definition of the display method of the three-dimensional geographic model, and details are not described here. The various modules in the above-described three-dimensional geographic model presentation apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as shown in fig. 6. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless communication can be realized through WIFI, an operator network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a method of presentation of a three-dimensional geographic model. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the computer equipment, an external keyboard, a touch pad or a mouse and the like.
Those skilled in the art will appreciate that the architecture shown in fig. 6 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In an embodiment, a computer device is provided, comprising a memory in which a computer program is stored and a processor, which when executing the computer program performs the method steps in the above embodiments.
In an embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which computer program, when being executed by a processor, carries out the method steps of the above-mentioned embodiments.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database or other medium used in the embodiments provided herein can include at least one of non-volatile and volatile memory. Non-volatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical storage, or the like. Volatile Memory can include Random Access Memory (RAM) or external cache Memory. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM), among others.
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A method for displaying a three-dimensional geographic model, the method comprising:
responding to a viewing operation of a three-dimensional geographic model, and acquiring configuration information of the three-dimensional geographic model, wherein the three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises an incidence relation between the component groups and display priorities; the presentation priority comprises a first priority and a second priority, the first priority being higher than the second priority;
loading and rendering a target component group corresponding to the first priority according to the incidence relation between the component group and the display priority;
when the time length spent on rendering the target component group is less than the preset time length, displaying the rendered target component group when the rendering of the target component group is completed, and loading and rendering the component group corresponding to the second priority.
2. The method of claim 1, wherein prior to the rendering of the target component grouping corresponding to the first priority, the method further comprises:
acquiring the number of triangular patches grouped by the target part;
and when the number of the triangular patches is larger than the preset number, filtering the triangular patches in the target component group to obtain the target component group of which the number of the triangular patches is not more than the preset number.
3. The method of claim 1, wherein determining the association of the component grouping with presentation priority comprises:
obtaining an original three-dimensional geographic model, and performing model segmentation on the original three-dimensional geographic model to obtain the plurality of component groups;
marking the display priority of each component group according to the preset display sequence of each component group, and generating the association relation between the component groups and the display priority.
4. The method of claim 1, wherein the presentation priority further comprises a third priority, the third priority being higher than the second priority; the method further comprises the following steps:
when the time taken for rendering the target component group is not less than the preset time length, loading and rendering the component group corresponding to the third priority when the rendering of the target component group is completed.
5. The method of any of claims 1 to 4, wherein the configuration information further comprises a component location; after the obtaining configuration information of the three-dimensional geographic model, the method further comprises:
and splicing the components in the target component group according to the component positions of the components in the target component group to obtain a partial three-dimensional geographic model.
6. The method according to any one of claims 1 to 4, wherein the loading and rendering the target component grouping corresponding to the first priority according to the association relationship between the component grouping and the presentation priority comprises:
and according to the incidence relation between the component groups and the display priority, loading and rendering the target component groups corresponding to the first priority in a multi-thread parallel mode through a non-main thread of the browser.
7. The method of any of claims 1 to 4, wherein the target component grouping corresponding to the first priority is rendered by a timed loop operations interface;
rendering, by an idle period callback interface, the component packet corresponding to the second priority.
8. An apparatus for displaying a three-dimensional geographic model, the apparatus comprising:
the system comprises a configuration information acquisition module, a display priority acquisition module and a display priority management module, wherein the configuration information acquisition module is used for acquiring configuration information of a three-dimensional geographic model, the three-dimensional geographic model comprises a plurality of component groups, and the configuration information comprises the incidence relation between the component groups and the display priority; the presentation priority comprises a first priority and a second priority, the first priority being higher than the second priority;
the first rendering and loading module is used for loading and rendering the target component group corresponding to the first priority according to the incidence relation between the component group and the display priority;
and the grouping display and loading module is used for displaying the rendered target component grouping and loading and rendering the component grouping corresponding to the second priority at the same time when the rendering of the target component grouping is completed when the time length spent on rendering the target component grouping is less than the preset time length.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor, when executing the computer program, implements the steps of the method of any of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7.
CN202111052344.3A 2021-09-08 2021-09-08 Three-dimensional geographic model display method and device, computer equipment and storage medium Pending CN113763552A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111052344.3A CN113763552A (en) 2021-09-08 2021-09-08 Three-dimensional geographic model display method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111052344.3A CN113763552A (en) 2021-09-08 2021-09-08 Three-dimensional geographic model display method and device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113763552A true CN113763552A (en) 2021-12-07

Family

ID=78793991

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111052344.3A Pending CN113763552A (en) 2021-09-08 2021-09-08 Three-dimensional geographic model display method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113763552A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024055462A1 (en) * 2022-09-16 2024-03-21 如你所视(北京)科技有限公司 Vr scene processing method and apparatus, electronic device and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024055462A1 (en) * 2022-09-16 2024-03-21 如你所视(北京)科技有限公司 Vr scene processing method and apparatus, electronic device and storage medium

Similar Documents

Publication Publication Date Title
CN108279966B (en) Webpage screenshot method, device, terminal and storage medium
CN109032722B (en) Method, device, equipment and medium for updating display effect of UI component
RU2632128C1 (en) Method and system of downloading image fragments to client device
US20220139017A1 (en) Layer composition method, electronic device, and storage medium
CN109388317B (en) Picture loading method, terminal device and storage medium
CN111080766A (en) WebGL-based GPU (graphics processing unit) method for accelerating efficient rendering of massive targets
CN110750664B (en) Picture display method and device
WO2023160167A1 (en) Image processing method, electronic device, and storage medium
CN108255546A (en) A kind of implementation method and device of data loading animation
CN111858827B (en) Map point location thinning display method and device and computer equipment
CN111951356B (en) Animation rendering method based on JSON data format
WO2023197762A1 (en) Image rendering method and apparatus, electronic device, computer-readable storage medium, and computer program product
US9646362B2 (en) Algorithm for improved zooming in data visualization components
CN113538502A (en) Picture clipping method and device, electronic equipment and storage medium
CN111667199A (en) Workflow construction method and device, computer equipment and storage medium
CN112162672A (en) Information flow display processing method and device, electronic equipment and storage medium
CN114003160A (en) Data visualization display method and device, computer equipment and storage medium
CN114416261B (en) Information display method, device, equipment and medium
CN113763552A (en) Three-dimensional geographic model display method and device, computer equipment and storage medium
CN111796825B (en) Bullet screen drawing method, bullet screen drawing device, bullet screen drawing equipment and storage medium
CN109739403B (en) Method and apparatus for processing information
CN114428573B (en) Special effect image processing method and device, electronic equipment and storage medium
CN114489910A (en) Video conference data display method, device, equipment and medium
CN115588064A (en) Video generation method and device, electronic equipment and storage medium
CN113961280B (en) View display method and device, electronic equipment and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination