A method and device for generating a virtual organism

By combining the API interface of the Three.js framework and the AvatarSDK toolkit, a hypertext page is developed to receive and render two-dimensional images uploaded by users, solving the problem that the virtual human model cannot be directly viewed and interacted in the browser, and realizing the 3D virtual human model display that is directly rendered and interacted in the browser.

CN117911615BActive Publication Date: 2025-03-11SHENGMING TECH (GUANGZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311870764.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-29
Publication Date
2025-03-11
Estimated Expiration
2043-12-29

AI Technical Summary

Technical Problem

The existing technology cannot directly view and interact with the generated virtual human models in the browser, and there is a lack of tools that support the browser to directly preview the 3D model, resulting in users needing to install 3D modeling software to view.

Method used

By using the Three.js framework and the API interface provided by the AvatarSDK toolkit, a hypertext page is developed to receive two-dimensional biological images uploaded by the user, generate the corresponding three-dimensional virtual biological model, and directly render and display it in the browser.

Benefits of technology

It realizes that virtual human models can be viewed and interacted with in the browser without installing any software, simplifying the user experience and improving the convenience of operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117911615B_ABST
    Figure CN117911615B_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of 3D modeling, and specifically to a method and device for generating a virtual organism, the method comprising: receiving a two-dimensional organism image uploaded through a browser, generating a three-dimensional virtual organism model corresponding to the two-dimensional organism image, and loading the three-dimensional virtual organism model into a hypertext page; wherein the hypertext page is a page file pre-loaded with a plug-in for running the three-dimensional model; and finally, through the page link corresponding to the hypertext page, the three-dimensional virtual organism model is rendered and displayed on the browser. In the above scheme, the present application does not need to install any software, and the developed hypertext page is deployed on the server, and the constructed three-dimensional virtual organism model is rendered and displayed through the hypertext page. The user only needs to access the page link of the hypertext page, and then upload his own two-dimensional organism image, and the corresponding three-dimensional virtual organism model can be directly rendered in the browser.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of 3D modeling, and in particular to a method and device for generating a virtual organism. Background Art

[0002] Creating a 3D avatar refers to the process of converting a 2D image or photo into a 3D model using certain techniques or tools. It is commonly used in fields such as gaming, filmmaking, virtual reality, and augmented reality.

[0003] At present, the AvatarSDK toolkit is often used to create 3D avatars. The core function of AvatarSDK is to convert the movement of human face and body into digital signals, thereby creating a digital person that can be used in the virtual world. It uses deep learning and computer vision technology to create 3D character models based on input 2D images and standard human body measurements, and supports animation generated after converting static images into dynamic models. In addition, AvatarSDK also provides a set of easy-to-use APIs that can help developers quickly integrate AvatarSDK technology and simplify development work. It can be seen that AvatarSDK is a powerful tool that can help developers create highly realistic 3D virtual avatars, bringing more possibilities to fields such as virtual reality, augmented reality, and game development.

[0004] However, in the above solution, due to the limitations of AvatarSDK itself, the virtual human model generated after the user uploads the picture cannot be directly viewed and interacted with in the browser, and there is no tool on the market that supports direct browser preview of 3D models. It can only be viewed by installing 3D modeling tools such as 3DMax, blender and other software, and the process is relatively cumbersome. Summary of the invention

[0005] In view of this, an embodiment of the present application provides a method and device for generating a virtual organism, which can directly view and interact with the generated virtual human model in a browser.

[0006] In a first aspect, the present application provides a method for generating a virtual organism, the method comprising:

[0007] receiving a two-dimensional biological image uploaded via a browser;

[0008] Generating a three-dimensional virtual organism model corresponding to the two-dimensional organism image;

[0009] Loading the three-dimensional virtual organism model into a hypertext page; wherein the hypertext page is a page file pre-loaded with a plug-in for running the three-dimensional model;

[0010] The three-dimensional virtual organism model is rendered and displayed on the browser through a page link corresponding to the hypertext page.

[0011] According to the above technical means, this application does not need to install any software, but develops a hypertext page and deploys it on the server. A three-dimensional virtual organism model is constructed through the hypertext page and rendered and displayed. Therefore, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser.

[0012] In combination with the first aspect, in one embodiment, before receiving the two-dimensional biological image uploaded by the browser, the method further includes:

[0013] Build a 3D virtual organism generation project in the browser;

[0014] Introducing the Three.js framework into the three-dimensional virtual organism generation project, and compiling the hypertext page of the three-dimensional virtual organism generation project; the hypertext page includes a character portrait upload page and a 3D digital human container display page;

[0015] The written three-dimensional virtual organism generation project is packaged, and the packaged three-dimensional virtual organism generation project is deployed on a server.

[0016] According to the above technical means, this application uses the Three.js framework to render and display the three-dimensional virtual organism model so that it can be directly presented in the browser.

[0017] In combination with the first aspect, in one implementation, the step of building a three-dimensional virtual organism generation project in a browser includes:

[0018] Create a target empty folder, and determine the project packaging entry, hypertext page generation template and project configuration file of the target empty folder;

[0019] Initialize the resource package manager through the command line tool and install the webpack packaging tool;

[0020] Add configuration items in the project configuration file, and package the added target empty folder to build the three-dimensional virtual organism generation project.

[0021] In combination with the first aspect, in one implementation, the three-dimensional virtual organism generation project is introduced with the Three.js framework, including:

[0022] The three.js framework is installed in the three-dimensional virtual organism generation project through the npm command, and the three.js framework is introduced into the hypertext page.

[0023] In combination with the first aspect, in one implementation, the receiving of the two-dimensional biological image uploaded through a browser includes:

[0024] Generate a page link corresponding to the hypertext page;

[0025] The two-dimensional biological image uploaded by the user in the browser by accessing the page link is obtained through the character portrait upload page.

[0026] According to the above technical means, in the present application, the user can access the page link of the hypertext page, and then upload his own two-dimensional organism image, and then generate the corresponding three-dimensional virtual organism model in the browser.

[0027] In combination with the first aspect, in one implementation, generating a three-dimensional virtual organism model corresponding to the two-dimensional organism image includes:

[0028] The two-dimensional organism image is uploaded to the API interface provided by the AvatarSDK toolkit through the character avatar upload page, so as to construct a three-dimensional virtual organism model corresponding to the two-dimensional organism image through the AvatarSDK toolkit.

[0029] According to the above-mentioned technical means, this application uses the API interface for generating three-dimensional virtual organism models provided by the Three.js framework and the AvatarSDK toolkit to develop a hypertext page, deploy it to the server, and use the AvatarSDK toolkit to build a three-dimensional virtual organism model corresponding to the two-dimensional organism image, and use the Three.js framework to directly render and display the three-dimensional virtual organism model in the browser.

[0030] In combination with the first aspect, in one implementation, loading the three-dimensional virtual organism model into a hypertext page includes:

[0031] The three-dimensional virtual organism model is rendered to the 3D digital human container page through the Three.js framework to display the rendered three-dimensional virtual organism model.

[0032] In a second aspect, the present application provides a virtual organism generation device, the device comprising:

[0033] A two-dimensional biological image receiving module, used for receiving a two-dimensional biological image uploaded through a browser;

[0034] A three-dimensional virtual organism model generation module, used to generate a three-dimensional virtual organism model corresponding to the two-dimensional organism image;

[0035] A hypertext page loading module, used for loading the three-dimensional virtual organism model into a hypertext page;

[0036] The browser display module is used to render and display the three-dimensional virtual organism model on the browser through the page link corresponding to the hypertext page.

[0037] In a third aspect, the present application provides a computer device, comprising a processor and a memory, wherein the memory stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement the above-mentioned method for generating a virtual organism.

[0038] In a fourth aspect, the present application provides a computer-readable storage medium, wherein the storage medium stores at least one instruction, and the at least one instruction is loaded and executed by a processor to implement the above-mentioned method for generating a virtual organism.

[0039] The technical solution provided by this application may have the following beneficial effects:

[0040] The present application receives a two-dimensional organism image uploaded by a user through a browser through a page link corresponding to a hypertext page, generates a three-dimensional virtual organism model corresponding to the two-dimensional organism image based on the AvatarSDK toolkit, and renders the three-dimensional virtual organism model to the hypertext page through the Three.js framework; finally, the three-dimensional virtual organism model is rendered and displayed on the browser through a page link corresponding to the hypertext page;

[0041] In the above scheme, the application does not need to install any software. A hypertext page is developed using the API interface for generating a three-dimensional virtual organism model provided by the Three.js framework and the AvatarSDK toolkit and deployed to the server. The three-dimensional virtual organism model corresponding to the two-dimensional organism image can be built through the AvatarSDK toolkit, and the three-dimensional virtual organism model can be directly rendered and displayed in the browser through the Three.js framework. Therefore, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the specific implementation methods of the present application or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0043] Figure 1 The present invention is a flowchart of a method for generating a virtual organism according to an exemplary embodiment.

