Method and apparatus for perspective conversion of three-dimensional model

By calculating the height of the target label's coordinates and the preset angle, the target position is determined, achieving accurate conversion of the 3D model's perspective. This ensures that the 3D sub-model corresponding to the target label is displayed without obstruction from the second perspective, solving the problem of inaccurate perspective conversion in existing technologies.

CN117745995BActive Publication Date: 2025-11-18REALSEE (BEIJING) TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311787162.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-22
Publication Date
2025-11-18
Estimated Expiration
2043-12-22

AI Technical Summary

Technical Problem

In existing technologies, the perspective transformation of 3D models cannot accurately transform the target perspective, making it difficult for users to accurately locate and view the area corresponding to the label.

Method used

By determining the coordinates of the target label relative to the label height value of the 3D model and the preset angle, the target position is calculated, and the viewpoint is transformed based on the position to ensure that the 3D sub-model corresponding to the target label is displayed without obstruction in the second viewpoint.

Benefits of technology

It achieves accurate perspective switching from first-person to second-person perspective, allowing users to view the 3D sub-model corresponding to the target label without any obstacles, thus solving the problem of inaccurate perspective switching in existing technologies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117745995B_ABST
    Figure CN117745995B_ABST
Patent Text Reader

Abstract

The embodiment of the present disclosure discloses a three-dimensional model perspective conversion method and device, wherein the method comprises: obtaining a preset three-dimensional model displayed at a first perspective; in response to receiving a triggering operation on a target label in the at least one label, determining a label height value of a coordinate point of the target label relative to a bottom surface of the preset three-dimensional model; based on the label height value and a preset angle, determining a target position corresponding to the target label; and based on the target position, displaying the preset three-dimensional model at a second perspective. The embodiment of the present disclosure can accurately convert from a target label at a first perspective to a three-dimensional sub-model at a second perspective, and accurately convert the perspective. The problem that the first perspective only displays labels and cannot accurately position and convert the perspective in the prior art is overcome.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to computer vision technology, and in particular to a method and apparatus for perspective transformation of a three-dimensional model. Background Technology

[0002] With the rise of emerging technologies such as Virtual Reality (VR) and Augmented Reality (AR), 3D modeling is being used more and more widely in the technology and creative industries. Both VR and AR rely on 3D models to construct immersive virtual environments, allowing users to interact naturally with virtual objects and scenes. 3D models, as a fundamental element of 3D computer graphics, play an increasingly important role. To achieve better results in real-world applications, various 3D model-related analysis and modeling algorithms require higher computational accuracy. Viewpoint transformation of 3D models is often used as a preprocessing step for other 3D model-related algorithms. However, existing viewpoint transformation techniques often suffer from the problem of inaccurate target viewpoint transformation. Summary of the Invention

[0003] To address the aforementioned technical problems, this disclosure is proposed. Embodiments of this disclosure provide a method and apparatus for perspective transformation of a three-dimensional model.

[0004] According to one aspect of the embodiments of this disclosure, a method for perspective transformation of a three-dimensional model is provided, comprising:

[0005] Obtain a preset 3D model displayed from a first-person perspective; wherein the preset 3D model displays at least one label from the first-person perspective, and the preset 3D model includes at least one 3D sub-model, each of the 3D sub-models corresponding to one label;

[0006] In response to receiving a trigger operation on a target label among the at least one labels, the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model is determined;

[0007] Based on the label height value and the preset angle, the target position corresponding to the target label is determined;

[0008] The preset 3D model is displayed from a second perspective based on the target location; wherein, the preset 3D model displays at least the 3D sub-model corresponding to the target label from the second perspective.

[0009] Optionally, determining the label height value of the target label's coordinate point relative to the bottom surface of the preset 3D model includes:

[0010] Determine the first height value of the bottom surface of the preset three-dimensional model and the second height value of the coordinate point of the target label in the model's three-dimensional coordinate system;

[0011] The label height value is determined based on the first height value and the second height value.

[0012] Optionally, determining the first height value of the bottom surface of the preset 3D model and the second height value of the coordinate point of the target label in the model's 3D coordinate system includes:

[0013] Determine the bounding box of the preset 3D model;

[0014] Based on the bounding box, the coordinate value of the bottom surface of the preset 3D model on the vertical axis in the 3D coordinate system of the model is determined, and the first height value is determined based on the coordinate value.

[0015] The second height value is determined based on the vertical axis coordinate value in the three-dimensional coordinate system corresponding to the coordinate point of the target label.

[0016] Optionally, determining the target position corresponding to the target label based on the label height value and a preset angle includes:

[0017] The target height value is determined based on the label height value and the preset angle;

[0018] Based on the target height value, a target plane is determined in the model's three-dimensional coordinate system;

[0019] Determine a circular trajectory on the target plane;

[0020] At least one coordinate point on the circular trajectory is determined as the target location.

[0021] Optionally, determining the target height value based on the label height value and the preset angle includes:

[0022] Based on the label height value and preset parameters, a reference height value is determined;

[0023] The target height value is determined based on the product of the reference height value and the trigonometric function value of the preset angle, as well as the label height value.

[0024] Optionally, determining a circular trajectory on the target plane includes:

[0025] The center point is determined based on the target height value and the three-dimensional coordinates of the target label's coordinate points;

[0026] The length value is determined based on the label height value and the preset angle;

[0027] The circular trajectory is determined based on the center point as the center and the length value as the radius.

[0028] Optionally, determining at least one coordinate point on the circular trajectory as the target location includes:

[0029] The circular trajectory is divided into a preset number of points, and the preset number of coordinate points on the circular trajectory are determined as reference points.

[0030] The target location is determined based on the preset number of reference points.

[0031] Optionally, determining the target location based on the preset number of reference points includes:

[0032] Perform a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test.

[0033] Based on whether each of the reference points passes the collision test, at least one reference point that passes the collision test is determined.

[0034] The target location is determined based on the at least one reference point that passed the collision test.

[0035] Optionally, performing a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test includes:

[0036] For each of the preset number of reference points, a ray is established from the reference point as the origin to the coordinate point of the target label to obtain a reference ray;

[0037] Based on the reference ray, determine whether the reference point passes the collision test.

[0038] Optionally, determining whether the reference point passes the collision test based on the reference ray includes:

[0039] The first distance is determined based on the distance between the intersection point of the reference ray and the preset three-dimensional model and the reference point;

[0040] The second distance is determined based on the distance from the reference point to the coordinates of the target label.

[0041] Based on the relationship between the first distance and the second distance, determine whether the reference point passes the collision test.

