Virtual object generation method, device, electronic device and storage medium
By triggering the three-dimensional image scanning box in the game environment, determining the projection information and performing model correction and bone binding, the accuracy problem of virtual object generation in complex backgrounds is solved, efficient and accurate virtual object generation is achieved, and the game experience is improved.
Patent Information
- Application Number
- CN202110138222.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-02-01
- Publication Date
- 2025-07-11
- Estimated Expiration
- 2041-02-01
AI Technical Summary
The prior art has poor accuracy when cutting virtual objects in complex backgrounds, which affects the user's gaming experience.
By triggering the three-dimensional image scanning box in the game environment where the target object is located, the projection information is determined, the model pattern and outline are corrected, and bone binding is performed to generate a virtual object.
Improve the accuracy and efficiency of virtual object generation, adapt to complex environments, reduce computing costs, and improve game experience.
Smart Images

Figure CN113577774B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to information processing technologies, and in particular, to a method, an apparatus, and an electronic device for generating virtual objects. Background Art
[0002] Artificial Intelligence (AI) is a comprehensive technology in computer science. By studying the design principles and implementation methods of various intelligent machines, machines are enabled to have functions of perception, reasoning, and decision-making. The AI technology is an interdisciplinary subject with a wide range of involved fields, such as natural language processing technology and machine learning / deep learning and other major directions. It is believed that with the development of technology, the AI technology will be applied in more fields and play an increasingly important role.
[0003] AR games generally have complex game rules and changing dynamic scenes. When using virtual objects (such as three-dimensional virtual characters) in social applications or game applications to simulate target objects (which can be characters or physical objects collected by the user's mobile phone) or images, it is required to be vivid. However, in the related technology when performing matte extraction processing, when the background is simple, the matte extraction accuracy is high, but when the background texture is relatively complex, the matte extraction effect is poor, which affects the user's game experience. Summary of the Invention
[0004] In view of this, embodiments of the present invention provide a method, an apparatus, an electronic device, and a storage medium for generating virtual objects. The technical solutions of the embodiments of the present invention are implemented as follows:
[0005] Embodiments of the present invention provide a method for generating virtual objects, including:
[0006] Triggering a three-dimensional image scanning frame in the game environment where the target object is located;
[0007] Based on the three-dimensional image scanning frame, determining projection information corresponding to the three-dimensional image scanning frame in the user interface;
[0008] According to the projection information corresponding to the three-dimensional image scanning frame in the user interface, determining the model pattern and the corresponding contour of the target object;
[0009] Respectively performing correction processing on the model pattern and the contour of the target object in the extracted model contour;
[0010] Performing bone binding processing on the model pattern and the contour of the target object after the correction processing to determine a virtual object in the game environment corresponding to the target object.
[0011] Embodiments of the present invention further provide a virtual object generation apparatus, including:
[0012] An information transmission module, configured to trigger a three-dimensional image scanning frame in the game environment where the target object is located;
[0013] An information processing module, configured to determine projection information corresponding to the three-dimensional image scanning frame in the user interface based on the three-dimensional image scanning frame;
[0014] The information processing module is configured to determine the model pattern and corresponding contour of the target object according to the projection information corresponding to the three-dimensional image scanning frame in the user interface;
[0015] The information processing module is configured to respectively perform correction processing on the model pattern and contour of the target object in the extracted model contour;
[0016] The information processing module is configured to perform bone binding processing on the model pattern and contour of the target object after the correction processing, and determine a virtual object in the game environment corresponding to the target object.
[0017] In the above solution,
[0018] The information processing module is configured to, when the person's perspective of the target object changes, obtain the image acquisition parameters transmitted by the sensor data transmission interface corresponding to the user interface;
[0019] Perform parsing processing on the image acquisition parameters to determine the data changes of the image acquisition parameters in different direction dimensions;
[0020] Based on the data changes of the image acquisition parameters in different direction dimensions, determine the change of the three-dimensional image scanning frame in the game environment where the target object is located.
[0021] In the above solution,
[0022] The information processing module is configured to determine the image acquisition focal length parameters and optical center parameters corresponding to the three-dimensional image scanning frame in the user interface based on the three-dimensional image scanning frame;
[0023] Determine the projection coordinates of the spatial points of the three-dimensional image scanning frame in the user interface;
[0024] According to the image acquisition focal length parameters, optical center parameters, and the projection coordinates of the spatial points in the user interface, determine the projection information corresponding to the three-dimensional image scanning frame in the user interface.
[0025] In the above solution,
[0026] The information processing module is configured to determine the image region of interest corresponding to the three-dimensional image scanning frame when determining according to the projection information corresponding to the three-dimensional image scanning frame in the user interface;
[0027] Determine the image gradient corresponding to the region of interest of the image;
[0028] Determine different image complexities according to the image gradient corresponding to the region of interest of the image;
[0029] Trigger corresponding contour extraction processes according to different image complexities, and extract the model pattern and corresponding contour of the target object according to different image complexities.
[0030] In the above solution,
[0031] The information processing module is used to trigger the first contour extraction process when it is determined that the image complexity is the first type;
[0032] Through the first contour extraction process, use an edge extraction operator to extract the contour of the target object in the projection information;
[0033] Extract the model pattern of the target object based on the extracted contour of the target object.
[0034] In the above solution,
[0035] The information processing module is used to trigger the second contour extraction process when it is determined that the image complexity is the second type;
[0036] Through the second contour extraction process, use an image processing model to extract the contour of the target object in the projection information;
[0037] Extract the model pattern of the target object based on the extracted contour of the target object.
[0038] In the above solution,
[0039] The information processing module is used to determine the homography matrix matching the target object in the projection information through the second contour extraction process;
[0040] Extract the mask cluster parameters of the target object in the projection information, and determine the contour of at least one object in the projection information;
[0041] Compare the contour areas of different objects in the projection information, and extract the contour of the object with the largest contour area as the contour of the target object extracted in the projection information.
[0042] In the above solution,
[0043] The information processing module is used to determine the homography matrix matching the target object in the projection information;
[0044] Obtain a scale factor that matches the target object in the projection information;
[0045] Based on the scale factor and the homography matrix that match the target object in the projection information, perform correction processing on the model pattern and the contour of the target object in the extracted model contour respectively, so that the scale factor and the homography matrix meet the corresponding constraint conditions.
[0046] In the above solution,
[0047] The information processing module is used to traverse the contour of the target object after over-correction processing to determine a set of target corner points, where the set of target corner points includes at least two corner points;
[0048] Combine different corner points in the determined set of target corner points to form the skeleton of the virtual object;
[0049] Traverse all the target corner points in the set of target corner points to determine the skeleton parameters of the virtual object;
[0050] Bind the skeleton parameters of the virtual object and the model pattern of the target object to determine the virtual object in the game environment corresponding to the target object.
[0051] In the above solution,
[0052] The information processing module is used to detect the determined skeleton parameters of the virtual object to determine the skeleton parameters with inclusion relationships and the skeleton parameters with cross relationships;
[0053] Delete the skeleton parameters with inclusion relationships and the skeleton parameters with cross relationships.
[0054] In the above solution,
[0055] The information processing module is used to present the virtual object in the user interface of the game environment where the target object is located when the control component in the game environment is triggered,
[0056] By triggering different game levels, use the virtual object to present corresponding game interaction instructions in the user interface.
[0057] In the above solution,
[0058] The information processing module is used to, when the target user selects any of the displayed virtual targets,
[0059] Based on the object feature vector of the target user, determine a payment method that matches the target user, or,
[0060] Determine a payment method that matches the target user based on the object characteristics of the target user and the type information of the virtual target;
[0061] Trigger a corresponding payment process based on the payment method that matches the target user.
[0062] In the above solution,
[0063] The information processing module is used to determine the level parameter of the target user and the level parameter of the virtual object;
[0064] Adjust the number of virtual objects in the user interface through the display control component according to the level parameter of the target user and the level parameter of the virtual object.
[0065] An embodiment of the present invention also provides an electronic device, and the electronic device includes:
[0066] A memory for storing executable instructions;
[0067] A processor, when running the executable instructions stored in the memory, implements the foregoing virtual object generation method.
[0068] An embodiment of the present invention also provides a computer-readable storage medium storing executable instructions, and when the executable instructions are executed by a processor, the foregoing virtual object generation method is implemented.
[0069] The embodiment of the present invention has the following beneficial effects:
[0070] In the present invention, a three-dimensional image scanning frame is triggered in the game environment where the target object is located; based on the three-dimensional image scanning frame, the projection information corresponding to the three-dimensional image scanning frame in the user interface is determined; according to the projection information corresponding to the three-dimensional image scanning frame in the user interface, the model pattern and the corresponding contour of the target object are determined; the model pattern and the contour of the target object in the extracted model contour are respectively corrected; the model pattern and the contour of the target object after the correction process are subjected to bone binding processing to determine the virtual object in the game environment corresponding to the target object. Thus, not only can the generation accuracy of the virtual object corresponding to the target object in the corresponding game environment be effectively guaranteed, the processing of the target object in a complex environment be realized, the processing of the game with complex dimensions be performed more quickly, but also the automatic bone binding has robustness and generalization for different game environments, reduces the calculation cost, improves the generation efficiency of the virtual object, and realizes the processing of the game environment with complex dimensions. Description of the Drawings
[0071] Figure 1 It is a schematic diagram of the usage scenario of the virtual object generation method provided by the embodiment of the present invention;
[0072] Figure 2 Schematic diagram of the composition structure of the virtual object generation device provided by the embodiment of the present invention;
[0073] Figure 3 An optional flowchart of the virtual object generation method provided by the embodiment of the present invention;
[0074] Figure 4 Schematic diagram of triggering a three-dimensional image scanning frame in the embodiment of the present invention;
[0075] Figure 5 Schematic diagram of correcting the model pattern and contour in the embodiment of the present invention;
[0076] Figure 6 An optional flowchart of the virtual object generation method provided by the embodiment of the present invention;
[0077] Figure 7 Schematic diagram of the change in the processing process of bone parameters in the embodiment of the present invention;
[0078] Figure 8 Schematic diagram of the change in the processing process of bone parameters in the embodiment of the present invention;
[0079] Figure 9A Front-end display schematic diagram of the virtual object generation method provided by the embodiment of the present invention;
[0080] Figure 9B Front-end display schematic diagram of the virtual object generation method provided by the embodiment of the present invention;
[0081] Figure 10 Front-end display schematic diagram of the virtual target generation method in the embodiment of the present invention;
[0082] Figure 11 An optional flowchart of the virtual target generation method provided by the embodiment of the present invention. Detailed implementation manners
[0083] In order to make the objectives, technical solutions, and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be construed as limitations on the present invention. All other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of the present invention.
[0084] In the following description, reference is made to "some embodiments", which describe a subset of all possible embodiments. However, it can be understood that "some embodiments" can be the same subset or different subsets of all possible embodiments, and can be combined with each other without conflict.
[0085] Before further describing the embodiments of the present invention in detail, the nouns and terms involved in the embodiments of the present invention are described. The nouns and terms involved in the embodiments of the present invention are subject to the following interpretations.
[0086] 1) In response, it is used to indicate the conditions or states on which the executed operations depend. When the dependent conditions or states are met, one or more operations executed may be in real time or have a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations executed are executed.
[0087] 2) Based on, used to indicate the conditions or states on which the executed operations depend. When the dependent conditions or states are met, one or more operations executed may be in real time or have a set delay. Unless otherwise specified, there is no restriction on the order of execution of the multiple operations executed.
[0088] 3) Neural Network (NN): Artificial Neural Network (ANN), referred to as neural network or quasi-neural network, is a mathematical model or computational model that imitates the structure and function of biological neural networks (the central nervous system of animals, especially the brain) in the field of machine learning and cognitive science, and is used to estimate or approximate functions.
[0089] 5) Game environment: It is the game environment displayed (or provided) when the application is running on the terminal. The game environment can be a simulation environment of the real world, a semi-simulated and semi-fictitious three-dimensional environment, or a purely fictitious three-dimensional environment. The game environment can be any one of a two-dimensional game environment, a 2.5-dimensional game environment, and a three-dimensional game environment. The following embodiments are illustrated by taking the game environment as a three-dimensional game environment, but are not limited to this. Optionally, the game environment is also used for a game environment battle between at least two virtual objects. Optionally, the game environment is also used for a battle between at least two virtual objects using virtual firearms. Optionally, the game environment can also be but not limited to gun battle games, parkour games, racing games, multiplayer online tactical competitive games (Multiplayer Online Battle Arena, MOBA), racing games (Racing Game, RCG) and sports games (SPG). The trained virtual object generation device provided by the present application can be deployed in the game servers corresponding to the aforementioned types of game scenarios to generate real-time game strategies, execute corresponding action information, simulate the operations of virtual users, and complete different types of games in the game environment together with users who actually participate in the game.
[0090] 6) Action information: Taking racing games, flight games, etc. where game users participate in speed competitions in the first or third person as examples, action information refers to operation instructions such as using the direction keys to control a racing car as actions. For role-playing games, action information refers to virtual weapons that attack by firing bullets in the game environment, or virtual bows and arrows that shoot arrows, virtual slingshots. Virtual objects can pick up virtual firearms in the game environment and attack with the picked-up virtual firearms.
[0091] Optionally, the virtual object can be a user virtual object controlled through operations on the client, or an artificial intelligence (AI) set in the game environment for battles through training, or a non-user virtual object (NPC) set in the game environment for interactions. Optionally, the virtual object can be a virtual character competing in the game environment. Optionally, the number of virtual objects participating in interactions in the game environment can be preset or dynamically determined according to the number of clients joining the interactions.
[0092] Among them, taking shooting games as an example, users can control virtual objects to perform corresponding action information at different times in the game environment, such as freely falling in the sky, gliding, or opening a parachute to fall, running, jumping, crawling, bending forward on land, or swimming, floating, or diving in the ocean. Of course, users can also control virtual objects to move in the game environment by taking virtual vehicles. For example, the virtual vehicle can be a virtual car, a virtual aircraft, a virtual yacht, etc. Only the above scenarios are used for illustration here, and the embodiments of the present invention do not make specific limitations in this regard. Users can also control virtual objects to interact with other virtual objects through virtual weapons in ways such as combat. The virtual weapon can be a cold weapon or a hot weapon, and the present invention does not make specific limitations on the type of virtual weapon.
[0093] The method provided in the present invention can be applied to virtual reality applications, three-dimensional map programs, simulation programs, first-person shooting games (FPS), multiplayer online battle arena games (MOBA), etc. The following embodiments are illustrated by taking applications in games as examples.
[0094] Figure 1 It is a schematic diagram of the usage scenario of the virtual object generation method provided by the embodiments of the present invention. See Figure 1, a client capable of loading, running, and displaying software for different game scenarios is set on the terminal (including terminal 10-1 and terminal 10-2), such as clients or plugins for different games. Through the corresponding client, the user can observe the virtual environment from the perspective of the virtual object, and adjust and display the position of the virtual object in the user interface during the change of the perspective screen (for example, during the progress of an AR game, converting the collected object into a virtual object in the game scenario, triggering different game plots or levels, and switching to the corresponding game user interface); the terminal is connected to the server 200 through the network 300, and the network 300 can be a wide area network, a local area network, or a combination of the two, and uses a wireless link to achieve data transmission.
[0095] As an example, the server 200 is used to deploy the virtual object generation device to implement the virtual object generation method provided by the present invention, so as to implement triggering a three-dimensional image scanning frame in the game environment where the target object is located;
[0096] Based on the three-dimensional image scanning frame, determine the projection information corresponding to the three-dimensional image scanning frame in the user interface; according to the projection information corresponding to the three-dimensional image scanning frame in the user interface, determine the model pattern and corresponding contour of the target object; respectively perform correction processing on the model pattern and contour of the target object in the extracted model contour; perform bone binding processing on the model pattern and contour of the target object after the correction processing to determine the virtual object in the game environment corresponding to the target object.
[0097] Of course, the virtual object generation device provided by the present invention can be applied to different game environments including but not limited to virtual reality applications, three-dimensional map programs, simulation programs, first-person shooting games (FPS), multiplayer online battle arena games (MOBA), etc., and finally present and control corresponding virtual props on the user interface (UI). The user can obtain different virtual targets in the current display interface (such as virtual props including virtual weapons, or virtual bows and arrows that shoot arrows, virtual slingshots, etc., or different virtual objects held by the user in the current game process), and the adjusted virtual targets can also be called by other application programs.
[0098] As an example, the server 200 is used to deploy the virtual object generation device to implement the virtual object generation method provided by the present invention. The latter can deploy a trained virtual object generation device to generate adapted virtual objects in different game environments (such as first-person shooter games, parkour games, racing games, Multiplayer Online Battle Arena (MOBA), Racing Game (RCG), and sports games (sportgame, SPG)), or can also be used for multiplayer online board game applications. The types of the above game applications can include but are not limited to at least one of the following: two-dimensional (2D) game applications, three-dimensional (3D) game applications, virtual reality (VR) game applications, augmented reality (AR) game applications, and mixed reality (MR) game applications. The above is only an example, and the embodiments of the present invention do not make any limitations thereto.
[0099] Of course, the virtual object generation device provided by the present invention can generate virtual objects for the same target object in different game environments, or can also perform adaptive adjustment according to different levels of the target object, and finally present the virtual object on the user interface (UI). It can also be presented in short video games or mini-program games, and the obtained virtual object can also be called by other application programs (such as game simulators or somatosensory game devices). Of course, the virtual objects matching different types of games can also be migrated to mini-program games, web games, and cloud games in the instant messaging process.
[0100] Of course, after the virtual object is generated, different game strategies can be generated through role simulation by the virtual object generation device, and corresponding action information can be executed to assist game players. Specifically, when the control component in the game environment is triggered, the virtual object is presented in the user interface of the game environment where the target object is located, and by triggering the trained virtual object generation device, the corresponding game interaction instructions are presented in the user interface by using the virtual object.
[0101] Next, the structure of the virtual object generation device according to the embodiments of the present invention will be described in detail. The virtual object generation device can be implemented in various forms, such as a dedicated terminal with the processing function of the virtual object generation device, or a server provided with the processing function of the virtual object generation device, such as the server 200 in the foregoing Figure 1 server 200. Figure 2The following is a schematic structural diagram of the virtual object generation device provided by the embodiments of the present invention. It can be understood that Figure 2 only the exemplary structure of the virtual object generation device is shown, rather than all structures, and partial or all of the structures shown can be implemented as needed. Figure 2
[0102] The virtual object generation device provided by the embodiments of the present invention includes: at least one processor 201, a memory 202, a user interface 203, and at least one network interface 204. Each component in the virtual object generation device is coupled together through a bus system 205. It can be understood that the bus system 205 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 205 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clear illustration, Figure 2 all kinds of buses are labeled as the bus system 205 in
[0103] Among them, the user interface 203 may include a display, a keyboard, a mouse, a trackball, a click wheel, a button, a touchpad, or a touch screen, etc.
[0104] It can be understood that the memory 202 may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. The memory 202 in the embodiments of the present invention is capable of storing data to support the operation of the terminal (such as 10-1). Examples of these data include: any computer program for operating on the terminal (such as 10-1), such as an operating system and application programs. Among them, the operating system contains various system programs, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks. The application programs may include various application programs.
[0105] In some embodiments, the virtual object generation device provided by the embodiments of the present invention may be implemented in a combination of software and hardware. As an example, the virtual object generation device provided by the embodiments of the present invention may be a processor in the form of a hardware decoding processor, which is programmed to execute the virtual object generation method provided by the embodiments of the present invention. For example, the processor in the form of a hardware decoding processor may adopt one or more application-specific integrated circuits (ASICs, Application Specific Integrated Circuits), DSPs, programmable logic devices (PLDs, Programmable Logic Devices), complex programmable logic devices (CPLDs, Complex Programmable Logic Devices), field-programmable gate arrays (FPGAs, Field-Programmable Gate Arrays), or other electronic components.
[0106] As an example of the virtual object generation device provided by the embodiments of the present invention implemented by combining software and hardware, the virtual object generation device provided by the embodiments of the present invention can be directly embodied as a combination of software modules executed by the processor 201. The software modules can be located in a storage medium, and the storage medium is located in the memory 202. The processor 201 reads the executable instructions included in the software modules in the memory 202 and combines the necessary hardware (for example, including the processor 201 and other components connected to the bus 205) to complete the virtual object generation method provided by the embodiments of the present invention.
[0107] As an example, the processor 201 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP, Digital Signal Processor), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor can be a microprocessor or any conventional processor, etc.
[0108] As an example of the virtual object generation device provided by the embodiments of the present invention implemented by hardware, the device provided by the embodiments of the present invention can be directly executed and completed by a processor 201 in the form of a hardware decoding processor. For example, it is executed and implemented by one or more application-specific integrated circuits (ASIC, Application Specific Integrated Circuit), DSP, programmable logic device (PLD, Programmable Logic Device), complex programmable logic device (CPLD, Complex Programmable Logic Device), field programmable gate array (FPGA, Field-Programmable Gate Array) or other electronic components to implement the virtual object generation method provided by the embodiments of the present invention.
[0109] The memory 202 in the embodiments of the present invention is used to store various types of data to support the operation of the virtual object generation device. Examples of these data include: any executable instructions for operating on the virtual object generation device, such as executable instructions, and the program implementing the virtual object generation method of the embodiments of the present invention can be included in the executable instructions.
[0110] In some other embodiments, the virtual object generation device provided by the embodiments of the present invention can be implemented in software. Figure 2 The virtual object generation device stored in the memory 202 is shown, which can be software in the form of a program and plug-ins, etc., and includes a series of modules. As an example of the program stored in the memory 202, it can include the virtual object generation device, and the following software modules are included in the virtual object generation device:
[0111] An information transmission module 2081, configured to trigger a three-dimensional image scanning frame in the game environment where the target object is located;
[0112] An information processing module 2082, configured to determine projection information corresponding to the three-dimensional image scanning frame in the user interface based on the three-dimensional image scanning frame;
[0113] The information processing module 2082 is configured to determine the model pattern and the corresponding contour of the target object according to the projection information corresponding to the three-dimensional image scanning frame in the user interface;
[0114] The information processing module 2082 is configured to respectively perform correction processing on the model pattern and the contour of the target object in the extracted model contour;
[0115] The information processing module 2082 is configured to perform bone binding processing on the model pattern and the contour of the target object after the correction processing, and determine a virtual object in the game environment corresponding to the target object.
[0116] In some embodiments, the server 200 may be an independent physical server, or a server cluster or a distributed system composed of multiple physical servers, or may also be a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs, Content Delivery Networks), and big data and artificial intelligence platforms. The terminal (such as terminal 10-1) may be a smart phone, a tablet computer, a notebook computer, a desktop computer, etc., but is not limited thereto. The terminal and the server may be directly or indirectly connected through wired or wireless communication methods, which are not limited in the embodiments of the present application.
[0117] In practical applications, the virtual object generation device provided in the embodiments of the present application may be applied to the fields of structural biology and medicine, and game strategy discovery, optimization, combination, etc. may be realized through the virtual object generation device.
[0118] According to Figure 2 For the electronic device shown, in one aspect of the present application, the present application further provides a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes different embodiments and combinations of the embodiments provided in various optional implementation manners of the above-mentioned virtual object generation method.
[0119] To overcome the defects of inaccuracy and low efficiency in the virtual object generation process caused by the virtual object generation method in the traditional game environment, the technical solution provided by the present invention uses artificial intelligence technology. Artificial intelligence (AI) is a theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a way similar to human intelligence. Artificial intelligence also studies the design principles and implementation methods of various intelligent machines to enable machines to have the functions of perception, reasoning, and decision-making.
[0120] Artificial intelligence technology is an interdisciplinary subject with a wide range of fields, including both hardware-level technologies and software-level technologies. The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. The software technologies of artificial intelligence mainly include several major directions such as computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0121] Machine learning (ML) is an interdisciplinary subject that involves multiple disciplines such as probability theory, statistics, approximation theory, convex analysis, and algorithm complexity theory. It specifically studies how computers simulate or implement human learning behaviors to acquire new knowledge or skills and reorganize the existing knowledge structure to continuously improve their own performance. Machine learning is the core of artificial intelligence and the fundamental way to make computers intelligent, and its applications cover all fields of artificial intelligence. Machine learning and deep learning usually include technologies such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and rote learning. With the research and progress of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields. For example, common ones include smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, driverless, autonomous driving, drones, robots, smart healthcare, and smart customer service. It is believed that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.
[0122] Continue to combine Figure 2 The virtual object generation device shown to illustrate the virtual object generation method provided by the embodiments of the present invention. Refer to Figure 3 , Figure 3 is an optional process schematic diagram of the virtual object generation method provided by the embodiments of the present invention. It can be understood that Figure 3The steps shown can be executed by various electronic devices running the virtual object generation device. For example, they can be various game devices with a virtual object generation device. Among them, a dedicated terminal with a virtual object generation device can be encapsulated in Figure 1 the terminal 101-1 shown to execute the foregoing Figure 2 corresponding software modules in the image processing device shown. The following will describe Figure 3 the steps shown.
[0123] The following will specifically describe Figure 3 the steps shown.
[0124] Step 301: The virtual object generation device triggers a three-dimensional image scanning frame in the game environment where the target object is located.
[0125] In some embodiments of the present invention, triggering a three-dimensional image scanning frame in the game environment where the target object is located can be achieved in the following manner:
[0126] When the person perspective of the target object changes, obtain the image acquisition parameters transmitted by the sensor data transmission interface corresponding to the user interface; perform parsing processing on the image acquisition parameters to determine the data changes of the image acquisition parameters in different direction dimensions; based on the data changes of the image acquisition parameters in different direction dimensions, determine the changes of the three-dimensional image scanning frame in the game environment where the target object is located. Among them, Figure 4 This is a schematic diagram of triggering a three-dimensional image scanning frame in an embodiment of the present invention. When the game terminal is a mobile phone, a 3D rectangular scanning frame can be calculated according to the gravity sensor of the mobile phone. The target object can be placed on a horizontal plane, and the default scanning frame is a rectangle on the horizontal plane, or it can be selected according to the user's needs. Calculate the coordinates of the rectangular frame in three-dimensional space, that is, the 3D rectangular frame displayed on the screen. Among them, the attitude rotation matrix of the mobile phone camera can be obtained according to the gravity sensor, and the orientation of the camera can be judged by the optical axis direction of the camera to meet the usage requirements of the game environment where the target object is located. In the specific implementation process, the relative offset of the terminal can be obtained by recording the offset corresponding to the initial position when the target object is collected and the instant offset of the user's mobile terminal, that is, output a difference value. Of course, since the output represents a vector value (in the X, Y, and Z directions), the output difference value is a vector difference or the projection of the vector difference on the display screen of the user terminal or the projection in a specific direction. The coordinate reference formula 1 for the four vertices of the rectangular three-dimensional image scanning frame is:
[0127] p0 = v0 + kv1 + k v 1, p1 = v0 - kv1 + kv2, p2 = v0 - kv1 - kv2, p3 = v0 + kv1 - kv2 Formula 1.
[0128] Step 302: The virtual object generation device determines the projection information corresponding to the three-dimensional image scanning frame in the user interface based on the three-dimensional image scanning frame.
[0129] In some embodiments of the present invention, based on the three-dimensional image scanning frame, the image acquisition focal length parameter and the optical center parameter corresponding to the three-dimensional image scanning frame in the user interface can be determined; the projection coordinates of the spatial points of the three-dimensional image scanning frame in the user interface can be determined; according to the image acquisition focal length parameter, the optical center parameter, and the projection coordinates of the spatial points in the user interface, the projection information corresponding to the three-dimensional image scanning frame in the user interface can be determined. Wherein, f is the camera focal length, cx and cy are the camera optical centers, and (u, v) are the projection coordinates of the 3D spatial point p on the screen. The four corner points of the 3D rectangular frame are respectively projected onto the mobile phone screen to obtain (u1, v1), (u2, v2), (u3, v3), (u4, v4). Referring to Formula 2, the quadrilateral formed by the four projection points is used as the ROI (Region of Interest).
[0130]
[0131] Step 303: The virtual object generation device determines the model pattern and the corresponding contour of the target object according to the projection information corresponding to the three-dimensional image scanning frame in the user interface.
[0132] In some embodiments of the present invention, determining the model pattern and the corresponding contour of the target object according to the projection information corresponding to the three-dimensional image scanning frame in the user interface can be achieved by the following methods:
[0133] Determine the region of interest (ROI) of the image corresponding to the 3D image scanning frame according to the projection information corresponding to the 3D image scanning frame in the user interface; determine the image gradient corresponding to the ROI; determine different image complexities according to the image gradient corresponding to the ROI; trigger corresponding contour extraction processes according to different image complexities, and extract the model pattern and corresponding contour of the target object. Among them, when it is determined that the image complexity is of the first type, trigger the first contour extraction process; through the first contour extraction process, use an edge extraction operator to extract the contour of the target object in the projection information; extract the model pattern of the target object based on the extracted contour of the target object. Specifically, the image complexity of the first type indicates that the background image of the target object is relatively simple (for example, it can be a solid color background). First, the average gradient of the image where the target object is located can be statistically calculated. When the image gradient exceeds the target threshold, it is considered that the image where the target object is located is a complex background. In some other embodiments, the proportion of points exceeding the target threshold extracted from the image where the target object is located can be statistically calculated. When the proportion exceeds the target threshold (the target threshold preferred for AR games is 30%), it can be determined that the image where the target object is located is a complex background.
[0134] When it is determined that the image complexity is of the first type, calculate the edge of the image through the first extraction process. Among them, the edge calculation method includes, but is not limited to, extracting the outer contour of the edge of the target object through the Canny operator. Further, since the contours of multiple objects in the game environment may be extracted, the contour with the largest area can be used as the contour of the target object.
[0135] In some embodiments of the present invention, when it is determined that the image complexity is of the second type, a second contour extraction process may be triggered; through the second contour extraction process, an image processing model is used to extract the contour of the target object from the projection information; based on the extracted contour of the target object, the model pattern of the target object is extracted. Among them, through the second contour extraction process, the image processing model may be used to determine the mask cluster parameters of the target object in the projection information; the mask cluster parameters of the target object in the projection information are extracted to determine the contour of at least one object in the projection information; the contour areas of different objects in the projection information are compared, and the contour of the object with the largest contour area is extracted as the contour of the target object extracted from the projection information. Specifically, in actual implementation, the image processing model can identify entities in a frame image through a single-shot multi-box detector (SSD), or an instance segmentation algorithm such as mask RCNN can be used to identify entities in a frame image, which is not limited in the embodiments of the present invention. In practical applications, entities to be identified can be preset in advance, such as only identifying cartoon images in a frame image or identifying anime characters in a frame image. For real-time AR games, the image processing model can be Regions with CNN Features (R-CNN), Fast Regions with CNN Features (FastR-CNN), Faster Regions with CNN Features (Faster R-CNN), and Mask Fast Regions with CNN Features (MaskFast R-CNN), Mask R-CNN, etc., which are not limited in the embodiments of the present application. Among them, Faster R-CNN can generate proposal boxes in only about 10 ms, which can meet the end-to-end real-time application requirements. The mask cluster Mask_cluster is obtained by clustering, and the result error value is relatively large. Therefore, the empirical threshold interval [lower, upper], that is, the pixels close to K in terms of distance, can be traversed at a fixed step length. For each threshold R at each step, a second mask cluster Mask can be obtained. To determine the optimal R value, the IOU (Intersection Of Union) between Mask and Mask_cluster can be calculated. When the IOU takes the maximum value, an optimal R is determined, that is, the best range of the contour is obtained, so that the virtual object corresponding to the target object is more accurate.
[0136] Step 304: The virtual object generation device performs correction processing on the model pattern and the contour of the target object in the extracted model contour respectively.
[0137] In some embodiments of the present invention, a homography matrix matching the target object in the projection information can be determined; a scale factor matching the target object in the projection information is obtained; based on the scale factor and the homography matrix matching the target object in the projection information, correction processing is performed on the model pattern and the contour of the target object in the extracted model contour respectively, so as to make the scale factor and the homography matrix satisfy the corresponding constraint conditions. Among them, refer to Figure 5 , Figure 5 is a schematic diagram of the correction of the model pattern and the contour in the embodiment of the present invention. Among them, the pattern needs to be corrected into a square, and the contour points are corrected synchronously. Let the side length of the corrected square image be W, and the value of W can range from 100 to 1000 depending on the pattern clarity. Then the corner coordinates of the square are (0, 0), (0, W), (W, 0), (W, W). Calculate the Homography matrix H according to the square corner points and the 4 projection points calculated in Step 2, and H satisfies the constraint conditions of Formula 3.
[0138]
[0139] Among them, s is the scale factor, x i , y i are the corner coordinates of the square, which have been given above. Perform affine transformation on the ROI map and the contour through H to obtain the corrected square pattern and the corrected contour.
[0140] Step 305: The virtual object generation device performs bone binding processing on the model pattern and the contour of the target object after correction processing, and determines the virtual object in the game environment corresponding to the target object.
[0141] Continue to refer to Figure 6 , where, refer to Figure 6 , Figure 6 is an optional flowchart of the virtual object generation method provided by the embodiment of the present invention. It can be understood that Figure 6 the steps shown can be executed by various electronic devices running the virtual object generation device. For example, it can be a dedicated terminal with a virtual object generation device, a game strategy database server, or a server cluster of a game operator. Among them, the dedicated terminal with a virtual object generation device can be the electronic device with a virtual object generation device in the previous Figure 2 shown embodiment, including the following steps:
[0142] Step 601: Traverse the contour of the over-corrected target object to determine the target corner point set.
[0143] Among them, the set of target corner points includes at least two corner points. During the generation process of the virtual object, the output of bone binding is the bone joint points of the model and the contour points bound to each bone point. The model area formed by the contour points and the bound bone points can rotate around the bone points, thereby generating various actions. First, analyze the model contour and extract the corner points whose curvature exceeds the curvature threshold. Specifically, the contour points can be sorted in clockwise order first, and for any point p on the contour i and the points with an interval of k (k can take 1, 2, etc.) before and after form two vectors where norm represents normalizing the vector into a unit vector. Determine whether the point has a large curvature according to the inner product of the vectors, and determine whether it is a convex point or a concave point according to the outer product of the vectors. The formula for determining whether point p i is a corner point refers to Formula 4:
[0144]
[0145] where θ is the angle threshold, for example, it can be 30 degrees.
[0146] Step 602: Combine different corner points in the determined set of target corner points to form the bones of the virtual object.
[0147] Among them, the conditions for any two corner points to form a bone are: 1) The distance between the two corner points is less than the target threshold (for example, it can be 10); 2) The contour length between the two corner points is less than half of the total contour length of the model; 3) The contour length between the two corner points divided by the distance between the two corner points is greater than the target threshold (for example, it can be 2).
[0148] Step 603: Traverse all the target corner points in the set of target corner points to determine the bone parameters of the virtual object.
[0149] Among them, refer to Figure 7 , Figure 7 is a schematic diagram of the change in the processing process of the bone parameters in the embodiment of the present invention. Among them, each bone contains parameters and its calculation method is as follows: 1) Joint point coordinates: the midpoint of the two paired corner points; 2) Bound contour: all the contour points between the two paired corner points; 3) Determine the parent node: The whole bone rotates around the joint of the parent bone, which can be omitted when there is no parent node.
[0150] Step 604: Bind the bone parameters of the virtual object and the model pattern of the target object to determine the virtual object in the game environment corresponding to the target object.
[0151] Step 605: Detect the bone parameters of the determined virtual object, and determine the bone parameters with inclusion relationships and the bone parameters with cross relationships.
[0152] Step 606: Delete the bone parameters with inclusion relationships and the bone parameters with cross relationships.
[0153] Among them, refer to Figure 8 , Figure 8 is a schematic diagram of the change in the processing process of bone parameters in an embodiment of the present invention. Due to the complexity of the game environment, there may be inclusion and cross relationships among the bones of all determined virtual objects, and these two situations need to be processed. When all the binding contour points of bone A are within the binding contour of bone B, it is considered that bone B is the parent node of bone A. It is necessary to specify the parent node of bone B as bone A, and at the same time delete the binding contour of B in bone A. When there are common binding contour points between bone A and bone B, and there is no inclusion relationship between A and B, one of the bones needs to be removed. The removal strategies include, but are not limited to: random removal, removing the contour with the shorter contour length.
[0154] In some embodiments of the present invention, due to the different game environments of the virtual object generation device, the noise thresholds of the background images matching the usage environment of the virtual object generation device are also different. For example, in the environment where a role-playing game applet is executed through an instant messaging client process, the noise threshold matching the usage environment of the virtual object generation device needs to be less than the noise threshold in the usage environment when the game user executes a role-playing game through a web game process. Therefore, in the bone processing of the virtual object, the contour with the shorter contour length can be removed to ensure the accuracy of the virtual object generated during the user's game process.
[0155] In some embodiments of the present invention, when the control component in the game environment is triggered, a virtual object is presented in the user interface of the game environment where the target object is located. By triggering different game levels, corresponding game interaction instructions are presented in the user interface using the virtual object. Among them, the interaction instructions can also be generated by detecting the gestures of the virtual object. For example, in a three-dimensional interaction scenario, the interaction instructions can be generated according to the gestures given by the virtual object. The skill identifier is used to uniquely identify a skill. There are often many skills that can be used in the game scene, including attack skills and dodge skills, and each skill corresponds to a skill identifier. The interaction instruction refers to the interaction operation initiated by the user, which is used to control the controlled virtual object to perform corresponding interaction actions.
[0156] Among them, the interaction includes attack interaction, dodge interaction, etc. Among them, the attack can be further divided into close-range attack and long-range attack. Figure 9AFront-end display schematic diagram of the virtual object generation method provided by the embodiments of the present invention Figure 9B Front-end display schematic diagram of the virtual object generation method provided by the embodiments of the present invention. When the user interface is switched, a game level switching component is presented in the switched user interface to enable switching between different game levels through the game level switching component. When the user interface is switched, corresponding game interaction instructions are presented in the user interface by triggering the virtual target. Among them, in the game scenario, the display state matching the virtual target can be adjusted by loading resource files of different games. The resource files may include game models, game levels, game characters, game sounds, game animations, etc. In some embodiments of the present invention, for the usage scenario of making a call to a game user, the adjustment of the sound playback state of the virtual target may also refer to the sound input by the user during the live broadcast (such as player sound, commentary sound, etc.). For role-playing games, the game components (such as obstacles between virtual objects and sound sources in the game) can be graphically analyzed centered on real images, and the sound emitted by the sound source can be rendered according to the results of the graphical analysis, so that the rendered game sound is closer to the physical phenomena in the real world.
[0157] In some embodiments of the present invention, when the target user selects any of the displayed virtual targets, a payment method matching the target user can be determined based on the object feature vector of the target user, or a payment method matching the target user can be determined based on the object feature vector of the target user and the type information of the virtual target; a corresponding payment process is triggered based on the payment method matching the target user. Among them, in the skill battle game, by triggering the corresponding payment process, the user can determine which virtual targets are currently missing according to the adjusted and displayed virtual targets to fill the slots in the container in the vacant state in the user's screen, thereby giving the user more choices and enhancing the user's usage experience.
[0158] In some embodiments of the present invention, the level parameter of the target user and the level parameter of the virtual object can also be determined; according to the level parameter of the target user and the level parameter of the virtual object, the number of virtual objects in the user interface is adjusted through the display control component. Specifically, by increasing the level parameter of the target user and the level parameter of the virtual object, high-level users and high-level virtual objects can adjust the number of virtual objects in the field of view. High-level users can obtain a game operation field of view with a larger viewing angle, and at the same time process at least two target objects in the operation field of view to form at least two virtual objects and display them simultaneously.
[0159] The following uses a role-playing game to illustrate the virtual target generation method provided by this application. Among them, Figure 10 is a front-end display schematic diagram of the virtual target generation method according to an embodiment of the present invention. Among them, refer to Figure 10 , game users usually collect virtual objects of interest (such as game props or cartoon characters) in a virtual environment. Among them, props can generally refer to any movable objects used for decoration and arrangement in the scene (virtual weapons or transportation tools held by game characters). There are also props in the game. Game props are items that provide convenience for game target users. For cartoon characters, real objects (i.e., target objects) in the game environment can be collected, and virtual objects corresponding to the target objects in the game environment can be generated based on the target objects. Specifically, refer to Figure 11 , Figure 11 is an optional flowchart of the virtual target generation method provided by an embodiment of the present invention, which specifically includes the following steps:
[0160] Step 1101: Input an image including a target object collected by a camera.
[0161] Step 1102: Obtain the detection data of the inertial measurement unit.
[0162] Step 1103: Calculate a 3D horizontal rectangular frame.
[0163] Step 1104: Project the rectangular frame onto the mobile phone screen to obtain an ROI.
[0164] Step 1105: Calculate the gradient parameters of the ROI image.
[0165] Step 1106: Determine whether the image background is complex. If so, execute step 1007; otherwise, execute step 1109.
[0166] Step 1107: Perform object segmentation through an image processing network.
[0167] Step 1108: Extract the largest contour based on the segmented Mask.
[0168] Step 1109: Calculate the image edge of the target object.
[0169] Step 1110: Extract the largest contour from the image edge of the target object.
[0170] Step 1111: Generate and output a virtual object corresponding to the target object,
[0171] Beneficial technical effects:
[0172] By triggering a three-dimensional image scanning frame in the game environment where the target object is located; based on the three-dimensional image scanning frame, determining the projection information corresponding to the three-dimensional image scanning frame in the user interface; according to the projection information corresponding to the three-dimensional image scanning frame in the user interface, determining the model pattern and the corresponding contour of the target object; respectively performing correction processing on the model pattern and the contour of the target object in the extracted model contour; performing bone binding processing on the model pattern and the contour of the target object after the correction processing to determine the virtual object in the game environment corresponding to the target object. Thus, not only can the generation accuracy of the virtual object corresponding to the target object in the corresponding game environment be effectively guaranteed, the processing of the target object in a complex environment can be realized, and the processing of games with complex dimensions can be carried out more quickly. At the same time, the automated bone binding is robust and generalizable for different game environments, reducing the computational cost, improving the efficiency of generating virtual objects, and realizing the processing of game environments with complex dimensions.
[0173] The above is only an embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for generating a virtual object, characterized in that, The method includes: Triggering a three-dimensional image scanning frame in the game environment where the target object is located; Based on the three-dimensional image scanning frame, determining the projection information corresponding to the three-dimensional image scanning frame in the user interface; According to the projection information corresponding to the three-dimensional image scanning frame in the user interface, determining the model pattern and corresponding contour of the target object; Determining the homography matrix that matches the target object in the projection information; Obtaining the scale factor that matches the target object in the projection information; Based on the scale factor and homography matrix that match the target object in the projection information, respectively performing correction processing on the model pattern and contour of the target object in the extracted model contour, so that the scale factor and homography matrix meet the corresponding constraint conditions; Performing bone binding processing on the model pattern and contour of the target object after correction processing, and determining the virtual object in the game environment corresponding to the target object.
2. The method according to claim 1, wherein The triggering of the three-dimensional image scanning frame in the game environment where the target object is located includes: When the person perspective of the target object changes, obtaining the image acquisition parameters transmitted by the sensor data transmission interface corresponding to the user interface; Performing parsing processing on the image acquisition parameters to determine the data changes of the image acquisition parameters in different direction dimensions; Based on the data changes of the image acquisition parameters in different direction dimensions, determining the change of the three-dimensional image scanning frame in the game environment where the target object is located.
3. The method according to claim 1, wherein The determining of the projection information corresponding to the three-dimensional image scanning frame in the user interface based on the three-dimensional image scanning frame includes: Based on the three-dimensional image scanning frame, determining the image acquisition focal length parameter and optical center parameter corresponding to the three-dimensional image scanning frame in the user interface; Determining the projection coordinates of the spatial points of the three-dimensional image scanning frame in the user interface; According to the image acquisition focal length parameter, optical center parameter, and the projection coordinates of the spatial points in the user interface, determining the projection information corresponding to the three-dimensional image scanning frame in the user interface.
4. The method according to claim 1, wherein The determining of the model pattern and corresponding contour of the target object according to the projection information corresponding to the three-dimensional image scanning frame in the user interface includes: According to the projection information corresponding to the three-dimensional image scanning frame in the user interface, determining the image region of interest corresponding to the three-dimensional image scanning frame; Determining the image gradient corresponding to the image region of interest; According to the image gradient corresponding to the image region of interest, determining different image complexities; Triggering corresponding contour extraction processes according to different image complexities, and extracting the model pattern and corresponding contour of the target object according to different image complexities.
5. The method according to claim 4, characterized in that, The triggering of corresponding contour extraction processes according to different image complexities, and extracting the model pattern and corresponding contour of the target object according to different image complexities includes: When it is determined that the image complexity is of the first type, triggering the first contour extraction process; Through the first contour extraction process, use an edge extraction operator to extract the contour of the target object in the projection information; Extract the model pattern of the target object based on the extracted contour of the target object.
6. The method according to claim 4, wherein The method of triggering corresponding contour extraction processes according to different image complexities, and extracting the model pattern and corresponding contour of the target object according to different image complexities includes: When it is determined that the image complexity is of the second type, trigger the second contour extraction process; Through the second contour extraction process, use an image processing model to extract the contour of the target object in the projection information; Extract the model pattern of the target object based on the extracted contour of the target object.
7. The method according to claim 6, wherein The step of using an image processing model to extract the contour of the target object in the projection information through the second contour extraction process includes: Through the second contour extraction process, use an image processing model to determine the mask cluster parameters of the target object in the projection information; Extract the mask cluster parameters of the target object in the projection information to determine the contour of at least one object in the projection information; Compare the contour areas of different objects in the projection information, and extract the contour of the object with the largest contour area as the contour of the target object extracted in the projection information.
8. The method according to claim 1, wherein The step of performing bone binding processing on the model pattern and contour of the target object after correction processing to determine the virtual object in the game environment corresponding to the target object includes: Traverse the contour of the target object after correction processing to determine a set of target corner points, where the set of target corner points includes at least two corner points; Combine different corner points in the determined set of target corner points to form the bones of the virtual object; Traverse all the target corner points in the set of target corner points to determine the bone parameters of the virtual object; Bind the bone parameters of the virtual object and the model pattern of the target object to determine the virtual object in the game environment corresponding to the target object.
9. The method according to claim 8, wherein The method further includes: Detect the determined bone parameters of the virtual object to determine the bone parameters with an inclusion relationship and the bone parameters with an intersection relationship; Delete the bone parameters with an inclusion relationship and the bone parameters with an intersection relationship.
10. The method according to claim 1, characterized in that, The method further includes: When the control component in the game environment is triggered, present the virtual object in the user interface of the game environment where the target object is located, By triggering different game levels, present corresponding game interaction instructions in the user interface using the virtual object.
11. The method according to claim 1, characterized in that, The method further includes: When the target user selects any of the displayed virtual targets, Based on the object feature vector of the target user, determine the payment method matching the target user, or, Based on the object features of the target user and the type information of the virtual target, determine the payment method matching the target user; Trigger the corresponding payment process based on the payment method matching the target user.
12. A virtual object generation device, characterized in that, The device includes: An information transmission module, configured to trigger a three-dimensional image scanning frame in a game environment where a target object is located; An information processing module, configured to determine projection information corresponding to the three-dimensional image scanning frame in a user interface based on the three-dimensional image scanning frame; The information processing module is configured to determine a model pattern of the target object and a corresponding contour according to the projection information corresponding to the three-dimensional image scanning frame in the user interface; The information processing module is configured to determine a homography matrix that matches the target object in the projection information; obtain a scale factor that matches the target object in the projection information; based on the scale factor and the homography matrix that match the target object in the projection information, respectively perform correction processing on the model pattern and the contour of the target object in the extracted model contour, so that the scale factor and the homography matrix meet corresponding constraint conditions; The information processing module is configured to perform bone binding processing on the model pattern and the contour of the target object after the correction processing, and determine a virtual object in the game environment corresponding to the target object.
13. An electronic device, characterized in that, The electronic device includes: A memory, configured to store executable instructions; A processor, configured to implement the virtual object generation method according to any one of claims 1 to 11 when running the executable instructions stored in the memory.
14. A computer-readable storage medium storing executable instructions, characterized in that, The executable instructions, when executed by the processor, implement the virtual object generation method according to any one of claims 1-11.
15. A computer program product, comprising computer instructions or a computer program, characterized in that, The computer instructions or computer program, when executed by the processor, implement the virtual object generation method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Method of creating a virtual game environment and interactive game system employing the method
CN108136257A
Ancient building contour extraction method and system based on point cloud
CN108447124A