[0044] Figure 2 The present invention is a flowchart of a method for generating a virtual organism according to an exemplary embodiment.

[0045] Figure 3 The present invention is a flowchart of a method for generating a virtual organism according to an exemplary embodiment.

[0046] Figure 4 It is a structural block diagram of a virtual organism generation device according to an exemplary embodiment.

[0047] Figure 5 A structural block diagram of a computer device shown in an exemplary embodiment of the present application is shown. DETAILED DESCRIPTION

[0048] The technical solution of the present application will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application.

[0049] AvatarSDK is a software development kit that allows developers to create 3D avatars that can be used in various applications, such as virtual reality games, augmented reality applications, and social media platforms; AvatarSDK uses machine learning algorithms to generate high-quality 3D avatars from 2D images. It is a powerful tool for creating personalized digital experiences and can be used in a variety of industries, from entertainment to healthcare.

[0050] Three.js is a third-party WebGL library written in JavaScript. It provides a lot of 3D display functions. It is a 3D engine running in the browser. It can be used to create various three-dimensional scenes, including cameras, lights, shadows, materials and other objects, and finally present 3D effects on the page.

[0051] Due to the limitations of AvatarSDK, the virtual human model generated after the user uploads the picture cannot be directly viewed and interacted with in the browser, and there is no tool on the market that supports the browser to directly preview the 3D model. It can only be viewed by installing 3D modeling tools. Therefore, this application proposes to use the Three.js framework to load the virtual human model generated by AvatarSDK to achieve the purpose of viewing the virtual human effect in the browser.