[0042] Optionally, determining the target location based on the at least one reference point that passed the collision test includes:

[0043] Based on the position of the at least one reference point that passed the collision test on the circular trajectory, determine the adjacency relationship of the at least one reference point;

[0044] Based on the adjacency relationship, the at least one reference point is clustered to obtain at least one set of reference points; wherein each set of reference points includes at least one reference point, and each reference point in the set of reference points is adjacent to at least one other reference point in the set of reference points;

[0045] The target location is determined based on the set of reference points that contains the largest number of reference points.

[0046] Optionally, determining the target location based on the reference point set that includes the largest number of reference points includes:

[0047] In response to the fact that the number of reference points included in the reference point set is even, the midpoint between the two reference points at the center position among the multiple reference points included in the reference point set on the circular trajectory is calculated, and the midpoint is taken as the target position;

[0048] In response to the fact that the number of reference points included in the reference point set is odd, the reference point at the center of the multiple reference points included in the reference point set is taken as the target position.

[0049] According to another aspect of the embodiments of this disclosure, a perspective conversion device for a three-dimensional model is provided, comprising:

[0050] The first model display module is used to obtain a preset 3D model displayed from a first perspective; wherein the preset 3D model displays at least one label from the first perspective, and the preset 3D model includes at least one 3D sub-model, each of the 3D sub-models corresponding to one label;

[0051] An operation receiving module is used to determine the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model in response to receiving a trigger operation on the target label of the at least one label.

[0052] The target location determination module is used to determine the target location corresponding to the target label based on the label height value and a preset angle;

[0053] The second model display module is used to display the preset 3D model from a second perspective based on the target location; wherein, the preset 3D model displays at least the 3D sub-model corresponding to the target label from the second perspective.

[0054] Optionally, the operation receiving module is specifically used to determine a first height value of the bottom surface of the preset three-dimensional model and a second height value of the coordinate point of the target label in the model's three-dimensional coordinate system; and to determine the label height value based on the first height value and the second height value.

[0055] Optionally, when the operation receiving module determines the first height value of the bottom surface of the preset 3D model and the second height value of the coordinate point of the target label in the model's 3D coordinate system, it is used to determine the bounding box of the preset 3D model; determine the coordinate value of the vertical axis of the bottom surface of the preset 3D model in the model's 3D coordinate system based on the bounding box; determine the first height value based on the coordinate value; and determine the second height value based on the vertical axis coordinate value in the 3D coordinate system corresponding to the coordinate point of the target label.

[0056] Optionally, the target location determination module includes:

[0057] A height determination unit is used to determine a target height value based on the label height value and the preset angle;

[0058] The target plane determination unit is used to determine a target plane in the three-dimensional coordinate system of the model based on the target height value.

[0059] A trajectory determination unit is used to determine a circular trajectory on the target plane;

[0060] The trajectory position determination unit is used to determine at least one coordinate point on the circular trajectory as the target position.

[0061] Optionally, the height determination unit is specifically used to determine a reference height value based on the label height value and preset parameters; and to determine the target height value based on the product of the reference height value and the trigonometric function value of the preset angle, and the label height value.

[0062] Optionally, the trajectory determination unit is specifically used to determine a center point based on the target height value and the three-dimensional coordinates of the target label's coordinate points; determine a length value based on the label height value and the preset angle; and determine the circular trajectory based on the center point as the center and the length value as the radius.

[0063] Optionally, the trajectory position determination unit is specifically used to divide the circular trajectory into a preset number of segments, determine the preset number of coordinate points on the circular trajectory as reference points, and determine the target position based on the preset number of reference points.

[0064] Optionally, when determining the target position based on the preset number of reference points, the trajectory position determination unit performs a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test; determines at least one reference point that passes the collision test based on the result of whether each reference point passes the collision test; and determines the target position based on the at least one reference point that passes the collision test.

[0065] Optionally, when the trajectory position determination unit performs a collision test on each of the preset number of reference points and determines whether each reference point passes the collision test, it is used to establish a ray from the reference point as the origin to the coordinate point of the target label for each of the preset number of reference points to obtain a reference ray; and determine whether the reference point passes the collision test based on the reference ray.

[0066] Optionally, when determining whether the reference point passes the collision test based on the reference ray, the trajectory position determination unit is used to determine a first distance based on the distance between the intersection of the reference ray and the preset three-dimensional model and the reference point; determine a second distance based on the distance from the reference point to the coordinate point of the target label; and determine whether the reference point passes the collision test based on the relationship between the first distance and the second distance.

[0067] Optionally, when determining the target position based on the at least one reference point that passed the collision test, the trajectory position determination unit is used to determine the adjacency relationship of the at least one reference point based on the position of the at least one reference point that passed the collision test on the circular trajectory; based on the adjacency relationship, cluster the at least one reference point to obtain at least one set of reference points; wherein each set of reference points includes at least one reference point, and each reference point in the set of reference points is adjacent to at least one other reference point in the set of reference points; and the target position is determined based on the set of reference points that includes the largest number of reference points.

[0068] Optionally, when determining the target position based on the reference point set with the largest number of reference points, the trajectory position determination unit is configured to, in response to the even number of reference points in the reference point set, calculate the midpoint of the two reference points at the center position among the multiple reference points in the reference point set on the circular trajectory, and take the midpoint as the target position; in response to the odd number of reference points in the reference point set, take the reference point at the center position among the multiple reference points in the reference point set as the target position.

[0069] According to another aspect of the present disclosure, an electronic device is provided, comprising:

[0070] Memory, used to store computer program products;

[0071] A processor is configured to execute a computer program product stored in the memory, and when the computer program product is executed, to implement the method described in any of the above embodiments.

[0072] According to another aspect of the present disclosure, a computer-readable storage medium is provided that stores computer program instructions thereon, which, when executed by a processor, implement the method described in any of the above embodiments.

[0073] According to another aspect of the present disclosure, a computer program product is provided, including computer program instructions, characterized in that the computer program instructions, when executed by a processor, implement the method described in any of the above embodiments.

[0074] A method and apparatus for perspective switching of a 3D model based on the above embodiments of this disclosure includes: obtaining a preset 3D model displayed in a first perspective; in response to receiving a trigger operation on a target label among at least one label, determining the label height value of the coordinate point of the target label relative to the bottom surface of the preset 3D model; determining a target position corresponding to the target label based on the label height value and a preset angle; and displaying the preset 3D model in a second perspective based on the target position; wherein, the preset 3D model displays at least a 3D sub-model corresponding to the target label in the second perspective. This disclosure, by determining the target position based on the label height value and the preset angle, and by switching the perspective to a second perspective where the 3D sub-model corresponding to the target label can be viewed based on the target position, can accurately switch from the target label in the first perspective to the 3D sub-model in the second perspective, achieving accurate perspective switching; overcoming the problem in the prior art where only the label is displayed in the first perspective, making accurate positioning and perspective switching impossible.

