Imaging method, device, electronic device and readable storage medium

By obtaining key feature points of target objects in virtual reality and augmented reality devices, building and filling spatial structure models, the problem of high device power consumption and long modeling time is solved, and an efficient three-dimensional modeling process is achieved.

CN112348965BActive Publication Date: 2024-09-13VIVO MOBILE COMM CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202011167192.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-27
Publication Date
2024-09-13
Estimated Expiration
2040-10-27

AI Technical Summary

Technical Problem

Existing virtual reality and augmented reality devices need to calculate the characteristics of each pixel, resulting in high power consumption and long modeling time, and cannot adapt to electronic devices with poor computing capabilities.

Method used

By obtaining the spatial position information of key feature points at the intersection of the target object's contour curve or the intersection of the material area, a spatial structure model is constructed, and the model is filled in based on the material information to generate a three-dimensional model, reducing the amount of calculation of pixel points.

Benefits of technology

It reduces the computational load and modeling time of electronic equipment, improves modeling efficiency, and enables equipment with poor computing power to quickly generate high-quality three-dimensional models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112348965B
    Figure CN112348965B
Patent Text Reader

Abstract

The present application discloses an imaging method, device, electronic device and readable storage medium, which belongs to the field of communication technology and can solve the problems of high power consumption and long modeling time of AR or VR devices. The method includes: obtaining the spatial position information of the key feature points of the target object; the key feature points include any of the following: the intersection of the contour curve of the target object, or the intersection of N material areas on the surface of the target object; constructing a spatial structure model of the target object according to the spatial position information of the key feature points; filling the spatial structure model according to the material information corresponding to each material area on the surface of the target object, and generating a three-dimensional model of the target object; wherein the material area on the surface of the target object is divided based on the contour curve of the target object. The embodiment of the present application is applied to the scene of using AR or VR devices for immersive experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of communication technology, and in particular, to an imaging method, device, electronic device, and readable storage medium. Background Art

[0002] With the development of augmented reality (AR) and virtual reality (VR) technologies, the scenarios in which users use virtual devices (for example, AR devices or VR devices) for immersive experience are becoming more and more diverse. Virtual devices can display the image data of the target object collected by the camera in a virtual scene after 3D modeling.

[0003] In the related art, the virtual device relies on collecting pixel features on the surface of the target object for three-dimensional modeling. However, since the above-mentioned imaging process requires calculating the pixel features of each collected pixel, this imaging method requires the virtual device to have greater computing power and graphics rendering capabilities, which in turn leads to high power consumption of the virtual device and long modeling time. Summary of the invention

[0004] The purpose of the embodiments of the present application is to provide an imaging method, device, electronic device and readable storage medium, which can solve the problems of high power consumption and long modeling time of AR or VR devices.

[0005] In order to solve the above technical problems, this application is implemented as follows:

[0006] In a first aspect, an embodiment of the present application provides an imaging method, the method comprising: obtaining spatial position information of key feature points of a target object; the key feature points comprising any of the following: intersection points of a contour curve of the target object, or intersection points of N material regions in the surface of the target object; constructing a spatial structure model of the target object based on the spatial position information of the key feature points; filling the spatial structure model according to material information corresponding to each material region in the surface of the target object to generate a three-dimensional model of the target object; wherein the material regions in the surface of the target object are divided based on the contour curve of the target object, and the materials of the N material regions are different.

[0007] In a second aspect, an embodiment of the present application also provides an imaging device, which includes: an acquisition module, a construction module and a generation module; the acquisition module is used to acquire spatial position information of key feature points of the target object; the key feature points include any of the following: the intersection of the contour curve of the target object, or the intersection of N material areas in the surface of the target object; the construction module is used to construct a spatial structure model of the target object according to the spatial position information of the key feature points acquired by the acquisition module; the generation module is used to fill the spatial structure model constructed by the construction module according to the material information corresponding to each material area in the surface of the target object, and generate a three-dimensional model of the target object; wherein the material area in the surface of the target object is divided based on the contour curve of the target object, and the materials of the N material areas are different.

[0008] In a third aspect, an embodiment of the present application provides an electronic device, comprising a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the imaging method described in the first aspect.

