Product rendering method and device

By obtaining the physical pictures of the product and extracting color and material information, and automatically rendering the three-dimensional model using image recognition technology, the problem of large workload and long cycle of manual rendering is solved, efficient automatic rendering is achieved, and cost is reduced.

CN111833407BInactive Publication Date: 2024-11-19GREE ELECTRIC APPLIANCE INC OF ZHUHAI
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010543699.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-06-15
Publication Date
2024-11-19
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

In the prior art, manual product rendering is large and the work cycle is long, making it difficult to achieve efficient automatic rendering.

Method used

By obtaining the real picture of the product, extracting color information and material information, and automatically rendering the three-dimensional model based on this information, using image recognition technology to match feature points, combining shooting data at different light brightness, calculating the reflectance to determine the material information, and then automatically Adjust the three-dimensional model parameters.

Benefits of technology

It realizes automatic rendering of products, reduces the workload of rendering work, improves work efficiency, reduces labor costs, and shortens the rendering cycle.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111833407B_ABST
    Figure CN111833407B_ABST
Patent Text Reader

Abstract

The present invention discloses a product rendering method and device. The method comprises: obtaining a physical picture of a product; extracting color information and material information of the product according to the physical picture; and rendering a three-dimensional model of the product according to the color information and the material information. The present invention is based on image recognition, automatically extracts color information and material information of the product from the physical picture of the product, and automatically renders the three-dimensional model of the product according to the color information and material information of the product, thereby realizing automatic rendering of the product, reducing the workload of rendering work, improving work efficiency, and reducing labor costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to a product rendering method and device. Background Art

[0002] In the process of product promotion, product rendered images are often used. Compared with photos, rendered images can often achieve special effects that cannot be achieved by taking photos, thus having better promotional effects.

[0003] Currently, product rendering is done manually. After obtaining the 3D model of the product, people render each component of the 3D file separately according to the expected or actual color and material. The more complex the product, the greater the rendering workload and the longer the work cycle. Summary of the invention

[0004] The embodiments of the present invention provide a product rendering method and device, so as to at least solve the problem of manual product rendering in the prior art, which has a large workload and a long working cycle.

[0005] To solve the above technical problems, an embodiment of the present invention provides a product rendering method, comprising:

[0006] Get physical pictures of the product;

[0007] Extracting color information and material information of the product according to the physical image;

[0008] The three-dimensional model of the product is rendered according to the color information and the material information.

[0009] Optionally, obtain physical images of the product, including:

[0010] Extracting a view of the product in at least one direction according to the three-dimensional model of the product;

[0011] The product is photographed in real life in at least one direction under a first light brightness and a second light brightness, respectively, to obtain real images of the product in at least one direction under different light brightnesses, wherein the product in the real image matches feature points of the product in the view of the corresponding direction.

[0012] Optionally, before photographing the product in real life in the at least one direction, the method further includes: outputting prompt information of light brightness and / or photographing direction.

[0013] Optionally, extracting color information of the product based on the physical image includes: identifying the color of each pixel in the physical image of the product in at least one direction under a first light brightness, to obtain the color information of the product.

[0014] Optionally, extracting material information of the product according to the physical image includes:

[0015] Determine the reflectivity of each pixel point according to the physical image of the product in at least one direction under the first light brightness and the physical image of the product in at least one direction under the second light brightness;

[0016] According to the preset correspondence between reflectivity and material, the material of each pixel is determined to obtain the material information of the product; wherein the brightness of the second light is greater than the brightness of the first light.

[0017] Optionally, determining the reflectivity of each pixel point according to a physical image of the product in at least one direction under a first light brightness and a physical image of the product in at least one direction under a second light brightness includes:

[0018] Obtaining a first brightness value of each pixel in the physical object picture in at least one direction under the brightness of the first light;

[0019] Obtaining a second brightness value of each pixel in the real object picture in at least one direction under the brightness of the second light;

[0020] The difference between the first brightness value and the second brightness value of the pixel point at the same position in the real object picture under the first light brightness and the real object picture under the second light brightness in the same direction is calculated as the reflectivity of the pixel point at the same position.

[0021] Optionally, rendering the three-dimensional model of the product according to the color information and the material information includes:

[0022] Determine corresponding color parameters and material parameters according to the color information and the material information;

[0023] The original parameters of the three-dimensional model of the product are modified according to the color parameters and the material parameters to complete automatic rendering.

[0024] The embodiment of the present invention further provides a product rendering device, comprising:

[0025] The acquisition module is used to obtain the physical image of the product;

[0026] An extraction module, used to extract the color information and material information of the product according to the physical image;

[0027] A rendering module is used to render the three-dimensional model of the product according to the color information and the material information.

[0028] The embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the product rendering method as described in the embodiment of the present invention is implemented.

[0029] An embodiment of the present invention also provides an electronic device, comprising: one or more processors; and a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the product rendering method as described in the embodiment of the present invention.

[0030] By applying the technical solution of the present invention, the color information and material information of the product are automatically extracted from the physical picture of the product based on image recognition, and the three-dimensional model of the product is automatically rendered according to the color information and material information of the product, thereby realizing automatic rendering of the product, reducing the workload of rendering work, improving work efficiency, and reducing labor costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 is a flow chart of a product rendering method provided by an embodiment of the present invention;

[0032] Figure 2 is a schematic diagram of a product rendering process provided by an embodiment of the present invention;

[0033] Figure 3 It is a structural block diagram of a product rendering device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0034] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0035] An embodiment of the present invention provides a product rendering method, which can realize automatic rendering of a three-dimensional model of a product. Figure 1 is a flow chart of a product rendering method provided by an embodiment of the present invention, such as Figure 1 As shown, the method comprises the following steps:

[0036] S101, obtaining a physical picture of the product.

[0037] S102: extracting color information and material information of the product according to the physical image.

[0038] S103: Rendering the three-dimensional model of the product according to the color information and the material information.

[0039] This embodiment is based on image recognition, automatically extracts product color information and material information from the physical picture of the product, and automatically renders the three-dimensional model of the product based on the product color information and material information, thereby realizing automated rendering of the product, reducing the workload of rendering work, improving work efficiency, and reducing labor costs.

[0040] In one embodiment, obtaining a physical picture of a product includes: extracting a view of the product in at least one direction based on a three-dimensional model of the product; and photographing the product in the at least one direction under a first light brightness and a second light brightness, respectively, to obtain a physical picture of the product in the at least one direction under different light brightnesses, wherein feature points of the product in the physical picture match those of the product in the view in the corresponding direction.

[0041] Among them, the view in at least one direction can be at least one of the six views, and the six views refer to the views in the six directions of front, back, left, right, top and bottom, that is, the main view, the rear view, the left view, the right view, the top view and the bottom view. The specific direction can be determined according to the actual rendering requirements. In this embodiment, a real picture in at least one direction is obtained at each light brightness, and the product in each real picture matches the feature points of the product in the view of the corresponding direction, so that the product color and material extracted according to the real picture can more accurately meet the rendering requirements of the three-dimensional model.

[0042] Before taking a physical photo of the product in the at least one direction, the method may further include: outputting prompt information of light brightness and / or shooting direction to remind the user of the required light brightness and / or shooting direction, so as to obtain a physical photo that meets the requirements as soon as possible and improve efficiency.

[0043] Specifically, the physical picture can be obtained by taking a photo or by video. For the photo method, if the target product does not appear in the current picture, or the product feature points in the current picture do not completely match those in the view of the corresponding direction, then take a new photo. For the video method, each frame of the video stream shot in the current direction can be read, and using feature matching technology, if the product in the current picture completely matches the product feature points in the view of the corresponding direction, then the current picture is determined as the physical picture in the current direction. Feature matching can use existing algorithms, which are not described in detail in this embodiment. The target product is identified and located in the physical picture taken through image recognition technology, and then the color and material of the physical product are read from the physical picture, and the three-dimensional model is rendered based on this, thereby completing automatic rendering.

[0044] The second light brightness is greater than the first light brightness. The first light brightness may be a normal ambient brightness, and the second light brightness may be a light brightness corresponding to adding a preset flash parameter under the normal ambient brightness, for example, turning on the flash of a camera device.