[0075] The technical solutions of this disclosure will be further described in detail below with reference to the accompanying drawings and embodiments. Attached Figure Description

[0076] The accompanying drawings, which form part of this specification, illustrate embodiments of this disclosure and, together with the description, serve to explain the principles of this disclosure.

[0077] This disclosure will become clearer with reference to the accompanying drawings and the following detailed description, wherein:

[0078] Figure 1 This is a flowchart illustrating a perspective transformation method for a three-dimensional model provided in an exemplary embodiment of this disclosure;

[0079] Figure 2 This is a public announcement Figure 1 A flowchart illustrating step 104 in the illustrated embodiment;

[0080] Figure 3 This is a public announcement Figure 1 A flowchart illustrating step 106 in the illustrated embodiment;

[0081] Figure 4 This is a schematic diagram of the circular trajectory determined in the perspective transformation method of a three-dimensional model provided in an exemplary embodiment of this disclosure;

[0082] Figure 5 This is a schematic diagram of the structure of a perspective conversion device for a three-dimensional model provided in an exemplary embodiment of the present disclosure;

[0083] Figure 6 A block diagram of an electronic device according to an embodiment of the present disclosure is shown. Detailed Implementation

[0084] Hereinafter, exemplary embodiments according to the present disclosure will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of the present disclosure, and not all embodiments of the present disclosure, and it should be understood that the present disclosure is not limited to the exemplary embodiments described herein.

[0085] It should be noted that, unless otherwise specifically stated, the relative arrangement, numerical expressions, and values ​​of the components and steps set forth in these embodiments do not limit the scope of this disclosure.

[0086] Those skilled in the art will understand that the terms "first," "second," etc., in the embodiments of this disclosure are only used to distinguish different steps, devices, or modules, and do not represent any specific technical meaning, nor do they indicate a necessary logical order between them.

[0087] It should also be understood that in the embodiments disclosed herein, "a plurality of" may refer to two or more, and "at least one" may refer to one, two or more.

[0088] It should also be understood that any component, data or structure mentioned in the embodiments of this disclosure can generally be understood as one or more unless expressly defined or given to the contrary in the context.

[0089] Furthermore, the term "and / or" in this disclosure is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this disclosure generally indicates that the preceding and following related objects have an "or" relationship. The data referred to in this disclosure can include unstructured data such as text, images, and videos, as well as structured data.

[0090] It should also be understood that the description of the various embodiments in this disclosure emphasizes the differences between the various embodiments, and the similarities or similarities can be referred to each other. For the sake of brevity, they will not be described in detail.

[0091] At the same time, it should be understood that, for ease of description, the dimensions of the various parts shown in the accompanying drawings are not drawn according to actual scale.

[0092] The following description of at least one exemplary embodiment is merely illustrative and is in no way intended to limit this disclosure or its application or use.

[0093] Techniques, methods, and equipment known to those skilled in the art may not be discussed in detail, but where appropriate, such techniques, methods, and equipment should be considered part of the specification.

[0094] It should be noted that similar labels and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be discussed further in subsequent figures.

[0095] The embodiments disclosed herein can be applied to electronic devices such as terminal devices, computer systems, and servers, and can operate together with a wide range of other general-purpose or special-purpose computing system environments or configurations. Examples of well-known terminal devices, computing systems, environments, and / or configurations suitable for use with electronic devices such as terminal devices, computer systems, and servers include, but are not limited to: personal computer systems, server computer systems, thin clients, thick clients, handheld or laptop devices, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputer systems, mainframe computer systems, and distributed cloud computing environments including any of the above systems, etc.

[0096] Electronic devices such as terminal devices, computer systems, and servers can be described in the general context of computer system executable instructions (such as program modules) executed by a computer system. Typically, program modules can include routines, programs, object programs, components, logic, data structures, etc., which perform specific tasks or implement specific abstract data types. Computer systems / servers can be implemented in distributed cloud computing environments, where tasks are executed by remote processing devices linked through communication networks. In distributed cloud computing environments, program modules can reside on local or remote computing system storage media, including storage devices.

[0097] Application Overview

[0098] In developing this disclosure, the inventors discovered that in related technologies, 3D models in bird's-eye view mode mark local areas as labels. When viewing the area corresponding to a label, a perspective shift is required, which can be done in two ways: first, clicking the label displays its information; second, entering a roaming state within the space marked by the label. However, both methods have at least the following problems: the first method only displays label information, which makes it difficult for users to perceive the model's location or area indicated by the label when the model is large. Furthermore, if there are too many labels, they may be obscured or cluttered and unclear. The second method does not support users viewing the entire area in model mode; they can only enter that location to view and browse from within.

[0099] Exemplary methods

[0100] Figure 1 This is a flowchart illustrating a viewpoint transformation method for a three-dimensional model provided in an exemplary embodiment of this disclosure. This embodiment can be applied to electronic devices, such as... Figure 1 As shown, it includes the following steps:

[0101] Step 102: Obtain the preset 3D model displayed in the first-person perspective.

[0102] The preset 3D model displays at least one label in the first-person perspective. The preset 3D model includes at least one 3D sub-model, and each 3D sub-model corresponds to one label.

[0103] Optionally, in the first-person perspective, detailed information included in the preset 3D model is not displayed, and the 3D sub-models are usually represented as labels. That is, information compression of the preset 3D model is achieved in the first-person perspective.

[0104] In this embodiment, the preset 3D model can be any 3D model with multiple 3D sub-models; for example, a 3D model corresponding to an area composed of multiple buildings. The first perspective can be a bird's-eye view, or the viewpoint viewing the preset 3D model can be far away from the preset 3D model, and details in the preset 3D model are not displayed. Optionally, from the perspective of application scenarios, this embodiment is more suitable for large or very large models, because in this type of model, if you want to see the entire model, in order to adapt to the window size (e.g., browser window), the model will be shrunk to a certain range, so that the observation of local parts is easily ignored.

[0105] Step 104: In response to receiving a trigger operation on a target label in at least one label, determine the label height value of the coordinate point of the target label relative to the bottom surface of the preset 3D model.

