Virtual item display method, device, electronic device and storage medium
By combining augmented reality technology and computer vision in the instant messaging client, dynamic display and interaction of virtual items is achieved, and the problem of single display of virtual items is solved, which improves the fun and interactiveness of the user experience.
Patent Information
- Application Number
- CN202010439631.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-05-22
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2040-05-22
AI Technical Summary
In the prior art, the display method of virtual items lacks the combination with augmented reality technology, resulting in insufficient user interaction and fun.
By displaying augmented reality scene display controls in the user operation page of the instant messaging client, an augmented reality page is displayed when an operation is detected, and the target virtual items are displayed in the augmented reality screen based on the item display operation. Combining computer vision and augmented reality technology, dynamic display and interaction of virtual items are achieved.
It enriches the display method of virtual items, expands the interaction between users and virtual items, and increases the fun and interactive nature of virtual items.
Smart Images

Figure CN111643899B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence, and specifically to a method, device, electronic device, and storage medium for displaying virtual items. Background Art
[0002] With the development of internet technology, more and more people are communicating online. To enhance fun and user interaction, many applications now offer the ability to send and purchase virtual items. Specifically, these virtual items can be virtual gifts. In some scenarios, such as around holidays, users can exchange virtual gifts as a way of expressing their wishes. Virtual items received by users or purchased from the gift store can be displayed on a gift collection page. Summary of the Invention
[0003] The embodiments of the present application provide a method, device, electronic device, and storage medium for displaying virtual items, which can realize the combination of the display of virtual items and augmented reality technology.
[0004] The present invention provides a method for displaying virtual items, including:
[0005] Displaying a user operation page of the instant messaging client, the user operation page including: an augmented reality scene display control;
[0006] When an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, wherein the augmented reality page includes an augmented reality picture corresponding to the real object display scene;
[0007] Based on the item display operation on the augmented reality page, a target virtual item is displayed in the item display area in the augmented reality screen.
[0008] Accordingly, an embodiment of the present application provides a virtual item display device, comprising:
[0009] A first display unit is configured to display a user operation page of the instant messaging client, wherein the user operation page includes: an augmented reality scene display control;
[0010] A second display unit is configured to display an augmented reality page when an operation on the augmented reality scene display control is detected, wherein the augmented reality page includes an augmented reality picture corresponding to the real object display scene;
[0011] The third display unit is configured to display a target virtual object in the object display area of the augmented reality screen based on the object display operation on the augmented reality page.
[0012] Optionally, in some embodiments of the present application, the augmented reality page includes an item display control; the third display unit can be specifically used to display the target virtual item in the item display area in the augmented reality screen when an operation on the item display control is detected.
[0013] Optionally, in some embodiments of the present application, the augmented reality page also includes a target virtual item to be displayed; the third display unit can be specifically used to display the target virtual item in the item display area in the augmented reality screen based on a movement operation on the target virtual item.
[0014] Optionally, in some embodiments of the present application, the third display unit may include a first rotating subunit and a first display subunit, as follows:
[0015] The first rotation subunit is configured to trigger the target virtual object to rotate to a corresponding angle in the augmented reality screen based on a rotation operation on the target virtual object, wherein the angle corresponds to the rotation operation;
[0016] The first display subunit is configured to display the rotated target virtual object in an object display area in the augmented reality screen based on a movement operation on the rotated target virtual object.
[0017] Optionally, in some embodiments of the present application, the third display unit may further include a second rotation subunit; the second rotation subunit may be configured to rotate a target virtual item displayed within an item display area in the augmented reality screen. Specifically, the second rotation subunit is configured to trigger, based on a rotation operation performed on the target virtual item, the rotation of the target virtual item within the item display area in the augmented reality screen by a corresponding angle, wherein the angle corresponds to the rotation operation.
[0018] Optionally, in some embodiments of the present application, the augmented reality page further includes an item adding control; the third display unit may further include a second display subunit and a third display subunit, as follows:
[0019] The second display subunit is configured to display a virtual item list on the augmented reality page when an operation of adding a control to an item on the augmented reality page is detected, wherein the virtual item list includes at least one virtual item to be displayed;
[0020] The third display subunit is configured to display a target virtual item selected from the virtual items to be displayed on the augmented reality page based on a selection operation on the virtual item list.
[0021] Optionally, in some embodiments of the present application, the virtual item display device may further include a scaling unit as follows:
[0022] The scaling unit is configured to determine a scaling factor based on a scaling operation on the augmented reality picture; and display the scaled augmented reality picture based on the scaling factor.
[0023] Optionally, in some embodiments of the present application, the augmented reality screen includes at least one item display area, and the item display area displays a motion effect prompting the display of items.
[0024] Optionally, in some embodiments of the present application, the augmented reality page further includes an item display control; the third display unit may include a first determining subunit, a second determining subunit, a third determining subunit, and a fourth display subunit, as follows:
[0025] The first determining subunit is used to determine the target virtual item to be displayed;
[0026] a second determining subunit, configured to determine position information of a target touch point when a touch operation on the augmented reality page is detected;
[0027] a third determining subunit, configured to determine an item display area for displaying the target virtual item according to the position information of the target touch point;
[0028] The fourth display subunit is configured to display a target virtual object in the object display area in the augmented reality screen when an operation on the object display control is detected.
[0029] Optionally, in some embodiments of the present application, the second determination subunit can be specifically used to obtain the touch time of the touch point corresponding to each touch operation when multiple touch operations on the augmented reality page are detected; based on the touch time, determine the target touch point from the multiple touch points, and determine the position information of the target touch point.
[0030] Optionally, in some embodiments of the present application, the third display unit may further include a fourth determination subunit and a fifth display subunit, including:
[0031] The fourth determining subunit is configured to determine, when a touch operation on the augmented reality page is detected, a new item display area on the augmented reality page for displaying the target virtual item;
[0032] The fifth display subunit is configured to display the target virtual object in the new object display area in the augmented reality screen when an operation on the object display control is detected.
[0033] Optionally, in some embodiments of the present application, the position information includes two-dimensional coordinate information; the third determination subunit may specifically include converting the two-dimensional coordinate information of the target touch point into three-dimensional coordinate information, and establishing a three-dimensional virtual scene model corresponding to the augmented reality page based on the three-dimensional coordinate information; based on the three-dimensional coordinate information of the target touch point, forming a ray in the three-dimensional space corresponding to the three-dimensional virtual scene model; obtaining the coordinates of the intersection position of the ray and the three-dimensional virtual scene model; and determining the item display area for displaying the target virtual item based on the coordinates of the intersection position.
[0034] Optionally, in some embodiments of the present application, the virtual item display device may further include a fourth display unit, a collection unit, and a generation unit, as follows:
[0035] The fourth display unit is configured to display a creation page for an augmented reality page, wherein the creation page includes a creation control for the augmented reality page;
[0036] a collection unit, configured to collect an augmented reality image corresponding to the real object display scene when a triggering operation on the creation control is detected;
[0037] A generating unit is configured to generate an augmented reality page based on the augmented reality picture corresponding to the real object display scene.
[0038] An electronic device provided in an embodiment of the present application includes a processor and a memory, wherein the memory stores a plurality of instructions, and the processor loads the instructions to execute the steps in the virtual item display method provided in the embodiment of the present application.
[0039] In addition, an embodiment of the present application further provides a storage medium on which a computer program is stored, wherein when the computer program is executed by a processor, the steps of the virtual item display method provided in the embodiment of the present application are implemented.
[0040] Embodiments of the present application provide a method, apparatus, electronic device, and storage medium for displaying virtual items. These methods can display a user operation page for an instant messaging client, the user operation page including an augmented reality scene display control. Upon detecting an operation on the augmented reality scene display control, an augmented reality page is displayed, the augmented reality page including an augmented reality screen corresponding to a real-world item display scene. Based on an item display operation on the augmented reality page, a target virtual item is displayed within an item display area on the augmented reality screen. This application can achieve a combination of virtual item display and augmented reality technology. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0042] Figure 1a Schematic diagram of a scenario of a method for displaying virtual items provided in an embodiment of the present application;
[0043] Figure 1b is a flowchart of a method for displaying virtual items provided in an embodiment of the present application;
[0044] Figure 1c Schematic diagram of the interface of the virtual item display method provided in the embodiment of the present application;
[0045] Figure 1d This is another interface diagram of the virtual item display method provided by an embodiment of the present application;
[0046] Figure 1e is another flow chart of the virtual item display method provided in an embodiment of the present application;
[0047] Figure 1f This is another interface diagram of the virtual item display method provided by an embodiment of the present application;
[0048] Figure 1g This is another interface diagram of the virtual item display method provided by an embodiment of the present application;
[0049] Figure 1h This is another interface diagram of the virtual item display method provided by an embodiment of the present application;
[0050] Figure 2a is another flow chart of the virtual item display method provided in an embodiment of the present application;
[0051] Figure 2b is another flow chart of the virtual item display method provided in an embodiment of the present application;
[0052] Figure 3a is a structural diagram of a virtual item display device provided in an embodiment of the present application;
[0053] Figure 3b is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0054] Figure 3c is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0055] Figure 3dis another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0056] Figure 3e is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0057] Figure 3f is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0058] Figure 3g is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0059] Figure 3h is another structural diagram of the virtual item display device provided in an embodiment of the present application;
[0060] Figure 4 It is a structural diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0061] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without making creative efforts are within the scope of protection of this application.
[0062] Embodiments of the present application provide a method, apparatus, electronic device, and storage medium for displaying virtual items. Specifically, embodiments of the present application provide a virtual item display apparatus suitable for an electronic device, which may be a terminal device such as a mobile phone, tablet computer, laptop computer, or personal computer (PC).
[0063] It is understandable that the virtual item display method of this embodiment can be executed on the terminal, or can be executed jointly by the terminal and the server. The above examples should not be understood as limiting the present application.
[0064] refer to Figure 1a Taking the electronic device as a terminal as an example, the system for displaying virtual items provided in the embodiment of the present application includes a terminal 10 and a server 11, etc.; the terminal 10 and the server 11 are connected via a network, such as a wired or wireless network connection, etc., wherein the virtual item display device is integrated into the terminal, for example, integrated into the terminal 10 in the form of a client, and the client can be an application client, etc.
[0065] Terminal 10 can be configured to: display a user operation page of an instant messaging client, the user operation page including an augmented reality scene display control; upon detecting an operation on the augmented reality scene display control, display an augmented reality page including an augmented reality screen corresponding to a real object display scene; and based on an object display operation on the augmented reality page, terminal 10 can display a target virtual object within an object display area of the augmented reality screen. Terminal 10 can include a mobile phone, tablet computer, laptop computer, or personal computer (PC).
[0066] Among them, based on the item display operation on the augmented reality page, the terminal 10 can send a request to the server 11 to obtain the target virtual screen data, then receive the target virtual screen data sent by the server 11, and based on the target virtual screen data, display the target virtual item in the item display area in the augmented reality screen.
[0067] The server 11 may be configured to, upon receiving a request from the terminal 10 for obtaining target virtual screen data, obtain the target virtual screen data based on an item display operation on the augmented reality page, and then send the target virtual screen data to the terminal 10. The server 11 may be a single server or a server cluster consisting of multiple servers.
[0068] The step of the server 11 acquiring the target virtual screen data may also be executed by the terminal 10 .
[0069] The virtual item display method provided in the embodiments of this application relates to computer vision (CV) in the field of artificial intelligence (AI), and more specifically to the field of augmented reality (AR) within computer vision. The embodiments of this application can combine the display of virtual items with augmented reality technology, thereby enriching the display methods of virtual items, expanding the forms of interaction between users and virtual items, and increasing the fun of virtual items.
[0070] Artificial Intelligence (AI) refers to the theories, methods, techniques, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, to perceive the environment, acquire knowledge, and use that knowledge to achieve optimal results. In other words, AI is a comprehensive field within computer science that seeks to understand the essence of intelligence and produce new intelligent machines that can respond in a manner similar to human intelligence. AI also studies the design principles and implementation methods of various intelligent machines, enabling them to possess the capabilities of perception, reasoning, and decision-making. AI technology is an interdisciplinary discipline encompassing a wide range of fields, encompassing both hardware and software technologies. Foundational AI technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, speech processing, natural language processing, and machine learning / deep learning.
[0071] Computer vision (CV) is the science of making machines "see." Specifically, it refers to the use of computers to identify and measure objects, replacing the human eye. Image processing is then performed to make the image more suitable for human observation or transmission to instrumentation. As a scientific discipline, computer vision studies related theories and technologies, aiming to build artificial intelligence systems capable of extracting information from images or multidimensional data. Computer vision technology typically includes image processing, image recognition, 3D object reconstruction, virtual reality, augmented reality, and other technologies. It also includes common biometric recognition techniques such as facial recognition and human posture recognition.
[0072] Among them, augmented reality (AR) technology is a technology that cleverly integrates virtual information with real scenes. It widely uses various technical means such as multimedia, three-dimensional modeling, real-time detection and registration, intelligent interaction, and sensing. It simulates computer-generated virtual information such as text, images, three-dimensional models, music, and videos, and applies them to real scenes, thereby achieving "enhancement" of the real scenes.
[0073] It should be noted that the order of description of the following embodiments is not intended to limit the preferred order of the embodiments.
[0074] The embodiment of the present application will be described by taking the virtual item display method executed by a terminal as an example, specifically, by a virtual item display device integrated in the terminal.
[0075] The virtual item display method of the embodiment of the present application can be applied to various types of applications, such as instant messaging applications. When an operation on the augmented reality scene display control is detected, the augmented reality page is displayed, and based on the item display operation on the augmented reality page, the target virtual item is displayed in the item display area of the augmented reality screen.
[0076] like Figure 1b As shown, the specific process of the virtual item display method is as follows:
[0077] 101. Display a user operation page of an instant messaging client, where the user operation page includes an augmented reality scene display control.
[0078] The virtual item display device is integrated into the terminal, specifically in the form of a client, which may be an instant messaging client.
[0079] The user operation page may be a chat page of an instant messaging client, which includes an augmented reality scene display control. By operating the augmented reality scene display control, the user can jump from the chat page to the augmented reality page, which may be an augmented reality screen of a virtual item. In some embodiments, a virtual item can be selected from the augmented reality page and displayed on the chat page. The display mode may be dynamic or static. In addition, the virtual item can be gifted to the chat partner.
[0080] In some embodiments, the user operation page may also be a virtual item purchase page, which may specifically display a gift mall, where users can purchase virtual items from the gift mall and give them to their friends. Figure 1c On page A, users can navigate from the current purchase page to the augmented reality page by operating the augmented reality scene display control in the upper right corner of the purchase page. In some embodiments, users can also select virtual items from the augmented reality page and give them to friends. Specifically, the virtual items can be virtual gifts.
[0081] In some embodiments, the user operation page can also be the user's gift-giving friend page, and the gift-giving friend page can specifically display the virtual gifts given by friends. Figure 1c As shown in page B, by operating the augmented reality scene display control in the upper right corner of the gift-giving friend page, you can jump from the current gift-giving friend page to the augmented reality page. Optionally, the augmented reality page can also display virtual gifts given by friends to be placed, and based on the operation of the virtual gift, the virtual gift is placed in the item display area of the augmented reality page.
[0082] In some embodiments, the user operation page may also be the user's gift collection page. Figure 1c As shown in page C, the gift collection page can display the virtual items received, given and owned by the user. The user can also view the virtual items that are not directly displayed on the gift collection page, that is, hidden virtual items, by operating the view hidden gift control. The control in the upper right corner of the gift collection page is the augmented reality scene display control. By operating the augmented reality scene display control, you can jump from the gift collection page to the augmented reality page.
[0083] It should be noted that this embodiment does not impose any specific restrictions on the user operation page, and the above examples should not be understood as limitations thereto.
[0084] 102. When an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, where the augmented reality page includes an augmented reality screen corresponding to the real object display scene.
[0085] The operation on the augmented reality scene display control may be a click operation, a sliding operation, or the like. When the operation on the augmented reality scene display control is detected, the augmented reality page is displayed. The augmented reality screen may be an augmented reality screen that is a combination of a virtual scene screen corresponding to a real scene and a virtual scene screen corresponding to a virtual scene. The real scene may be a real object display scene with the real scene as the background screen. The virtual scene may be a virtual scene composed of virtual objects. The virtual scene screen corresponding to the virtual scene may be generated based on the multi-dimensional screen data corresponding to the virtual object. What is displayed on the augmented reality screen is a virtual collection room of virtual objects, which is used to display virtual objects. Specifically, the virtual objects may be virtual gifts.
[0086] In some embodiments, the augmented reality page may not include virtual items, that is, no virtual items have been placed on the augmented reality page.
[0087] The virtual scene image corresponding to the real scene can be obtained in a variety of ways. For example, the image information of the real scene can be obtained by capturing the real scene through an image acquisition device. By processing the image information of the real scene, a virtual scene image corresponding to the real scene is generated. The virtual scene image is an image captured by the image acquisition device. The image acquisition device can be a camera, etc. For another example, a picture of a real scene can be selected from a local database as the virtual scene image corresponding to the real scene of this embodiment. Alternatively, the virtual item display device can also receive a picture of a real scene sent by other devices and use it as the virtual scene image corresponding to the real scene of this embodiment.
[0088] Among them, augmented reality refers to computer technology that uses the position and angle of camera images and image analysis technology to enable virtual scenes on the screen to be combined and interact with real scenes in reality.
[0089] Optionally, in this embodiment, the virtual item display method may further include:
[0090] Displaying a creation page for an augmented reality page, the creation page including a creation control for the augmented reality page;
[0091] When a trigger operation on the creation control is detected, an augmented reality image corresponding to the real object display scene is captured;
[0092] An augmented reality page is generated based on the augmented reality picture corresponding to the real object display scene.
[0093] Among them, the creation page can be the same page as the user operation page in step 101, or it can be a different page. If it is the same page, the user operation page, that is, the creation page, can include an augmented reality scene display control and a creation control. In some embodiments, the augmented reality scene display control and the creation control can be the same control, then the control is a multifunctional control that can both create an augmented reality page and display an augmented reality page. In the case where the augmented reality page has been created, the augmented reality page is displayed by operating the control; in the case where the augmented reality page has not been created, the augmented reality screen corresponding to the real object display scene can be collected by operating the control to create an augmented reality page.
[0094] Optionally, the augmented reality page may include a control for recreating the augmented reality screen. Based on the operation of the control for recreating the augmented reality screen, the augmented reality screen corresponding to the real object display scene can be re-collected, and the original augmented reality screen can be removed. The re-collected virtual scene screen corresponding to the real object display scene can be used as the background screen to create a new collection room for virtual objects.
[0095] Optionally, the augmented reality page may include a virtual item display control and an item deletion control. The item display control allows virtual items to be placed in the augmented reality screen, and the item deletion control allows virtual items to be removed from the augmented reality screen. Based on operations on the item display control and the item deletion control, the virtual items in the augmented reality screen can be adjusted.
[0096] Optionally, in some embodiments, the real object display scene does not include a platform for displaying real objects, and correspondingly, the virtual scene screen corresponding to the real object display scene does not include a platform for displaying virtual objects. In this case, a platform for displaying virtual objects can be constructed using virtual objects, wherein the virtual objects include a virtual display platform, which can be a virtual table, shelf, and chair, etc. The virtual display platform can be a virtual object owned by the user, which can be obtained through purchase or gift from friends, etc. The virtual display platform can also be a system pre-set for displaying virtual objects. Specifically, the augmented reality page can include a virtual display platform control, and based on the operation of the virtual display platform control, the corresponding virtual display platform can be added to the augmented reality screen. Figure 1d As shown in pages E and F of the , there are three virtual display platform controls on the right side of the augmented reality page. Different control icons represent different virtual display platforms. By operating the virtual display platform controls, you can add corresponding virtual display platforms to the augmented reality page for displaying virtual items.
[0097] For example, Figure 1d As shown, users can use the My Gifts page (see Figure 1d Click the Create Control icon in the upper right corner of Page D (i.e., Create Page) to enter the initial page (see Figure 1d On the right side of the initial page, there are three icons of virtual display platform controls. Users can click on the three icons on the right side, select their favorite items and place them, and then create an augmented reality page that suits their preferences (see Figure 1d Page F) of the augmented reality page displays a collection room of virtual items, which can specifically be virtual gifts. If the captured background image includes a display platform, the virtual display platform controls do not need to be operated. In some embodiments, the initial page may include an item addition control for adding virtual gifts to the page. By placing the virtual gifts on the display platform, a collection room that suits your preferences can be created and saved. In other embodiments, after saving the created augmented reality page, a virtual gift can be placed in the item display area of the augmented reality screen before saving.
[0098] In this embodiment, ARKit (Augmented Reality Kit) can be used to implement AR display and interaction with gifts. Specifically, ARKit (Augmented Reality Kit) is an AR development platform. Specifically, collection room objects can be pre-set, and the user can select the desired collection room object, such as a table or shelf. After the user selects the collection room object, the virtual item display system will download the corresponding three-dimensional (3D) data in the background. ARKit then renders the 3D model on the client, giving the user a preview.
[0099] like Figure 1e As shown, after the user clicks the Collection Room button (i.e., clicks the Create control), he / she will enter the initial augmented reality page, and can turn on the camera to obtain the virtual scene image corresponding to the current real scene in real time and use it as the background image; the user selects the favorite collection room object, downloads the 3D data of the collection room object from the background, and draws the 3D model through ARKit. When it is detected that the user clicks the Save control to create the collection room, the collection room data is uploaded to the background for saving, and the collection room creation process is completed.
[0100] 103. Based on the item display operation on the augmented reality page, display a target virtual item in an item display area in the augmented reality screen.
[0101] The item display operation refers to placing the target virtual item into the item display area in the augmented reality screen. The item display area is the area where the target virtual item is placed. Specifically, it can refer to a certain area of the virtual display platform in the augmented reality screen.
[0102] Optionally, in some embodiments, the augmented reality page includes an item display control; the step of “displaying a target virtual item in an item display area in the augmented reality screen based on an item display operation on the augmented reality page” may include:
[0103] When an operation on the item display control is detected, a target virtual item is displayed in the item display area in the augmented reality screen.
[0104] The operation on the item display control may be a click operation, a long press operation, or a slide operation on the item display control. When the operation on the item display control is detected, the target virtual item is placed in the item display area in the augmented reality screen.
[0105] In some embodiments, the item display area can be pre-set by the system for displaying virtual items. When a user's operation on the item display control is detected, the augmented reality page switches to display an augmented reality image of the target virtual item displayed in the pre-set item display area. Optionally, the item display area can also display an animation prompting the display of the item. The type of animation is not limited, for example, it can be a luminous animation effect. Figure 1f As shown, the dotted frustum represents a luminous item display area. When an operation on the item display control is detected, a target virtual item is displayed in the luminous item display area.
[0106] Among them, there may be multiple item display areas pre-set by the system for displaying virtual items, and each item display area has a different priority, wherein the priority can be determined based on the location of each item display area and whether a virtual item has been placed in the item display area. Optionally, based on the priority of the item display area, a target item display area can be determined, and the target virtual item can be displayed in the target item display area in the augmented reality screen. Specifically, when an operation on the item display control is detected, the target virtual item is placed in the item display area with the highest priority in the augmented reality screen. When another operation on the item display control is detected, the target virtual item is placed in the item display area with the second priority in the augmented reality screen, and so on.
[0107] In other embodiments, the item display area may also be determined by the user. The item display area for displaying the target virtual item may be determined based on the user's touch operation on the augmented reality page.
[0108] Optionally, in some embodiments, the augmented reality page further includes a target virtual item to be displayed; and the step of “displaying the target virtual item in the item display area in the augmented reality screen based on the item display operation on the augmented reality page” may include:
[0109] Based on the movement operation on the target virtual item, the target virtual item is displayed in the item display area in the augmented reality screen.
[0110] Optionally, the augmented reality page may display an item display area with an animated effect indicating the displayed items, and the user may move the target virtual item to the item display area according to the prompt information on the augmented reality page. In some embodiments, the augmented reality page may have multiple item display areas with animated effects indicating the displayed items, and the user may select a target item display area and move the target virtual item to the target item display area.
[0111] Optionally, in some embodiments, before the step of “displaying the target virtual item in the item display area in the augmented reality screen based on the movement operation on the target virtual item”, the following steps may also be included:
[0112] Based on the rotation operation on the target virtual object, triggering the target virtual object to rotate to a corresponding angle in the augmented reality screen, wherein the angle corresponds to the rotation operation;
[0113] The step of “displaying the target virtual item in the item display area in the augmented reality screen based on the movement operation on the target virtual item” may include:
[0114] Based on the movement operation on the rotated target virtual object, the rotated target virtual object is displayed in the object display area in the augmented reality screen.
[0115] Among them, the rotation operation of the target virtual object can be set according to the actual situation. For example, the rotation operation can specifically be a left or right slide of the target virtual object on the screen. It should be noted that the above examples should not be understood as limitations on this application. For example, the target virtual object can be rotated to a corresponding angle by sliding the screen left or right with your finger. Among them, the correspondence between the rotation operation (specifically the size of the sliding amplitude) and the rotation angle of the target virtual object can be set according to actual needs. For example, it can be set to: the finger slides 10 pixels (px, pixel) from left to right, corresponding to rotating the model (target virtual object) counterclockwise around the Z axis by 1 degree. Conversely, the finger slides 10 pixels from right to left, corresponding to rotating the model clockwise around the Z axis by 1 degree. The Z axis represents the direction vertical to the augmented reality page. Based on the rotation operation of the target virtual object, the target virtual object is triggered to rotate the corresponding angle in the augmented reality screen, and the rotated target virtual object is displayed in the augmented reality screen.
[0116] Optionally, in some embodiments, after the step of “displaying the target virtual item in the item display area in the augmented reality screen based on the item display operation on the augmented reality page”, the following steps may also be performed:
[0117] Based on the rotation operation on the target virtual object, the target virtual object is triggered to rotate a corresponding angle in the object display area in the augmented reality screen, wherein the angle corresponds to the rotation operation.
[0118] In some embodiments, the augmented reality page may further include a rotation control, and the target virtual object may be rotated based on the operation of the rotation control. Specifically, the rotation control may include settings for a rotation direction and a rotation angle.
[0119] It should be noted that the rotation operation of the target virtual object can be performed before or after the object display operation, and this embodiment does not limit this.
[0120] Optionally, in some embodiments, the augmented reality page further includes an item adding control; and before the step of “displaying the target virtual item in the item display area in the augmented reality screen based on the item display operation on the augmented reality page,” the following steps may also be included:
[0121] When an operation of adding a control to an item on the augmented reality page is detected, displaying a virtual item list on the augmented reality page, the virtual item list including at least one virtual item to be displayed;
[0122] Based on a selection operation on the virtual item list, a target virtual item selected from the virtual items to be displayed is displayed on the augmented reality page.
[0123] The operation of adding an item to the control may be a click operation or a slide operation on the control, which is not limited in this embodiment. The operation of selecting a virtual item from the virtual item list may be to select a virtual item from the virtual item list and use it as the target virtual item.
[0124] Optionally, in this embodiment, the virtual item display method may further include:
[0125] Determining a zoom factor based on a zoom operation on the augmented reality image;
[0126] Based on the zoom factor, a zoomed augmented reality image is displayed.
[0127] Among them, the zoom operation of the augmented reality screen can be set according to actual conditions. For example, it can be set to: open or contract two fingers on the screen (i.e., on the augmented reality screen) to enlarge or reduce the model. The model can specifically refer to a virtual object, and also refer to the augmented reality screen. Specifically, the zoom factor can be determined according to the degree of opening or contraction. Among them, when a zoom operation is performed on a virtual object in the augmented reality screen, that is, when the user opens or contracts the position of a virtual object on the screen with his fingers, the augmented reality screen can be zoomed with the virtual object as the center, and the zoomed augmented reality screen is displayed.
[0128] In some embodiments, Figure 1dAs shown in page F of the augmented reality page, you can also zoom in or out on the virtual item or augmented reality screen by clicking the gesture icon in the upper right corner of the augmented reality page. Specifically, you can set a single click on the gesture icon to zoom in, and double click on the gesture icon to zoom out. It should be understood that the above examples should not be construed as limitations on this application. The zoom in and zoom out operations can be set according to actual circumstances, and this application does not impose any restrictions on this. For example, when a user selects a virtual item, they can zoom in on the virtual item by clicking the gesture icon to observe and adjust the virtual item.
[0129] Optionally, in this embodiment, the augmented reality screen includes at least one item display area, and the item display area displays a motion effect prompting the display of items.
[0130] The augmented reality screen may have one or more item display areas, and the item display areas may display dynamic effects that prompt items to be displayed, such as using a luminous dynamic effect to prompt the user that the area can display items. Figure 1f Page G, where the dotted frustum represents a glowing item display area. The user can place the target virtual item in the glowing item display area by operating the item display control or by moving the target virtual item (gift 8). Figure 1f Page I. Through the prompt effect, users can more quickly determine the placement area. Optional, such as Figure 1f As shown on page H of the , before placing the target virtual item in the illuminated item display area, the target virtual item can also be scaled and rotated, and then the adjusted target virtual item can be placed in the illuminated item display area. In some embodiments, the target virtual item can be directly placed in the illuminated item display area by operating the gift placement control. Figure 1f The shadow of the virtual gift in the figure may indicate that the virtual gift is displayed in three dimensions in the augmented reality page.
[0131] In this embodiment, after the virtual items are successfully placed, the augmented reality screen (i.e., the collection room) after placement can be shared. Figure 1g As shown, you can share the augmented reality screen with others by operating the "Show Collection Room" control. In addition, after successfully placing the virtual objects, if you are not satisfied with the placement effect, you can also rearrange the virtual objects, such as Figure 1g As shown, you can remove the placed virtual objects from the augmented reality screen by operating the "replace" control, and then re-place the virtual objects in the augmented reality page.
[0132] Optionally, in some embodiments, the augmented reality page further includes an item display control; and the step of “displaying a target virtual item in an item display area in the augmented reality screen based on an item display operation on the augmented reality page” may include:
[0133] Determining target virtual items to be displayed;
[0134] When a touch operation on the augmented reality page is detected, determining position information of a target touch point;
[0135] determining an item display area for displaying the target virtual item according to the position information of the target touch point;
[0136] When an operation on the item display control is detected, a target virtual item is displayed in the item display area in the augmented reality screen.
[0137] The virtual item to be displayed can be directly displayed on the augmented reality page; or the augmented reality page includes an item addition control, and based on the operation of the item addition control, a virtual item list can be displayed on the augmented reality page, and the virtual item list includes at least one virtual item to be displayed. If there is only one virtual item to be displayed, the virtual item display device can directly select it as the target virtual item. If there are multiple virtual items to be displayed, a selection operation can be performed to select one of the virtual items to be displayed as the target virtual item.
[0138] Optionally, in some embodiments, the step of “determining the location information of the target touch point when a touch operation on the augmented reality page is detected” may include:
[0139] When multiple touch operations on the augmented reality page are detected, acquiring the touch time of the touch point corresponding to each touch operation;
[0140] Based on the touch time, a target touch point is determined from the multiple touch points, and position information of the target touch point is determined.
[0141] Among them, when the user touches the display screen (i.e., the augmented reality screen) multiple times, the touch point with the latest touch time can be determined, that is, the touch point corresponding to the last touch operation, and the touch point can be used as the target touch point. Based on the position information of the target touch point, the item display area for displaying the target virtual item can be determined.
[0142] Optionally, in some embodiments, after the step of “when an operation on the item display control is detected, displaying the target virtual item in the item display area in the augmented reality screen”, the following steps may also be included:
[0143] When a touch operation on the augmented reality page is detected, determining a new item display area on the augmented reality page for displaying the target virtual item;
[0144] When an operation on the item display control is detected, the target virtual item is displayed in a new item display area in the augmented reality screen.
[0145] Among them, after the user places the target virtual item in the item display area of the augmented reality screen, if the user is not satisfied with the display position or needs to change the item display area of the target virtual item, the user can re-determine the new item display area for displaying the target virtual item based on the touch operation of the augmented reality screen, and then place the target virtual item in the new item display area. It should be noted that the above process of changing the item display area of the target virtual item can be performed multiple times, that is, the item display area of the target virtual item can be changed multiple times. Based on the above method, the display effect of the target virtual item can be displayed in different item display areas. The user can more conveniently select the item display area that he or she is satisfied with by comparing the display effects of different item display areas multiple times.
[0146] Specifically, the position information may include two-dimensional coordinate information; and the step of “determining an item display area for displaying the target virtual item based on the position information of the target touch point” may include:
[0147] Converting the two-dimensional coordinate information of the target touch point into three-dimensional coordinate information, and establishing a three-dimensional virtual scene model corresponding to the augmented reality page based on the three-dimensional coordinate information;
[0148] Based on the three-dimensional coordinate information of the target touch point, forming a ray in the three-dimensional space corresponding to the three-dimensional virtual scene model;
[0149] Obtaining the coordinates of the intersection position of the ray and the three-dimensional virtual scene model;
[0150] An item display area for displaying the target virtual item is determined based on the coordinates of the intersection position.
[0151] The display area for displaying the target virtual item can be determined by simulating a ray. Specifically, the simulated ray refers to emitting a ray in the direction of an image acquisition device (such as a camera) based on the touch point corresponding to the touch operation on the display screen (i.e., the augmented reality page), with the touch point as the ray origin. The ray is then extended and intersected with objects in the three-dimensional virtual scene model, and the coordinates of the intersection position are calculated.
[0152] Optionally, based on the coordinates of the intersection position, an item display area for displaying the target virtual item may be determined with the coordinates as the center.
[0153] Currently, relevant technologies such as Figure 1h As shown, virtual gifts are limited to two-dimensional display, the gameplay is relatively simple, and the interaction between users and virtual gifts is relatively low. This application can use AR technology to allow users to independently create a virtual collection room and place virtual gifts in the virtual collection room. It can also use AR technology to realize the display of three-dimensional virtual gifts, improve the playability of virtual gifts, thereby enhancing the interactivity between gifts and users and between users, and making the whole process more scene-based.
[0154] As can be seen from the above, this embodiment can display a user operation page of an instant messaging client, the user operation page including an augmented reality scene display control; when an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, the augmented reality page including an augmented reality screen corresponding to a real object display scene; based on an object display operation on the augmented reality page, a target virtual object is displayed in an object display area on the augmented reality screen. This application can realize the combination of virtual object display and augmented reality technology.
[0155] According to the method described in the previous embodiment, the following will be further described in detail by taking the example of the virtual item display device being specifically integrated into a terminal.
[0156] like Figure 2a As shown, the virtual item display method provided in the embodiment of the present application is specifically described through the following embodiments:
[0157] 201. The terminal displays a user operation page of an instant messaging client, where the user operation page includes an augmented reality scene display control.
[0158] In this embodiment, the user operation page can specifically be a gift mall and a gift-giving friend page, such as Figure 1c As shown, in the upper right corner of the Gift Mall and Gift to Friends pages, there is an icon that switches to the augmented reality page. This icon is the augmented reality scene display control. Users can enter the virtual collection room they created by clicking the augmented reality scene display control.
[0159] 202. When an operation on the augmented reality scene display control is detected, the terminal displays an augmented reality page, where the augmented reality page includes an augmented reality picture corresponding to the real object display scene.
[0160] 203. Based on the item display operation on the augmented reality page, the terminal displays the target virtual item in the item display area in the augmented reality screen.
[0161] In this embodiment, the augmented reality page displays a user-created virtual collection room. After entering the collection room, the user can arrange and view the virtual gifts within. Operations involved include selecting a model, selecting a position, rotating, and scaling the model. Models refer to virtual items, which specifically include virtual gifts and collection shelves. Collection shelves are virtual display platforms.
[0162] Among them, the selection of the model is mainly achieved by simulating rays, that is, the user can click on the point on the screen to send a ray in the direction of the camera, and calculate the first model that the ray collides with in the three-dimensional virtual scene model, which is the model selected by the user. The selection of the position is also achieved by simulating rays, and the coordinates of the intersection of the ray and the first model in the three-dimensional virtual scene model are calculated, which are the coordinates selected by the user. Specifically, the selection of the model can be used to determine the target virtual item, and the selection of the position can be based on the selected position to determine the item display area for displaying the target virtual item.
[0163] In a specific embodiment, if Figure 2b As shown, by operating the augmented reality scene display control, you can enter the virtual gift collection room, download the collection room data previously saved by the user from the background, and display the augmented reality screen corresponding to the collection room data through the augmented reality toolbox ARKit; monitor the user's operation on the augmented reality screen. Specifically, monitoring user operations can include:
[0164] Listen for the placement of a virtual gift. If so, first determine the placement of the virtual gift. Shoot a ray from the point where the finger touches the screen toward the camera, obtain the coordinates where the ray intersects the collection shelf, and set these coordinates as the placement of the virtual gift. After determining the placement of the virtual gift, continue to monitor for user actions.
[0165] Monitor whether a virtual gift is being previewed; if so, first determine the target virtual gift to be previewed. Raycasting can be used to obtain the target virtual gift selected by the user. When the user selects the target virtual gift, enter the gift close-up page and display the target virtual gift. When the user exits the gift close-up page, continue monitoring the user's actions. If the user does not select the target virtual gift, continue monitoring the user's actions.
[0166] If no user operation is detected within the preset time, the latest data in the collection room can be automatically saved.
[0167] This application can transform two-dimensional virtual gifts into three-dimensional ones through AR technology, and can observe the details of the gifts and place the gifts, creating a stronger interactive and realistic experience for users, so that the gifts are displayed in front of users as if they were real. Users can view and operate the gifts in all directions through operations on the screen. It is more interesting and playable than traditional gifts, which inspires users to give gifts or increases users' curiosity about gifts, and increases users' desire to buy gifts.
[0168] As can be seen from the above, this embodiment can display a user operation page of an instant messaging client through a terminal, and the user operation page includes: an augmented reality scene display control; when an operation on the augmented reality scene display control is detected, the terminal displays an augmented reality page, and the augmented reality page includes an augmented reality screen corresponding to a real object display scene; based on the object display operation on the augmented reality page, the terminal displays the target virtual object in the object display area of the augmented reality screen. This application can realize the combination of virtual object display and augmented reality technology.
[0169] In order to better implement the above method, the embodiment of the present application further provides a virtual item display device, wherein the virtual item display device can be specifically integrated into a terminal or other device, such as Figure 3a As shown, the virtual item display device may include a first display unit 301, a second display unit 302, and a third display unit 303, as follows:
[0170] (1) a first display unit 301;
[0171] The first display unit 301 is used to display a user operation page of the instant messaging client, where the user operation page includes an augmented reality scene display control.
[0172] (2) a second display unit 302;
[0173] The second display unit 302 is configured to display an augmented reality page when an operation on the augmented reality scene display control is detected. The augmented reality page includes an augmented reality picture corresponding to a real object display scene.
[0174] (3) a third display unit 303;
[0175] The third display unit 303 is configured to display a target virtual object in the object display area of the augmented reality screen based on the object display operation on the augmented reality page.
[0176] Optionally, in some embodiments, the augmented reality page includes an item display control; the third display unit 303 can be specifically used to display the target virtual item in the item display area in the augmented reality screen when an operation on the item display control is detected.
[0177] Optionally, in some embodiments of the present application, the augmented reality page also includes a target virtual item to be displayed; the third display unit 303 can be specifically used to display the target virtual item in the item display area in the augmented reality screen based on a movement operation on the target virtual item.
[0178] Optionally, in some embodiments of the present application, the third display unit 303 may include a first rotating subunit 30301 and a first display subunit 30302, see Figure 3b ,as follows:
[0179] The first rotation subunit 30301 is configured to trigger the target virtual object to rotate to a corresponding angle in the augmented reality image based on a rotation operation on the target virtual object, wherein the angle corresponds to the rotation operation;
[0180] The first display sub-unit 30302 is configured to display the rotated target virtual object in the object display area in the augmented reality screen based on a movement operation on the rotated target virtual object.
[0181] Optionally, in some embodiments of the present application, the third display unit 303 may further include a second rotating subunit 30303, see Figure 3c The second rotation sub-unit 30303 can be used to rotate the target virtual item displayed in the item display area on the augmented reality screen. Specifically, the second rotation sub-unit 30303 is used to trigger the target virtual item to rotate a corresponding angle within the item display area on the augmented reality screen based on the rotation operation on the target virtual item, where the angle corresponds to the rotation operation.
[0182] Optionally, in some embodiments of the present application, the augmented reality page further includes an item adding control; the third display unit 303 may further include a second display subunit 30304 and a third display subunit 30305, see Figure 3d ,as follows:
[0183] The second display sub-unit 30304 is configured to display a virtual item list on the augmented reality page when an operation of adding a control to an item on the augmented reality page is detected, wherein the virtual item list includes at least one virtual item to be displayed;
[0184] The third display sub-unit 30305 is configured to display a target virtual item selected from the virtual items to be displayed on the augmented reality page based on a selection operation on the virtual item list.
[0185] Optionally, in some embodiments of the present application, the virtual item display device may further include a scaling unit 304, see Figure 3e ,as follows:
[0186] The scaling unit 304 is configured to determine a scaling factor based on a scaling operation on the augmented reality image; and display the scaled augmented reality image based on the scaling factor.
[0187] Optionally, in some embodiments of the present application, the augmented reality screen includes at least one item display area, and the item display area displays a motion effect prompting the display of items.
[0188] Optionally, in some embodiments of the present application, the augmented reality page further includes an item display control; the third display unit 303 may include a first determination subunit 30306, a second determination subunit 30307, a third determination subunit 30308 and a fourth display subunit 30309, see Figure 3f ,as follows:
[0189] The first determining subunit 30306 is used to determine the target virtual item to be displayed;
[0190] The second determining subunit 30307 is configured to determine the position information of the target touch point when a touch operation on the augmented reality page is detected;
[0191] The third determining subunit 30308 is configured to determine an item display area for displaying the target virtual item based on the position information of the target touch point;
[0192] The fourth display sub-unit 30309 is configured to display a target virtual object in the object display area in the augmented reality screen when an operation on the object display control is detected.
[0193] Optionally, in some embodiments of the present application, the second determination subunit 30307 can be specifically used to obtain the touch time of the touch point corresponding to each touch operation when multiple touch operations on the augmented reality page are detected; based on the touch time, determine the target touch point from the multiple touch points, and determine the position information of the target touch point.
[0194] Optionally, in some embodiments of the present application, the third display unit 303 may further include a fourth determining subunit 30310 and a fifth display subunit 30311, see Figure 3g ,include:
[0195] The fourth determining subunit 30310 is configured to determine, upon detecting a touch operation on the augmented reality page, a new item display area for displaying the target virtual item on the augmented reality page;
[0196] The fifth display sub-unit 30311 is configured to display the target virtual object in a new object display area in the augmented reality screen when an operation on the object display control is detected.
[0197] Optionally, in some embodiments of the present application, the position information includes two-dimensional coordinate information; the third determination subunit 30308 may specifically include converting the two-dimensional coordinate information of the target touch point into three-dimensional coordinate information, and establishing a three-dimensional virtual scene model corresponding to the augmented reality page based on the three-dimensional coordinate information; based on the three-dimensional coordinate information of the target touch point, forming a ray in the three-dimensional space corresponding to the three-dimensional virtual scene model; obtaining the coordinates of the intersection position of the ray and the three-dimensional virtual scene model; and determining the item display area for displaying the target virtual item based on the coordinates of the intersection position.
[0198] Optionally, in some embodiments of the present application, the virtual item display device may further include a fourth display unit 305, a collection unit 306 and a generation unit 307, see Figure 3h ,as follows:
[0199] The fourth display unit 305 is configured to display a creation page for an augmented reality page, wherein the creation page includes a creation control for the augmented reality page;
[0200] A collection unit 306 is configured to collect an augmented reality image corresponding to the real object display scene when a trigger operation on the creation control is detected;
[0201] The generating unit 307 is configured to generate an augmented reality page based on the augmented reality image corresponding to the real object display scene.
[0202] As can be seen from the above, in this embodiment of the application, the first display unit 301 can display a user operation page of the instant messaging client, wherein the user operation page includes an augmented reality scene display control. When an operation on the augmented reality scene display control is detected, the second display unit 302 displays an augmented reality page, wherein the augmented reality page includes an augmented reality screen corresponding to a real object display scene. Based on the object display operation on the augmented reality page, the third display unit 303 displays a target virtual object in the object display area of the augmented reality screen. This application can realize the combination of virtual object display and augmented reality technology.
[0203] The present application also provides an electronic device, such as Figure 4 , which shows a schematic diagram of the structure of the electronic device involved in the embodiment of the present application, specifically:
[0204] The electronic device may include one or more processing core processors 401, one or more computer-readable storage media memories 402, a power supply 403, an input unit 404 and other components. Those skilled in the art will understand that Figure 4 The electronic device structure shown in the figure does not constitute a limitation of the electronic device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange components differently.
[0205] Processor 401 is the control center of the electronic device, connecting the various parts of the entire electronic device using various interfaces and lines. By running or executing software programs and / or modules stored in memory 402 and accessing data stored in memory 402, it performs various functions of the electronic device and processes data, thereby performing overall testing of the electronic device. Optionally, processor 401 may include one or more processing cores; preferably, processor 401 may integrate an application processor and a modem processor, wherein the application processor primarily processes the operating system, user interface, and application programs, and the modem processor primarily handles wireless communications. It is understood that the modem processor may not be integrated into processor 401.
[0206] The memory 402 can be used to store software programs and modules. The processor 401 executes various functional applications and data processing by running the software programs and modules stored in the memory 402. The memory 402 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device, etc. In addition, the memory 402 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage device. Accordingly, the memory 402 may also include a memory controller to provide the processor 401 with access to the memory 402.
[0207] The electronic device also includes a power supply 403 for supplying power to various components. Preferably, the power supply 403 can be logically connected to the processor 401 via a power management system, thereby enabling the power management system to manage charging, discharging, and power consumption. The power supply 403 can also include one or more DC or AC power supplies, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and other arbitrary components.
[0208] The electronic device may further include an input unit 404, which may be configured to receive input digital or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.
[0209] Although not shown, the electronic device may further include a display unit, etc., which will not be described in detail here. Specifically, in this embodiment, the processor 401 in the electronic device will load the executable files corresponding to the processes of one or more application programs into the memory 402 according to the following instructions, and the processor 401 will run the application programs stored in the memory 402 to implement various functions as follows:
[0210] A user operation page of an instant messaging client is displayed, the user operation page including: an augmented reality scene display control; when an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, the augmented reality page including an augmented reality screen corresponding to a real object display scene; based on the object display operation on the augmented reality page, a target virtual object is displayed in an object display area in the augmented reality screen.
[0211] The specific implementation of the above operations can be found in the previous embodiments and will not be repeated here.
[0212] As can be seen from the above, this embodiment can display a user operation page of an instant messaging client, the user operation page including an augmented reality scene display control; when an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, the augmented reality page including an augmented reality screen corresponding to a real object display scene; based on an object display operation on the augmented reality page, a target virtual object is displayed in an object display area on the augmented reality screen. This application can realize the combination of virtual object display and augmented reality technology.
[0213] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be accomplished by instructions, or by controlling related hardware through instructions. The instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.
[0214] To this end, an embodiment of the present application provides a storage medium storing a plurality of instructions that can be loaded by a processor to execute the steps of any of the virtual item display methods provided in the embodiments of the present application. For example, the instructions can execute the following steps:
[0215] A user operation page of an instant messaging client is displayed, the user operation page including: an augmented reality scene display control; when an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, the augmented reality page including an augmented reality screen corresponding to a real object display scene; based on the object display operation on the augmented reality page, a target virtual object is displayed in an object display area in the augmented reality screen.
[0216] The specific implementation of the above operations can be found in the previous embodiments and will not be repeated here.
[0217] The storage medium may include a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0218] Since the instructions stored in the storage medium can execute the steps of any virtual item display method provided in the embodiments of the present application, the beneficial effects that can be achieved by any virtual item display method provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.
[0219] The above is a detailed introduction to a virtual item display method, device, electronic device and storage medium provided in the embodiments of the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core ideas of the present application. At the same time, for those skilled in the art, based on the ideas of the present application, there may be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present application.
Claims
1. A method for displaying virtual items, characterized in that: include: Displaying a user operation page of the instant messaging client, the user operation page including: an augmented reality scene display control; When an operation on the augmented reality scene display control is detected, an augmented reality page is displayed, wherein the augmented reality page includes an augmented reality screen corresponding to a real object display scene, and the augmented reality page includes an object display control; Based on an item display operation on the augmented reality page, a target virtual item is displayed in an item display area in the augmented reality screen, including: determining a target virtual item to be displayed; when a touch operation on the augmented reality page is detected, determining position information of a target touch point, the position information including two-dimensional coordinate information; converting the two-dimensional coordinate information of the target touch point into three-dimensional coordinate information; and establishing a three-dimensional virtual scene model corresponding to the augmented reality page based on the three-dimensional coordinate information; forming a ray in a three-dimensional space corresponding to the three-dimensional virtual scene model based on the three-dimensional coordinate information of the target touch point, obtaining the coordinates of a position where the ray intersects with the three-dimensional virtual scene model, determining position information of an item display area for displaying the target virtual item based on the coordinates of the intersection position, determining an item display area for displaying the target virtual item; and when an operation on the item display control is detected, displaying the target virtual item in the item display area in the augmented reality screen.
2. The method according to claim 1, characterized in that The augmented reality page includes an item display control; and the item display operation on the augmented reality page, displaying a target virtual item in an item display area in the augmented reality screen, includes: When an operation on the item display control is detected, a target virtual item is displayed in the item display area in the augmented reality screen.
3. The method according to claim 1, characterized in that The augmented reality page also includes a target virtual item to be displayed; and the displaying of the target virtual item in the item display area in the augmented reality screen based on the item display operation on the augmented reality page includes: Based on the movement operation on the target virtual item, the target virtual item is displayed in the item display area in the augmented reality screen.
4. The method according to claim 3, characterized in that Before displaying the target virtual item in the item display area on the augmented reality screen based on the movement operation on the target virtual item, the method further includes: Based on the rotation operation on the target virtual object, triggering the target virtual object to rotate to a corresponding angle in the augmented reality screen, wherein the angle corresponds to the rotation operation; The step of displaying the target virtual item in the item display area in the augmented reality screen based on the movement operation on the target virtual item includes: Based on the movement operation on the rotated target virtual object, the rotated target virtual object is displayed in the object display area in the augmented reality screen.
5. The method according to claim 1, wherein After displaying the target virtual item in the item display area in the augmented reality screen based on the item display operation on the augmented reality page, the method further includes: Based on the rotation operation on the target virtual object, the target virtual object is triggered to rotate a corresponding angle in the object display area in the augmented reality screen, wherein the angle corresponds to the rotation operation.
6. The method according to claim 1, characterized in that The augmented reality page further includes an item adding control; and the item display operation based on the augmented reality page, before displaying the target virtual item in the item display area in the augmented reality screen, further includes: When an operation of adding a control to an item on the augmented reality page is detected, displaying a virtual item list on the augmented reality page, the virtual item list including at least one virtual item to be displayed; Based on a selection operation on the virtual item list, a target virtual item selected from the virtual items to be displayed is displayed on the augmented reality page.
7. The method according to claim 1, characterized in that The method further comprises: Determining a zoom factor based on a zoom operation on the augmented reality image; Based on the zoom factor, a zoomed augmented reality image is displayed.
8. The method according to claim 1, characterized in that The augmented reality screen includes at least one item display area, and the item display area displays a motion effect prompting the display of items.
9. The method according to claim 1, characterized in that When a touch operation on the augmented reality page is detected, determining the position information of the target touch point includes: When multiple touch operations on the augmented reality page are detected, acquiring the touch time of the touch point corresponding to each touch operation; Based on the touch time, a target touch point is determined from the multiple touch points, and position information of the target touch point is determined.
10. The method according to claim 1, characterized in that When an operation on the item display control is detected, after displaying the target virtual item in the item display area in the augmented reality screen, the method further includes: When a touch operation on the augmented reality page is detected, determining a new item display area on the augmented reality page for displaying the target virtual item; When an operation on the item display control is detected, the target virtual item is displayed in a new item display area in the augmented reality screen.
11. The method according to claim 1, wherein The method further comprises: Displaying a creation page for an augmented reality page, the creation page including a creation control for the augmented reality page; When a trigger operation on the creation control is detected, an augmented reality image corresponding to the real object display scene is captured; An augmented reality page is generated based on the augmented reality picture corresponding to the real object display scene.
12. A virtual item display device, characterized in that: include: A first display unit is configured to display a user operation page of the instant messaging client, wherein the user operation page includes: an augmented reality scene display control; a second display unit, configured to display an augmented reality page when an operation on the augmented reality scene display control is detected, wherein the augmented reality page includes an augmented reality image corresponding to a real object display scene, and the augmented reality page includes an object display control; A third display unit is configured to display a target virtual item in an item display area in the augmented reality screen based on an item display operation on the augmented reality page, comprising: determining a target virtual item to be displayed; when a touch operation on the augmented reality page is detected, determining position information of a target touch point, the position information comprising two-dimensional coordinate information; converting the two-dimensional coordinate information of the target touch point into three-dimensional coordinate information; and establishing a three-dimensional virtual scene model corresponding to the augmented reality page based on the three-dimensional coordinate information; forming a ray in a three-dimensional space corresponding to the three-dimensional virtual scene model based on the three-dimensional coordinate information of the target touch point; obtaining the coordinates of a position where the ray intersects with the three-dimensional virtual scene model; determining position information of an item display area for displaying the target virtual item based on the coordinates of the intersection; determining an item display area for displaying the target virtual item; and displaying the target virtual item in the item display area in the augmented reality screen when an operation on the item display control is detected.
13. An electronic device, characterized in that: The method comprises a memory and a processor; the memory stores an application program, and the processor is configured to run the application program in the memory to execute the steps of the virtual item display method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Method and system for implementing gift giving in video live broadcasting process on basis of AR (Augmented Reality) technology
CN106411877A
Method, device and system for augmented reality processing, storage medium and electronic equipment
CN111179435A