[0052] Figure 1 FIG. 1 is a flowchart of a method for generating a virtual organism according to an exemplary embodiment. Figure 1 As shown, the method may include the following steps:

[0053] Step S101: receiving a two-dimensional biological image uploaded through a browser.

[0054] In a possible implementation, since the present application needs to render a three-dimensional virtual organism model on the browser, the present embodiment first receives a two-dimensional object image uploaded by the browser. The two-dimensional object image can be a 2D avatar uploaded by the user through the user terminal. That is to say, when the user needs to construct a virtual portrait with a 3D effect, the user uploads the 2D avatar to be converted to the browser through his own user terminal for subsequent three-dimensional construction, thereby obtaining a 3D avatar corresponding to the 2D avatar.

[0055] Step S102: Generate a three-dimensional virtual organism model corresponding to the two-dimensional organism image.

[0056] In a possible implementation, this embodiment pre-develops a hypertext page using the Three.js framework and the API interface for generating a three-dimensional virtual organism model provided by the AvatarSDK toolkit. After obtaining the 2D avatar to be converted (i.e., the above-mentioned two-dimensional organism image), this embodiment calls the API interface provided by the AvatarSDK toolkit through the hypertext page, and constructs a 3D avatar corresponding to the 2D avatar through the AvatarSDK toolkit, i.e., the above-mentioned three-dimensional virtual organism model.

[0057] Step S103: loading the three-dimensional virtual organism model into a hypertext page; wherein the hypertext page is a page file pre-loaded with a plug-in for running the three-dimensional model.

[0058] In a possible implementation, after the three-dimensional virtual organism model is constructed, this embodiment also loads the three-dimensional virtual organism model through the Three.js framework introduced in the hypertext page and renders it to the hypertext page.

[0059] Furthermore, the above-mentioned hypertext page is a page file pre-loaded with a plug-in for running a three-dimensional model. That is to say, the hypertext page introduces the Three.js framework and the API interface for generating a three-dimensional virtual organism model provided by the AvatarSDK toolkit, which is achieved by building a three-dimensional virtual organism generation project in a browser.