[0106] In one embodiment, since only at least one label is displayed in the preset 3D model from the first perspective, the position information of the preset 3D model can be roughly understood from a global perspective through at least one label. When it is necessary to observe the 3D sub-model corresponding to one of the labels (target label), a trigger operation (e.g., clicking) can be performed on the target label. At this time, the label height value of the target label is determined according to the trigger operation, so as to ensure that the 3D sub-model corresponding to the target label can be viewed without obstruction from the second perspective.

[0107] Step 106: Determine the target position corresponding to the target label based on the label height value and the preset angle.

[0108] Optionally, the label height value represents the height of the target label within the preset 3D model. To better view the 3D sub-model within the preset 3D model, it is most suitable for the simulated camera corresponding to the second viewpoint to observe the 3D sub-model corresponding to the target label from a position at a certain distance from the label and with a certain pitch angle. Therefore, in this embodiment, a preset angle is set as the pitch angle based on the application scenario. By combining the pitch angle and the label height value, a target position more suitable for observing the 3D sub-model corresponding to the target label can be determined. Optionally, the target position may include, but is not limited to, at least one position.

[0109] Step 108: Display the preset 3D model from a second perspective based on the target location.

[0110] Among them, the preset 3D model displays at least the 3D sub-model corresponding to the target label in the second perspective.

