CN113744400A - Method and device for determining terrain mask selection area and computer equipment - Google Patents
Method and device for determining terrain mask selection area and computer equipment Download PDFInfo
- Publication number
- CN113744400A CN113744400A CN202111057762.1A CN202111057762A CN113744400A CN 113744400 A CN113744400 A CN 113744400A CN 202111057762 A CN202111057762 A CN 202111057762A CN 113744400 A CN113744400 A CN 113744400A
- Authority
- CN
- China
- Prior art keywords
- terrain
- area
- determining
- virtual object
- voxel structure
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 56
- 238000005070 sampling Methods 0.000 claims description 30
- 238000003860 storage Methods 0.000 claims description 10
- 238000004590 computer program Methods 0.000 claims description 7
- 230000004044 response Effects 0.000 claims description 6
- 230000010076 replication Effects 0.000 claims description 5
- 238000012545 processing Methods 0.000 description 12
- 238000004364 calculation method Methods 0.000 description 11
- 238000010586 diagram Methods 0.000 description 9
- 230000006870 function Effects 0.000 description 6
- 230000008569 process Effects 0.000 description 6
- 238000013461 design Methods 0.000 description 4
- 238000009826 distribution Methods 0.000 description 4
- 230000000694 effects Effects 0.000 description 4
- 230000002452 interceptive effect Effects 0.000 description 4
- 238000004891 communication Methods 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000005034 decoration Methods 0.000 description 3
- 230000003993 interaction Effects 0.000 description 3
- 230000006399 behavior Effects 0.000 description 2
- 238000012938 design process Methods 0.000 description 2
- 238000013507 mapping Methods 0.000 description 2
- 230000003068 static effect Effects 0.000 description 2
- 230000008901 benefit Effects 0.000 description 1
- 230000015572 biosynthetic process Effects 0.000 description 1
- 238000005520 cutting process Methods 0.000 description 1
- 230000008676 import Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000007781 pre-processing Methods 0.000 description 1
- 238000007789 sealing Methods 0.000 description 1
- 230000007480 spreading Effects 0.000 description 1
- 238000003892 spreading Methods 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 238000003786 synthesis reaction Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T17/00—Three dimensional [3D] modelling, e.g. data description of 3D objects
- G06T17/05—Geographic models
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T17/00—Three dimensional [3D] modelling, e.g. data description of 3D objects
- G06T17/20—Finite element generation, e.g. wire-frame surface description, tesselation
Abstract
The application provides a method and a device for determining a terrain mask selected area and computer equipment. Relates to the technical field of computers, and the method comprises the following steps: determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region; determining a corresponding bounding box of each voxel structure in the first terrain region; for each voxel structure, determining a collision region in a surrounding frame of the voxel structure corresponding to the voxel structure; a mask selection area is determined in the first terrain area based on the collision area of each voxel structure. Thereby quickly generating a mask selection area on the terrain on which the model has been laid out.
Description
Technical Field
The application relates to the technical field of computers, in particular to a method and a device for determining a terrain mask selected area and computer equipment.
Background
The landform of Hodini always needs to generate various mask selection areas in the design process, and sometimes the various mask selection areas are used for calculating a mixed mapping, or for calculating point cloud distribution, or for marking a special area and the like. However, the current mask selection area generation mode is complex.
Disclosure of Invention
The application aims to provide a method and a device for determining a terrain mask selection area and computer equipment, so as to solve the technical problem that the mask selection area generation mode is complex in the prior art.
In a first aspect, the present application provides a method for determining a terrain mask selected area. The method comprises the following steps:
determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region;
determining a corresponding bounding box of each voxel structure in the first terrain region;
for each voxel structure, determining a collision region in a surrounding frame of the voxel structure corresponding to the voxel structure;
a mask selection area is determined in the first terrain area based on the collision area for each voxel structure.
In an optional implementation manner, the method further includes:
determining a first virtual object model;
determining a second terrain area in the first terrain area;
and performing multi-instantiation replication on the first virtual object model in a second terrain area according to a preset rule to obtain a second virtual object model, and determining the second virtual object model as a target virtual object model.
In an alternative implementation, determining a voxel structure of a plurality of target virtual object models included in a first terrain region includes: and performing collision sampling on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model.
In an optional implementation manner, for each target virtual object model, performing collision sampling in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model, including:
for each target virtual object, performing collision sampling from multiple dimensions in a three-dimensional space to obtain a sampling result;
and performing Boolean operation on the sampling result of each target virtual object model to synthesize a voxel structure corresponding to each target virtual object model.
In an alternative implementation, the plurality of dimensions includes an X-axis dimension, a Y-axis dimension, and a Z-axis dimension.
In an alternative implementation, determining a corresponding bounding box of each voxel structure in the first terrain region includes:
based on the preset range parameters, determining a bounding box of the voxel structure of each target virtual object model in the first terrain region.
In an alternative implementation, the first terrain region is a voxel terrain region.
In an alternative implementation, the mask selection area is used to determine areas other than the impact area; the method further comprises the following steps:
determining a third terrain area in the first terrain area based on the mask selection area;
arranging virtual objects in the third terrain area.
In an optional implementation, the determining, based on the mask selection area, a third terrain area in the first terrain area includes:
in response to a selection operation in the first terrain area, determining a selected initial area;
and deleting the collision area in the initial area based on the mask selection area to obtain the third terrain area.
In a second aspect, the present application provides a land mask selection area determination device, including:
a voxel determination module for determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region;
a bounding box determining module, configured to determine a corresponding bounding box of each voxel structure in the first terrain region;
a collision region determining module, configured to determine, for each voxel structure, a collision region in a bounding box corresponding to the voxel structure;
a mask selection determination module for determining a mask selection in the first terrain area based on the collision area for each voxel structure.
In an optional implementation manner, the system further includes a target virtual object model determining module, configured to:
determining a first virtual object model;
determining a second terrain area in the first terrain area;
and performing multi-instantiation replication on the first virtual object model in a second terrain area according to a preset rule to obtain a second virtual object model, and determining the second virtual object model as a target virtual object model.
In an alternative implementation, the voxel determination module is specifically configured to: and performing collision sampling on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model.
In an alternative practice, the voxel determination module is specifically configured to:
for each target virtual object, performing collision sampling from multiple dimensions in a three-dimensional space to obtain a sampling result;
and performing Boolean operation on the sampling result of each target virtual object model to synthesize a voxel structure corresponding to each target virtual object model.
In an alternative implementation, the plurality of dimensions includes an X-axis dimension, a Y-axis dimension, and a Z-axis dimension.
In an alternative implementation, the bounding box determining module is specifically configured to:
based on the preset range parameters, determining a bounding box of the voxel structure of each target virtual object model in the first terrain region.
In an alternative implementation, the first terrain region is a voxel terrain region.
In an alternative implementation, the mask selection area is used to determine areas other than the impact area; the apparatus further comprises an arrangement module for:
determining a third terrain area in the first terrain area based on the mask selection area;
arranging virtual objects in the third terrain area.
In an alternative implementation, the placement module is further configured to:
in response to a selection operation in the first terrain area, determining a selected initial area;
and deleting the collision area in the initial area based on the mask selection area to obtain the third terrain area.
In a third aspect, the present application provides a computer device comprising a memory and a processor; the memory has stored therein a computer program operable on the processor, which when executed implements the steps of the method of any of the preceding embodiments.
In a fourth aspect, the present application provides a computer readable storage medium having stored thereon machine executable instructions which, when invoked and executed by a processor, cause the processor to perform the method of any of the preceding embodiments.
The application provides a method and a device for determining a terrain mask selected area and computer equipment. Determining a voxel structure of a plurality of target virtual object models included in a first terrain region; determining a corresponding bounding box of each voxel structure in the first terrain region; for each voxel structure, determining a collision region in a surrounding frame of the voxel structure corresponding to the voxel structure; a mask selection area is determined in the first terrain area based on the collision area of each voxel structure. Therefore, the mask selection area can be generated quickly and accurately on the terrain where the model is arranged, and the method is low in calculation amount and high in calculation efficiency.
Drawings
In order to more clearly illustrate the detailed description of the present application or the technical solutions in the prior art, the drawings needed to be used in the detailed description of the present application or the prior art description will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a schematic flow chart of a method for determining a terrain mask selected area according to an embodiment of the present application;
FIG. 2 is an example of a user interface for editing a terrain mask selection area provided by an embodiment of the present application;
FIG. 3 is another example of a user interface for editing a terrain mask selection area provided by an embodiment of the present application;
fig. 4 is an example of a voxel structure determination provided in an embodiment of the present application;
FIG. 5 is an example of bounding box determination provided by an embodiment of the present application;
fig. 6 is a schematic structural diagram of a land mask selection area determining apparatus according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a computer device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
Considering that three-dimensional design software has many mature and convenient processing schemes, Houdini (a kind of three-dimensional design software) in the current mainstream three-dimensional software is the only three-dimensional software with abundant scene editing tool chains, such as topographic and geomorphic calculus, spreading and clustering placement of vegetation models, automatic tool processes, and the like. Due to the unique resource format of the mosaic engine architecture (Messiah Server, which may be referred to as Messiah for short), a customized input/output interface needs to be written when interacting with other software, so that the mosaic engine architecture cannot directly interact with Houdini. Therefore, when processing the terrain of the existing scene in Messiah, an art worker is usually required to edit the terrain manually. However, the existing scene terrain processing mode often brings a large amount of repeated work to the art personnel, which causes that the efficiency of terrain processing is not high and the user experience degree is not high. Based on this, the embodiment of the application provides a method and a device for determining a terrain mask selection area, an electronic terminal and a machine readable storage medium, so that the processing efficiency and the use convenience of art workers during scene processing are improved, and further the user experience is effectively improved.
Some embodiments of the present application will be described in detail below with reference to the accompanying drawings. The embodiments described below and the features of the embodiments can be combined with each other without conflict.
Fig. 1 is a schematic flow chart of a method for determining a terrain mask selected area according to an embodiment of the present application. As shown in fig. 1, the method may include the steps of: for understanding, a graphical user interface is provided through the terminal, and the graphical user interface can comprise a terrain editing interface which comprises a terrain to be edited. For example, the method can be applied to a terminal device capable of running three-dimensional design software, and the graphical user interface can be an interactive interface provided by the three-dimensional design software. The three-dimensional design software can be Houdini, as shown in fig. 1, and the method mainly comprises the following steps:
s110, determining voxel structures of a plurality of target virtual object models included in the first terrain area.
The first terrain area may be a terrain area to be edited, the first terrain area may include an edited virtual object model, or a new virtual object model may be edited in the first terrain area. The first terrain region may be a voxel terrain region.
For example, an edited virtual object may be selected in the first terrain area, and the selected edited virtual object may be determined as a target virtual object.
For another example, a new virtual object model may be edited in the first terrain area, and the newly edited virtual object may be determined as the target virtual object. As one example, a first virtual object model may be determined; determining a second terrain area in the first terrain area; and performing multi-instantiation replication on the first virtual object model in a second terrain area according to a preset rule to obtain a second virtual object model, and determining the second virtual object model as a target virtual object model. For example, one or more second virtual object models may be randomly replicated, or the second virtual object models may be replicated according to a preset distribution rule and/or a preset number. The preset distribution rule may specify a distance between the second virtual object models.
In this embodiment, the terrain area may refer to a terrain in a virtual object, and the virtual object may refer to a virtual object other than the terrain. The virtual object refers to a static object in a virtual scene, such as a terrain, a house, a bridge, vegetation, and the like in a game scene. Static objects are often not directly controlled by the player, but may behave accordingly in response to the interaction behavior (e.g., attack, tear down, etc.) of the virtual objects in the scene, such as: the virtual object may be demolished, picked up, dragged, built, etc. of the building. Alternatively, the virtual object may not respond to the interaction behavior of the virtual object, for example, the virtual object may also be a building, a door, a window, a plant, etc. in the game scene, but the virtual object cannot interact with the virtual object, for example, the virtual object cannot destroy or remove the window, etc.
Determining the voxel structure of the target virtual object model may include a variety of implementations. For example, collision sampling may be performed on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model. For example, collision sampling may be performed on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model. As an example, for each target virtual object, collision sampling may be performed from multiple dimensions in a three-dimensional space to obtain a sampling result; and performing Boolean operation on the sampling result of each target virtual object model to synthesize a voxel structure corresponding to each target virtual object model.
The plurality of dimensions may include an X-axis dimension, a Y-axis dimension, and a Z-axis dimension, among others.
S120, determining a corresponding bounding box of each voxel structure in the first terrain area;
after the voxel structure of each target object model is determined, the region of interest corresponding to each voxel structure can be determined based on the voxel structure, and the data amount of points to be judged can be reduced based on the region of interest, so that the operation efficiency can be improved.
As an example, a bounding box in the first terrain region of the voxel structure of each target virtual object model may be determined based on a preset range parameter. The preset range parameter may be a distance threshold, and the distance threshold may be determined according to actual needs. If the range parameter is too large, the calculation efficiency is low, and if the threshold parameter is too small, the robustness of the calculation result is affected.
And S130, determining a collision region in a surrounding frame of each voxel structure corresponding to the voxel structure.
After determining the region of interest of each voxel structure, a collision region of the region of interest with the voxel structure may be determined within the region of interest, which may be considered as a region where the terrain is in contact with the target virtual object or as a region covered by the target virtual object in the first terrain region.
In some embodiments, the first region may also be a voxel structure, and the region occupied by the target virtual object in the first terrain region may be determined by a collision between the voxel structure structures of the two.
And S140, determining a mask selection area in the first terrain area based on the collision area of each voxel structure.
After determining the collision region of the voxel structure of the target virtual object in the first terrain region, the collision region is the position of the target region object in the first terrain region, in other words, the collision region is occupied by the target virtual object model. In this case, the mask selection area may be determined based on the collision region, and the mask selection area may be an area including only the collision region or an area other than the collision region.
In some embodiments, after the mask selection is determined, a design of a virtual game scene may be conducted based on the mask selection. For example, when the mask selection is an area other than the collision area, other virtual object models may be arranged in the mask selection. For example, the mask selection area is used to determine areas other than the impact area; the method further comprises the following steps: determining a third terrain area in the first terrain area based on the mask selection area; the arrangement of the virtual object is performed in a third topographic region. Wherein the third topographical region may be determined based on the steps of: in response to a selection operation in a first terrain area, determining a selected initial area; and deleting the collision area in the initial area based on the mask selection area to obtain a third terrain area.
The selection operation may include a wipe trigger operation or a circle trigger operation. The smearing operation may be, for example, dragging the target area to be edited after clicking to form a smeared area, and determining the smeared area as an initial area; the circle selection triggering operation may be, for example, to circle the outline of the target area to be edited to obtain an area within the circle selection outline, and determine the area within the circle selection outline as the initial area. In practical application, any one of the first selection trigger operations can be selected according to the characteristics of the terrain. Through the first selection trigger operation, the terrain area to be edited can be selected quickly, so that the operation efficiency and the convenience of art workers are improved.
As an example, the target virtual object may be a building, a road, or the like, and after the building or the road is arranged, decorations such as vegetation may be arranged around the building or the road, at this time, a first terrain area with decorations may be determined, a road or a building included in the first terrain area may be determined, a voxel structure of the road or the building may be determined, a bounding box may be determined in the first terrain area based on the voxel structure of the road or the building, a collision area may be determined based on the bounding box and the voxel structure of the road or the building, a mask selection area may be determined in the first terrain area based on the collision area, and decorations such as vegetation may be arranged based on the mask selection area.
By the embodiment of the application, the voxel structures of a plurality of target virtual object models included in a first terrain area are determined; determining a corresponding bounding box of each voxel structure in the first terrain region; for each voxel structure, determining a collision region in a surrounding frame of the voxel structure corresponding to the voxel structure; a mask selection area is determined in the first terrain area based on the collision area of each voxel structure. Therefore, the mask selection area can be generated quickly and accurately on the terrain where the model is arranged, and the method is low in calculation amount and high in calculation efficiency.
Considering as an art person, it may be necessary to manually adjust the effect in the view, in order to improve convenience and efficient interactive experience, and to simplify the operation and reduce unnecessary calculation amount as much as possible. Fig. 2 shows a schematic diagram of an editing interface for a terrain editing process applied to a terminal device running Houdini, with a terrain editing area on the left for presenting a current scene terrain, such as a large scene terrain which may be a game scene. The right side in fig. 2 is a node selection area for matching the node where the current terrain to be processed is located. As can be seen from fig. 2, the nodes include child nodes, that is, the nodes in the embodiment of the present application can quickly browse information such as existing scenes, hierarchies, and Entity (Entity) of a scene in a hierarchical tree manner, and import, edit, update, and export selected contents. The fine arts personnel can select the corresponding node according to the requirement of actual processing.
For ease of understanding, a schematic diagram of an interface for generating interactive nodes by pulling different hierarchical contents is illustrated, and referring to fig. 3, the interface can also encapsulate nodes by pulling different hierarchical contents for quickly generating nodes at a specified network location. Because the relevant parameters of each resource are more, the operation can be simplified as much as possible to enable the art to directly and quickly use each interactive node without knowing the parameters by dragging and selecting the generated nodes and presetting the deployment parameters, and the path does not need to be manually configured on the node.
The landform of Hodini always needs to generate various mask selection areas in the design process, for example, the mask selection areas can be used for calculating a mixed mapping, or for calculating point cloud distribution, or for marking a special area, and the like. According to the method and the device, after a large number of scene models are imported from a game engine, masks can be generated according to the existing models, and the masks can ensure that the landform where the models are arranged is not influenced by further editing operation.
The terrain can generate a mask according to the voxel structure of the model, but when the model is converted into the voxel, the generation of the completely complete voxel which can be converted into a collision level is not easy for the model with a complex structure or incomplete sealing. And the number of models is usually very large, and the operation is feasible for one voxel collision box, but the obvious efficiency is still inconspicuous when the object becomes tens of thousands of voxels, and the method provided by the embodiment of the application can well solve the problem.
The Package is an instantiation scheme of Houdini, when a model assumes that a 100 x 100 voxel structure is generated and a large number of models are instantiated in a scene, a lot of memory can be saved obviously without generating more voxels, but the voxels for instantiating the Package cannot directly sample the voxel values through vex codes, and the instantiated voxels cannot be directly used for merging the voxels, and if each Package is unpacked and resampled, the efficiency is only further reduced.
With such design requirements, we need a scheme that is efficient enough to sample multiple voxels in the terrain and efficiently convert the scene model into voxels without placing too much of a performance burden.
As an example, as shown in fig. 4, in the embodiment of the present application, a scheme for generating a collision-level voxel structure may include multiple types, in the embodiment of the present application, cutting and sampling are performed from three different dimensions of XYZ, and then a result of the sampling is subjected to boolean operation synthesis, so that the generated voxel structure may have an effect similar to "wrapping from three different angles," and the problem of local hollowing and the like can also be effectively handled.
After the transformation of the voxel structure is completed, as shown in fig. 5, memory can be saved by a Package (also referred to as a bounding box or bounding box), but some adjustments need to be made when sampling voxels in the terrain, and in the Houdini native nodes and the Vex code, modifying the terrain needs to allow each sampling point on the terrain to detect a single voxel, and this process can be performed after unpacking. In order to improve the efficiency, the calculation is carried out reversely, each voxel determines the range interval for detecting the terrain according to the bounding box of the voxel, so that the calculation of terrain sampling points which are far away from the collision box and are irrelevant can be avoided, and the calculation efficiency is improved.
And finally, collecting mask data corresponding to each collision box after recording the terrain sampling points needing masks, so that the areas needing masks on the terrain can be obtained.
In some embodiments, the best choice to accomplish the above idea is to design by using Houdini Hdk instead, on one hand, the operation efficiency can be maximized, some cache structures do not need to be saved by attributes and repeatedly transmitted among nodes, on the other hand, the contents of the packages can be directly filtered in Hdk, all the actual types of the packages can be cached and used for calculation before operation, and thus, each Package does not need to be separately unpacked and then operated.
In the embodiment of the application, the method can meet the requirement of the traditional intersection region mask sampling method between the point cloud and the terrain, and provides more selection possibilities for houdini automatic process design.
Fig. 6 is a schematic structural diagram of a device for determining a selected area of a terrain mask according to an embodiment of the present application. As shown in fig. 6, the apparatus includes:
a voxel determination module 601 for determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region;
a bounding box determining module 602, configured to determine a corresponding bounding box of each voxel structure in the first terrain region;
a collision region determining module 603, configured to determine, for each voxel structure, a collision region in a bounding box of the voxel structure corresponding to the voxel structure;
a mask selection determination module 604 for determining a mask selection in the first terrain region based on the collision region for each voxel structure.
In some embodiments, the system further comprises a target virtual object model determination module to:
determining a first virtual object model;
determining a second terrain area in the first terrain area;
and performing multi-instantiation replication on the first virtual object model in a second terrain area according to a preset rule to obtain a second virtual object model, and determining the second virtual object model as a target virtual object model.
In some embodiments, the voxel determination module is specifically configured to: and performing collision sampling on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model.
In some embodiments, the voxel determination module is specifically configured to:
for each target virtual object, performing collision sampling from multiple dimensions in a three-dimensional space to obtain a sampling result;
and performing Boolean operation on the sampling result of each target virtual object model to synthesize a voxel structure corresponding to each target virtual object model.
In some embodiments, the plurality of dimensions includes an X-axis dimension, a Y-axis dimension, and a Z-axis dimension.
In some embodiments, the bounding box determination module is specifically configured to:
based on the preset range parameters, determining a bounding box of the voxel structure of each target virtual object model in the first terrain region.
In some embodiments, the first terrain region is a voxel terrain region.
In some embodiments, the mask selection area is used to determine areas other than the impact area; the apparatus also includes an arrangement module to: determining a third terrain area in the first terrain area based on the mask selection area; the arrangement of the virtual object is performed in a third topographic region. Wherein the arrangement module is specifically configured to: in response to a selection operation in a first terrain area, determining a selected initial area; and deleting the collision area in the initial area based on the mask selection area to obtain a third terrain area.
The device for determining the selected area of the terrain mask provided by the embodiment of the application has the same technical characteristics as the method for determining the selected area of the terrain mask provided by the embodiment, so that the same technical problems can be solved, and the same technical effects can be achieved.
As shown in fig. 7, a computer device 700 provided in an embodiment of the present application, for example, the computer device 700 may be a preprocessing server, including: a processor 701, a memory 702 and a bus, the memory 702 storing machine readable instructions executable by the processor 701, the processor 701 communicating with the memory 702 via the bus when the computer device is running, the processor 701 executing the machine readable instructions to perform the steps of the method for determining a selected area of a terrain mask as described above.
The processor 701 may be implemented in at least one hardware form of a Digital Signal Processor (DSP), a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), the processor 701 may be one or a combination of several of a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), or other forms of processing units having data processing capabilities and/or instruction execution capabilities, and may control other components in the computer device 700 to perform desired functions.
Specifically, the memory 702 and the processor 701 can be general-purpose memory and processor, which are not limited in particular, and the terrain mask selection area determination method can be executed when the processor 701 executes a computer program stored in the memory 702.
Additionally, the computer device 700 may also include input means as well as output means. The input device is mainly used for realizing human-computer interaction, and the input device can be a device used by a user for inputting instructions and can comprise one or more of a keyboard, a mouse, a microphone, a touch screen and the like. The output device may output various information (e.g., images or sounds) to an external (e.g., user), and may include one or more of a display, a speaker, and the like. The output device may be adapted to display a graphical user interface of the actuator.
Corresponding to the above-mentioned method for determining a selected area of a terrain mask, an embodiment of the present application further provides a computer-readable storage medium, in which machine executable instructions are stored, and when the computer executable instructions are called and executed by a processor, the computer executable instructions cause the processor to execute the steps of the above-mentioned method for determining a selected area of a terrain mask.
The device for determining the selected area of the terrain mask provided by the embodiment of the application can be specific hardware on the equipment or software or firmware installed on the equipment. The device provided by the embodiment of the present application has the same implementation principle and technical effect as the foregoing method embodiments, and for the sake of brief description, reference may be made to the corresponding contents in the foregoing method embodiments where no part of the device embodiments is mentioned. It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the foregoing systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, a division of a unit is merely a division of one logic function, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
Units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, functional units in the embodiments provided in the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device to execute all or part of the steps of the movement control method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus once an item is defined in one figure, it need not be further defined and explained in subsequent figures, and moreover, the terms "first", "second", "third", etc. are used merely to distinguish one description from another and are not to be construed as indicating or implying relative importance.
Finally, it should be noted that: the above examples are only specific embodiments of the present application, and are not intended to limit the technical solutions of the present application, and the scope of the present application is not limited thereto, although the present application is described in detail with reference to the foregoing examples, those skilled in the art should understand that: any person skilled in the art can modify or easily conceive the technical solutions described in the foregoing embodiments or equivalent substitutes for some technical features within the technical scope disclosed in the present application; such modifications, changes or substitutions do not depart from the scope of the embodiments of the present application. Are intended to be covered by the scope of the present application.
Claims (12)
1. A method for determining a terrain mask selected area is characterized by comprising the following steps:
determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region;
determining a corresponding bounding box of each voxel structure in the first terrain region;
for each voxel structure, determining a collision region in a surrounding frame of the voxel structure corresponding to the voxel structure;
a mask selection area is determined in the first terrain area based on the collision area of each voxel structure.
2. The method of claim 1, further comprising:
determining a first virtual object model;
determining a second terrain area in the first terrain area;
and performing multi-instantiation replication on the first virtual object model in the second terrain area according to a preset rule to obtain a second virtual object model, and determining the second virtual object model as a target virtual object model.
3. The method of claim 1, wherein determining a voxel structure of a plurality of target virtual object models included in a first terrain region comprises: and performing collision sampling on each target virtual object model in a three-dimensional space to obtain a voxel structure corresponding to each target virtual object model.
4. The method according to claim 3, wherein the performing collision sampling on each of the target virtual object models in a three-dimensional space to obtain a voxel structure corresponding to each of the target virtual object models comprises:
for each target virtual object, performing collision sampling from multiple dimensions in a three-dimensional space to obtain a sampling result;
and performing Boolean operation on the sampling result of each target virtual object model to synthesize a voxel structure corresponding to each target virtual object model.
5. The method of claim 4, wherein the plurality of dimensions includes an X-axis dimension, a Y-axis dimension, and a Z-axis dimension.
6. The method of claim 1,
the determining a corresponding bounding box of each voxel structure in the first terrain region comprises:
determining a bounding box of the voxel structure of each of the target virtual object models in the first terrain region based on preset range parameters.
7. The method of claim 1, wherein the first terrain region is a voxel terrain region.
8. The method of claim 1, wherein the mask selection area is used to determine areas other than the collision area; the method further comprises the following steps:
determining a third terrain area in the first terrain area based on the mask selection area;
arranging virtual objects in the third terrain area.
9. The method of claim 8, wherein determining a third terrain area in the first terrain area based on the mask selection area comprises:
in response to a selection operation in the first terrain area, determining a selected initial area;
and deleting the collision area in the initial area based on the mask selection area to obtain the third terrain area.
10. A terrain mask selected area determining apparatus, comprising:
a voxel determination module for determining a voxel structure of a plurality of target virtual object models comprised in a first terrain region;
a bounding box determination module, configured to determine a corresponding bounding box of each voxel structure in the first terrain region;
a collision region determining module, configured to determine, for each voxel structure, a collision region in a bounding box corresponding to the voxel structure;
a mask selection determination module for determining a mask selection in the first terrain region based on the collision region for each voxel structure.
11. A computer device comprising a memory and a processor; the memory has stored therein a computer program operable on the processor, the processor implementing the steps of the method of any of the preceding claims 1 to 9 when executing the computer program.
12. A computer readable storage medium having stored thereon machine executable instructions which, when invoked and executed by a processor, cause the processor to execute the method of any of claims 1 to 9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111057762.1A CN113744400A (en) | 2021-09-09 | 2021-09-09 | Method and device for determining terrain mask selection area and computer equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111057762.1A CN113744400A (en) | 2021-09-09 | 2021-09-09 | Method and device for determining terrain mask selection area and computer equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN113744400A true CN113744400A (en) | 2021-12-03 |
Family
ID=78737703
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111057762.1A Pending CN113744400A (en) | 2021-09-09 | 2021-09-09 | Method and device for determining terrain mask selection area and computer equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113744400A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2023185660A1 (en) * | 2022-03-31 | 2023-10-05 | 北京字跳网络技术有限公司 | Rendering display method and apparatus, and computer device and storage medium |
Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080291216A1 (en) * | 2007-05-21 | 2008-11-27 | World Golf Tour, Inc. | Electronic game utilizing photographs |
WO2014020364A1 (en) * | 2012-07-30 | 2014-02-06 | Zinemath Zrt. | System and method for generating a dynamic three-dimensional model |
CN104123529A (en) * | 2013-04-25 | 2014-10-29 | 株式会社理光 | Human hand detection method and system thereof |
US20170354886A1 (en) * | 2016-06-10 | 2017-12-14 | Nintendo Co., Ltd. | Game apparatus, game controlling method and storage medium |
WO2018030453A1 (en) * | 2016-08-09 | 2018-02-15 | 株式会社コロプラ | Information processing method, program for causing computer to execute said information processing method, and computer |
CN109308739A (en) * | 2018-10-11 | 2019-02-05 | 南京工程学院 | A kind of soft tissue Minimally Invasive Surgery training method based on virtual reality |
GB201918840D0 (en) * | 2019-03-26 | 2020-02-05 | Forte Marco | Interactive image matting using neural networks |
CN111640176A (en) * | 2018-06-21 | 2020-09-08 | 华为技术有限公司 | Object modeling movement method, device and equipment |
CN111714895A (en) * | 2020-06-29 | 2020-09-29 | 天津亚克互动科技有限公司 | Game data processing method and device, storage medium and computer equipment |
US20200389573A1 (en) * | 2019-06-04 | 2020-12-10 | Canon Kabushiki Kaisha | Image processing system, image processing method and storage medium |
US20210104100A1 (en) * | 2019-10-02 | 2021-04-08 | Magic Leap, Inc. | Mission driven virtual character for user interaction |
US10991160B1 (en) * | 2019-06-25 | 2021-04-27 | A9.Com, Inc. | Depth hull for rendering three-dimensional models |
-
2021
- 2021-09-09 CN CN202111057762.1A patent/CN113744400A/en active Pending
Patent Citations (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080291216A1 (en) * | 2007-05-21 | 2008-11-27 | World Golf Tour, Inc. | Electronic game utilizing photographs |
WO2014020364A1 (en) * | 2012-07-30 | 2014-02-06 | Zinemath Zrt. | System and method for generating a dynamic three-dimensional model |
CN104123529A (en) * | 2013-04-25 | 2014-10-29 | 株式会社理光 | Human hand detection method and system thereof |
US20170354886A1 (en) * | 2016-06-10 | 2017-12-14 | Nintendo Co., Ltd. | Game apparatus, game controlling method and storage medium |
WO2018030453A1 (en) * | 2016-08-09 | 2018-02-15 | 株式会社コロプラ | Information processing method, program for causing computer to execute said information processing method, and computer |
CN111640176A (en) * | 2018-06-21 | 2020-09-08 | 华为技术有限公司 | Object modeling movement method, device and equipment |
CN109308739A (en) * | 2018-10-11 | 2019-02-05 | 南京工程学院 | A kind of soft tissue Minimally Invasive Surgery training method based on virtual reality |
GB201918840D0 (en) * | 2019-03-26 | 2020-02-05 | Forte Marco | Interactive image matting using neural networks |
US20200389573A1 (en) * | 2019-06-04 | 2020-12-10 | Canon Kabushiki Kaisha | Image processing system, image processing method and storage medium |
US10991160B1 (en) * | 2019-06-25 | 2021-04-27 | A9.Com, Inc. | Depth hull for rendering three-dimensional models |
US20210104100A1 (en) * | 2019-10-02 | 2021-04-08 | Magic Leap, Inc. | Mission driven virtual character for user interaction |
CN111714895A (en) * | 2020-06-29 | 2020-09-29 | 天津亚克互动科技有限公司 | Game data processing method and device, storage medium and computer equipment |
Non-Patent Citations (1)
Title |
---|
俞鸿波;雷莉萍;谢志萍;吴丽红;: "基于体素渲染的障碍物探测雷达数据可视化", 数据采集与处理, vol. 26, no. 06, 15 November 2011 (2011-11-15), pages 723 - 727 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2023185660A1 (en) * | 2022-03-31 | 2023-10-05 | 北京字跳网络技术有限公司 | Rendering display method and apparatus, and computer device and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US6823299B1 (en) | Modeling objects, systems, and simulations by establishing relationships in an event-driven graph in a computer implemented graphics system | |
Lipp et al. | Interactive visual editing of grammars for procedural architecture | |
CN102385744B (en) | The watermark of 3D modeling object is added | |
CN109147050B (en) | Road grid creating method and device based on Unity engine terrain system | |
CN109710357B (en) | Method and system for realizing server operation based on Unity3D engine | |
JP2000076487A (en) | Device and method for processing information, and providing medium | |
CN105988933B (en) | The operable node recognition methods in interface, application testing method, apparatus and system | |
CN104915245B (en) | Realize analogue system and the integrated system and method for the operation of actual functional capability systematic unity | |
CN112365597B (en) | Modelica-based three-dimensional model creation and visual simulation method and device | |
KR101944544B1 (en) | Designing a modeled volume represented by dexels | |
CN108415697B (en) | Configuration method and device of visual component | |
He et al. | Real-Time Extendible-Resolution Display of On-line Dynamic Terrain. | |
CN113744400A (en) | Method and device for determining terrain mask selection area and computer equipment | |
CN111659123A (en) | Navigation data processing method and device, storage medium and electronic equipment | |
CN113744401A (en) | Terrain splicing method and device, electronic equipment and storage medium | |
CN113781642A (en) | Three-dimensional model multi-level LOD generation method based on face reduction algorithm | |
CN116452756A (en) | Three-dimensional scene local automatic generation method, device, equipment and storage medium | |
EP2090994A2 (en) | System, method and computer program product for computer modeling with generative components | |
CN116109767A (en) | Rendering method of three-dimensional scene, image processor, electronic device and storage medium | |
JPH0636013A (en) | Method and device for generating topographic data | |
US20020154149A1 (en) | System, method and computer program product for associative region generation and modification | |
CN108553900A (en) | A method of the stackable storage Reusability based on UE engines | |
CN111897530A (en) | UI system and method based on UE4 platform | |
JP6746851B2 (en) | Terrain classification system and terrain classification method | |
JPH0136152B2 (en) |
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 |