[0060] Step S104: Render and display the three-dimensional virtual organism model on the browser through the page link corresponding to the hypertext page.

[0061] In a possible implementation, after the three-dimensional virtual organism model is loaded and rendered into a hypertext page, in order to display the three-dimensional virtual organism model in a browser, the three-dimensional virtual organism model can be rendered and displayed on the browser through a page link corresponding to the hypertext page. At this time, the three-dimensional virtual organism model can be directly rendered and displayed in the browser; that is, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser.

[0062] In summary, the present application receives a two-dimensional organism image uploaded by a user through a browser through a page link corresponding to a hypertext page, generates a three-dimensional virtual organism model corresponding to the two-dimensional organism image based on the AvatarSDK toolkit, and renders the three-dimensional virtual organism model to the hypertext page through the Three.js framework; finally, the three-dimensional virtual organism model is rendered and displayed on the browser through a page link corresponding to the hypertext page;

[0063] In the above scheme, the application does not need to install any software. A hypertext page is developed using the API interface for generating a three-dimensional virtual organism model provided by the Three.js framework and the AvatarSDK toolkit and deployed to the server. The three-dimensional virtual organism model corresponding to the two-dimensional organism image can be built through the AvatarSDK toolkit, and the three-dimensional virtual organism model can be directly rendered and displayed in the browser through the Three.js framework. Therefore, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser.

[0064] Figure 2 FIG. 1 is a flowchart of a method for generating a virtual organism according to an exemplary embodiment. Figure 2 As shown, the method may include the following steps:

[0065] Step S201: Build a three-dimensional virtual organism generation project in a browser.

[0066] In a possible implementation, step S201 includes:

[0067] Create a target empty folder, and determine the project packaging entry, hypertext page generation template and project configuration file of the target empty folder;

[0068] Initialize the resource package manager through the command line tool and install the webpack packaging tool;

[0069] Add configuration items to the project configuration file, and package the added target empty folder to build the three-dimensional virtual organism generation project.

[0070] For further information, see Figure 3 A method flow chart of a virtual organism generation method is shown. In this embodiment, a project is first built, namely the above-mentioned three-dimensional virtual organism generation project; building a project refers to generating a directory structure of the three-dimensional virtual organism generation project in a browser. Since this project needs to run in a browser, the project structure is built in order to install dependent resources during the development process and to package the code after the project development is completed. The packaged code can then run on the browser.

[0071] As mentioned above, the specific steps of building a 3D virtual organism generation project include:

[0072] 1. Create an empty target folder, use main.js as the project packaging entry, index.html as the template for packaging and generating HTML pages (that is, the hypertext page generation template mentioned above), and package.json as the project configuration file;

[0073] 2. Use the command line tool to execute the npminit-y command to initialize the resource package manager to prepare for the subsequent installation of project resources;

[0074] 3. Install the webpack packaging tool through the npminstall webpack--save-dev command;

[0075] 4. Add the "build" configuration item in the package.json command, that is, build:webpack, and then use the npmrun build command to package and build the three-dimensional virtual organism generation project.

[0076] Step S202: Introduce the Three.js framework into the three-dimensional virtual organism generation project, and compile the hypertext page of the three-dimensional virtual organism generation project; the hypertext page includes a character portrait upload page and a 3D digital human container page. The character portrait upload page is used to obtain the two-dimensional organism image uploaded by the browser, and upload the two-dimensional organism image to the API interface provided by the AvatarSDK toolkit to construct the three-dimensional virtual organism model through the AvatarSDK toolkit; the 3D digital human container page is used to render and display the three-dimensional virtual organism model;

[0077] In a possible implementation, step S202 includes:

[0078] The three.js framework is installed in the three-dimensional virtual organism generation project through the npm command (i.e., the following npminstall three--save command), and the three.js framework is introduced into the hypertext page.

[0079] Further, such as Figure 3 As shown, after building the project, introduce the three.js plug-in and write a hypertext page. As mentioned above, the specific steps of introducing the Three.js framework include:

[0080] 1. Install the three.js framework through the npm install three --save command.