[0111] In this embodiment, after determining the target location, the simulated camera can be switched from the position corresponding to the first perspective (e.g., in a bird's-eye view, the simulated camera is located at a very far distance directly above the preset 3D model) to the target location; when viewing the preset 3D model from the target location, the 3D sub-model corresponding to the target label can be viewed without obstruction, enabling detailed viewing of the area corresponding to the target label.

[0112] The three-dimensional model perspective conversion method provided in the above embodiments of this disclosure includes: obtaining a preset three-dimensional model displayed in a first perspective; responding to receiving a trigger operation on a target label among the at least one label, determining the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model; determining the target position corresponding to the target label based on the label height value and a preset angle; and displaying the preset three-dimensional model in a second perspective based on the target position; wherein, the preset three-dimensional model displays at least the three-dimensional sub-model corresponding to the target label in the second perspective. This disclosure, by determining the target position based on the label height value and a preset angle, and converting the perspective to a second perspective that allows viewing of the three-dimensional sub-model corresponding to the target label, can accurately convert from the target label in the first perspective to the three-dimensional sub-model in the second perspective, achieving accurate perspective conversion; overcoming the problem in the prior art where only the label is displayed in the first perspective, making accurate positioning and perspective conversion impossible.

[0113] like Figure 2 As shown above, in the above Figure 1 Based on the illustrated embodiment, step 104 may include the following steps:

[0114] Step 1041: Determine the first height value of the bottom surface of the preset 3D model and the second height value of the coordinate point of the target label in the model's 3D coordinate system.

[0115] In this embodiment, the preset 3D model can be generated using a commonly used 3D engine in the prior art, such as a 3D engine running in a browser, which can be used to create various 3D scenes, including THREE.js objects such as cameras, lighting, and materials. The 3D coordinate system corresponding to the preset 3D model built based on the 3D engine includes an x-axis, a y-axis, and a z-axis, where the vertical axis is the y-axis. The 3D coordinates (x, y, z) corresponding to each label correspond to the model's 3D coordinate system. The preset 3D model can be represented using a variable mesh. In this embodiment, given the 3D coordinate system of the model, the value of the bottom surface of the 3D model relative to the y-axis in the model's 3D coordinate system can be determined to determine the first height value; based on the coordinate point of the target label relative to the y-axis in the model's 3D coordinate system, the second height value can be determined.

[0116] Step 1042: Determine the label height value based on the first height value and the second height value.

[0117] Optionally, the height of the target label's coordinates relative to the bottom surface of the preset 3D model can be determined based on the difference between the second height value and the first height value, and this height can be used as the label height value. Since the preset 3D model includes at least one 3D sub-model, the label height value corresponding to each label is different. In order to enable viewing of the 3D sub-model corresponding to the target label from a second perspective, this embodiment needs to determine the height of the 3D sub-model in the preset 3D model to avoid the 3D sub-model being obscured by other parts of the preset 3D model in the future, so as to improve the effect of viewing the preset 3D model from a second perspective.

[0118] Optionally, step 1041 may include:

[0119] Determine the bounding box of the preset 3D model.

[0120] In this embodiment, since the three-dimensional coordinates of the points in the preset three-dimensional model are all known (for example, the preset three-dimensional model is determined based on the three-dimensional point cloud), a hexahedral bounding box can be determined based on the preset three-dimensional model, so that all contents in the preset three-dimensional model are included in the bounding box; and the determined bounding box is a regular hexahedron, and the origin and each coordinate axis in the model coordinate system can be determined based on the hexahedron.

[0121] The coordinates of the bottom surface of the preset 3D model on the vertical axis in the model's 3D coordinate system are determined based on the bounding box, and the first height value is determined based on the coordinates.

[0122] In this embodiment, after determining the model coordinate system corresponding to the preset three-dimensional model based on the bounding box, the vertical axis coordinate of the bottom surface of the preset three-dimensional model relative to the model coordinate system can be determined (optionally, the first height value can be determined based on the difference between the y-axis coordinates of the bottom surface of the preset three-dimensional model and the bottom surface of the bounding box), thus determining the first height value of the bottom surface of the preset three-dimensional model in the model coordinate system.

[0123] The second height value is determined based on the vertical axis coordinate value of the three-dimensional coordinates corresponding to the coordinate point of the target label.

[0124] In this embodiment, since the three-dimensional coordinates of the target label are known, the second height value of the target label in the model coordinate system can be determined based on the y-axis coordinate value of the three-dimensional coordinate system relative to the vertical axis coordinate of the model coordinate system (for example, the second height value can be determined based on the difference between the y-axis coordinate value of the target label and the y-axis coordinate of the bottom surface of the bounding box). The first height value and the second height value are both relative heights. That is, in this embodiment, the heights of the coordinate points of the preset three-dimensional model and the target label are uniformly displayed in the model coordinate system to determine the corresponding target position in the model coordinate system.

[0125] like Figure 3 As shown above, in the above Figure 1Based on the illustrated embodiment, step 106 may include the following steps:

[0126] Step 1061: Determine the target height value based on the label height value and the preset angle.

[0127] Optionally, the preset angle can be set according to the specific application scenario. The preset angle represents the better pitch angle for viewing the 3D sub-model corresponding to the target label. For example, the preset angle can be set to 45 degrees. An intermediate value can be determined based on the label height value. Combining this intermediate value with the pitch angle, the height of the observation point relative to the target label point can be determined, which is the target height value.

[0128] Step 1062: Based on the target height value, determine a target plane in the model's three-dimensional coordinate system.

[0129] After determining a target height value, the plane containing all points corresponding to that target height value in the model coordinate system is defined as the target plane. Points suitable for observing the 3D sub-model are located on this target plane.

[0130] Step 1063: Determine a circular trajectory on the target plane.

[0131] In this embodiment, after determining the target plane, since the target plane is relatively large, to improve the efficiency of determining the target position, optionally, a circular trajectory on the target plane is determined in conjunction with a preset angle. The 3D sub-model corresponding to the target label can be observed along this circular trajectory based on the preset angle. Optionally, in some optional examples... Figure 4 It is a circular trajectory determined based on the target label. For example... Figure 4 As shown, the distance between the circular trajectory and the target label is the target height value minus the target label height value, and the angle between the line connecting the trajectory L and the target label coordinate point and the xz plane where the y-axis coordinate of the target label is located is a preset angle α.

[0132] Step 1064: Determine at least one coordinate point on the circular trajectory as the target location.

[0133] In this embodiment, after obtaining the circular trajectory, it is necessary to determine the final target position on the circular trajectory. To ensure the observation effect, it is desirable that there is no occlusion between the final target position and the observation area (the three-dimensional sub-model corresponding to the target label). Optionally, collision tests can be continuously performed on some points selected on the circular trajectory, and finally at least one point that passes the collision test can be determined as the target position.

[0134] Optionally, different labels have different relative heights in the preset 3D model. The label is located at the top center of the marked area (3D sub-model), which requires the target position to be dynamically adjusted according to the height and position of different labels.

[0135] Optionally, step 1061 may include:

[0136] A reference height value is determined based on the label height value and preset parameters.

[0137] Optionally, the preset parameters can be set according to the preset scenario, and the reference height value can be determined based on the product of the label height value and the preset parameters. For example, in an optional example, the preset parameter is set to 1, and the reference height value is equal to the label height value.

[0138] The target height value is determined based on the product of the reference height value and the trigonometric function value of the preset angle, as well as the label height value.

[0139] In one optional example, the target height value determined by combining the trigonometric function value of the preset angle is more suitable for observing the 3D sub-model corresponding to the target label. Optionally, in some optional examples, the target height value can be determined based on the following formula (1):

[0140] Target height value = Label height value + Reference height value × sinα Formula (1)

[0141] Where α represents the preset angle; as can be seen from the above calculation, the target height value determined in this embodiment is higher than the reference height value × sinα relative to the coordinates of the target label, and a more comprehensive view of the three-dimensional sub-model can be achieved through the higher viewing angle.

[0142] In some alternative embodiments, step 1063 includes:

[0143] The center point is determined based on the target height value and the three-dimensional coordinates of the target label's coordinate points.

[0144] Optionally, the coordinates of the target label can be mapped onto the target plane corresponding to the target height value to determine the center point. Alternatively, a straight line along the y-axis can be established based on the x-axis and z-axis values ​​corresponding to the coordinates of the target label. The point where the y-axis value is the target height value is the center point. That is, the x-axis and z-axis coordinates of the center point are the same as those of the target label, while the y-axis coordinates are the same as those of the target height value.

[0145] The length value is determined based on the label height value and the preset angle.

[0146] Optionally, when determining the length value, in one example, the length value can be determined based on the product of the label height value and the trigonometric function value of the preset angle; in another example, a reference height value can be determined first based on the label height value, and then the length value can be determined based on the product of the reference height value and the trigonometric function value of the preset angle. Optionally, the length value = label height value × cosα, or the length value = reference height value × cosα.

[0147] The circular trajectory is determined by using the center point as the center and the length value as the radius.

[0148] In this embodiment, given the center and radius of the circle, a circular trajectory can be directly obtained on the target plane. The points on this circular trajectory are all observation points for observing the three-dimensional sub-model corresponding to the target label within a preset distance, based on a preset angle as the pitch angle. This embodiment further limits the range of the target position by using a preset angle as the pitch angle, thereby improving the efficiency and accuracy of target position determination.

[0149] In some alternative embodiments, step 1064 may include:

[0150] The circular trajectory is divided into a preset number of segments, and a preset number of coordinate points are determined on the circular trajectory as reference points.

[0151] The target location is determined based on a preset number of reference points.

[0152] After determining the circular trajectory, several points can be randomly selected from the trajectory to determine the target location. In this embodiment, to better determine the target location, the circular trajectory is divided into a preset number of arcs, with each segmentation point serving as a reference point. Dividing the circular trajectory evenly according to the preset number allows for a more regular determination of the target location, and the effectiveness of the target location determination is directly proportional to the value of the preset number. That is, the larger the preset number, the higher the accuracy of the target location, and the better the effect of observing the preset 3D model at the determined target location. However, a large preset number leads to an increased computational load. Therefore, the preset number can be determined according to the actual situation. For example, a larger value can be used in scenarios with powerful computing capabilities, while a relatively smaller value can be used in scenarios with less computing power. For example, in an optional scenario, a preset number of 12 is used, resulting in 12 reference points after division, forming an array containing 12 3D coordinate points. In this embodiment, dividing the circular trajectory allows for the rapid determination of multiple reference points, improving the efficiency of target location determination.

[0153] In some optional embodiments, the process of determining the target location based on a preset number of reference points may include:

[0154] Perform a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test.

[0155] Based on the results of the crash test for each reference point, at least one reference point that passed the crash test is determined.

[0156] In this embodiment, all reference points that pass the collision test are used as candidates for the target location, ensuring that the line of sight is unobstructed when observing the 3D sub-model corresponding to the target label at the determined target location, thus improving the observation effect of the target location.

[0157] The target location is determined based on at least one reference point that has passed the collision test.

[0158] In this embodiment, some reference points are selected on the circular trajectory, and collision detection is continuously performed to ultimately determine at least one suitable, unobstructed target location. After confirming the target location, the simulated camera is moved to the target location and looks at the preset 3D model. When viewing the preset 3D model at the target location, the 3D sub-model corresponding to the target label can be viewed without obstruction due to the successful collision test.

[0159] Optionally, performing a collision test on each of the preset number of reference points, and determining whether each reference point passes the collision test, may include:

[0160] For each of the preset number of reference points, a ray is established from the reference point as the origin to the coordinate point of the target label to obtain the reference ray.

[0161] Based on the reference ray, determine whether the reference point passes the collision test.

[0162] In this embodiment, the collision test is to determine whether the three-dimensional sub-model corresponding to the target label observed from the reference point will be occluded by other parts of the preset three-dimensional model. Therefore, a reference ray from the reference point to the coordinate point of the target label can be determined by the method of proposing a straight line based on two points. Optionally, a first distance can be determined based on the distance between the intersection of the reference ray and the preset three-dimensional model and the reference point.

[0163] Determine the second distance based on the distance from the reference point to the coordinates of the target label;

[0164] Based on the relationship between the first distance and the second distance, determine whether the reference point passes the collision test.

[0165] In this embodiment, the reference point is determined to have passed the collision test if the first distance and the second distance are the same; if the first distance and the second distance are different, the reference point is determined to have failed the collision test. This embodiment ensures through the collision test that the determined target position is not obscured by other parts of the model when observing the 3D sub-model, thus improving the observation effect of the preset 3D model.

[0166] In one optional example, a collision test can be implemented based on the following pseudocode:

[0167] Perform raycasting on all reference points and return true or false. Taking point A as an example:

[0168] const ray = new Raycaster(TagPosition, PointA) / / Ray from the tag point to PointA;

[0169] const d1 = ray.intersectObject(Mesh)[0].distance / / d1 is the first distance from the label point to the model along the ray;

[0170] const d2 = TagPosition.distanceTo(PointA) / / d2 is the second distance from the tag point to PointA;

[0171] If d2 is greater than d1, it means there is model occlusion between the label point and PointA, and the result is recorded as false; otherwise, it means there is no model occlusion between the label point and PointA, and the result is recorded as true.

[0172] In some alternative embodiments, determining the target location based on at least one reference point that has passed the collision test includes:

[0173] Based on the position of at least one reference point that has passed the collision test on the circular trajectory, determine the adjacency relationship of at least one reference point.

[0174] Based on adjacency relationships, at least one reference point is clustered to obtain at least one set of reference points.

[0175] Each reference point set includes at least one reference point, and each reference point in the reference point set is adjacent to at least one other reference point in the reference point set.

[0176] The target location is determined based on the set of reference points that contains the largest number of reference points.

[0177] In this embodiment, based on the adjacency relationship of multiple reference points on the circular trajectory, the multiple reference points are clustered into at least one set of reference points. The set of reference points with the largest number of reference points is the largest continuous set of reference points, which means that there is no model occlusion between reference points in this segment. Therefore, at least one position in this segment of reference points can be determined as the nearest target position corresponding to the second viewpoint. Optionally, in response to the even number of reference points included in the set of reference points, the midpoint of the two reference points at the center position among the multiple reference points included in the set of reference points is calculated on the circular trajectory, and the midpoint is taken as the target position.

[0178] In response to an odd number of reference points in the reference point set, the reference point at the center of the multiple reference points in the reference point set is taken as the target location.

[0179] In this embodiment, if the number of reference points in the reference point set is divisible by 2, the midpoint of the two middle points on the circular trajectory is calculated as the unique target position; if the number of reference points in the reference point set is not divisible by 2, the middle reference point is directly taken as the unique target position.

[0180] Alternatively, after determining the corresponding target location for the target label, if memory allows, the target location and the corresponding target label can be stored. Within a preset time (e.g., 2 minutes, 5 minutes, etc., which can be set according to the actual scenario), when it is necessary to determine the target location corresponding to the second-view perspective for the target label, no calculation is required, and the stored target location can be directly called.

[0181] The perspective transformation method for any three-dimensional model provided in this disclosure can be executed by any suitable device with data processing capabilities, including but not limited to terminal devices and servers. Alternatively, the perspective transformation method for any three-dimensional model provided in this disclosure can be executed by a processor, such as by a processor executing the perspective transformation method for any three-dimensional model mentioned in this disclosure by calling corresponding instructions stored in memory. Further details will not be elaborated below.

[0182] Exemplary device

[0183] Figure 5 This is a schematic diagram of the viewpoint conversion device for a three-dimensional model provided in an exemplary embodiment of this disclosure. Figure 5 As shown, the apparatus provided in this embodiment includes:

[0184] The first model display module 51 is used to obtain a preset 3D model for display from a first perspective.

[0185] The preset 3D model displays at least one label in the first-person perspective. The preset 3D model includes at least one 3D sub-model, and each 3D sub-model corresponds to one label.

[0186] The operation receiving module 52 is used to determine the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model in response to receiving a trigger operation on at least one target label.

[0187] The target location determination module 53 is used to determine the target location corresponding to the target label based on the label height value and the preset angle.

[0188] The second model display module 54 is used to display a preset 3D model from a second perspective based on the target location.

[0189] Among them, the preset 3D model displays at least the 3D sub-model corresponding to the target label in the second perspective.

[0190] The three-dimensional model perspective conversion device provided in the above embodiments of this disclosure determines the target position based on the label height value and the preset angle, and converts the perspective to a second perspective that allows viewing of the three-dimensional sub-model corresponding to the target label based on the target position. It can accurately convert the target label from the first perspective to the three-dimensional sub-model from the second perspective, thus achieving accurate perspective conversion. This overcomes the problem in the prior art that the perspective cannot be accurately located and converted because only the label is displayed in the first perspective.

[0191] In some optional embodiments, the operation receiving module 52 is specifically used to determine a first height value of the bottom surface of the preset three-dimensional model and a second height value of the coordinate point of the target label in the three-dimensional coordinate system of the model; and to determine the label height value based on the first height value and the second height value.

[0192] Optionally, when the operation receiving module 52 determines the first height value of the bottom surface of the preset three-dimensional model and the second height value of the coordinate point of the target label in the three-dimensional coordinate system of the model, it is used to determine the bounding box of the preset three-dimensional model; determine the coordinate value of the vertical axis of the bottom surface of the preset three-dimensional model in the three-dimensional coordinate system of the model based on the bounding box; determine the first height value based on the coordinate value; and determine the second height value based on the vertical axis coordinate value of the three-dimensional coordinate system corresponding to the coordinate point of the target label.

[0193] In some optional embodiments, the target location determination module 53 includes:

[0194] The height determination unit is used to determine the target height value based on the label height value and a preset angle;

[0195] The target plane determination unit is used to determine a target plane in the model's three-dimensional coordinate system based on the target height value;

[0196] The trajectory determination unit is used to determine a circular trajectory on the target plane;

[0197] The trajectory position determination unit is used to determine at least one coordinate point on the circular trajectory as the target position.

[0198] Optionally, the height determination unit is specifically used to determine a reference height value based on the label height value and preset parameters; and to determine a target height value based on the product of the reference height value and the trigonometric function value of the preset angle, and the label height value.

[0199] Optionally, the trajectory determination unit is specifically used to determine the center point based on the target height value and the three-dimensional coordinates of the target label's coordinate points; determine the length value based on the label's height value and a preset angle; and determine a circular trajectory based on the center point as the center and the length value as the radius.

[0200] Optionally, the trajectory position determination unit is specifically used to divide the circular trajectory into a preset number of points, determine a preset number of coordinate points on the circular trajectory as reference points, and determine the target position based on the preset number of reference points.

[0201] Optionally, when determining the target position based on a preset number of reference points, the trajectory position determination unit performs a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test; determines at least one reference point that passes the collision test based on the result of whether each reference point passes the collision test; and determines the target position based on at least one reference point that passes the collision test.

[0202] Optionally, when the trajectory position determination unit performs a collision test on each of the preset number of reference points and determines whether each reference point passes the collision test, it establishes a ray from the reference point as the origin to the coordinate point of the target label for each of the preset number of reference points to obtain a reference ray; and determines whether the reference point passes the collision test based on the reference ray.

[0203] Optionally, when determining whether a reference point passes the collision test based on a reference ray, the trajectory position determination unit determines a first distance based on the distance between the intersection of the reference ray and the preset 3D model and the reference point; determines a second distance based on the distance from the reference point to the coordinate point of the target label; and determines whether the reference point passes the collision test based on the relationship between the first distance and the second distance.

[0204] Optionally, when determining the target position based on at least one reference point that has passed the collision test, the trajectory position determination unit is used to determine the adjacency relationship of at least one reference point based on the position of at least one reference point that has passed the collision test on the circular trajectory; based on the adjacency relationship, the at least one reference point is clustered to obtain at least one set of reference points; wherein each set of reference points includes at least one reference point, and each reference point in the set of reference points is adjacent to at least one other reference point in the set of reference points; and the target position is determined based on the set of reference points that includes the largest number of reference points.

[0205] Optionally, when determining the target position based on the reference point set that includes the largest number of reference points, the trajectory position determination unit is used to calculate the midpoint of the two reference points at the center position among the multiple reference points included in the reference point set on the circular trajectory in response to the even number of reference points included in the reference point set, and take the midpoint as the target position; in response to the odd number of reference points included in the reference point set, take the reference point at the center position among the multiple reference points included in the reference point set as the target position.

[0206] Exemplary electronic devices

[0207] Below, for reference Figure 6 This describes an electronic device according to embodiments of the present disclosure. The electronic device may be either or both of a first device and a second device, or a standalone device independent of them, which may communicate with the first device and the second device to receive acquired input signals from them.

[0208] Figure 6 A block diagram of an electronic device according to an embodiment of the present disclosure is shown.

[0209] like Figure 6 As shown, the electronic device includes one or more processors and memory.

[0210] A processor can be a central processing unit (CPU) or other form of processing unit with data processing and / or instruction execution capabilities, and can control other components in an electronic device to perform desired functions.

[0211] The memory can store one or more computer program products, and the memory can include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, random access memory (RAM) and / or cache memory. The non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program products can be stored on the computer-readable storage medium, and the processor can run the computer program products to implement the perspective transformation methods for three-dimensional models of the various embodiments of this disclosure described above, and / or other desired functions.

[0212] In one example, the electronic device may also include input devices and output devices, which are interconnected via a bus system and / or other forms of connection mechanism (not shown).

[0213] In addition, the input device may also include, for example, a keyboard, a mouse, etc.

[0214] This output device can output various information to the outside, including determined distance information, direction information, etc. The output device may include, for example, a display, a speaker, a printer, and a communication network and its connected remote output devices, etc.

[0215] Of course, for the sake of simplicity, Figure 6 Only some of the components of the electronic device relevant to this disclosure are shown, omitting components such as buses, input / output interfaces, etc. In addition, the electronic device may include any other suitable components depending on the specific application.

[0216] In addition to the methods and apparatus described above, embodiments of this disclosure may also be computer program products comprising computer program instructions that, when executed by a processor, cause the processor to perform the steps in the perspective transformation methods for three-dimensional models according to various embodiments of this disclosure as described in the foregoing portions of this specification.

[0217] The computer program product can be written in any combination of one or more programming languages ​​to perform the operations of the embodiments of this disclosure. The programming languages ​​include object-oriented programming languages ​​such as Java and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on a user's computing device, partially on a user's computing device, as a standalone software package, partially on a user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0218] Furthermore, embodiments of this disclosure may also be computer-readable storage media storing computer program instructions thereon, which, when executed by a processor, cause the processor to perform the steps in the perspective transformation method for a three-dimensional model according to various embodiments of this disclosure as described in the foregoing portion of this specification.

