Virtual model processing method, device, medium and electronic device
By updating the location of the open virtual object model to match the virtual terrain model, the problem of exposure to the open area is solved, and the aesthetics and visual effects of the virtual terrain are improved.
Patent Information
- Application Number
- CN202210819998.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-12
- Publication Date
- 2025-02-18
- Estimated Expiration
- 2042-07-12
AI Technical Summary
During the virtual game production process, when the open virtual object model comes into contact with the virtual terrain model, the open area is easily exposed outside the surface, resulting in poor visual effects of the virtual terrain.
By determining the positional relationship between the opening point position information of the opening virtual object model and the positional relationship between the virtual terrain model, if specific conditions are met, the position of the opening virtual object model is updated, such as moving or rotating in a specific direction, to ensure that the opening point and the virtual terrain model are Suitable alignment.
The aesthetics of virtual terrain in a three-dimensional virtual scene is improved, and the opening area of the open virtual object model is avoided from being exposed to the surface of the virtual terrain model, thereby improving the overall visual effect.
Smart Images

Figure CN115193036B_ABST
Abstract
Description
Background Art
[0002] Virtual terrain production is a key link in the virtual game production process. During the virtual terrain production process, virtual object models such as rocks, low vegetation or large plants can be used to decorate the virtual terrain model to make the virtual terrain model more visually rich.
[0003] Usually, since the normals of the surface of the open virtual object model that contacts the virtual terrain model are substantially parallel, decorating the virtual terrain model with the open virtual object model facilitates the connection between the two models and can achieve a better fusion effect.
[0004] However, due to the working characteristics of the 3D engine, after the opening virtual object model is placed in the virtual terrain model, the opening area of the opening virtual object model will be exposed outside the surface of the virtual terrain model, resulting in poor visual effects of the virtual terrain. Summary of the invention
[0005] The present disclosure provides a virtual model processing method, a virtual model processing device, a computer-readable storage medium and an electronic device, thereby improving the aesthetics of a virtual terrain in a three-dimensional virtual scene at least to a certain extent.
[0006] According to a first aspect of the present disclosure, a virtual model processing method is provided, comprising:
[0007] Determine the position information of the opening point of the open virtual object model in the three-dimensional virtual scene, the opening point being the end point of the edge without colinear constituent surface among the multiple edges constituting the constituent surface of the open virtual object model;
[0008] Determine the positional relationship between the opening point and the virtual terrain model according to the positional information of the virtual terrain model and the positional information of the opening point;
[0009] If it is determined according to the position relationship that the model position update condition is met, the position of the opening virtual object model is updated.
[0010] Optionally, the method further includes:
[0011] If the position relationship indicates that the opening point is located above the surface of the virtual terrain model, it is determined that the model position update condition is met;
[0012] Update the position of the opening virtual object model, including:
[0013] The opening virtual object model is moved along a first target direction by a first preset distance, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0014] Optionally, the method further includes:
[0015] If the position relationship indicates that at least one opening point is located above the surface of the virtual terrain model, then determining that the model position update condition is met;
[0016] Update the position of the opening virtual object model, including:
[0017] Determine the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model, wherein the target opening point is an opening point in the opening virtual object model located above the ground surface of the virtual terrain model;
[0018] The opening virtual object model is rotated by a preset angle based on the rotation axis, and the rotated opening virtual object model is moved by a second preset distance along a first target direction, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0019] Optionally, determining the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model includes:
[0020] Based on the rotation axis formula, the rotation axis of the opening virtual object model is determined according to the position information of the target opening point and the position information of the center point of the opening virtual object model. The rotation axis formula is:
[0021]
[0022] Among them, Dir is the rotation axis, A i is the position information of the i-th target opening point among the n target opening points, and B is the position information of the center point of the opening virtual object model.
[0023] Optionally, the method further includes:
[0024] If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, then when it is determined that the distance value between at least one opening point and the virtual terrain model is greater than a distance threshold, it is determined that the model position update condition is satisfied;
[0025] Update the position of the opening virtual object model, including:
[0026] The opening virtual object model is moved along a second target direction by a third preset distance, where the second target direction is a second preset direction of the three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0027] Optionally, determining position information of an opening point of an opening virtual object model in a three-dimensional virtual scene includes:
[0028] identifying at least one open edge of the open virtual object model, where the open edge is an edge without a colinear constituent surface among a plurality of edges constituting a constituent surface of the open virtual object model;
[0029] The position information of the endpoints of each opening edge is determined to obtain the position information of the opening point of the opening virtual object model.
[0030] Optionally, after updating the position of the opening virtual object model, the method further includes:
[0031] Obtain updated position information of the opening point of the opening virtual object model;
[0032] Determine an updated positional relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated positional information of the virtual terrain model and the opening point;
[0033] If it is determined according to the updated positional relationship that the model position stop updating condition is met, then the position of the opening virtual object model is stopped from being updated;
[0034] If it is determined according to the updated positional relationship that the model position update condition is met, the position of the opening virtual object model is updated again.
[0035] Optionally, the method further includes:
[0036] If the updated position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point and the virtual terrain model is less than or equal to the distance threshold, it is determined that the model position update stop condition is met.
[0037] According to a second aspect of the present disclosure, there is provided a virtual model processing device, comprising:
[0038] A first determination module is configured to determine position information of an opening point of an open virtual object model in a three-dimensional virtual scene, wherein the opening point is an end point of an edge without a colinear constituent surface among a plurality of edges constituting a constituent surface of the open virtual object model;
[0039] A second determination module is configured to determine a positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point;
[0040] The updating module is configured to update the position of the opening virtual object model if it is determined according to the position relationship that the model position update condition is met.
[0041] Optionally, the virtual model processing device further includes a first judgment module configured to:
[0042] If the position relationship indicates that the opening point is located above the surface of the virtual terrain model, it is determined that the model position update condition is met;
[0043] Update module, configured as:
[0044] The opening virtual object model is moved along a first target direction by a first preset distance, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0045] Optionally, the virtual model processing device further includes a first judgment module configured to:
[0046] If the position relationship indicates that at least one opening point is located above the surface of the virtual terrain model, then determining that the model position update condition is met;
[0047] Update module, configured as:
[0048] Determine the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model, wherein the target opening point is an opening point in the opening virtual object model located above the ground surface of the virtual terrain model;
[0049] The opening virtual object model is rotated by a preset angle based on the rotation axis, and the rotated opening virtual object model is moved by a second preset distance along a first target direction, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0050] Optionally, the update module is configured to:
[0051] Based on the rotation axis formula, the rotation axis of the opening virtual object model is determined according to the position information of the target opening point and the position information of the center point of the opening virtual object model. The rotation axis formula is:
[0052]
[0053] Among them, Dir is the rotation axis, A i is the position information of the i-th target opening point among the n target opening points, and B is the position information of the center point of the opening virtual object model.
[0054] Optionally, the virtual model processing device further includes a first judgment module configured to:
[0055] If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, then when it is determined that the distance value between at least one opening point and the virtual terrain model is greater than a distance threshold, it is determined that the model position update condition is satisfied;
[0056] Update module, configured as:
[0057] The opening virtual object model is moved along a second target direction by a third preset distance, where the second target direction is a second preset direction of the three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0058] Optionally, the first determining module is configured to:
[0059] identifying at least one open edge of the open virtual object model, where the open edge is an edge without a colinear constituent surface among a plurality of edges constituting a constituent surface of the open virtual object model;
[0060] The position information of the endpoints of each opening edge is determined to obtain the position information of the opening point of the opening virtual object model.
[0061] Optionally, the virtual model processing device further includes an update processing module configured to:
[0062] Obtain updated position information of the opening point of the opening virtual object model;
[0063] Determine an updated positional relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated positional information of the virtual terrain model and the opening point;
[0064] If it is determined according to the updated positional relationship that the model position stop updating condition is met, then the position of the opening virtual object model is stopped from being updated;
[0065] If it is determined according to the updated positional relationship that the model position update condition is met, the position of the opening virtual object model is updated again.
[0066] Optionally, the virtual model processing device further includes a second judgment module configured to:
[0067] If the updated position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point and the virtual terrain model is less than or equal to the distance threshold, it is determined that the model position update stop condition is met.
[0068] According to a third aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the method of the first aspect is implemented.
[0069] According to a fourth aspect of the present disclosure, there is provided an electronic device, including:
[0070] Processor; and
[0071] A memory for storing executable instructions of the processor;
[0072] The processor is configured to perform the method of the first aspect by executing executable instructions.
[0073] The technical solution disclosed in this disclosure has the following beneficial effects:
[0074] Provided are a virtual model processing method, device, medium and electronic device, which can determine whether the position of an opening virtual object model in a three-dimensional virtual scene is correct, and adjust the position of an opening virtual object model that is incorrectly positioned, to ensure that the opening virtual object model does not affect the visual effect of the three-dimensional virtual scene, and to improve the aesthetics of the terrain model in the three-dimensional virtual scene.
[0075] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0076] The drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and are used together with the specification to explain the principles of the present disclosure. Obviously, the drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0077] Figure 1 A partial schematic diagram showing a three-dimensional virtual scene in the related art;
[0078] Figure 2 A schematic architecture diagram of a virtual model processing system in this exemplary embodiment is shown;
[0079] Figure 3 A flowchart showing a virtual model processing method in this exemplary embodiment;
[0080] Figure 4 A flowchart showing a method of updating the position of an opening virtual object model in this exemplary embodiment;
[0081] Figure 5 A partial schematic diagram showing a three-dimensional virtual scene in this exemplary embodiment;
[0082] Figure 6 A flowchart showing another virtual model processing method in this exemplary embodiment;
[0083] Figure 7 A schematic diagram showing the structure of a virtual model processing device in this exemplary embodiment is shown;
[0084] Figure 8 A schematic structural diagram of an electronic device in this exemplary embodiment is shown. DETAILED DESCRIPTION
[0085] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, exemplary embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the exemplary embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.
[0086] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0087] The flowcharts shown in the accompanying drawings are only exemplary and do not necessarily include all the steps. For example, some steps may be decomposed, while some steps may be combined or partially combined, so the actual execution order may change according to the actual situation.
[0088] In the related art, a three-dimensional engine can be used to create a three-dimensional virtual scene, wherein in the process of creating a virtual terrain, the three-dimensional engine can determine the normal direction of the surface of the contact portion of the opening virtual object model and the virtual terrain model according to the type of the selected opening virtual object model, and place the opening virtual object model in the virtual terrain model according to the normal direction of the surface of the ground surface in the virtual terrain model and the normal direction of the surface of the contact portion of the opening virtual object model and the virtual terrain model. The three-dimensional engine can include a three-dimensional virtual scene creation engine such as a game engine or an animation engine.
[0089] However, since the three-dimensional engine does not consider the actual shape of the opening virtual object model when placing the opening virtual object model on the virtual terrain model, the opening area of the opening virtual object model placed on the surface of the virtual terrain model will be exposed outside the surface of the virtual terrain model, resulting in a poor visual effect of the produced virtual terrain.
[0090] For example, Figure 1As shown, Figure 1 A partial schematic diagram of a three-dimensional virtual scene provided in a related art is shown, wherein the three-dimensional virtual scene includes a virtual terrain model 101 and an open virtual object model 102 placed on the surface of the virtual terrain model 101, wherein an area 1021 where an opening point of the open virtual object model 102 is located is exposed outside the surface of the virtual terrain model 101, affecting the visual effect of the virtual terrain.
[0091] In view of the above problems, an exemplary embodiment of the present disclosure provides a virtual model processing method, and the application scenarios of the business processing method include but are not limited to: in a three-dimensional virtual scene including an opening virtual object model, the position of the opening virtual object model whose setting position will affect the visual effect of the virtual terrain is adjusted to improve the visual effect of the produced virtual terrain.
[0092] In order to implement the above virtual model processing method, an exemplary embodiment of the present disclosure provides a virtual model processing system. Figure 2 FIG. 4 shows a schematic architecture diagram of the virtual model processing system. Figure 2 As shown, the virtual model processing system 200 may include a first terminal 210 and a second terminal 220. The first terminal 210 is a terminal device of a virtual model processing service provider; the second terminal 220 is a terminal device of a virtual model processing service demander, and the terminal device may include, for example, a desktop computer, a notebook, a tablet computer or a server. The first terminal 210 and the second terminal 220 may establish a connection through a network to implement virtual model processing, such as the first terminal 210 establishing a video connection with the second terminal 220 through a wired or wireless network to perform virtual model processing.
[0093] In which, in an optional implementation, the first terminal 210 can receive a 220 virtual model processing request sent by the second terminal 220, and parse the file to be parsed in the virtual model processing request, wherein the file to be parsed is a three-dimensional virtual scene file including an opening virtual object model; further, the first terminal 210 can load the file to be parsed based on a three-dimensional engine, and according to the virtual model processing method provided in the embodiment of the present disclosure, adjust the position of the opening virtual object model in the three-dimensional virtual scene whose position will affect the visual effect of the virtual terrain.
[0094] In an optional embodiment, the first terminal 210 can create a three-dimensional virtual scene including an opening virtual object model based on a three-dimensional engine, and adjust the position of the opening virtual object model in the three-dimensional virtual scene whose position will affect the visual effect of the virtual terrain according to the virtual model processing method provided in the embodiment of the present disclosure.
[0095] The present disclosure provides a virtual model processing method. Figure 3 A flowchart of a virtual model processing method provided in an embodiment of the present disclosure, the virtual model processing method can be applied to Figure 2 The three-dimensional engine of the first terminal is shown as Figure 3 As shown in , the method includes the following steps S301 to S303:
[0096] Step S301, determining the position information of the opening point of the opening virtual object model in the three-dimensional virtual scene;
[0097] In the disclosed embodiment, the open virtual object model is a virtual object model in a three-dimensional virtual scene, in which there are open edges in the constituent surfaces of the virtual object model, and the open edges are the edges of the constituent surfaces of the open virtual object model that are not co-linear with the constituent surfaces; the open points are the endpoints of the edges of the constituent surfaces of the open virtual object model that are not co-linear with the constituent surfaces, i.e., the endpoints of the open edges. The constituent surfaces may be triangular surfaces or quadrilateral surfaces, etc.
[0098] Step S302, determining the positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point;
[0099] Step S303: if it is determined according to the position relationship that the model position update condition is met, the position of the opening virtual object model is updated.
[0100] To summarize, in the embodiments of the present disclosure, the positional relationship between the opening point of the opening virtual object model and the virtual terrain model can be determined based on the position information of the opening point of the opening virtual object model in the three-dimensional virtual scene and the position information of the virtual terrain model. If it is determined based on the positional relationship that the model position update condition is met, the position of the opening virtual object model is updated, and whether the position of the opening virtual object model in the three-dimensional virtual scene is correct can be determined. The position of the opening virtual object model with an incorrect position can be adjusted to ensure that the opening virtual object model does not affect the visual effect of the three-dimensional virtual scene, thereby improving the aesthetics of the terrain model in the three-dimensional virtual scene.
[0101] Below Figure 3 Each step is described in detail:
[0102] In step S301, the first terminal determines position information of an opening point of an opening virtual object model in a three-dimensional virtual scene.
[0103] In the embodiment of the present disclosure, the position information of the opening point is the position information of the opening point in the three-dimensional coordinate system of the three-dimensional virtual scene, wherein the three-dimensional coordinate system of the three-dimensional virtual scene can be a three-dimensional coordinate system used to construct the three-dimensional virtual scene, for example, a world coordinate system; the position information can be the position coordinates of the opening point in the three-dimensional coordinate system.
[0104] In an optional embodiment, the process of the first terminal determining the position information of the opening point of the open virtual object model in the three-dimensional virtual scene may include: the three-dimensional engine in the first terminal responds to the model virtual model processing instruction, or receives the virtual model processing operation to obtain model processing information, and the model processing information includes the open virtual object model to be processed in the three-dimensional virtual scene; further, the first terminal can determine the position information of the opening point of the open virtual object model in the three-dimensional virtual scene.
[0105] The process of the first terminal determining the position information of the opening point of the open virtual object model in the three-dimensional virtual scene may include: identifying at least one opening edge of the open virtual object model; determining the position information of the endpoints of each opening edge, and obtaining the position information of the opening point of the open virtual object model. The speed of determining the position information of the opening point of the open virtual object model can be improved by identifying the opening edge of the open virtual object model and obtaining the position information of the opening point.
[0106] In an optional embodiment, when the three-dimensional engine does not have the ability to identify open edges, the process of the first terminal identifying at least one open edge of the open virtual object model can be implemented based on the geometry processing (GeometryProcessing) plug-in and the constructor in the three-dimensional engine. The process of the first terminal identifying at least one open edge of the open virtual object model based on the geometry processing (GeometryProcessing) plug-in and the constructor in the three-dimensional engine can include: using the geometry processing GeometryProcessing plug-in to determine the geometric feature data of the open virtual object model, and determining at least one open edge based on the constructor to process the geometric feature data. The geometric feature data may include feature data of the constituent faces of the open virtual object model, for example, the position information of the three vertices of the triangular face constituting the open virtual object model in the three-dimensional coordinate system, and the identification of the triangular face, etc.
[0107] In step S302, the first terminal determines the positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point.
[0108] In the embodiment of the present disclosure, the positional relationship between the opening point and the virtual terrain model is the positional relationship between the opening point and the surface of the virtual terrain model. The positional relationship between the opening point and the virtual terrain model may include the opening point being above the surface of the virtual terrain model, or the opening point being below the surface of the virtual terrain model, or the opening point and the surface of the virtual terrain model overlapping.
[0109] In an optional embodiment, the process of determining the positional relationship between the opening point and the virtual terrain model by the first terminal according to the position information of the virtual terrain model and the position information of the opening point can be implemented based on a ray detection algorithm, wherein the process of determining the positional relationship between the opening point and the virtual terrain model based on the ray detection algorithm according to the position information of the virtual terrain model and the position information of the opening point can include: determining the position of the opening point in the three-dimensional coordinate system according to the position information of the opening point, taking the position of the opening point as the ray origin, emitting a detection ray in the first target direction, and obtaining a first ray detection result; further, the first terminal can determine the positional relationship between the opening point and the virtual terrain model according to the first ray detection result and the position information of the virtual terrain model, wherein the first ray detection result can include the position information of the target object, and the target object is a virtual model in the three-dimensional virtual scene that collides with the detection ray, wherein the first target direction can be a first preset direction of the three-dimensional coordinate system in which the three-dimensional virtual scene is located. wherein the first preset direction can be determined based on the type of the three-dimensional coordinate system in which the three-dimensional virtual scene is located; for example, if the three-dimensional coordinate system in which the three-dimensional virtual scene is located is a world coordinate system, then the first preset direction can be the negative direction of the Z axis.
[0110] Among them, the process of determining the positional relationship between the opening point and the virtual terrain model based on the first ray detection result and the position information of the virtual terrain model may include: comparing the position information of the target object with the position information of the virtual terrain model, if the position information of the target object is the same as the position information of the virtual terrain model, then determining that the target object is a virtual terrain model, and determining that the opening point is above the surface of the virtual terrain model; if the position information of the target object is different from the position information of the virtual terrain model, then determining that the target object is not a virtual terrain model, and further, if it is determined that the position information of the opening point is different from the position information of the virtual terrain model, then determining that the opening point is below the surface of the virtual terrain model; determining that the position information of the opening point is the same as the position information of the virtual terrain model, then determining that the opening point and the surface of the virtual terrain model overlap.
[0111] It should be noted that, in the disclosed embodiment, when all opening points of the opening virtual object model are located below the surface of the virtual terrain model, and the distance between the opening point and the surface of the virtual terrain model is less than a certain distance, it can be determined that the setting position of the opening virtual object model in the three-dimensional virtual scene will not affect the visual effect of the virtual terrain. Therefore, when it is determined that the opening point is located below the surface of the virtual terrain model, it is necessary to determine the distance value between the opening point and the surface of the virtual terrain model.
[0112] In an optional embodiment, the process of the first terminal determining the distance value between the opening point and the surface of the virtual terrain model may include: determining the position of the opening point in the three-dimensional coordinate system based on the position information of the opening point, taking the position of the opening point as the ray origin, emitting a detection ray in the direction of the second target, and obtaining a second ray detection result; wherein the second ray detection result includes the distance value between the opening point and the virtual terrain model, and the distance value between the opening point and the virtual terrain model is used to represent the distance between the opening point and the surface of the virtual terrain model.
[0113] In an optional embodiment, after determining the positional relationship between the opening point of the opening virtual object model and the virtual terrain model, the first terminal can also determine whether the model position update condition is met according to the positional relationship, wherein the process of determining whether the model position update condition is met according to the positional relationship may include: if the positional relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point of the opening virtual object model and the virtual terrain model is less than or equal to the distance threshold, then it is determined that the model position update condition is not met; otherwise, it is determined that the model position update condition is met. It can be understood that when it is determined that the model position update condition is not met, it means that the position of the opening virtual object model in the three-dimensional virtual scene does not affect the aesthetics of the virtual terrain in the three-dimensional virtual scene.
[0114] In step S303, if the first terminal determines that the model position update condition is met according to the position relationship, the position of the opening virtual object model is updated.
[0115] In the embodiment of the present disclosure, when it is determined based on the position relationship that the model position update condition is met, it can be determined that the current position of the opening virtual object model will affect the visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene, and the position of the opening virtual object model needs to be corrected.
[0116] In an optional embodiment, if the position relationship indicates that the opening point is located above the surface of the virtual terrain model, it is determined that the model position update condition is met; the process of the first terminal updating the position of the opening virtual object model may include: moving the opening virtual object model along the first target direction by a first preset distance to obtain the opening virtual object model after the position is updated. Among them, the first preset distance can be obtained from the model processing information, and the first preset distance can be determined based on actual needs, which is not limited in the embodiment of the present disclosure. When it is determined that all the opening points of the opening virtual object model are located above the surface of the virtual terrain model, the opening points of the opening virtual object model can be controlled to move to a position below the surface of the virtual terrain model to prevent the opening points from being exposed outside the surface of the virtual terrain model, which will adversely affect the visual effect of the virtual terrain at the location of the opening virtual object model in the three-dimensional virtual scene.
[0117] In an optional implementation, if the position relationship indicates that at least one opening point is located above the surface of the virtual terrain model, it is determined that the model position update condition is met; Figure 4 As shown, the process of the first terminal updating the position of the opening virtual object model may include steps S401 to S402:
[0118] Step S401 : determining the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model.
[0119] In the embodiment of the present disclosure, the target opening point is an opening point located above the ground surface of the virtual terrain model in the opening virtual object model, and the position information may be a position coordinate.
[0120] In an optional implementation, based on a rotation axis formula, the rotation axis of the opening virtual object model is determined according to the position information of the target opening point and the position information of the center point of the opening virtual object model. The rotation axis formula is:
[0121]
[0122] Among them, Dir is the rotation axis, A i is the position information of the i-th target opening point among the n target opening points, and B is the position information of the center point of the opening virtual object model; Normalize means normalization, and the rotation axis can be determined according to the target opening point, so as to quickly adjust the position of the opening virtual object model to a suitable position according to the rotation axis to prevent the opening point from being exposed outside the surface of the virtual terrain model.
[0123] Step S402: rotating the opening virtual object model by a preset angle based on the rotation axis, and moving the rotated opening virtual object model by a second preset distance along a first target direction.
[0124] In the embodiment of the present disclosure, the first preset angle and the second preset distance may be obtained from model processing information, and the preset angle and the second preset distance may be determined based on actual needs, which is not limited in the embodiment of the present disclosure.
[0125] In an optional embodiment, the first terminal may rotate the opening virtual object model by a preset angle based on the rotation axis, and move the rotated opening virtual object model by a second preset distance along the first target direction, wherein the process of rotating the opening virtual object model by a preset angle based on the rotation axis may include: rotating the opening virtual object model by a preset angle clockwise based on the rotation axis; or rotating the opening virtual object model by a preset angle counterclockwise based on the rotation axis.
[0126] It should be noted that, in the embodiment of the present disclosure, for an opening virtual object model in which some opening points are located above the surface of the virtual terrain model and some opening points are located below the surface of the virtual terrain model, the position of the opening virtual object model can be adjusted by rotation and movement, and the opening points of the opening virtual object model can be controlled to move to a position above the surface of the virtual terrain model to prevent the opening points from being exposed outside the surface of the virtual terrain model, which would adversely affect the visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene.
[0127] In an optional embodiment, if the position relationship indicates that the opening point is located below the surface of the virtual terrain model, then when it is determined that the distance value between at least one opening point and the virtual terrain model is greater than the distance threshold, it is determined that the model position update condition is met; the process of the first terminal updating the position of the opening virtual object model may include: moving the opening virtual object model along the second target direction by a third preset distance, wherein the second target direction is the second preset direction of the three-dimensional coordinate system in which the three-dimensional virtual scene is located, and the distance threshold and the third preset distance may be obtained from the model processing information, and the distance threshold and the third distance threshold may be determined based on actual needs, and the embodiments of the present disclosure do not limit this. Among them, the second preset direction may be determined based on the type of the three-dimensional coordinate system in which the three-dimensional virtual scene is located; for example, if the three-dimensional coordinate system in which the three-dimensional virtual scene is located is the world coordinate system, then the second preset direction may be the positive direction of the Z axis.
[0128] It should be noted that, in the disclosed embodiment, when all the opening points of the opening virtual object model are located below the ground surface of the virtual terrain model, although there is no problem of poor visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene due to the opening points being located above the ground surface of the virtual terrain model; however, when the opening points located below the ground surface of the virtual terrain model are far away from the ground surface of the virtual terrain model, there will be a situation where the portion of the opening virtual object model retained above the ground surface of the virtual terrain model is small, and the problem of poor visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene will also occur. Therefore, when the position relationship indicates that the opening point is located below the ground surface of the virtual terrain model, and when it is determined that the distance value between at least one opening point and the virtual terrain model is greater than the distance threshold, the opening point of the opening virtual object model is controlled to move to a position close to the ground surface of the virtual terrain model, so as to prevent the portion of the virtual terrain model above the ground surface from being small, which will cause adverse effects on the visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene.
[0129] It can be understood that in the embodiment of the present disclosure, if the position relationship indicates that the opening point coincides with the surface of the virtual terrain model, it is determined that the model position update condition is met; the process of the first terminal updating the position of the opening virtual object model may include: if all the opening points of the opening virtual object model coincide with the surface of the virtual terrain model, the opening virtual object model is moved along the first target direction by a fourth preset distance to obtain the opening virtual object model after the position is updated. Among them, the fourth preset distance can be obtained from the model processing information, and the fourth preset distance can be determined based on actual needs, which is not limited in the embodiment of the present disclosure. When it is determined that the opening point of the opening virtual object model coincides with the surface of the virtual terrain model, the opening point of the opening virtual object model can be controlled to move to a position below the surface of the virtual terrain model to prevent the opening point from being exposed outside the surface of the virtual terrain model, which will adversely affect the visual effect of the terrain model at the location of the opening virtual object model in the three-dimensional virtual scene.
[0130] In an optional implementation, after updating the position of the opening virtual object model, the first terminal may also obtain updated position information of the opening point of the opening virtual object model; determine the updated position relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated position information of the virtual terrain model and the opening point; if it is determined according to the updated position relationship that the model position stop updating condition is satisfied, then stop updating the position of the opening virtual object model; if it is determined according to the updated position relationship that the model position update condition is satisfied, then update the position of the opening virtual object model again until it is determined according to the updated position relationship that the model position stop updating condition is satisfied, and the position adjustment of the opening virtual object model is completed. After updating the position of the opening virtual object model, when it is determined that the position update result of the virtual formation model is not ideal (i.e., the updated position will also affect the visual effect of the terrain model at the position of the opening virtual object model in the three-dimensional virtual scene), the position adjustment of the opening virtual object model may be adjusted again through the virtual model processing process, and the position of the opening virtual object model is adjusted to a suitable position so as not to affect the visual effect of the terrain model at the position of the opening virtual object model in the three-dimensional virtual scene.
[0131] Among them, the process of the first terminal obtaining the updated position information of the opening point of the opening virtual object model can refer to the above-mentioned step S301, and the present embodiment of the disclosure will not elaborate on this; the process of the first terminal determining the updated position relationship between the opening point of the opening virtual object model and the virtual terrain model based on the virtual terrain model and the updated position information of the opening point can refer to the above-mentioned step S302, and the present embodiment of the disclosure will not elaborate on this; the process of the first terminal updating the position of the opening virtual object model again can refer to the above-mentioned step S303, and the present embodiment of the disclosure will not elaborate on this.
[0132] Among them, the process of the first terminal determining whether the model position stop updating condition is met according to the updated position relationship may include: if the updated position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point and the virtual terrain model is less than or equal to the distance threshold, then it is determined that the model position stop updating condition is met. When the position of the opening virtual object model is adjusted to not affect the visual effect of the terrain model at the position of the opening virtual object model in the three-dimensional virtual scene, it is determined that the position of the opening virtual object model does not need to be adjusted again, and the virtual model processing flow is terminated in time to prevent waste of data processing resources.
[0133] For example, Figure 5 As shown, Figure 5 A partial schematic diagram of a three-dimensional virtual scene provided in an embodiment of the present disclosure is shown. Figure 5 The three-dimensional virtual scene shown in Figure 1 The three-dimensional virtual scene shown in FIG. 1 is a three-dimensional virtual scene after the position of the opening virtual object model in the three-dimensional virtual scene is adjusted. Figure 5 As shown, the three-dimensional virtual scene includes a virtual terrain model 101 and an opening virtual object model 102 placed on the surface of the virtual terrain model 101, wherein the opening virtual object model 102 has an area outside the surface of the virtual terrain model 101 where there are no opening points, and does not affect the visual effect of the virtual terrain.
[0134] It should be noted that, in the embodiment of the present disclosure, the above virtual model processing process can be implemented in a non-blocking form in the 3D engine, that is, the 3D engine can allow the designer to perform other operations during the execution of the above virtual model processing method, which can further improve the modeling efficiency of the 3D virtual scene.
[0135] For example, Figure 6 As shown, Figure 6 1 shows a flowchart of a virtual model processing method executed by a first terminal. The three-dimensional engine in the first terminal may be a game engine, and the game engine may be a Houdini engine. Figure 6 As shown, the method includes the following steps S601 to S609:
[0136] Step S601, determining the position information of the opening point of the opening virtual object model in the three-dimensional virtual scene;
[0137] Step S602, determining the positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point;
[0138] Step S603, determining whether a model position update condition is met according to the position relationship;
[0139] Step S604: if it is determined based on the position relationship that the model position update condition is not met, the process ends;
[0140] Step S605, if it is determined according to the position relationship that the model position update condition is met, then the position of the opening virtual object model is updated;
[0141] Step S606, obtaining updated position information of the opening point of the opening virtual object model;
[0142] Step S607, determining an updated positional relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated position information of the virtual terrain model and the opening point;
[0143] Step S608, determining whether a model position stop updating condition is satisfied according to the updated position relationship;
[0144] Step S609, if it is determined according to the updated position relationship that the model position stop updating condition is met, then the position of the opening virtual object model is stopped from being updated, and the process ends;
[0145] Among them, if it is determined according to the updated position relationship that the model position update condition is met, the position of the opening virtual object model is updated again; it is mainly to be noted that, in the embodiment of the present disclosure, the process of updating the position of the opening virtual object model again may include executing the above steps S606 to S609 again, until it is determined according to the updated position relationship that the model position stop updating condition is met, thereby completing the position adjustment of the opening virtual object model.
[0146] The present disclosure provides a virtual model processing device. Figure 7 A schematic diagram of a virtual model processing device provided in an embodiment of the present disclosure. The virtual model processing method can be applied to Figure 2 The three-dimensional engine of the first terminal is shown as Figure 7 As shown in , the virtual model processing device 700 comprises:
[0147] The first determination module 701 is configured to determine the position information of the opening point of the open virtual object model in the three-dimensional virtual scene, where the opening point is the end point of the edge without a colinear constituent surface among the multiple edges constituting the constituent surface of the open virtual object model;
[0148] The second determination module 702 is configured to determine the positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point;
[0149] The updating module 703 is configured to update the position of the opening virtual object model if it is determined according to the position relationship that the model position update condition is met.
[0150] Optional, such as Figure 7 As shown, the virtual model processing device 700 further includes a first judgment module 704 configured to:
[0151] If the position relationship indicates that the opening point is located above the surface of the virtual terrain model, it is determined that the model position update condition is met;
[0152] The update module 703 is configured to:
[0153] The opening virtual object model is moved along a first target direction by a first preset distance, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0154] Optional, such as Figure 7 As shown, the virtual model processing device 700 further includes a first judgment module 704 configured to:
[0155] If the position relationship indicates that at least one opening point is located above the surface of the virtual terrain model, then determining that the model position update condition is met;
[0156] The update module 703 is configured to:
[0157] Determine the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model, wherein the target opening point is an opening point in the opening virtual object model located above the ground surface of the virtual terrain model;
[0158] The opening virtual object model is rotated by a preset angle based on the rotation axis, and the rotated opening virtual object model is moved by a second preset distance along a first target direction, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0159] Optionally, the update module 703 is configured to:
[0160] Based on the rotation axis formula, the rotation axis of the opening virtual object model is determined according to the position information of the target opening point and the position information of the center point of the opening virtual object model. The rotation axis formula is:
[0161]
[0162] Among them, Dir is the rotation axis, A i is the position information of the i-th target opening point among the n target opening points, and B is the position information of the center point of the opening virtual object model.
[0163] Optional, such as Figure 7 As shown, the virtual model processing device 700 further includes a first judgment module 704 configured to:
[0164] If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, then when it is determined that the distance value between at least one opening point and the virtual terrain model is greater than a distance threshold, it is determined that the model position update condition is satisfied;
[0165] The update module 703 is configured to:
[0166] The opening virtual object model is moved along a second target direction by a third preset distance, where the second target direction is a second preset direction of the three-dimensional coordinate system where the three-dimensional virtual scene is located.
[0167] Optionally, the first determining module 701 is configured to:
[0168] identifying at least one open edge of the open virtual object model, where the open edge is an edge without a colinear constituent surface among a plurality of edges constituting a constituent surface of the open virtual object model;
[0169] The position information of the endpoints of each opening edge is determined to obtain the position information of the opening point of the opening virtual object model.
[0170] Optional, such as Figure 7 As shown, the virtual model processing device 700 further includes an update processing module 705, which is configured to:
[0171] Obtain updated position information of the opening point of the opening virtual object model;
[0172] Determine an updated positional relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated positional information of the virtual terrain model and the opening point;
[0173] If it is determined according to the updated positional relationship that the model position stop updating condition is met, then the position of the opening virtual object model is stopped from being updated;
[0174] If it is determined according to the updated positional relationship that the model position update condition is met, the position of the opening virtual object model is updated again.
[0175] Optional, such as Figure 7 As shown, the virtual model processing device 700 further includes a second judgment module 706 configured to:
[0176] If the updated position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point and the virtual terrain model is less than or equal to the distance threshold, it is determined that the model position update stop condition is met.
[0177] The exemplary embodiments of the present disclosure also provide a computer-readable storage medium, which can be implemented in the form of a program product, which includes a program code, and when the program product is run on an electronic device, the program code is used to cause the electronic device to perform the steps described in the above "Exemplary Method" section of this specification according to various exemplary embodiments of the present disclosure. In one embodiment, the program product can be implemented as a portable compact disk read-only memory (CD-ROM) and includes program code, and can be run on an electronic device, such as a personal computer. However, the program product of the present disclosure is not limited to this, and in this document, the readable storage medium can be any tangible medium containing or storing a program, which can be used by or in combination with an instruction execution system, device or device.
[0178] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0179] Computer readable signal media may include data signals propagated in baseband or as part of a carrier wave, in which readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Readable signal media may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0180] The program code embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0181] Program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., through the Internet using an Internet service provider).
[0182] The exemplary embodiment of the present disclosure also provides an electronic device, which may be a terminal device of a virtual model processing service provider. Figure 8 The electronic device is described. It should be understood that Figure 8 The electronic device 800 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0183] like Figure 8 As shown, the electronic device 800 is in the form of a general computing device. The components of the electronic device 800 may include but are not limited to: at least one processing unit 810, at least one storage unit 820, and a bus 830 connecting different system components (including the storage unit 820 and the processing unit 810).
[0184] The storage unit stores program codes, which can be executed by the processing unit 810, so that the processing unit 810 performs the steps of various exemplary embodiments of the present invention described in the above “Exemplary Method” section of this specification. For example, the processing unit 810 can perform the following steps: Figure 3 The method steps shown, etc.
[0185] The storage unit 820 may include a volatile storage unit, such as a random access storage unit (RAM) 821 and / or a cache storage unit 822 , and may further include a read-only storage unit (ROM) 823 .
[0186] The storage unit 820 may also include a program / utility 824 having a set (at least one) of program modules 825, such program modules 825 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0187] The bus 830 may include a data bus, an address bus, and a control bus.
[0188] The electronic device 800 may also communicate with one or more external devices 900 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), and such communication may be performed via an input / output (I / O) interface 840. The electronic device 800 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 850. As shown, the network adapter 850 communicates with other modules of the electronic device 800 via a bus 830. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 800, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.
[0189] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the exemplary embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0190] It will be appreciated by those skilled in the art that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or implementations combining hardware and software aspects, which may be collectively referred to herein as "circuit", "module" or "system". Those skilled in the art will readily think of other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any variations, uses or adaptive changes of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The specification and implementation are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the claims.
[0191] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims
1. A virtual model processing method, characterized in that: include: Determine the position information of the opening point of the open virtual object model in the three-dimensional virtual scene, wherein the opening point is the endpoint of the edge without a colinear constituent surface among the multiple edges constituting the constituent surface of the open virtual object model; Determining a positional relationship between the opening point and the virtual terrain model according to the position information of the virtual terrain model and the position information of the opening point; If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point of the opening virtual object model and the virtual terrain model is less than or equal to a distance threshold, it is determined that the model position update condition is not met; Otherwise, it is determined that the model position update condition is met; If it is determined according to the position relationship that the model position update condition is met, the position of the opening virtual object model is updated.
2. The method according to claim 1, characterized in that The method further comprises: If the position relationship indicates that the opening point is located above the surface of the virtual terrain model, determining that a model position update condition is satisfied; The updating of the position of the opening virtual object model comprises: The opening virtual object model is moved along a first target direction by a first preset distance, where the first target direction is a first preset direction of a three-dimensional coordinate system where the three-dimensional virtual scene is located.
3. The method according to claim 1, characterized in that The method further comprises: If the position relationship indicates that at least one of the opening points is located above the surface of the virtual terrain model, determining that a model position update condition is satisfied; The updating of the position of the opening virtual object model comprises: Determining the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model, wherein the target opening point is an opening point in the opening virtual object model located above the surface of the virtual terrain model; The opening virtual object model is rotated by a preset angle based on the rotation axis, and the rotated opening virtual object model is moved by a second preset distance along a first target direction, where the first target direction is a first preset direction of the three-dimensional coordinate system where the three-dimensional virtual scene is located.
4. The method according to claim 3, characterized in that The step of determining the rotation axis of the opening virtual object model according to the position information of the target opening point and the position information of the center point of the opening virtual object model comprises: Based on the rotation axis formula, the rotation axis of the opening virtual object model is determined according to the position information of the target opening point and the position information of the center point of the opening virtual object model. The rotation axis formula is: Among them, Dir is the rotation axis, A i is the position information of the i-th target opening point among the n target opening points, and B is the position information of the center point of the opening virtual object model.
5. The method according to claim 1, characterized in that The method further comprises: If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, then when it is determined that the distance value between at least one of the opening points and the virtual terrain model is greater than a distance threshold, it is determined that the model position update condition is satisfied; The updating of the position of the opening virtual object model comprises: The opening virtual object model is moved along a second target direction by a third preset distance, where the second target direction is a second preset direction of the three-dimensional coordinate system where the three-dimensional virtual scene is located.
6. The method according to claim 1, characterized in that The step of determining the position information of the opening point of the opening virtual object model in the three-dimensional virtual scene includes: identifying at least one opening edge of the opening virtual object model, wherein the opening edge is an edge without a colinear constituting surface among a plurality of edges constituting a constituting surface of the opening virtual object model; The position information of the endpoint of each of the opening edges is determined to obtain the position information of the opening point of the opening virtual object model.
7. The method according to any one of claims 1 to 6, characterized in that: After updating the position of the opening virtual object model, the method further includes: Acquire updated position information of the opening point of the opening virtual object model; Determining an updated positional relationship between the opening point of the opening virtual object model and the virtual terrain model according to the updated positional information of the virtual terrain model and the opening point; If it is determined according to the updated positional relationship that the model position stop updating condition is met, then the updating of the position of the opening virtual object model is stopped; If it is determined according to the updated positional relationship that the model position update condition is satisfied, the position of the opening virtual object model is updated again.
8. The method according to claim 7, characterized in that The method further comprises: If the updated position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point and the virtual terrain model is less than or equal to a distance threshold, it is determined that the model position update stop condition is met.
9. A virtual model processing device, characterized in that: include: A first determination module is configured to determine position information of an opening point of an open virtual object model in a three-dimensional virtual scene, wherein the opening point is an end point of an edge without a colinear constituent surface among a plurality of edges constituting a constituent surface of the open virtual object model; A second determination module is configured to determine a positional relationship between the opening point and the virtual terrain model according to the virtual terrain model and the position information of the opening point; If the position relationship indicates that the opening point is located below the surface of the virtual terrain model, and the distance value between each opening point of the opening virtual object model and the virtual terrain model is less than or equal to a distance threshold, it is determined that the model position update condition is not met; Otherwise, it is determined that the model position update condition is met; The updating module is configured to update the position of the opening virtual object model if it is determined according to the position relationship that a model position updating condition is met.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.
11. An electronic device, characterized in that: include: processor; as well as A memory, configured to store executable instructions of the processor; The processor is configured to perform the method of any one of claims 1 to 8 by executing the executable instructions.
Citation Information
Patent Citations
Three-dimensional optimization and line selection system, method and device for roaming establishment in stereoscopic scenes of three-dimensional optimization and line selection system
CN102184570A
Three-dimensional terrain model adjusting method by considering vector element natural characteristic limitation
CN111445579A