[0045] In an optional embodiment, extracting the color information of the product based on the physical image includes: identifying the color of each pixel in the physical image of the product in at least one direction under the first light brightness to obtain the color information of the product. The color information of the product is determined based on the normal ambient brightness, and the result is more accurate and reliable.

[0046] In an optional embodiment, extracting the material information of the product according to the physical image includes: determining the reflectivity of each pixel according to the physical image of the product in at least one direction under a first light brightness and the physical image of the product in at least one direction under a second light brightness; determining the material of each pixel according to a preset correspondence between reflectivity and material, and obtaining the material information of the product. Under the same conditions, different materials correspond to different reflectivity (also called reflectivity) ranges, for example, plastic materials have lower reflectivity and glass materials have higher reflectivity.

[0047] This implementation determines the reflectivity of each pixel based on the comparison of real-life images under different light brightnesses, and then comprehensively obtains the material information of the product according to the different reflectivities corresponding to different materials, thereby providing accurate and reliable material information for subsequent automatic rendering of the product.

[0048] Further, the reflectivity of each pixel is determined based on the physical picture of the product in at least one direction under the first light brightness and the physical picture of the product in at least one direction under the second light brightness, including: obtaining the first brightness value of each pixel in the physical picture in at least one direction under the first light brightness; obtaining the second brightness value of each pixel in the physical picture in at least one direction under the second light brightness; calculating the difference between the first brightness value and the second brightness value of the pixel at the same position in the physical picture under the first light brightness and the physical picture under the second light brightness in the same direction as the reflectivity of the pixel at the same position. In this way, the reflectivity of each pixel can be obtained based on the physical pictures under different light brightnesses in the same direction, and the calculation is simple and reliable.

[0049] In one embodiment, rendering the three-dimensional model of the product according to the color information and the material information includes: determining corresponding color parameters and material parameters according to the color information and the material information; modifying the original parameters of the three-dimensional model of the product according to the color parameters and the material parameters to complete automatic rendering. Specifically, the color and material of each pixel point can be mapped to the three-dimensional model according to the corresponding relationship between the pixel point position of the physical picture and the three-dimensional model.

[0050] In this embodiment, for each direction, a real picture of the product under the first light brightness (called a regular picture) and a real picture of the product under the second light brightness (called a flashing picture) are obtained in that direction; the color information of each part of the product in that direction is obtained based on the regular picture, and the color of the corresponding part in the three-dimensional model is set; the material information of each part of the product in that direction is obtained based on the regular picture and the flashing picture, and the material of the corresponding part in the three-dimensional model is set. In this way, after the color and material of all directions of the three-dimensional model are set, the automatic rendering is completed, which reduces the cycle of two or three days for manual rendering to a few minutes.

[0051] After the automatic rendering is completed, correction information can also be received, and the rendering result can be corrected according to the correction information, so as to further ensure the satisfaction of the product rendering effect. Among them, the correction information can be input by the user.

[0052] Combine the following Figure 2 The above product rendering scheme is described, however, it is worth noting that this specific embodiment is only for better illustrating the present application and does not constitute an improper limitation on the present application. The explanation of terms that are the same or corresponding to the above embodiment will not be repeated in this embodiment.

[0053] refer to Figure 2 , the steps are as follows:

[0054] S201, after completing product design, the designer logs into the rendering software, creates a rendering project P, and uploads the 3D model file of the project P.

[0055] S202, analyzing the three-dimensional model to obtain views of the three-dimensional model in six directions (also called six faces): front, back, left, right, top, and bottom.

[0056] S203, select the view of the X side of the product, and prompt the user to take a picture of the X side of the real product to obtain a regular picture. For example, for the left view, take a real picture from the left side of the product.

[0057] S204, the view of the X side of the product and the regular picture taken by the user are matched with feature point matching technology to perform product recognition.

[0058] S205, whether the target product is recognized, if so, determine the current picture as the final regular picture, and proceed to step S206; if not, return to step S203 and retake. In a specific application, each frame of the video stream can be read, and feature matching technology can be used to try to identify the target product shown in the view in each frame, until the target product is recognized in one of the frames, and the frame is saved as the final regular picture.

[0059] S206, providing the product X-side view again, prompting the user to take a photo of the X-side of the actual product again and turn on the flash to obtain a flash picture.