[0219] The computer-readable storage medium may be any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may, for example, include, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses, or devices, or any combination thereof. More specific examples of readable storage media (a non-exhaustive list) include: electrical connections having one or more wires, portable disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0220] The basic principles of this disclosure have been described above with reference to specific embodiments. However, it should be noted that the advantages, benefits, and effects mentioned in this disclosure are merely examples and not limitations, and should not be considered as essential features of each embodiment of this disclosure. Furthermore, the specific details disclosed above are for illustrative and facilitative purposes only, and are not limitations. These details do not limit the scope of this disclosure to the necessity of employing the aforementioned specific details for implementation.

[0221] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For system embodiments, since they largely correspond to method embodiments, the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.

[0222] The block diagrams of devices, apparatuses, devices, and systems disclosed herein are merely illustrative examples and are not intended to require or imply that they must be connected, arranged, or configured in the manner shown in the block diagrams. As those skilled in the art will recognize, these devices, apparatuses, devices, and systems can be connected, arranged, and configured in any manner. Words such as “comprising,” “including,” “having,” etc., are open-ended terms meaning “including but not limited to,” and are used interchangeably with them. The terms “or” and “and” as used herein refer to the terms “and / or,” and are used interchangeably with them unless the context clearly indicates otherwise. The term “such as” as used herein refers to the phrase “such as but not limited to,” and is used interchangeably with it.