[0081] 2. Import three.js into HTML by importing three from'three'.

[0082] like Figure 3 As shown, the specific steps of writing the hypertext page of the three-dimensional virtual organism generation project include:

[0083] 1. Write the entry page for uploading avatars (that is, write the avatar upload page) to obtain the avatar image uploaded by the user and upload the user's avatar image to the API interface provided by the AvatarSDK toolkit.

[0084] 2. Write a container page for displaying 3D digital humans (i.e., write the container page for displaying 3D digital humans). After uploading the user's avatar image to the API interface provided by the AvatarSDK toolkit, a gltf model file (i.e., the file corresponding to the three-dimensional virtual organism model) will be returned. Then, use the GLTFLoader loader provided by the three.js framework to load the gltf model file into the html page (i.e., the above-mentioned hypertext page). Then, use the THREE.WebGLRenderer method to render the three-dimensional virtual organism model into the html page (i.e., the above-mentioned hypertext page).

[0085] In a possible implementation, after step S202, the written three-dimensional virtual organism generation project is packaged, and the packaged three-dimensional virtual organism generation project is deployed on a server; that is, the written three-dimensional virtual organism generation project and the compressed code are packaged to obtain a compressed hypertext page;

[0086] The compressed hypertext page is deployed on the server.

[0087] Furthermore, the specific steps of packaging and deploying the written three-dimensional virtual organism generation project include:

[0088] 1. Use the webpack packaging tool to package the three-dimensional virtual organism generation project, and the npm run build command to package the compressed code. After packaging, a compressed html page (that is, the above-mentioned hypertext page) will be generated.

[0089] 2. Deploy the compressed HTML page to the server.

[0090] Step S203: Generate a page link corresponding to the hypertext page, and obtain the two-dimensional biological image uploaded by the user in the browser by accessing the page link through the character portrait upload page.

[0091] Furthermore, the page link is used for user access to upload the two-dimensional biological image through a browser.

[0092] Step S204: upload the two-dimensional organism image to the API interface provided by the AvatarSDK toolkit through the character avatar upload page, so as to construct a three-dimensional virtual organism model corresponding to the two-dimensional organism image through the AvatarSDK toolkit.

[0093] Furthermore, the character portrait upload page is equivalent to the portrait upload entrance, that is, the upload entrance of the two-dimensional biological image.

[0094] Step S205: Render the three-dimensional virtual organism model to the 3D digital human container page through the Three.js framework to display the rendered three-dimensional virtual organism model.

[0095] Furthermore, the page showing the 3D digital human container is equivalent to a rendering display page of a three-dimensional virtual organism model.

[0096] Step S206: Render and display the three-dimensional virtual organism model on the browser through the page link corresponding to the hypertext page.

[0097] In summary, the present application receives a two-dimensional organism image uploaded by a user through a browser through a page link corresponding to a hypertext page, generates a three-dimensional virtual organism model corresponding to the two-dimensional organism image based on the AvatarSDK toolkit, and renders the three-dimensional virtual organism model to the hypertext page through the Three.js framework; finally, the three-dimensional virtual organism model is rendered and displayed on the browser through a page link corresponding to the hypertext page;

[0098] In the above scheme, the application does not need to install any software. A hypertext page is developed using the API interface for generating a three-dimensional virtual organism model provided by the Three.js framework and the AvatarSDK toolkit and deployed to the server. The three-dimensional virtual organism model corresponding to the two-dimensional organism image can be built through the AvatarSDK toolkit, and the three-dimensional virtual organism model can be directly rendered and displayed in the browser through the Three.js framework. Therefore, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser.

[0099] Figure 4 1 is a block diagram of a virtual organism generation device according to an exemplary embodiment. The device includes:

[0100] The two-dimensional biological image receiving module 401 is used to receive the two-dimensional biological image uploaded through the browser;

[0101] A three-dimensional virtual organism model generating module 402 is used to generate a three-dimensional virtual organism model corresponding to the two-dimensional organism image;

[0102] A hypertext page loading module 403 is used to load the three-dimensional virtual organism model into a hypertext page;

[0103] The browser display module 404 is used to render and display the three-dimensional virtual organism model on the browser through the page link corresponding to the hypertext page.