[0060] S207, the view of the X side of the product and the flash picture taken by the user are used to identify the product by using feature point matching technology.

[0061] S208, whether the target product is recognized, if so, determine the current picture as the final flash picture, and enter step S209; if not, return to step S206 and retake. In a specific application, each frame of the video stream can be read, and the feature matching technology can be used to try to identify the target product shown in the view in each frame, until the target product is recognized in one of the frames, and the frame is saved as the final flash picture.

[0062] S209, determine that a flash image that meets the requirements is obtained, and start extracting color information and material information. Read the color information of the product from the conventional image of the X side of the product, and set the color of the corresponding part in the 3D model file.

[0063] S210, compare the brightness difference of the target product in the regular image and the flash image of the X surface, obtain the reflectivity of each component of the target product on the X surface, and according to the preset relationship between the reflectivity and the material (for example, low reflectivity is plastic, medium reflectivity is metal, and high reflectivity is glass), convert the reflectivity information into material information, and set the material for the corresponding part in the three-dimensional model file.

[0064] S211, determine whether the views in six directions have been rendered, if so, proceed to step S213, if not, proceed to step S212.

[0065] S212, set the side that has not been photographed as a new X side, and return to step S203.

[0066] S213, complete product rendering.

[0067] The user can proofread and adjust the final rendering result. It should be noted that if the shooting terminal does not have a camera function, you can take a photo. If the target product is not recognized in the photographed picture, take another photo.

[0068] Exemplarily, the above product rendering method can be implemented by automated rendering software. The software can be installed on a terminal with a 3D model design function and a shooting function. If the terminal does not have a 3D model design function, the user uses the terminal to log in to the rendering software, receives the 3D model file transmitted from other devices through WIFI, Bluetooth, USB, etc., selects the corresponding rendering project to start the automated rendering process, obtains the physical product picture, and transmits the rendered file to the target device after the rendering is completed.

[0069] Based on the same inventive concept, an embodiment of the present invention further provides a product rendering device, which can be used to implement the product rendering method described in the above embodiment. The device can be implemented by software and / or hardware, and the device can generally be integrated in a terminal.

[0070] Figure 3 is a structural block diagram of a product rendering device provided by an embodiment of the present invention, such as Figure 3 As shown, the device comprises:

[0071] An acquisition module 31 is used to acquire a physical image of a product;

[0072] An extraction module 32, used to extract the color information and material information of the product according to the physical image;

[0073] The rendering module 33 is used to render the three-dimensional model of the product according to the color information and the material information.

[0074] Optionally, the acquisition module 31 includes:

[0075] an extraction unit, configured to extract a view of the product in at least one direction according to the three-dimensional model of the product;

[0076] A shooting unit is used to take a real-life picture of the product in the at least one direction under a first light brightness and a second light brightness, respectively, to obtain a real-life picture of the product in the at least one direction under different light brightnesses, wherein the product in the real-life picture matches feature points of the product in the view of the corresponding direction.

[0077] Optionally, the device further includes: an output module, configured to output prompt information of light brightness and / or shooting direction before physically shooting the product in the at least one direction.

[0078] Optionally, the extraction module 32 includes: an identification unit, configured to identify the color of each pixel in a physical image of the product in at least one direction under the first light brightness, to obtain color information of the product.

[0079] Optionally, the extraction module 32 includes:

[0080] A first determination unit determines the reflectivity of each pixel point according to a physical image of the product in at least one direction under a first light brightness and a physical image of the product in at least one direction under a second light brightness;

[0081] The second determination unit is used to determine the material of each pixel point according to the preset correspondence between the reflectivity and the material, so as to obtain the material information of the product; wherein the brightness of the second light is greater than the brightness of the first light.

[0082] Optionally, the first determining unit includes:

[0083] A first acquisition subunit, used to acquire a first brightness value of each pixel point in the real object picture in at least one direction under the brightness of the first light;

[0084] A second acquisition subunit is used to acquire a second brightness value of each pixel point in the real object picture in at least one direction under the brightness of the second light;

[0085] The calculation subunit is used to calculate the difference between the first brightness value and the second brightness value of the pixel point at the same position in the real object picture under the first light brightness and the real object picture under the second light brightness in the same direction as the reflectivity of the pixel point at the same position.