[0223] The methods and apparatus of this disclosure may be implemented in many ways. For example, they may be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above-described order of steps for the methods is for illustrative purposes only, and the steps of the methods of this disclosure are not limited to the order specifically described above unless otherwise specifically stated. Furthermore, in some embodiments, this disclosure may also be implemented as a program recorded on a recording medium, the program including machine-readable instructions for implementing the methods according to this disclosure. Thus, this disclosure also covers recording media storing programs for performing the methods according to this disclosure.

[0224] It should also be noted that in the apparatus, devices, and methods of this disclosure, the components or steps can be disassembled and / or recombined. These disassemblies and / or recombinations should be considered as equivalent solutions to this disclosure.

[0225] The above description of the disclosed aspects is provided to enable any person skilled in the art to make or use this disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of this disclosure. Therefore, this disclosure is not intended to be limited to the aspects shown herein, but rather to be carried out within the widest scope consistent with the principles and novel features disclosed herein.

[0226] The above description has been given for purposes of illustration and description. Furthermore, this description is not intended to limit the embodiments of this disclosure to the forms disclosed herein. Although numerous exemplary aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, alterations, additions, and sub-combinations therein.

Claims

1. A method for perspective transformation of a three-dimensional model, characterized in that, include: Obtain a preset 3D model displayed from a first-person perspective; wherein the preset 3D model displays at least one label from the first-person perspective, and the preset 3D model includes at least one 3D sub-model, each of the 3D sub-models corresponding to one label; In response to receiving a trigger operation on a target label among the at least one labels, the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model is determined; Based on the label height value and the preset angle, the target position corresponding to the target label is determined; The preset 3D model is displayed from a second perspective based on the target location; wherein, the preset 3D model displays at least the 3D sub-model corresponding to the target label from the second perspective; Determining the target location corresponding to the target label based on the label height value and the preset angle includes: The target height value is determined based on the label height value and the preset angle; Based on the target height value, a target plane is determined in the model's three-dimensional coordinate system; Determine a circular trajectory on the target plane; At least one coordinate point on the circular trajectory is determined as the target location.