[0009] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0010] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.

[0011] In an embodiment of the present application, the spatial position information of the key feature points of the target object is obtained through the intersection of the contour curve of the target object, or the intersection of N adjacent material areas of different materials on the surface of the target object, and the spatial structure model of the target object is constructed based on the spatial position information of the key feature points. Afterwards, the above-mentioned spatial structure model is filled according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel of the target object in the image captured by the camera, thereby reducing the amount of calculation of the electronic device. Afterwards, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which greatly improves the modeling efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] Figure 1 This is one of the schematic diagrams of an imaging method provided in an embodiment of the present application;

[0013] Figure 2 It is a schematic diagram of a flow chart of an imaging method provided in an embodiment of the present application;

[0014] Figure 3 This is the second schematic diagram of an imaging method provided in an embodiment of the present application;

[0015] Figure 4 This is a third schematic diagram of an imaging method provided in an embodiment of the present application;

[0016] Figure 5 is a schematic diagram of the structure of an imaging device provided in an embodiment of the present application;

[0017] Figure 6 This is one of the structural schematic diagrams of an electronic device provided in an embodiment of the present application;

[0018] Figure 7 This is the second structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0019] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not 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 this application.

[0020] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.

[0021] The imaging method provided in the embodiments of the present application can be applied to scenarios where AR or VR devices are used for immersive experience.

