Method for displaying virtual object, electronic device, and storage medium
By reading spatial information on the folding device, cutting virtual objects, displaying their profile information, and combining with wearable devices, the problem of single content and insufficient interactiveness of virtual objects in the prior art is solved, improving user experience and extending device life .
Patent Information
- Application Number
- PCT/CN2024/099900
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-07-06
- Filing Date
- 2024-06-18
- Publication Date
- 2025-01-09
AI Technical Summary
The existing three-dimensional interaction method is mainly to restore the full view of virtual objects in the space. The display content is very single, the interaction is insufficient, and the user experience is affected.
By reading spatial information on the display screen of the folding device, cutting the virtual object according to the spatial information of the display screen, displaying the profile information of the virtual object, and using the combination of the folding device and the wearable device to realize the cutting of the virtual object at different angles. and internal structure display.
It enhances users' understanding of virtual objects, increases interactivity, improves user experience, and extends the service life of the display screen of the folding device.
Smart Images

Figure CN2024099900_09012025_PF_FP_ABST
Abstract
Description
Virtual object display method, electronic device and storage medium
[0001] Related applications
[0002] This application claims priority to Chinese patent application No. 202310827459.8 filed on July 6, 2023, the entire contents of which are incorporated by reference into this application. Technical Field
[0003] The present application relates to the field of augmented reality technology, and in particular to a virtual object display method, electronic device, and storage medium. Background Art
[0004] With the rapid development of augmented reality technology and foldable mobile phone technology, more and more users are seeking to experience more realistic, three-dimensional and interactive three-dimensional virtual environments in order to obtain a more immersive three-dimensional interactive experience.
[0005] In existing technologies, users typically interact with virtual objects in three dimensions by adjusting their own perspective or the perspective of virtual objects through handheld or head-mounted displays (HMDs), or other wearable devices. However, this 3D interaction method primarily aims to restore the virtual object's overall appearance in space. The displayed content is limited and lacks interactivity, hindering users' ability to gain a detailed understanding of the virtual object and negatively impacting the user experience.
[0006] Summary of the Invention
[0007] The present application provides a virtual object display method, electronic device and storage medium.
[0008] In a first aspect, the present application provides a method for displaying a virtual object, the method comprising: when displaying a virtual object on a display screen of a folding device, reading spatial information of the display screen; cutting the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object; and displaying the cross-sectional information through one or more display screens of the folding device.
[0009] In a second aspect, the present application provides an electronic device comprising: a processor and a memory, wherein the processor is configured to execute a program for displaying a virtual object stored in the memory to implement the virtual object display method described in any one of the first aspects.
[0010] In a third aspect, the present application provides a storage medium storing one or more programs, which can be executed by one or more processors to implement the virtual object display method described in any one of the first aspects. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0012] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0013] One or more embodiments are exemplarily illustrated by pictures in the corresponding drawings. These exemplifications do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings are represented as similar elements. Unless otherwise stated, the figures in the drawings do not constitute proportional limitations.
[0014] FIG1 is a flow chart of an embodiment of a method for displaying a virtual object provided in an embodiment of the present application;
[0015] FIG2 is a schematic diagram of a virtual object cut by a foldable display screen according to an embodiment of the present application;
[0016] FIG3 is a flow chart of another embodiment of a virtual object display method provided in an embodiment of the present application;
[0017] FIG4 is a schematic diagram of establishing a rectangular coordinate system provided by an embodiment of the present application;
[0018] FIG5 is a flow chart of another embodiment of a virtual object display method provided in an embodiment of the present application;
[0019] FIG6 is a schematic diagram of a wearable device cutting a virtual object according to an embodiment of the present application;
[0020] FIG7 is a block diagram of an embodiment of a virtual object display device provided in an embodiment of the present application;
[0021] FIG8 is a schematic structural diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0022] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0023] The disclosure below provides many different embodiments or examples for implementing different structures of the present application. In order to simplify the disclosure of the present application, the components and settings of specific examples are described below. Of course, these are merely examples and are not intended to limit the present application. In addition, the present application may repeat reference numbers and / or letters in different examples. Such repetition is for the purpose of simplicity and clarity and does not in itself indicate the relationship between the various embodiments and / or settings discussed.
[0024] In order to at least solve the technical problems in the existing technology that the three-dimensional interaction method is mainly for restoring the overall appearance of the virtual object in space, the displayed content is very simple, and the interaction is insufficient, the present application provides a virtual object display method that can cut the virtual object and display the cross-sectional information of the virtual object, thereby realizing the display of the internal structure information of the virtual object, allowing users to understand the virtual object in more detail, increase interactivity, and enhance user experience.
[0025] Figure 1 is a flow chart of an embodiment of a virtual object display method provided by an embodiment of the present application. As shown in Figure 1, the process may include the following steps.
[0026] Step 101: When a virtual object is displayed on a display screen of a foldable device, read spatial information of the display screen.
[0027] The above-mentioned spatial information refers to the spatial parameters related to the display screen. For example, when the display screen is folded, the spatial information can be the folding angle of the folded display screen, or the position information of the display screen relative to the reference coordinate system, or the relative position information between the display screen and the virtual object, etc.
[0028] The above-mentioned foldable device refers to a device whose display screen can be folded, which can be a foldable mobile phone, a foldable tablet, etc.
[0029] The above-mentioned virtual objects refer to virtual objects formed by AR (Augmented Reality) technology, which may include images, videos, text, three-dimensional models, etc.
[0030] In this application, the executing entity of this application may be the above-mentioned folding device, in which an AR application may be installed, and users may share virtual objects on the folding screen through the AR application in the folding device, so that users may interact with virtual objects more intuitively.
[0031] In one embodiment, the foldable device may pre-store the virtual objects. Based on this, when it is determined to display the virtual objects, the virtual objects may be displayed on the foldable screen of the foldable device through the installed AR application.
[0032] In another embodiment, the aforementioned foldable device can be connected to a 3D scanning device, such as a 3D scanner. The foldable device can use the 3D scanning device to scan objects in the real world and generate corresponding virtual objects based on the scan results. This virtual object can then be displayed on the display of the foldable device using an installed AR application.
[0033] In the present application, the folding device may include two display screens, and the virtual object may be displayed on any one of the display screens or on both display screens, and the embodiments of the present application do not impose any restrictions on this.
[0034] In an exemplary embodiment, the foldable device may display virtual objects on the two display screens.
[0035] In one embodiment, when determining that a virtual object is displayed on a display screen of a foldable device, the execution subject of the present application may read spatial information of the display screen.
[0036] As an implementation in an exemplary embodiment, the spatial information of the display screen can be read directly by reading a file for recording display screen parameters in the folding device.
[0037] As another implementation in an exemplary embodiment, the spatial information of the display screen may be determined with the help of a third-party device.
[0038] As another implementation method in an exemplary embodiment, when the above-mentioned spatial information includes multiple spatial parameters, after determining one of the spatial parameters (such as the folding angle of the folded display screen), other spatial parameters (such as the cross-sectional model of the folded display screen) can be determined based on the spatial parameter.
[0039] Step 102: Cut the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object.
[0040] The above-mentioned cross-section information refers to information parameters related to the cross-section formed after the virtual object is cut, which may include shape information of the cross-section, surface structure information, etc.
[0041] In this application, the displayed virtual object can be cut according to the spatial information of the display screen of the folding device to obtain a cross-section of the virtual object and the cross-sectional information of the cross-section, so that the user can not only understand the overall information of the virtual object, but also understand the internal structure information of the virtual object in more detail.
[0042] In an exemplary embodiment, the folding device may include two display screens. The user can fold the display screens so that the plane of the folded display screens intersects with the virtual object. This intersection can be used as a cross-section of the virtual object, thereby cutting the virtual object. For example, Figure 2 is a schematic diagram of a folded display screen cutting a virtual object according to an embodiment of the present application. As shown in the figure, the intersection line between the folded display screen and the virtual object is the black circle where the sphere intersects with the bent portion of the screen. Depending on the bending angle, the plane of the folded display screen and the virtual object will intersect at different locations.
[0043] As a possible implementation, the user can fold one of the display screens and cut the virtual object at different levels by folding it at different angles, wherein each folding can obtain a cross-section of the virtual object.
[0044] As another possible implementation, the user can fold the two display screens of the folding device to simultaneously slice the virtual object from different angles, wherein each folding operation can obtain two cross-sections of the virtual object.
[0045] In order to prevent cutting errors due to inaccurate folding angles when cutting virtual objects through the folded display screen, which requires repeated folding and reduces the service life of the folding screen, in this application, after the virtual object is cut through the folded display screen, the virtual object can be subsequently cut through a connected wearable device in conjunction with the folded display screen to reduce the folding frequency, thereby extending the service life of the display screen.
[0046] As for how to cut the virtual object based on the spatial information of the folded display screen and determine the cross-sectional information of the virtual object, and how to cut the virtual object through the wearable device and the folded display screen and determine the cross-sectional information, they can be explained below through the processes shown in Figures 3 and 5 respectively, which will not be described in detail here.
[0047] Step 103: Display the cross-sectional information through one or more display screens of the foldable device.
[0048] In this application, after the virtual object is cut through the folded display screen and the cross-sectional information of the virtual object is obtained, the corresponding cross-sectional information can be displayed through one or more display screens of the folding device, so that the user can understand the cross-sectional information of the virtual object more intuitively and in detail.
[0049] As a possible implementation, if both display screens of the folding device are folded, and the virtual object is cut through the two folded display screens of the folding device, cross-sectional information obtained by cutting the folded display screens can be displayed on each folded display screen.
[0050] As another possible implementation, if one of the display screens of the folding device is folded and the virtual object is cut through the folded display screen, cross-sectional information of the virtual object may be displayed on the folded display screen.
[0051] In one embodiment, in order to achieve the effect of switching between upper and lower levels on the mobile phone screen, generate three-dimensional spatial application information, increase the playability, display space and display depth of the mobile phone, the execution entity of this application can obtain the application information corresponding to the foldable device and map the application information on the above-mentioned virtual object.
[0052] Based on this, when the executive entity of this application displays the cross-sectional information of a virtual object through one or more display screens of a folding device, it can display the above cross-sectional information through one or more display screens of the folding device based on the application information mapped on the virtual object.
[0053] The technical solution provided by this application reads the spatial information of the display screen when displaying a virtual object on the display screen of a foldable device, cuts the virtual object based on the spatial information of the display screen, obtains cross-sectional information of the virtual object, and displays the cross-sectional information on one or more display screens of the foldable device. This technical solution utilizes the folding feature of the foldable device to fold the display screen of the foldable device to cut the virtual object based on the spatial information of the display screen, obtains cross-sectional information of the virtual object, and realizes cutting the virtual object at different angles to display the cross-sectional information of the virtual object, thereby realizing the display of the internal structure information of the virtual object, allowing users to understand the virtual object in more detail from different angles, increasing interactivity, and improving user experience.
[0054] See Figure 3, which is a flowchart of another embodiment of a virtual object display method provided in an embodiment of the present application. The process shown in Figure 3 builds on the process shown in Figure 1 and describes how, when a foldable device's display screen is detected to be in a folded state, a virtual object is sliced based on the display screen's spatial information to obtain cross-sectional information of the virtual object. As shown in Figure 3, this process may include the following steps.
[0055] Step 301: Display a virtual object on the display screen of the folding device, and when it is detected that the display screen of the folding device is in a folded state, read the folding angle of the folded display screen.
[0056] Step 302: Determine a first cross-sectional model corresponding to the folded display screen according to the folding angle of the folded display screen.
[0057] The following is a unified description of step 301 and step 302.
[0058] The above-mentioned folding angle refers to the angle at which the folded display screen is folded on the folding device.
[0059] The above-mentioned first cross-sectional model refers to the model corresponding to the plane where the folded display screen is located. It can be an equation or a model expression, and the embodiment of the present application does not limit this.
[0060] In the present application, when it is detected that a virtual object is displayed on the display screen of the folding device and the display screen of the folding device is in a folded state, the folding angle of the folded display screen can be determined as the spatial information of the folded display screen.
[0061] Based on this, the executive body of this application can read the folding angle of the folded display screen.
[0062] As a possible implementation method, the folding angle of the folded display screen can be determined by reading parameter information about the folding display screen in the folding device.
[0063] As another possible implementation manner, the folding angle of the folded display screen may be measured by a third-party device.
[0064] In the present application, after determining the folding angle of the folded display screen, in order to allow the plane where the folded display screen is located to cut the virtual object, a first cross-sectional model corresponding to the folded display screen can be determined according to the folding angle of the folded display screen.
[0065] In one embodiment, when a display screen of a foldable device is folded, a rectangular coordinate system may be established based on the unfolded display screen as a reference plane, and position information corresponding to the folded display screen (hereinafter referred to as "first position information" for ease of description) may be determined based on the rectangular coordinate system and the folding angle. The first position information herein refers to the position information of the folded display screen in the rectangular coordinate system, for example, the coordinates of any point on the folded display screen in the rectangular coordinate system.
[0066] Afterwards, a first cross-sectional model corresponding to the folded display screen may be determined according to the first position information.
[0067] In an exemplary embodiment, a rectangular coordinate system is established with the midpoint of the fold line of the two display screens of the foldable mobile phone as the origin, and the plane of the unfolded display screen as the reference plane, i.e., the plane containing the x-axis and y-axis in the rectangular coordinate system. For example, Figure 4 is a schematic diagram of establishing a rectangular coordinate system provided in an embodiment of the present application. The coordinates of any point on the plane containing the folded display screen and the normal vector of the plane are then determined. Using the principle that the line connecting any point and the origin is perpendicular to the normal vector, an equation for the plane is determined, which contains multiple unknowns.
[0068] Afterwards, the direction cosines of the normal vector direction can be determined based on the above folding angle, and based on this, the unknowns in the above equation expression can be solved to obtain the equation expression of the plane where the folded display screen is located.
[0069] For example, first, find a vector perpendicular to the plane of the folded display. This vector is the normal vector of the plane. Let the normal vector be n = (A, B, C), where A, B, and C are not all zero.
[0070] Then, using the property that the line connecting any point P(x, y, z) on the plane and the origin O(0, 0, 0) is perpendicular to the normal vector, we can obtain the point normal equation of the plane: A(x-0)+B(y-0)+C(z-0)=0, that is, Ax+By+Cz=0.
[0071] Finally, based on the folded angle, determine the direction cosines of the normal vector. Let's assume the angle between the plane and the x-axis is α, meaning the folding angle of the folded display is α. Then, we have cosα = frac{A}{sqrt{A^{2}+B^{2}+C^{2}}}. Similarly, let's assume the angles between the plane of the folded display and the y-axis and z-axis are β and γ, respectively. Then, we have cosβ = frac{B}{sqrt{A^{2}+B^{2}+C^{2}}} and cosγ = frac{C}{sqrt{A^{2}+B^{2}+C^{2}}}. From this, we can solve for A, B, and C, and substitute Ax+By+Cz=0 to obtain the equation of the plane.
[0072] Finally, it can be calculated that when the folding angle of the folded display screen is α, the cross-sectional equation of the folded display screen (ie, the first cross-sectional model) is: cos(α)x+sin(α)z=0.
[0073] In another embodiment, when the two display screens of the folding device are folded, a rectangular coordinate system (such as the rectangular coordinate system established as shown in FIG4 ) can be established with the two display screens before being folded as a reference plane, and based on the rectangular coordinate system and the folding angle of each folded display screen, the position information corresponding to each folded display screen is determined (hereinafter referred to as the fourth position information for ease of description). The fourth position information here refers to the position information of each folded display screen in the rectangular coordinate system, such as the coordinates of any point of each folded display screen in the rectangular coordinate system.
[0074] Afterwards, the first cross-sectional model corresponding to each folded display screen may be determined according to the fourth position information.
[0075] As for how to specifically determine the first cross-sectional model corresponding to each folded display screen, reference may be made to the above-mentioned process of determining the first cross-sectional model of the folded display screen when one display screen of the folding device is folded.
[0076] Step 303: Determine first page information of a first intersection surface between the folded display screen and the virtual object based on the first cross-sectional model of the folded display screen.
[0077] Step 304: Determine the first page information as cross-section information of the virtual object.
[0078] The following is a unified description of step 303 and step 304.
[0079] The first intersecting surface refers to a plane where the folded display screen intersects with the virtual object.
[0080] Correspondingly, the first page information refers to the page information corresponding to the first intersecting surface, which may include but is not limited to the plane shape and plane structure information of the first intersecting surface.
[0081] In the present application, the folding device may include two display screens. A user may fold at least one of the display screens so that the plane of the folded display screen intersects with the virtual object (hereinafter referred to as the "first intersecting surface" for ease of description), and use the first intersecting surface as a cross-section of the virtual object, thereby achieving cutting of the virtual object. Subsequently, page information of the first intersecting surface may be determined (hereinafter referred to as the "first page information" for ease of description), and the first page information may be determined as the cross-sectional information of the virtual object.
[0082] In an exemplary embodiment, it can be seen from the above step description that when determining the first cross-sectional model corresponding to the folded display screen, a rectangular coordinate system can be established and determined based on the position information of the folded display screen in the rectangular coordinate system.
[0083] Based on this, when determining the first page information of the first intersection surface of the folded display screen and the virtual object, the position information of the virtual object in the rectangular coordinate system can be determined (hereinafter referred to as second position information for ease of description).
[0084] Afterwards, a first three-dimensional model corresponding to the virtual object may be constructed based on the second position information. The first three-dimensional model here refers to a model that approximately represents the virtual object, such as a triangular mesh model.
[0085] Based on this, the executing entity of the embodiment of the present application can determine the first page information of the first intersection surface of the folded display screen and the virtual object according to the above-mentioned first cross-sectional model and the first three-dimensional model, and determine the first page information as the cross-sectional information of the virtual object.
[0086] In an exemplary embodiment, the first page information of the first intersection surface can be determined in the following manner: first, based on the above-mentioned first cross-sectional model and the first three-dimensional model, an expression of the first intersection surface between the folded display screen and the virtual object (hereinafter referred to as the first expression for ease of description) can be determined. The first expression can be used to represent the coordinates of the first intersection surface between the folded display screen and the virtual object in an established rectangular coordinate system.
[0087] Afterwards, multiple intersection points between the folded display screen and the virtual object may be determined according to the first expression. The multiple intersection points may be critical points of a first intersection surface between the folded display screen and the virtual object.
[0088] Based on this, shape information of the first intersection surface between the folded display screen and the virtual object (hereinafter referred to as first shape information for ease of description) can be determined based on the multiple intersection points. In this case, the first shape information of the first intersection surface can be used to characterize the shape of the first intersection surface. However, in this case, the entire plane is covered by the model surface of the first three-dimensional model. For example, if the first three-dimensional model corresponding to the virtual object is a triangular mesh model, then the first intersection surface is entirely triangles.
[0089] Therefore, the executing entity of the embodiment of the present application can remove the model surface corresponding to the first intersecting surface in the above-mentioned first three-dimensional model, thereby obtaining the plane structure information corresponding to the first intersecting surface. Since the first intersecting surface belongs to any plane of the virtual object, the plane structure information of the first intersecting surface can represent the internal structure information of the virtual object.
[0090] Finally, the first shape information and the first plane structure information may be determined as the first page information of the first intersection surface.
[0091] For example, taking the first three-dimensional model mentioned above as a triangular mesh model, assume that the surface of the virtual object is composed of n triangles, each triangle is determined by three vertices P_i, Q_i, R_i (i = 1, 2, ..., n), and the plane corresponding to the folded display screen is determined by the equation ax+by+cz+d=0, where (a, b, c) is the normal vector of the plane, and d is a constant.
[0092] In an exemplary embodiment, for each triangle, assume that the ray L_i starts from any point on the plane and is emitted along the direction of the normal vector of the plane, that is, L_i(t) = (x_0, y_0, z_0) + t(a, b, c), where t is a parameter, and (x_0, y_0, z_0) is any point on the plane, which can be obtained by substituting into the plane equation.
[0093] After that, find the intersection point S_i of the ray L_i and the triangle P_iQ_iR_i. If it exists, it can be calculated by the following formula:
[0094] Suppose the edge vectors of the triangle are u_i=Q_i-P_i, v_i=R_i-P_i, and the direction vector of the ray is w=(a, b, c), then S_i=P_i+su_i+tv_i=L_i(r)=(x_0,y_0,z_0)+rw, where s, t, r are unknowns.
[0095] Then, substituting the coordinates of S_i into the above equation, we can get a system of linear equations: [u_iv_i-w][str]^T=(x_0, y_0, z_0)-P_i, where [u_iv_i-w] is a 3x3 matrix and [str]^T is a 3x1 column vector.
[0096] After that, solving this linear system of equations yields the values of s, t, and r. If this matrix is singular, meaning the determinant is zero, then the ray is parallel or coplanar with the triangle, and there is no intersection. If s, t, and r are all non-negative numbers, and s + t <= 1, then the intersection point S_i is inside the triangle. Otherwise, the intersection point is outside the triangle or does not exist.
[0097] Then, all the intersection points S_i inside the triangle are collected. These points constitute the boundary points of the cross section, that is, the intersection points of the folded display and the AR object. These points can be connected using some algorithms, such as convex hull algorithms or alpha-shape algorithms, to form one or more closed polygons.
[0098] Afterwards, the above-mentioned first intersecting surface can be expressed by the following first expression: suppose the cross section is composed of m polygons, each polygon is composed of k_j (j = 1, 2, ..., m) vertices, and the vertices are arranged counterclockwise as V_{j1}, V_{j2}, ..., V_{jk_j} (j = 1, 2, ..., m), then the first shape information = {polygon_1, polygon_2, ..., polygon_m}, polygon_j = {V_{j1}, V_{j2}, ..., V_{jk_j}} (j = 1, 2, ..., m), V_{ji} = (x_{ji}, y_{ji}, z_{ji}) (i = 1, 2, ..., k_j; j = 1, 2, ..., m).
[0099] Finally, the triangular face of the object model on one side of the screen may be removed according to the normal direction of the intersecting first intersection surface, thereby displaying the object structure in the cross section after being cut, that is, the first plane structure information.
[0100] Step 305: Display the above-mentioned cross-sectional information through the folded display screen of the folding device.
[0101] In this application, in order to facilitate users to understand the cross-sectional information of the above-mentioned virtual object more intuitively and clearly, the executive entity of this application can map the above-mentioned cross-sectional page information on the corresponding folded display screen for display, that is, the cross-sectional information is obtained by cutting the virtual object by the first display screen, and then the cross-sectional information is mapped on the first display screen for display.
[0102] In addition, before displaying the above-mentioned cross-sectional information through one or more display screens of the foldable device, the executing entity of the embodiment of the present application may obtain application information of the foldable device and map the application information onto the virtual object.
[0103] Based on this, the execution entity of the embodiment of the present application can display, through one or more display screens of the folding device, the following content, including but not limited to: internal structure information of the virtual object, information about the page where the virtual object is cut, and application information of the folding device. The internal structure information includes first plane structure information, and the page information includes first shape information.
[0104] The technical solution provided by this application displays a virtual object on the display screen of a folding device, and when it is detected that the display screen of the folding device is in a folded state, reads the folding angle of the folded display screen, determines a first cross-sectional model corresponding to the folded display screen based on the folding angle of the folded display screen, determines first page information of a first intersection surface between the folded display screen and the virtual object based on the first cross-sectional model of the folded display screen, determines the first page information as the cross-sectional information of the virtual object, and displays the above cross-sectional information through the folded display screen of the folding device. This technical solution, by folding at least one display screen of the folding device so that the folded display screen and the virtual object form an intersection surface, thereby achieving cutting of the virtual object and displaying the shape and structural information of the intersection surface, enables users to freely cut the virtual object and displays the internal structural information of the virtual object, allowing users to understand the virtual object in more detail from different angles, thereby improving the user experience.
[0105] See Figure 5, which is a flowchart of another embodiment of a virtual object display method provided in an embodiment of the present application. The process shown in Figure 5, based on the process shown in Figure 3, describes how to use a wearable device to cut a virtual object. As shown in Figure 5, the process may include the following steps.
[0106] Step 501: Display a virtual object on the display screen of the folding device, and when it is detected that the display screen of the folding device is in a folded state, read the folding angle of the folded display screen.
[0107] Step 502: Determine a first cross-sectional model corresponding to the folded display screen according to the folding angle of the folded display screen.
[0108] The detailed description of step 501 and step 502 can refer to the description of step 301 and step 302, which will not be repeated here.
[0109] Step 503: When the wearable device is detected to be moving, obtain movement data of the wearable device.
[0110] The wearable device may be a wearable device connected to a foldable device, which may be a watch, earphones, AR glasses, or AR helmet, etc., and this application does not limit this. The connection between the foldable device and the wearable device may be a Bluetooth connection or an electrical connection, and this application does not limit this.
[0111] The above-mentioned movement data refers to the movement data of the wearable device relative to the foldable device, which may include but is not limited to the movement distance, movement direction, etc.
[0112] In this application, when the folding device detects that the wearable device connected to it moves, the movement data of the wearable device can be obtained.
[0113] As an implementation in an exemplary embodiment, the foldable device can obtain the movement data of the wearable device in real time.
[0114] As another implementation in an exemplary embodiment, the foldable device may periodically obtain movement data of the wearable device.
[0115] As another implementation in an exemplary embodiment, the folding device may obtain movement data of the wearable device after detecting that the wearable device stops moving.
[0116] Step 504: Determine second page information of a second intersection surface between the folded display screen and the virtual object based on the first cross-sectional model and the movement data.
[0117] Step 505: Determine the second page information as the cross-section information of the virtual object.
[0118] The following is a unified description of step 504 and step 505.
[0119] As can be seen from the process description shown in FIG3 , the first cross-sectional model may be a cross-sectional model corresponding to the plane where the folded display screen is located.
[0120] In this application, because errors may occur when the folded display screen cuts the virtual object, the user needs to repeatedly fold the display screen to achieve accurate cutting of the virtual object. However, frequent folding of the display screen may shorten the life of the display screen. Therefore, after folding at least one display screen, the wearable device can be used to move the virtual object to achieve accurate cutting of the virtual object, thereby reducing the number of display screen folding times and extending the life of the folding device's display screen.
[0121] In an exemplary embodiment, after at least one display screen of the folding device is folded, the angle between the two display screens of the folding device is less than 180°. At this time, if the above-mentioned virtual object is moved, the intersection position of the folded display screen and the AR object can be changed, thereby forming a new intersection plane (hereinafter referred to as the "second intersection plane" for ease of description). For example, see Figure 6, which is a schematic diagram of a wearable device cutting a virtual object provided in an embodiment of the present application. As shown in Figure 6, taking the wearable device as a watch as an example, the watch is connected to the folding device via Bluetooth. The user wears the watch and moves the arm wearing the watch to move the virtual object and cut the virtual object through the folded display screen.
[0122] In one embodiment, when there is only one folded display screen, the mobile wearable device may form a new second intersection surface.
[0123] In another embodiment, when there are two folded display screens, the mobile wearable device may form two new second intersection surfaces.
[0124] Thereafter, second page information of the second intersection surface may be determined, and the second page information may be determined as cross-sectional information of the virtual object.
[0125] In an exemplary embodiment, the second page information of the second intersection surface may be determined in the following manner:
[0126] First, a second three-dimensional model corresponding to the virtual object may be determined based on the movement data. The second three-dimensional model herein refers to a model that approximately represents the virtual object, such as a triangular mesh model.
[0127] As an implementation method in an exemplary embodiment, when a display screen of a folding device is folded, the executive body of the present application can establish a rectangular coordinate system based on the unfolded display screen, and determine the position information of the virtual object in the rectangular coordinate system before it moves (for the sake of ease of description, hereinafter referred to as the third position information). Afterwards, a second three-dimensional model corresponding to the virtual object can be constructed based on the above-mentioned third position information and movement data.
[0128] In an exemplary embodiment, a rectangular coordinate system is established with the midpoint of the folding line of the two display screens of the foldable mobile phone as the origin and the plane where the unfolded display screen is located as the reference plane, that is, the plane where the x-axis and y-axis in the rectangular coordinate system are located.
[0129] As another exemplary implementation, when the two display screens of the foldable device are folded, a rectangular coordinate system (such as the one shown in FIG. 4 ) can be established using the two display screens before folding as a reference plane, and the position information of the virtual object in the rectangular coordinate system before movement (hereinafter referred to as third position information for ease of description) can be determined. Subsequently, a second 3D model corresponding to the virtual object can be constructed based on the third position information and the movement data.
[0130] In an exemplary embodiment, the position information of the virtual object in the rectangular coordinate system after movement (hereinafter referred to as the fifth position information for ease of description) can be determined based on the third position information and movement data, and then a second three-dimensional model of the virtual object can be constructed based on the fifth position information.
[0131] For example, assuming the coordinates of a point in the AR object are (1, 0, 5) and the movement data is (5, 0, 5), then after combining the position information with the movement data, the new coordinates of the point are (6, 0, 5).
[0132] The specific process of constructing the three-dimensional model according to the position information of the virtual model in the rectangular coordinate system is the same as the construction process in the prior art and will not be repeated here.
[0133] Then, based on the above-mentioned first cross-sectional model and second three-dimensional model, an expression of the second intersection surface between the folded display screen and the virtual object (hereinafter referred to as the second expression for ease of description) can be determined. The second expression can be used to represent the coordinates of the second intersection surface where the folded display screen and the virtual object intersect in the established rectangular coordinate system.
[0134] Afterwards, multiple intersection points between the folded display screen and the virtual object may be determined according to the second expression. The multiple intersection points may be critical points of a second intersection surface between the folded display screen and the virtual object.
[0135] Based on this, shape information of a second intersection surface between the folded display screen and the virtual object (hereinafter referred to as second shape information for ease of description) can be determined based on the multiple intersection points. In this case, the second shape information of the second intersection surface can be used to characterize the shape of the second intersection surface. However, in this case, the entire plane is covered by the model surface of the second three-dimensional model. For example, if the second three-dimensional model corresponding to the virtual object is a triangular mesh model, then the second intersection surface is entirely triangles.
[0136] In an exemplary embodiment, the plurality of intersection points may be connected using a preset algorithm to obtain the second shape information of the second intersection surface. The algorithm may be a convex hull algorithm or an alpha-shape algorithm.
[0137] Therefore, the executing entity of the embodiment of the present application can remove the model surface corresponding to the second intersecting surface in the above-mentioned second three-dimensional model, thereby obtaining the plane structure information corresponding to the second intersecting surface. Since the second intersecting surface belongs to any plane of the virtual object, the plane structure information of the second intersecting surface can represent the internal structure information of the virtual object.
[0138] Finally, the second shape information and the second plane structure information may be determined as the second page information of the second intersection surface.
[0139] Step 506: Display the above-mentioned cross-sectional information through the folded display screen of the folding device.
[0140] In this application, in order to facilitate users to understand the cross-sectional information of the above-mentioned virtual object more intuitively and clearly, the executive entity of this application can map the above-mentioned cross-sectional page information on the corresponding folded display screen for display, that is, the cross-sectional information is obtained by cutting the virtual object by the first display screen, and then the cross-sectional information is mapped on the first display screen for display.
[0141] In addition, before displaying the above-mentioned cross-sectional information through one or more display screens of the foldable device, the executing entity of the embodiment of the present application may obtain application information of the foldable device and map the application information onto the virtual object.
[0142] Based on this, the execution subject of the embodiment of the present application can display, through one or more display screens of the folding device, the following content including but not limited to: internal structure information of the virtual object, page information of the virtual object being cut, and application information of the folding device. The above-mentioned internal structure information includes first plane structure information or second plane structure information, and the above-mentioned page information includes first shape information or second shape information.
[0143] The technical solution provided by this application displays a virtual object on the display screen of a folding device, and when it is detected that the display screen of the folding device is in a folded state, reads the folding angle of the folded display screen, and determines a first cross-sectional model corresponding to the folded display screen based on the folding angle of the folded display screen. When the wearable device is detected to be moving, the movement data of the wearable device is obtained, and based on the first cross-sectional model and the above movement data, second page information of the second intersection surface of the folded display screen and the virtual object is determined, and the second page information is determined as the cross-sectional information of the virtual object. This technical solution reduces the number of folding times of the display screen and extends the life of the display screen of the folding device by allowing the wearable device connected to the folding device to accurately cut the virtual object in combination with the folded display screen after the virtual object is cut by the folded display screen, thereby reducing the number of times the display screen is folded and extending the life of the display screen of the folding device.
[0144] 7 , which is a block diagram of an embodiment of a virtual object display device provided in an embodiment of the present application, as shown in FIG7 , the device may include a reading module 71 , a cutting module 72 , and a display module 73 .
[0145] The reading module 71 is used to read the spatial information of the display screen of the foldable device when a virtual object is displayed on the display screen.
[0146] The cutting module 72 is configured to cut the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object.
[0147] The display module 73 is configured to display the cross-sectional information via one or more display screens of the folding device.
[0148] As shown in Figure 8, an electronic device according to an embodiment of the present application is provided, which includes a processor 101, a communication interface 102, a memory 103, and a communication bus 104. The processor 101, the communication interface 102, and the memory 103 communicate with each other via the communication bus 104. The memory 103 is used to store computer programs.
[0149] In one embodiment of the present application, the processor 101, when executing the program stored in the memory 103, implements the AR object display method provided by any of the aforementioned method embodiments, including: when displaying a virtual object on a display screen of a folding device, reading the spatial information of the display screen; cutting the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object; and displaying the cross-sectional information through one or more display screens of the folding device.
[0150] An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by one or more processors, the steps of the virtual object display method provided in any of the aforementioned method embodiments are implemented.
[0151] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the modules may be selected based on actual needs to achieve the objectives of this embodiment.
[0152] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a general hardware platform, or of course, by hardware. Based on this understanding, the above technical solution, in essence, or the part that contributes to the relevant technology, can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or certain parts of the embodiment.
[0153] The terms used herein are for the purpose of describing specific example embodiments only and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "one", "an" and "said" as used herein may also be meant to include plural forms. The terms "comprise", "include", "contain" and "have" are inclusive and therefore specify the presence of stated features, steps, operations, elements and / or parts, but do not exclude the presence or addition of one or more other features, steps, operations, elements, parts, and / or combinations thereof. The method steps, processes, and operations described herein are not to be construed as necessarily requiring them to be performed in the specific order described or illustrated, unless the order of execution is clearly indicated. It should also be understood that additional or alternative steps may be used.
[0154] The foregoing is merely a list of specific embodiments of the present application, intended to enable those skilled in the art to understand or implement the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not limited to the embodiments shown herein, but is intended to conform to the broadest scope consistent with the principles and novel features of the present application.
Claims
1. A method for displaying a virtual object, wherein: The method comprises: In a case where a virtual object is displayed on a display screen of a foldable device, reading spatial information of the display screen; Cutting the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object; The cross-sectional information is displayed via one or more display screens of the foldable device.
2. The method according to claim 1, wherein: When it is detected that the display screen of the folding device is in a folded state, reading the spatial information of the display screen includes: Read the folding angle of the folded display; The step of cutting the virtual object according to the spatial information of the display screen to obtain cross-sectional information of the virtual object includes: Determining a first cross-sectional model corresponding to the folded display screen according to a folding angle of the folded display screen; Determining first page information of a first intersection surface between the folded display screen and the virtual object according to a first cross-sectional model of the folded display screen; The first page information is determined as the cross-section information of the virtual object.
3. The method according to claim 2, wherein: When a display screen of the folding device is folded, determining a first cross-sectional model corresponding to the folded display screen according to a folding angle of the folded display screen includes: Establishing a rectangular coordinate system based on the unfolded display screen; Determining first position information of the folded display screen according to the rectangular coordinate system and the folding angle; A first cross-sectional model corresponding to the folded display screen is determined according to the first position information.
4. The method according to claim 3, wherein: The step of determining first page information of a first intersection surface between the folded display screen and the virtual object according to the first cross-sectional model of the folded display screen: Determining second position information of the virtual object in the rectangular coordinate system; constructing a first three-dimensional model corresponding to the virtual object according to the second position information; First page information of a first intersection surface between the folded display screen and the virtual object is determined according to the first cross-sectional model and the first stereoscopic model.
5. The method according to claim 4, wherein: The determining, according to the first cross-sectional model and the first stereoscopic model, first page information of a first intersection surface between the folded display screen and the virtual object comprises: Determine a first expression of a first intersection surface between the folded display screen and the virtual object based on the first cross-sectional model and the first stereoscopic model; Determine, according to the first expression, a plurality of intersection points between the folded display screen and the virtual object; Determining first shape information of a first intersection surface between the folded display screen and the virtual object according to the plurality of intersection points; Removing a model surface corresponding to the first intersecting surface in the first three-dimensional model to obtain first plane structure information of the virtual object corresponding to the first intersecting surface; The first shape information and the first plane structure information are determined as first page information of the first intersection surface.
6. The method according to claim 2, wherein: The folding device is connected to a wearable device, and the virtual object is cut according to the spatial information of the display screen to obtain the cross-sectional information of the virtual object, including: When the wearable device is detected to be moving, obtaining movement data of the wearable device; Determining second page information of a second intersection surface between the folded display screen and the virtual object according to the first cross-sectional model and the movement data; The second page information is determined as the cross-section information of the virtual object.
7. The method according to claim 6, wherein: The determining, according to the first cross-sectional model and the movement data, second page information of a second intersection surface between the folded display screen and the virtual object comprises: Determining a second three-dimensional model corresponding to the virtual object according to the movement data; Determine a second expression of a second intersection surface between the folded display screen and the virtual object based on the first cross-sectional model and the second three-dimensional model; According to the second expression, determining a plurality of intersection points between the folded display screen and the virtual object; Determining second shape information of a second intersection surface between the folded display screen and the virtual object according to the plurality of intersection points; Removing the model surface corresponding to the second intersecting surface in the second three-dimensional model to obtain second plane structure information of the virtual object corresponding to the second intersecting surface; The second shape information and the second plane structure information are determined as second page information of the second intersection surface.
8. The method according to claim 7, wherein: When a display screen of the folding device is folded, determining a second three-dimensional model corresponding to the virtual object according to the movement data includes: Establishing a rectangular coordinate system based on the unfolded display screen; determining third position information of the virtual object in the rectangular coordinate system before the virtual object moves; A second three-dimensional model corresponding to the virtual object is constructed according to the third position information and the movement data.
9. The method according to claim 5 or 7, wherein: Before displaying the cross-sectional information on one or more display screens of the folding device, the method further includes: Obtaining application information corresponding to the folding device; mapping the application information onto the virtual object; The displaying of the cross-sectional information by one or more display screens of the folding device comprises: One or more of the following is displayed through the folded display screen of the folding device: the internal structure of the virtual object, the page information of the cut virtual object, and the application information of the folding device, wherein the internal structure includes the first plane structure information or the second plane structure information, and the page information includes the first shape information or the second shape information.
10. An electronic device, comprising: One or more memories and one or more processors, wherein the one or more processors are used to execute a virtual object display program stored in the one or more memories to implement the virtual object display method according to any one of claims 1 to 9.
11. A storage medium, wherein: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the virtual object display method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Virtual object control method and device, electronic equipment and storage medium
CN109806589A
Display control method, electronic equipment and computer readable storage medium
CN110721467A
Content presentation method and device, terminal equipment and computer readable storage medium
CN111338737A
Content presentation method and device, terminal equipment and computer readable storage medium
CN114816617A