2. The method according to claim 1, characterized in that, Determining the label height value of the target label's coordinate point relative to the bottom surface of the preset 3D model includes: Determine the first height value of the bottom surface of the preset three-dimensional model and the second height value of the coordinate point of the target label in the model's three-dimensional coordinate system; The label height value is determined based on the first height value and the second height value.

3. The method according to claim 2, characterized in that, The determination of the first height value of the bottom surface of the preset 3D model and the second height value of the coordinate point of the target label in the model's 3D coordinate system includes: Determine the bounding box of the preset 3D model; Based on the bounding box, the coordinate value of the bottom surface of the preset 3D model on the vertical axis in the 3D coordinate system of the model is determined, and the first height value is determined based on the coordinate value. The second height value is determined based on the vertical axis coordinate value in the three-dimensional coordinate system corresponding to the coordinate point of the target label.

4. The method according to any one of claims 1-3, characterized in that, Determining the target height value based on the label height value and the preset angle includes: Based on the label height value and preset parameters, a reference height value is determined; The target height value is determined based on the product of the reference height value and the trigonometric function value of the preset angle, as well as the label height value.

5. The method according to any one of claims 1-3, characterized in that, Determining a circular trajectory on the target plane includes: Based on the target height value and the three-dimensional coordinates of the target label's coordinate points, a center point is determined; the x-axis and z-axis coordinates of the center point are the same as those of the target label, and the y-axis coordinate of the center point is the same as that of the target height value. The length value is determined based on the label height value and the preset angle; The circular trajectory is determined based on the center point as the center and the length value as the radius.

6. The method according to any one of claims 1-3, characterized in that, Determining at least one coordinate point on the circular trajectory as the target location includes: The circular trajectory is divided into a preset number of points, and the preset number of coordinate points on the circular trajectory are determined as reference points. The target location is determined based on the preset number of reference points.

7. The method according to claim 6, characterized in that, Determining the target location based on the preset number of reference points includes: Perform a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test. Based on whether each of the reference points passes the collision test, at least one reference point that passes the collision test is determined. The target location is determined based on the at least one reference point that passed the collision test.

8. The method according to claim 7, characterized in that, The step of performing a collision test on each of the preset number of reference points to determine whether each reference point passes the collision test includes: For each of the preset number of reference points, a ray is established from the reference point as the origin to the coordinate point of the target label to obtain a reference ray; Based on the reference ray, determine whether the reference point passes the collision test.

9. The method according to claim 8, characterized in that, The step of determining whether the reference point passes the collision test based on the reference ray includes: The first distance is determined based on the distance between the intersection point of the reference ray and the preset three-dimensional model and the reference point; The second distance is determined based on the distance from the reference point to the coordinates of the target label. Based on the relationship between the first distance and the second distance, determine whether the reference point passes the collision test.

10. The method according to claim 7, characterized in that, Determining the target location based on the at least one reference point that passed the collision test includes: Based on the position of the at least one reference point that passed the collision test on the circular trajectory, determine the adjacency relationship of the at least one reference point; Based on the adjacency relationship, the at least one reference point is clustered to obtain at least one set of reference points; wherein each set of reference points includes at least one reference point, and each reference point in the set of reference points is adjacent to at least one other reference point in the set of reference points; The target location is determined based on the set of reference points that contains the largest number of reference points.

11. The method according to claim 10, characterized in that, Determining the target location based on the reference point set that includes the largest number of reference points includes: In response to the fact that the number of reference points included in the reference point set is even, the midpoint between the two reference points at the center position among the multiple reference points included in the reference point set on the circular trajectory is calculated, and the midpoint is taken as the target position; In response to the fact that the number of reference points included in the reference point set is odd, the reference point at the center of the multiple reference points included in the reference point set is taken as the target position.

12. A perspective conversion device for a three-dimensional model, characterized in that, include: The first model display module is used to obtain a preset 3D model displayed from a first perspective; wherein the preset 3D model displays at least one label from the first perspective, and the preset 3D model includes at least one 3D sub-model, each of the 3D sub-models corresponding to one label; An operation receiving module is used to determine the label height value of the coordinate point of the target label relative to the bottom surface of the preset three-dimensional model in response to receiving a trigger operation on the target label of the at least one label. The target location determination module is used to determine the target location corresponding to the target label based on the label height value and a preset angle; The second model display module is used to display the preset 3D model from a second perspective based on the target location; wherein, the preset 3D model displays at least the 3D sub-model corresponding to the target label from the second perspective; The target location determination module includes: A height determination unit is used to determine a target height value based on the label height value and the preset angle; The target plane determination unit is used to determine a target plane in the three-dimensional coordinate system of the model based on the target height value. A trajectory determination unit is used to determine a circular trajectory on the target plane; The trajectory position determination unit is used to determine at least one coordinate point on the circular trajectory as the target position.

Citation Information

Patent Citations

  • Panorama display method and device for point locations outside model, equipment and medium

    CN115512046A

  • Three-dimensional model display visual angle adjustment method and device, electronic equipment and storage medium

    CN117237500A