[0022] For example, in the related art, for a scene in which a target object is added to a virtual screen through three-dimensional modeling, such as Figure 1 As shown, the electronic device can capture the target object (such as Figure 1 According to the pixel information of each pixel point of the target object in the image (such as Figure 1The dotted line of the three-dimensional figure shown in (B) only shows the outline pixels here. In fact, it is necessary to obtain all the pixels on the surface of the three-dimensional image) to generate a three-dimensional model of the target object. Since the above method does not screen the pixels, the electronic device usually needs to calculate the pixel information of each pixel, including: the color of each pixel, the spatial position information of each pixel, etc. In this way, a huge amount of data calculation will be generated. For electronic devices with poor computing power, the modeling time will be very long, resulting in delays in generating models in the virtual screen. Therefore, the above method is not suitable for most electronic devices. With the popularization of AR gameplay, for electronic devices with poor computing power, an imaging method with less computational effort is needed to adapt to most electronic devices.

[0023] For this problem, in the technical solution provided in the embodiment of the present application, for the related art, the pixels obtained are not screened, resulting in a large amount of calculation. Those skilled in the art can think of reducing the amount of data calculation of the electronic device by screening the pixels. However, how to screen the pixels, that is, how to extract key points from the massive amount of pixels obtained, which can reduce the amount of data calculation and will not significantly reduce the quality of imaging, is not easy to think of. The technical solution in the present application, through the observation of the house structure and the human skeleton, finds that during the movement of the human body, only the joints will undergo structural changes, and the human tissue between the joints will not change with the movement of the human body. Therefore, the joints of the human body can be regarded as key points, and the human skeleton model can be constructed by the lines between the key points, and the human skeleton model can be filled with muscle tissue to obtain a relatively complete human body model.

[0024] Therefore, the technical solution in the present application first obtains the contour information of the target object, determines the intersection of the contour curve of the target object based on the contour information, or the intersection of N adjacent material areas with different materials on the surface of the target object, obtains the spatial position information of the key feature points of the target object, and constructs the spatial structure model of the target object based on the spatial position information of the key points. After that, the above-mentioned spatial structure model is filled according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. After that, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which reduces the modeling time and greatly improves the modeling efficiency.

[0025] The imaging method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.

[0026] like Figure 2 As shown, an imaging method provided in an embodiment of the present application may include the following steps 201 to 203:

[0027] Step 201: An imaging device obtains spatial position information of key feature points of a target object.

[0028] The key feature points include any of the following: intersections of contour curves of the target object, or intersections of N material regions on the surface of the target object, the N material regions have different materials, and N≥2. It is understandable that the N material regions are adjacent material regions.

[0029] Step 202: The imaging device constructs a spatial structure model of the target object according to the spatial position information of the key feature points.

[0030] For example, the target object may be a person, an animal, or any other object with a three-dimensional structure. Figure 1 The key feature points of the target object may be the intersection of the contour curves of the target object, or the intersection of N adjacent regions of different materials on the surface of the target object. The spatial position information of the key feature points may be understood as the position information of the key feature points in three-dimensional space, which is represented by (x, y, z) in the spatial coordinate system constructed by the x-axis, the y-axis and the z-axis.

[0031] Exemplarily, the key feature point may be the intersection of at least two straight lines in the contour of the target object. Therefore, two key feature points may be connected by a straight line to construct a spatial structure model of the target object. However, usually, since there is no absolute straight line on the surface of an object, the straight line may be represented by a curve with a curvature less than a preset curvature. Therefore, the intersection of the contour curve of the target object may be understood as a turning point of the contour curve of the target object.

[0032] For example, combining Figure 1 ,like Figure 3 As shown, the electronic device determines the key feature points through the intersection of the contour curves of the target object, such as Figure 3 As shown in (A), the electronic device uses the intersection of the cube boundary as the key feature point (such as Figure 3 At this time, the electronic device only needs to calculate the spatial position information of each key feature point to build the spatial structure model of the cube, without calculating other pixel points on each edge of the cube, which greatly reduces the amount of data calculation.

[0033] Exemplarily, the electronic device can collect the material information of each material area on the surface of the target object through a camera. When the electronic device generates a three-dimensional model of the target object, it needs to fill the material into the corresponding spatial position. Therefore, after the electronic device obtains the material information of each material area on the surface of the target object, it also needs to obtain the position information of the position where the material information of each material area is to be filled, that is, the position information of the area corresponding to the material area in the three-dimensional model. It can be understood that three points can determine a surface. Therefore, after the electronic device obtains the material information of each material area on the surface of the target object, it only needs to obtain the position information of three different position points on the material area to fill the material of the material area into the correct position when generating the three-dimensional model of the target object.

[0034] For example, combining Figure 1 ,like Figure 4 As shown, the electronic device determines the key feature points through the intersection of adjacent material areas on the surface of the target object, such as Figure 4 As shown in (A), material region 41 and material region 42 are two adjacent material regions, and three key feature points (point a, point b and point c) are determined through the above two adjacent material regions. By determining the spatial position information of the above three key feature points, the position information of the material region 41 in the corresponding area of ​​the three-dimensional model can be determined when generating a three-dimensional model of the cube.

[0035] It should be noted that the above material information can be understood as: a combination of visual characteristic attributes of the object surface, and the characteristic attributes include texture, color, smoothness, transparency, refractive index, etc. of the object surface.

[0036] Exemplarily, the above key feature points are points in three-dimensional space, so the electronic device needs to obtain the three-dimensional spatial position information of each key feature point. The electronic device can obtain the key feature points of the target object in at least the following two ways.

[0037] Method 1:

[0038] In method 1, the electronic device can determine the spatial position information of the above key feature points through structured light. Structured light is a system structure composed of a projector (a light source that emits invisible light) and a camera. After the projector projects specific light information onto the surface of the object and the background, the camera collects it. According to the changes in the light signal caused by the object, the position and depth of the object are calculated, and then the entire three-dimensional space is restored. In this way, the spatial position information of the above key feature points can be obtained.

[0039] Method 2:

[0040] In method 2, the electronic device can determine the spatial position information of the key feature points through a time of flight (TOF) sensor. The principle is that the TOF sensor emits modulated near-infrared light and reflects it after encountering an object. The TOF sensor calculates the time difference or phase difference between the emission and reflection of the light to convert the distance of the photographed scene to generate depth information. The electronic device can determine the spatial position information of the key feature points based on the depth information.

[0041] Step 203: The imaging device fills the spatial structure model according to the material information corresponding to each material region on the surface of the target object to generate a three-dimensional model of the target object.

[0042] The material area on the surface of the target object is divided based on the contour curve of the target object.

[0043] Exemplarily, after the electronic device constructs a spatial structure model of the target object according to the spatial position information of the key feature points, it generates a three-dimensional model of the target object by filling the spatial structure model with materials.

[0044] For example, Figure 1 As shown, Figure 1 The material of the material area 11 shown in (A) is black. Figure 1 ,like Figure 3 As shown in (B), after the electronic device constructs the spatial structure model of the cube, it fills the material corresponding to the material area 11 into area 31 of the spatial structure model of the cube. Alternatively, after the electronic device constructs the spatial structure model of the cube, it fills the material corresponding to the material area 11 into area 41 of the spatial structure model of the cube.

[0045] In this way, the spatial position information of the key feature points of the target object is obtained through the intersection of the contour curve of the target object, or the intersection of N adjacent material areas with different materials on the surface of the target object, and the spatial structure model of the target object is constructed based on the spatial position information of the key feature points. After that, the above-mentioned spatial structure model is filled according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel point of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. After that, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which greatly improves the modeling efficiency.

[0046] Optionally, in an embodiment of the present application, the electronic device needs to obtain the contour of the target object before obtaining the key feature points of the target object. In order to obtain the contour information of the target object more clearly and accurately, the electronic device can capture images of the target object in different brightness scenes.

[0047] Exemplarily, the above step 201 may include the following steps 201a1 and 201a2:

[0048] Step 201a1: The imaging device obtains contour information of the target object, where the contour information includes: contour information of the target object collected by the electronic device in different brightness scenes.

[0049] Step 201a2: The imaging device determines the spatial position information of the key feature points of the target object according to the above outline information.

[0050] Exemplarily, the above outline information is used to represent the appearance outline of the target object, that is, Figure 1 The dotted line portion of (B) shows the cube outline. After the electronic device obtains the outline information of the target object, it uses the intersection of the outline curve indicated by the above outline information as the key feature point of the target object.

[0051] In this way, the electronic device can obtain more accurate contour information of the target object by comparing images of the target object captured in scenes with different brightness.

[0052] Optionally, in an embodiment of the present application, when the key feature point is an intersection point of a contour curve of the target object, the electronic device may determine the key feature point by the following method.

[0053] Exemplarily, when the key feature point is an intersection of the contour curve of the target object, before the step 201, the imaging method provided in the embodiment of the present application further includes the following steps 201b1 and 201b2:

[0054] Step 201b1: The imaging device collects a contour curve of the target object.

[0055] Step 201b2: The imaging device uses the intersection of the target contour curve as the key feature point of the target object.

[0056] The curvature of the contour curve of the target object is less than or equal to a preset curvature; the target contour curve is a contour curve among the contour curves of the target object that intersects with other contour curves.

[0057] Exemplarily, the intersection point may be an intersection point of at least two contour curves, and the electronic device constructs a spatial structure model of the target object according to the key feature points and the contour curves.

[0058] In this way, the electronic device can use the focus of the contour curve of the target object as the above-mentioned target feature point, and then realize the screening of the above-mentioned massive pixel points, thereby achieving the purpose of reducing the amount of calculation.

[0059] Optionally, in an embodiment of the present application, when the above-mentioned key feature points are the intersection points of adjacent material areas in the surface of the target object, the key feature points in each material area can be extracted by the following method to determine the position filled by the material corresponding to the material area in the three-dimensional model.

[0060] Exemplarily, when the key feature points are intersections of N adjacent material regions of different materials on the surface of the target object, the surface of the target object includes at least two material regions, and each material region includes at least three key feature points.

[0061] Exemplarily, the above step 201 may further include the following step 201c:

[0062] Step 201c: The imaging device uses any feature point in the first material region as a first key feature point, and uses two feature points on the intersection line of the first material region and the second material region as second key feature points.

[0063] The first material region is any one of the at least two material regions; and the second material region is a material region adjacent to the first material region.

[0064] Exemplarily, since three points can determine a surface, three different points in the first material region can be obtained as key feature points to further determine the spatial position information of the material region.

[0065] For example, combining Figure 1 After the electronic device obtains the material information of the material corresponding to the material area 11, in order to fill the material into Figure 4 In the spatial structure model shown in (B), it is necessary to obtain the spatial position information of the material region 11. In this case, only three points in the material region 11 need to be obtained (for example, Figure 4 The spatial position information of point a, point b and point c) shown in (A) can be used to determine the spatial position information of area 41 in the spatial structure model that needs to be filled in the material area 11.

[0066] In this way, the electronic device can construct a spatial structure model of the target object by determining the three key feature points from each material area, and when generating a three-dimensional model of the target object, determine the position where the material corresponding to each material area is filled in the three-dimensional model.

[0067] Optionally, in an embodiment of the present application, when the material on the surface of the target object is filled into the spatial structure model of the target object, the material in each material area needs to be accurately filled into the corresponding area of ​​the spatial structure model.

[0068] Exemplarily, the surface of the target object includes at least two material regions, and the spatial structure model includes at least one region for filling the material.

[0069] Exemplarily, the above step 203 may include the following steps 203a:

[0070] Step 203a: The imaging device fills the target area in the above-mentioned spatial structure model according to the material information corresponding to the third material area, and generates a three-dimensional model of the target object.

[0071] The third material region is any one of the at least two material regions, and the target region is a region corresponding to the third material region in at least one region for filling the material.

[0072] It should be noted that after the electronic device constructs the spatial structure model of the target object, the material corresponding to each material area of ​​the target object is filled into the spatial structure model. The correspondence between the material area and the corresponding area in the spatial structure model has been described in detail in the above method. In order to avoid repetition, it will not be repeated here.

[0073] In this way, the electronic device can correctly fill the material of each material area on the surface of the target object into the spatial structure model according to the correspondence between the third material area and the target area in the spatial structure model.

[0074] The imaging method provided in the embodiment of the present application first obtains the contour information of the target object, determines the intersection of the contour curve of the target object according to the contour information, or divides the target object into material regions according to the contour information, and determines the intersection of N adjacent material regions with different materials on the surface of the target object, obtains the spatial position information of the key feature points of the target object, and constructs the spatial structure model of the target object according to the spatial position information of the key points, and then fills the above-mentioned spatial structure model according to the material information corresponding to each material region on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel point of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. Afterwards, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which reduces the modeling time and greatly improves the modeling efficiency.

[0075] It should be noted that the imaging method provided in the embodiment of the present application can be executed by an imaging device or a control module in the imaging device for executing the imaging method. In the embodiment of the present application, the imaging device provided in the embodiment of the present application is described by taking the imaging device executing the imaging method as an example.

[0076] It should be noted that in the embodiments of the present application, the imaging methods shown in the above-mentioned method drawings are all illustrated by combining one of the drawings in the embodiments of the present application as an example. In specific implementation, the imaging methods shown in the above-mentioned method drawings can also be implemented in combination with any other drawings that can be combined as shown in the above-mentioned embodiments, which will not be repeated here.

[0077] Figure 5 A possible structural diagram of an imaging device provided in an embodiment of the present application is as follows: Figure 5 As shown, the imaging device 600 includes: an acquisition module 601, a construction module 602 and a generation module 603; wherein the acquisition module 601 is used to acquire the spatial position information of the key feature points of the target object; the key feature points include any of the following: the intersection of the contour curve of the target object, or the intersection of N material areas in the surface of the target object; the construction module 602 is used to construct a spatial structure model of the target object according to the spatial position information of the key feature points acquired by the acquisition module 601; the generation module 603 is used to fill the spatial structure model constructed by the construction module 602 according to the material information corresponding to each material area in the surface of the target object, and generate a three-dimensional model of the target object; wherein the material area in the surface of the target object is divided based on the contour curve of the target object, and the materials of the N material areas are different.

[0078] Alternatively, if Figure 5 As shown, the electronic device 600 also includes: a determination module 604 and an acquisition module 601, which are specifically used to obtain contour information of the target object, and the contour information includes: contour information of the target object collected under different brightness scenes; the determination module 604 is used to determine the spatial position information of the key feature points of the target object based on the contour information obtained by the acquisition module 601.

[0079] Alternatively, if Figure 5 As shown, in the case where the key feature point is the intersection point of the contour curve of the target object, the electronic device 600 also includes: a collection module 605; the collection module 605 is used to collect the contour curve of the target object; a determination module 604 is used to use the intersection point of the target contour curve as the key feature point of the target object; wherein the curvature of the contour curve of the target object is less than or equal to the preset curvature; the target contour curve is a contour curve that intersects with other contour curves among the contour curves of the target object collected by the collection module 605.

[0080] Optionally, in the case where the key feature point is the intersection of N material regions in the surface of the target object, the surface of the target object includes at least two material regions, and each material region includes at least three key feature points; the acquisition module 601 is specifically used to take any feature point in the first material region as the first key feature point, and take two feature points on the intersection line of the first material region and the second material region as the second key feature point; wherein the first material region is any material region of the at least two material regions; and the second material region is a material region adjacent to the first material region.

[0081] Optionally, it is characterized in that the surface of the target object includes at least two material areas; the spatial structure model includes at least one area for filling material; the generation module 603 is specifically used to fill the target area in the spatial structure model according to the material information corresponding to the third material area, and generate a three-dimensional model of the target object; wherein the third material area is any material area of ​​the at least two material areas; the target area is an area corresponding to the third material area in at least one area for filling material.

[0082] It should be noted that if Figure 5 As shown, the modules that must be included in the imaging device 600 are indicated by solid-line boxes, such as the acquisition module 601, the construction module 602 and the generation module 603; the modules that may be included in the imaging device 600 are indicated by dotted-line boxes, such as the determination module 604 and the acquisition module 605.

[0083] The imaging device in the embodiment of the present application can be a device, or a component, integrated circuit, or chip in a terminal. The device can be a mobile electronic device or a non-mobile electronic device. For example, the mobile electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (PDA), etc. The non-mobile electronic device can be a server, a network attached storage (NAS), a personal computer (PC), a television (TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.

[0084] The imaging device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0085] The imaging device provided in the embodiment of the present application can achieve Figures 2 to 4 To avoid repetition, the various processes implemented by the method embodiment are not described here.

[0086] The imaging device provided in the embodiment of the present application first obtains the contour information of the target object, determines the intersection of the contour curve of the target object according to the contour information, or divides the target object into material regions according to the contour information, and determines the intersection of N adjacent material regions with different materials on the surface of the target object, obtains the spatial position information of the key feature points of the target object, and constructs the spatial structure model of the target object according to the spatial position information of the key points, and then fills the above-mentioned spatial structure model according to the material information corresponding to each material region on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel point of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. Afterwards, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which reduces the modeling time and greatly improves the modeling efficiency.

[0087] Optional, such as Figure 6 As shown, an embodiment of the present application also provides an electronic device M00, including a processor M01, a memory M02, and a program or instruction stored in the memory M02 and executable on the processor M01. When the program or instruction is executed by the processor M01, each process of the above-mentioned imaging method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0088] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.

[0089] Figure 7 A schematic diagram of the hardware structure of an electronic device for implementing various embodiments of the present application.

[0090] The electronic device 100 includes but is not limited to components such as a radio frequency unit 101, a network module 102, an audio output unit 103, an input unit 104, a sensor 105, a display unit 106, a user input unit 107, an interface unit 108, a memory 109, and a processor 110.

[0091] Those skilled in the art will appreciate that the electronic device 100 may also include a power source (such as a battery) for supplying power to various components, and the power source may be logically connected to the processor 110 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 7The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.

[0092] Among them, the sensor 105 or the input unit 104 is used to obtain the spatial position information of the key feature points of the target object; the key feature points include any of the following: the intersection of the contour curve of the target object, or the intersection of N material areas on the surface of the target object; the processor 110 is used to construct a spatial structure model of the target object according to the spatial position information of the key feature points obtained by the sensor 105 or the input unit 104; the display unit 106 is used to fill the spatial structure model according to the material information corresponding to each material area on the surface of the target object, and generate a three-dimensional model of the target object; wherein the material area on the surface of the target object is divided based on the contour curve of the target object, and the materials of the N material areas are different.

[0093] In this way, the spatial position information of the key feature points of the target object is obtained through the intersection of the contour curve of the target object, or the intersection of N adjacent material areas with different materials on the surface of the target object, and the spatial structure model of the target object is constructed based on the spatial position information of the key feature points. After that, the above-mentioned spatial structure model is filled according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel point of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. After that, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which greatly improves the modeling efficiency.

[0094] Optionally, the sensor 105 or the input unit 104 is specifically used to obtain contour information of the target object, and the contour information includes: contour information of the target object collected under different brightness scenes; the processor 110 is used to determine the spatial position information of the key feature points of the target object based on the contour information obtained by the sensor 105 or the input unit 104.

[0095] In this way, the electronic device can obtain more accurate contour information of the target object by comparing images of the target object captured in scenes with different brightness.

[0096] Optionally, when the key feature point is the intersection point of the contour curve of the target object, the sensor 105 or the input unit 104 is used to collect the contour curve of the target object; the processor 110 is used to use the intersection point of the target contour curve as the key feature point of the target object; wherein the curvature of the contour curve of the target object is less than or equal to a preset curvature; the target contour curve is a contour curve that intersects with other contour curves among the contour curves of the target object collected by the sensor 105 or the input unit 104.

[0097] In this way, the electronic device can use the focus of the contour curve of the target object as the above-mentioned target feature point, and then realize the screening of the above-mentioned massive pixel points, thereby achieving the purpose of reducing the amount of calculation.

[0098] Optionally, in the case where the key feature point is the intersection of N material regions in the surface of the target object, the surface of the target object includes at least two material regions, and each material region includes at least three key feature points; the processor 110 is specifically used to take any feature point in the first material region as the first key feature point, and take two feature points on the intersection line of the first material region and the second material region as the second key feature point; wherein the first material region is any material region of the at least two material regions; and the second material region is a material region adjacent to the first material region.

[0099] In this way, the electronic device can construct a spatial structure model of the target object by determining the three key feature points from each material area, and when generating a three-dimensional model of the target object, determine the position where the material corresponding to each material area is filled in the three-dimensional model.

[0100] Optionally, it is characterized in that the surface of the target object includes at least two material areas; the spatial structure model includes at least one area for filling material; the display unit 106 is specifically used to fill the target area in the spatial structure model according to the material information corresponding to the third material area, and generate a three-dimensional model of the target object; wherein the third material area is any material area of ​​the at least two material areas; the target area is an area in at least one area for filling material that corresponds to the third material area.

[0101] In this way, the electronic device can correctly fill the material of each material area on the surface of the target object into the spatial structure model according to the correspondence between the third material area and the target area in the spatial structure model.

[0102] The electronic device provided in the embodiment of the present application first obtains the contour information of the target object, determines the intersection of the contour curve of the target object according to the contour information, or divides the target object into material regions according to the contour information, and determines the intersection of N adjacent material regions with different materials on the surface of the target object, obtains the spatial position information of the key feature points of the target object, and constructs the spatial structure model of the target object according to the spatial position information of the key points, and then fills the above-mentioned spatial structure model according to the material information corresponding to each material region on the surface of the target object to generate a three-dimensional model of the target object. The electronic device only needs to obtain the key feature points of the target object to construct the spatial structure model of the target object, and there is no need to calculate the spatial position of each pixel point of the target object in the image captured by the camera, which reduces the amount of calculation of the electronic device. Afterwards, the material information corresponding to the material on the surface of the target object is used to fill the above-mentioned spatial structure model, which reduces the modeling time and greatly improves the modeling efficiency.

[0103] It should be understood that in the embodiment of the present application, the input unit 104 may include a graphics processor (Graphics Processing Unit, GPU) 1041 and a microphone 1042, and the graphics processor 1041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 106 may include a display panel 1061, and the display panel 1061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 107 includes a touch panel 1071 and other input devices 1072. The touch panel 1071 is also called a touch screen. The touch panel 1071 may include two parts: a touch detection device and a touch controller. Other input devices 1072 may include but are not limited to a physical keyboard, a function key (such as a volume control button, a switch button, etc.), a trackball, a mouse, and a joystick, which will not be repeated here. The memory 109 can be used to store software programs and various data, including but not limited to applications and operating systems. The processor 110 can integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, the user interface, and the application program, etc., and the modem processor mainly processes wireless communication. It is understandable that the above-mentioned modem processor may not be integrated into the processor 110.

[0104] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned imaging method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0105] The processor is a processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0106] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned imaging method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0107] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0108] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0109] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling an electronic device (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0110] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. An imaging method, characterized in that: The method comprises: Acquire spatial position information of key feature points of the target object; the key feature points include intersections of N material regions on the surface of the target object; Constructing a spatial structure model of the target object according to the spatial position information of the key feature points; Filling the spatial structure model according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object; Wherein, the material regions in the surface of the target object are divided based on the contour curve of the target object, and the materials of the N material regions are different; The surface of the target object includes at least two material regions, each material region includes at least three key feature points; The step of obtaining key feature points of the target object includes: Taking any feature point in the first material region as a first key feature point, and taking two feature points on the intersection line of the first material region and the second material region as second key feature points; The first material region is any one of the at least two material regions; and the second material region is a material region adjacent to the first material region.