[0104] In a possible implementation manner, the device is further used for:

[0105] Build a 3D virtual organism generation project in the browser;

[0106] The Three.js framework is introduced into the three-dimensional virtual organism generation project, and the hypertext page of the three-dimensional virtual organism generation project is written; the hypertext page includes a character portrait upload page and a 3D digital human container display page;

[0107] The written three-dimensional virtual organism generation project is packaged, and the packaged three-dimensional virtual organism generation project is deployed on a server.

[0108] In a possible implementation manner, the device is further used for:

[0109] Create a target empty folder, and determine the project packaging entry, hypertext page generation template and project configuration file of the target empty folder;

[0110] Initialize the resource package manager through the command line tool and install the webpack packaging tool;

[0111] Add configuration items to the project configuration file, and package the added target empty folder to build the three-dimensional virtual organism generation project.

[0112] In a possible implementation manner, the device is further used for:

[0113] Through the npm command, the three.js framework is installed in the three-dimensional virtual organism generation project, and the three.js framework is introduced into the hypertext page.

[0114] In a possible implementation manner, the two-dimensional biological image receiving module 401 is further used for:

[0115] Generate a page link corresponding to the hypertext page;

[0116] The two-dimensional biological image uploaded by the user in the browser by accessing the link of the page is obtained through the character portrait upload page.

[0117] In a possible implementation, the three-dimensional virtual organism model generation module 402 is further used to:

[0118] The two-dimensional organism image is uploaded to the API interface provided by the AvatarSDK toolkit through the character avatar upload page, so as to construct a three-dimensional virtual organism model corresponding to the two-dimensional organism image through the AvatarSDK toolkit.

[0119] In a possible implementation manner, the hypertext page loading module 403 is further used to:

[0120] The three-dimensional virtual organism model is rendered to the 3D digital human container page through the Three.js framework to display the rendered three-dimensional virtual organism model.

[0121] In summary, the present application receives a two-dimensional organism image uploaded by a user through a browser through a page link corresponding to a hypertext page, generates a three-dimensional virtual organism model corresponding to the two-dimensional organism image based on the AvatarSDK toolkit, and renders the three-dimensional virtual organism model to the hypertext page through the Three.js framework; finally, the three-dimensional virtual organism model is rendered and displayed on the browser through a page link corresponding to the hypertext page;

[0122] In the above scheme, the application does not need to install any software. A hypertext page is developed using the API interface for generating a three-dimensional virtual organism model provided by the Three.js framework and the AvatarSDK toolkit and deployed to the server. The three-dimensional virtual organism model corresponding to the two-dimensional organism image can be built through the AvatarSDK toolkit, and the three-dimensional virtual organism model can be directly rendered and displayed in the browser through the Three.js framework. Therefore, the user only needs to access the page link of the hypertext page and then upload his own two-dimensional organism image to generate the corresponding three-dimensional virtual organism model in the browser.

[0123] See also Figure 5 , which is a schematic diagram of a computer device provided according to an exemplary embodiment of the present application, the computer device includes a memory and a processor, the memory is used to store a computer program, and when the computer program is executed by the processor, the above-mentioned method for generating a virtual organism is implemented.

[0124] The processor may be a central processing unit (CPU). The processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or a combination of the above chips.

[0125] As a non-transitory computer-readable storage medium, the memory can be used to store non-transitory software programs, non-transitory computer executable programs and modules, such as program instructions / modules corresponding to the method in the implementation of the present application. The processor executes various functional applications and data processing of the processor by running the non-transitory software programs, instructions and modules stored in the memory, that is, implementing the method in the above method implementation.

[0126] The memory may 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; the data storage area may store data created by the processor, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-transitory memory, such as at least one disk storage device, a flash memory device, or other non-transitory solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0127] In an exemplary embodiment, a computer-readable storage medium is also provided, which is used to store at least one computer program, and the at least one computer program is loaded and executed by a processor to implement all or part of the steps in the above method. For example, the computer-readable storage medium can be a read-only memory (ROM), a random access memory (RAM), a compact disc read-only memory (CD-ROM), a magnetic tape, a floppy disk, an optical data storage device, etc.