[0086] Optionally, the rendering module 33 includes:

[0087] A third determining unit, configured to determine corresponding color parameters and material parameters according to the color information and the material information;

[0088] The rendering unit is used to modify the original parameters of the three-dimensional model of the product according to the color parameters and the material parameters to complete automatic rendering.

[0089] The above device can execute the method provided by the embodiment of the present invention, and has the functional modules and beneficial effects corresponding to the execution method. For technical details not described in detail in this embodiment, please refer to the method provided by the embodiment of the present invention.

[0090] An embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the product rendering method as described in the above embodiment is implemented.

[0091] An embodiment of the present invention also provides an electronic device, comprising: one or more processors; a memory, communicatively connected to the one or more processors, and used to store one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the product rendering method as described in the above embodiments.

[0092] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0093] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0094] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A product rendering method, characterized in that: include: Get physical pictures of the product; Extracting color information and material information of the product according to the physical image; Rendering a three-dimensional model of the product according to the color information and the material information; Extracting material information of the product according to the physical image includes: Determine the reflectivity of each pixel point according to the physical image of the product in at least one direction under the first light brightness and the physical image of the product in at least one direction under the second light brightness; According to the preset correspondence between reflectivity and material, the material of each pixel is determined to obtain the material information of the product; Among them, the brightness of the second light is greater than the brightness of the first light; the difference in brightness values ​​of the pixel points at the same position in the real object picture under the first light brightness and the real object picture under the second light brightness in the same direction is used as the reflectivity of the pixel points at the same position.

2. The method according to claim 1, characterized in that: Get physical images of your products, including: Extracting a view of the product in at least one direction according to the three-dimensional model of the product; The product is photographed in real life in at least one direction under a first light brightness and a second light brightness, respectively, to obtain real images of the product in at least one direction under different light brightnesses, wherein the product in the real image matches feature points of the product in the view of the corresponding direction.

3. The method according to claim 2, characterized in that Before photographing the product in real life in the at least one direction, the method further includes: Outputs information about light brightness and / or shooting direction.

4. The method according to claim 1, characterized in that: Extracting the color information of the product according to the physical image includes: The color of each pixel in the physical image of the product in at least one direction under the brightness of the first light is identified to obtain color information of the product.

5. The method according to claim 1, characterized in that Determining the reflectivity of each pixel point according to the physical image of the product in at least one direction under the first light brightness and the physical image of the product in at least one direction under the second light brightness includes: Obtaining a first brightness value of each pixel in the physical object picture in at least one direction under the brightness of the first light; Obtaining a second brightness value of each pixel in the real object picture in at least one direction under the brightness of the second light; The difference between the first brightness value and the second brightness value of the pixel point at the same position in the real object picture under the first light brightness and the real object picture under the second light brightness in the same direction is calculated as the reflectivity of the pixel point at the same position.

6. The method according to claim 1, characterized in that Rendering the three-dimensional model of the product according to the color information and the material information includes: Determine corresponding color parameters and material parameters according to the color information and the material information; The original parameters of the three-dimensional model of the product are modified according to the color parameters and the material parameters to complete automatic rendering.

7. A product rendering device, characterized in that: include: The acquisition module is used to obtain the physical image of the product; An extraction module, used to extract the color information and material information of the product according to the physical image; A rendering module, used for rendering the three-dimensional model of the product according to the color information and the material information; The extraction module comprises: A first determination unit determines the reflectivity of each pixel point according to a physical image of the product in at least one direction under a first light brightness and a physical image of the product in at least one direction under a second light brightness; A second determination unit is used to determine the material of each pixel point according to a preset correspondence between reflectivity and material, and obtain material information of the product; Among them, the brightness of the second light is greater than the brightness of the first light; the difference in brightness values ​​of the pixel points at the same position in the real object picture under the first light brightness and the real object picture under the second light brightness in the same direction is used as the reflectivity of the pixel points at the same position.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the product rendering method according to any one of claims 1 to 6 is implemented.

9. An electronic device, comprising: one or more processors; A memory for storing one or more programs, characterized in that when the one or more programs are executed by the one or more processors, the one or more processors implement the product rendering method as described in any one of claims 1 to 6.