2. The method according to claim 1, characterized in that The step of obtaining the spatial position information of the key feature points of the target object includes: Acquire contour information of the target object, wherein the contour information includes: contour information of the target object collected under different brightness scenes; The spatial position information of the key feature points of the target object is determined according to the contour information.

3. The method according to claim 1 or 2, characterized in that: The key feature points also include intersections of contour curves of the target object. Before acquiring spatial position information of the key feature points of the target object, the method further includes: Collecting the contour curve of the target object; The intersection of the target contour curve is used as the key feature point of the target object; The curvature of the contour curve of the target object is less than or equal to a preset curvature; and the target contour curve is a contour curve among the contour curves of the target object that intersects with other contour curves.

4. The method according to claim 1, characterized in that: The surface of the target object includes at least two material areas; the spatial structure model includes at least one area for filling with material; Filling the spatial structure model according to the material information corresponding to each material area on the surface of the target object to generate a three-dimensional model of the target object includes: Filling the target area in the spatial structure model according to the material information corresponding to the third material area to generate a three-dimensional model of the target object; The third material area is any one of the at least two material areas; and the target area is an area in the at least one area for filling material that corresponds to the third material area.

5. An imaging device, characterized in that: The device comprises: an acquisition module, a construction module and a generation module; The acquisition module is used to acquire spatial position information of key feature points of the target object; the key feature points include intersections of N material areas on the surface of the target object; The construction module is used to construct a spatial structure model of the target object according to the spatial position information of the key feature points acquired by the acquisition module; The generating module is used to fill the spatial structure model constructed by the constructing module according to the material information corresponding to each material area on the surface of the target object, so as to generate a three-dimensional stereoscopic model of the target object; Wherein, the material regions in the surface of the target object are divided based on the contour curve of the target object, and the materials of the N material regions are different; The surface of the target object includes at least two material regions, each material region includes at least three key feature points; The acquisition module is specifically used to take any feature point in the first material area as a first key feature point, and take two feature points on the intersection line of the first material area and the second material area as second key feature points; The first material region is any one of the at least two material regions; and the second material region is a material region adjacent to the first material region.