[0128] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the application disclosed herein. The present application is intended to cover any variations, uses or adaptations of the present application, which follow the general principles of the present application and include common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.

[0129] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.

Claims

1. A method for generating a virtual organism, characterized in that: The method comprises: receiving a two-dimensional biological image uploaded via a browser; Generating a three-dimensional virtual organism model corresponding to the two-dimensional organism image; Loading the three-dimensional virtual organism model into a hypertext page; wherein the hypertext page is a page file pre-loaded with a plug-in for running the three-dimensional model; Rendering and displaying the three-dimensional virtual organism model on the browser through a page link corresponding to the hypertext page; Before receiving the two-dimensional biological image uploaded by the browser, the method further includes: Build a 3D virtual organism generation project in the browser; Introducing the Three.js framework into the three-dimensional virtual organism generation project, and compiling the hypertext page of the three-dimensional virtual organism generation project; the hypertext page includes a character portrait upload page and a 3D digital human container display page; Packaging the written three-dimensional virtual organism generation project, and deploying the packaged three-dimensional virtual organism generation project on a server; The step of generating a three-dimensional virtual organism model corresponding to the two-dimensional organism image comprises: Uploading the two-dimensional organism image to the API interface provided by the AvatarSDK toolkit through the character avatar upload page, so as to construct a three-dimensional virtual organism model corresponding to the two-dimensional organism image through the AvatarSDK toolkit; After the three-dimensional virtual organism model is constructed, the three-dimensional virtual organism model is loaded through the Three.js framework introduced in the hypertext page and rendered to the hypertext page.

2. The method according to claim 1, characterized in that The three-dimensional virtual organism generation project is constructed in the browser, including: Create a target empty folder, and determine the project packaging entry, hypertext page generation template and project configuration file of the target empty folder; Initialize the resource package manager through the command line tool and install the webpack packaging tool; Add configuration items in the project configuration file, and package the added target empty folder to build the three-dimensional virtual organism generation project.

3. The method according to claim 1, characterized in that The Three.js framework is introduced into the three-dimensional virtual organism generation project, including: The three.js framework is installed in the three-dimensional virtual organism generation project through the npm command, and the three.js framework is introduced into the hypertext page.

4. The method according to claim 1, characterized in that: The receiving of the two-dimensional biological image uploaded by the browser comprises: Generate a page link corresponding to the hypertext page; The two-dimensional biological image uploaded by the user in the browser by accessing the page link is obtained through the character portrait upload page.

5. The method according to any one of claims 1 to 4, characterized in that: The step of loading the three-dimensional virtual organism model into a hypertext page comprises: The three-dimensional virtual organism model is rendered to the 3D digital human container page through the Three.js framework to display the rendered three-dimensional virtual organism model.

6. A virtual organism generating device, characterized in that: The device comprises: A two-dimensional biological image receiving module, used for receiving a two-dimensional biological image uploaded through a browser; A three-dimensional virtual organism model generation module, used to generate a three-dimensional virtual organism model corresponding to the two-dimensional organism image; A hypertext page loading module, used for loading the three-dimensional virtual organism model into a hypertext page; A browser display module, used for rendering and displaying the three-dimensional virtual organism model on the browser through a page link corresponding to the hypertext page; The device is also used to: build a three-dimensional virtual organism generation project in a browser; Introducing the Three.js framework into the three-dimensional virtual organism generation project, and compiling the hypertext page of the three-dimensional virtual organism generation project; the hypertext page includes a character portrait upload page and a 3D digital human container display page; Packaging the written three-dimensional virtual organism generation project, and deploying the packaged three-dimensional virtual organism generation project on a server; The three-dimensional virtual organism model generation module is also used for: Uploading the two-dimensional organism image to the API interface provided by the AvatarSDK toolkit through the character avatar upload page, so as to construct a three-dimensional virtual organism model corresponding to the two-dimensional organism image through the AvatarSDK toolkit; The device is also used for: after constructing the three-dimensional virtual organism model, loading the three-dimensional virtual organism model through the Three.js framework introduced in the hypertext page, and rendering it to the hypertext page.

7. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement a virtual organism generation method as described in any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that: The storage medium stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement a virtual organism generation method as described in any one of claims 1 to 5.