6. The device according to claim 5, characterized in that The device further comprises: a determination module; The acquisition module is specifically used to acquire contour information of the target object, wherein the contour information includes: contour information of the target object collected under different brightness scenes; The determining module is used to determine the spatial position information of the key feature points of the target object according to the contour information acquired by the acquiring module.

7. The device according to claim 5 or 6, characterized in that The key feature points also include intersections of contour curves of the target object, and the device also includes: a collection module and a determination module; The acquisition module is used to acquire the contour curve of the target object; The determination module is used to use the intersection of the target contour curve as the key feature point of the target object; The curvature of the contour curve of the target object is less than or equal to a preset curvature; and the target contour curve is a contour curve intersecting with other contour curves among the contour curves of the target object collected by the collection module.

8. The device according to claim 5, characterized in that The surface of the target object includes at least two material areas; the spatial structure model includes at least one area for filling with material; The generating module is specifically used to fill the target area in the spatial structure model according to the material information corresponding to the third material area, and generate a three-dimensional model of the target object; The third material area is any one of the at least two material areas; and the target area is an area in the at least one area for filling material that corresponds to the third material area.

9. An electronic device, characterized in that: The method comprises a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the imaging method according to any one of claims 1 to 4.

10. A readable storage medium, characterized in that: The readable storage medium stores a program or an instruction, and when the program or the instruction is executed by a processor, the steps of the imaging method according to any one of claims 1 to 4 are implemented.