CN114283266A - Three-dimensional model adjusting method and device, storage medium and equipment - Google Patents

Three-dimensional model adjusting method and device, storage medium and equipment Download PDF

Info

Publication number
CN114283266A
CN114283266A CN202111574371.7A CN202111574371A CN114283266A CN 114283266 A CN114283266 A CN 114283266A CN 202111574371 A CN202111574371 A CN 202111574371A CN 114283266 A CN114283266 A CN 114283266A
Authority
CN
China
Prior art keywords
texture
point
points
dimensional model
sampling
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111574371.7A
Other languages
Chinese (zh)
Inventor
芦爱余
马光辉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Huya Technology Co Ltd
Original Assignee
Guangzhou Huya Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Huya Technology Co Ltd filed Critical Guangzhou Huya Technology Co Ltd
Priority to CN202111574371.7A priority Critical patent/CN114283266A/en
Publication of CN114283266A publication Critical patent/CN114283266A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Generation (AREA)

Abstract

The present specification provides a three-dimensional model adjustment method, an apparatus, a storage medium, and a device, in which sampling points are selected based on texture edges of a texture image of an initial three-dimensional model, point cloud thinning is performed according to the sampling points, and a target three-dimensional model is constructed according to thinned vertices. Therefore, the automatic adjustment of the initial three-dimensional model is realized, the workload of professional technicians is effectively reduced, meanwhile, the three-dimensional problem is converted into the two-dimensional problem, the sampling averaging is realized, and the thinned vertex is the vertex in the original point cloud, so that the uncontrollable result is effectively reduced.

Description

Three-dimensional model adjusting method and device, storage medium and equipment
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method, an apparatus, a storage medium, and a device for adjusting a three-dimensional model.
Background
The point cloud model generated by scanning the object has dense point clouds, and accordingly, the point cloud density of the grid model constructed by generating the topological structure for the point cloud model is high, and equipment needs to perform a large amount of calculation when rendering the grid model, so that long time is consumed. Therefore, before putting into service, it is often necessary to manually perform point cloud thinning on such mesh model and adjust the polygonal mesh according to the thinned point cloud. The process is repeated and takes long time, and the business is easy to be influenced to be on-line. However, this scheme is prone to have an uncontrollable result, for example, a triangular surface patch adjusted according to the thinned point cloud is easily irregular, and thus a problem of inconsistent light reflection is caused.
Disclosure of Invention
In a first aspect, a three-dimensional model adjustment method is provided, including: acquiring a texture image of an initial three-dimensional model, wherein the texture image comprises a plurality of texture points; acquiring texture edges of the texture images, sampling the texture edges according to preset sampling conditions, and performing sparsification on vertexes of the initial three-dimensional model by using texture points selected by sampling; and constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
In some embodiments, the texture edge is selected according to a curvature of each texture point; the curvature of a texture point is determined according to the included angle between the texture point and an adjacent point.
In some embodiments, the obtaining the texture edge of the texture image includes: acquiring a target point on the texture edge which is determined for the last time; selecting target adjacent points with the smallest curvature, wherein the curvature of the target adjacent points is smaller than a preset curvature threshold value; determining the target adjacent points as target points on the texture edge until no target adjacent points with the curvature smaller than a preset curvature threshold exist; and determining the target point on the texture edge for the first time as a point which is not determined as any texture edge and has the smallest curvature.
In some embodiments, the preset sampling condition includes a preset sampling interval.
In some embodiments, the preset sampling condition further includes a preset sampling flag, and the texture points sampled and selected include texture points sampled according to a preset sampling interval and texture points with the preset sampling flag.
In some embodiments, the sparsifying the vertices of the three-dimensional model by using the sampled texture points includes: and obtaining sparse point cloud according to each vertex corresponding to the sampled and selected texture point.
In some embodiments, the constructing the polygon mesh according to the thinned vertices includes: in the process of constructing the polygonal network, if two vertexes belong to preset constraint points, constructing a polygon by taking an edge formed by the two vertexes as a reference; the preset constraint points are vertexes carrying constraint marks.
In a second aspect, there is provided a three-dimensional model adjustment apparatus, including: the system comprises an acquisition module, a processing module and a display module, wherein the acquisition module is used for acquiring a texture image of an initial three-dimensional model, and the texture image comprises a plurality of texture points; the sparse module is used for acquiring texture edges of the texture images, sampling the texture edges according to preset sampling conditions, and performing sparse processing on vertexes of the initial three-dimensional model by using texture points selected by sampling; and the construction module is used for constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
In a third aspect, a computer-readable storage medium is provided, on which a computer program is stored, which program, when executed by a processor, performs the method of any of the embodiments of the specification.
In a fourth aspect, a computer device is provided, comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the method of any of the embodiments of the specification when executing the program.
The technical scheme provided by the embodiment of the specification can have the following beneficial effects:
in the method, sampling points are selected based on texture edges of a texture image of an initial three-dimensional model, point cloud sparsification is performed according to the sampling points, and a target three-dimensional model is constructed according to sparsified vertexes. Therefore, the automatic adjustment of the initial three-dimensional model is realized, the workload of professional technicians is effectively reduced, meanwhile, the three-dimensional problem is converted into the two-dimensional problem, the sampling averaging is realized, and the thinned vertex is the vertex in the original point cloud, so that the uncontrollable result is effectively reduced.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the specification.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present specification and together with the description, serve to explain the principles of the specification.
FIG. 1 is a schematic diagram of a mesh model with a dense point cloud shown in accordance with an exemplary embodiment of the present description;
FIG. 2 is a flow chart illustrating a method of three-dimensional model adjustment according to an exemplary embodiment of the present description;
FIG. 3 is a schematic diagram of a texture image shown in accordance with an exemplary embodiment of the present description;
FIG. 4A is a schematic diagram illustrating a local effect after a triangular patch is automatically constructed using a triangulation algorithm according to an exemplary embodiment;
FIG. 4B is a diagram illustrating a partial effect of automatically constructing a triangular patch after adding a preset mark according to an exemplary embodiment;
FIG. 5A is a schematic diagram of a point cloud and triangular patches of a three-dimensional face model shown in accordance with an exemplary embodiment of the present description;
FIG. 5B is a schematic diagram of a texture image of a three-dimensional face model shown in the present specification in accordance with an exemplary embodiment;
FIG. 6 is a hardware block diagram of a computer device in which a three-dimensional model adjustment apparatus according to an exemplary embodiment is shown;
fig. 7 is a block diagram of a three-dimensional model adjustment apparatus shown in the present specification according to an exemplary embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present specification. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the specification, as detailed in the appended claims.
The terminology used in the description herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the description. As used in this specification and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used herein to describe various information, these information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, the first information may also be referred to as second information, and similarly, the second information may also be referred to as first information, without departing from the scope of the present specification. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
In the three-dimensional technology, point cloud data obtained by an optical three-dimensional scanner is used as basic input, and the point cloud data is preprocessed through registration, denoising, repair and the like, so that a point cloud model can be established, and a grid model with a topological structure can be generated after the point cloud model is subjected to grid reconstruction through a drawing tool. The mesh model generated based on this method is shown in fig. 1, and since the point cloud density is high and the number of triangular facets is large, a large amount of calculation is required when the device renders such a mesh model, which requires a long time. Therefore, before putting into service, it is often necessary to manually perform point cloud thinning on such mesh model and adjust the polygonal mesh according to the thinned point cloud. The process is repeated and takes long time, and the business is easy to be influenced to be on-line. However, this scheme is prone to have an uncontrollable result, for example, a triangular surface patch adjusted according to the thinned point cloud is easily irregular, and thus a problem of inconsistent light reflection is caused.
Based on this, the embodiments of the present specification provide a three-dimensional model adjustment scheme to solve the above problems. The following provides a detailed description of examples of the present specification.
As shown in fig. 2, fig. 2 is a flowchart illustrating a three-dimensional model adjustment method according to an exemplary embodiment, the method including:
step 201, obtaining a texture image of an initial three-dimensional model, wherein the texture image comprises a plurality of texture points;
the scheme of the embodiment can realize automatic adjustment of the initial three-dimensional model, wherein the adjustment comprises point cloud sparsization. The point cloud data of the initial three-dimensional model can be obtained by scanning a target object based on an optical three-dimensional scanner, the topological structure of the initial three-dimensional model represents the point-line-surface layout, the structure and the connection condition of the initial three-dimensional model, and the topological structure can be manually drawn by a professional technician or obtained by carrying out grid reconstruction on the point cloud model through a deep learning algorithm. Optionally, the target object may be an object such as a person, an animal, a plant, furniture, an electrical appliance, or a part of an object, such as a human face, a human hand, or the like.
The points in the point cloud data of the initial three-dimensional model are called vertexes, and the coordinates of the vertexes in the point cloud space are called geometric coordinates which are generally represented by three dimensions of x, y and z, and the geometric coordinates determine the drawing positions of the vertexes. When rendering a texture mapped scene, it is also necessary to specify texture coordinates for the vertex, typically represented by U, V two dimensions, which determine the texel assigned to the vertex. The texture image of the initial three-dimensional model, also referred to as a texture coordinate map, may be obtained by unfolding and mapping the initial three-dimensional model to a texture coordinate space. Points in the texture image are called texture points and can also be called texture coordinate points, and the texture points and the vertexes have a one-to-one mapping relation, namely, each texture point corresponds to one vertex; the connection condition between the texture points is determined according to the topological structure of the initial three-dimensional model, and if the 1 st point, the 2 nd point and the 4 th point in the point cloud of the initial three-dimensional model form a triangular patch, connection relationship can be formed between every two texture points respectively corresponding to the 1 st point, the 2 nd point and the 4 th point.
202, acquiring texture edges of the texture images, sampling the texture edges according to preset sampling conditions, and performing sparsification on vertexes of the initial three-dimensional model by using texture points selected by sampling;
the texture edge mentioned in this embodiment is an edge formed by at least two connecting lines in the texture image, and the texture edge may be a straight line or a curved line. Different from a way of selecting sparse points in a point cloud space in the related art, the sparse points are selected based on the texture image in the embodiment, so that a three-dimensional problem is converted into a two-dimensional problem, sampling averaging is more conveniently realized, and edges of a polygonal mesh can be more intuitively processed. Meanwhile, in the embodiment, sparse points are selected on the texture edges, namely, the sparse points are selected on the basis of the original points, and no additional interpolation is performed, so that the situation of uncontrollable results is avoided as much as possible.
In an alternative embodiment, the texture edge may be selected based on the curvature of each texture point. For one of the texture points, the neighboring point of the target point is the texture point having an edge connected to the target point. For example, the target point is the 100 th point in the point cloud corresponding to the initial three-dimensional model, the target point forms a triangle patch with the 80 th point and the 90 th point, the target point forms another triangle patch with the 90 th point and the 120 th point, and the neighboring points of the target point at least include the 80 th point, the 90 th point and the 120 th point. In this embodiment, the curvature of a texture point may be determined according to an included angle between the texture point and an adjacent point, and optionally, the curvature of a texture point may be a minimum included angle corresponding to the texture point. For example, if a texture point and an adjacent point form 3 triangular patches in the texture image, and the corresponding included angles of the texture point in the 3 triangular patches are 25 °, 35 °, and 60 °, respectively, the curvature of the texture point may be 25 °. In this way, each texture point in the texture image has a corresponding curvature, and a relatively smooth edge can be selected by the curvature of each texture point, i.e., a texture edge can be formed by a continuous connecting line on the texture image, which is close to a straight line, and a texture edge can also be formed by a continuous connecting line on an arc. Therefore, after sampling, more average and reasonable sampling points can be obtained.
In some examples, texture edges may be obtained based on: acquiring a target point on the texture edge determined last time; selecting a target adjacent point with the smallest curvature, wherein the curvature of the target adjacent point is smaller than a preset curvature threshold value; determining the target adjacent points as target points on the texture edge until no target adjacent points with the curvature smaller than a preset curvature threshold exist; the target point on the texture edge determined for the first time is a point which is not determined as any texture edge yet and has the smallest curvature. Optionally, the preset curvature threshold may be 20 °, and of course, in other embodiments, the preset curvature threshold may be set according to the requirements of a specific scenario. The method includes that all texture points are traversed globally, the texture point with the smallest curvature is determined as a starting point of a texture edge, then the texture point with the smallest curvature in adjacent points of a target point is determined as a point on the texture edge, and the process is repeated until the curvatures of all the adjacent points of a certain point are larger than or equal to a preset curvature threshold value, so that a first texture edge is obtained, then the global traversal can be continued in the rest points, the edge selection is continued according to the same mode, and after all the texture points are traversed, a plurality of texture edges can be obtained. For example, 10000 texture points are in the texture image of a three-dimensional model, and the 20 th point is determined to be the texture point with the smallest curvature among the 10000 texture points through global traversal, then the 20 th point is taken as the starting point of the first texture edge, the adjacent points of the 20 th point include the 21 st point, the 22 nd point and the 23 rd point, the texture point with the smallest curvature among the three adjacent points is the 22 th point, and the curvature of the 22 th point is less than the preset curvature threshold value of 20 °, then the 22 th point is determined to be the point on the first texture edge, the adjacent points of the 22 th point include the 34 th point, the 35 th point and the 36 th point, the texture point with the smallest curvature among the three adjacent points is the 34 th point, and the curvature of the 34 th point is less than the preset curvature threshold value of 20 °, then the 34 th point is determined to be the point on the first texture edge, and the curvatures of the adjacent points of the 34 th point are all greater than the preset curvature threshold value of 20 °, so that the adjacent points of the first texture edge are searched, determining the 20 th point, the 22 nd point and the 34 th point as points on a first texture edge, namely the first texture edge is an edge formed by a connecting line between the 20 th point and the 22 nd point and a connecting line between the 22 nd point and the 34 th point; and after the 20 th point, the 22 th point and the 34 th point are excluded from the 10000 texture points, the global traversal is continuously carried out on the rest points, and the edge selection is carried out in the same way until all the texture points are globally traversed. As shown in fig. 3, fig. 3 is a schematic diagram of a texture image of a three-dimensional model, and the texture edge 31 and the texture edge 32 in fig. 3 are two texture edges selected according to the above-mentioned manner. As can be seen from fig. 3, in this way, the device can automatically select the texture edge according to the smoothest direction, thereby ensuring the rationality of the subsequent sampling.
It should be noted that, in the process of searching for neighboring points, although texture points with curvatures greater than or equal to the preset curvature threshold value are not selected, when a starting point of a new texture edge is searched, i.e., during global traversal, the texture points with curvatures greater than or equal to the preset curvature threshold value may be selected and form a new texture edge with other texture points with curvatures less than the preset curvature threshold value, so that the smoothness of the texture edge is ensured and the integrity of the sample is ensured. In addition, during edge selection, the texture point that has been determined as a point on the texture edge is not involved in the subsequent edge selection process, for example, a Flag with a value "True" may be set for the texture point that has been determined as a point on the texture edge, indicating that the texture point has been searched, so that the texture point with the Flag with the value "True" may be ignored when searching for the neighboring point and the start point of the new texture edge, thereby avoiding the occurrence of dead loop. In other embodiments, other edge selection manners may also be selected according to the requirements of a specific scenario, such as through a tree structure.
The preset sampling condition mentioned in this step may include a preset sampling interval, where the preset sampling interval may be regarded as a sampling step length, and in this embodiment, an edge between any two adjacent texture points in the texture image is regarded as one step length, for example, points on one texture edge respectively correspond to the 1 st point, the 10 th point, the 20 th point, the 30 th point, the 60 th point, the 80 th point, and the 100 th point in the point cloud of the initial three-dimensional model, and if the preset sampling interval is 3 step lengths, the texture points selected by sampling are texture points corresponding to three vertexes, that is, the 1 st point, the 30 th point, and the 100 th point. In this way, averaging of the selection points can be achieved. Further, in order to avoid that some important vertices, such as eye corner points and nose tip points, in the point cloud topology are excluded in the sampling process, in some examples, the preset sampling condition may further include that a preset sampling mark is provided, and the texture points selected by sampling include texture points sampled according to a preset sampling interval and texture points with the preset sampling mark. The preset sampling mark can be obtained by adding an important vertex in the data of the initial network model in a manual adding mode, or can be automatically added in the data of the initial network model after the important vertex is identified through a neural network algorithm. In the foregoing example, if the 20 th point has the preset sampling mark, the texture points selected by sampling include the texture point corresponding to the 20 th point, in addition to the texture points corresponding to the three vertices of the 1 st point, the 30 th point and the 100 th point. Therefore, important vertexes in the point cloud can be effectively reserved.
After sampling and selecting the texture points, the vertex of the initial three-dimensional model can be thinned by using the texture points. Each vertex of the initial three-dimensional model has an index, information such as vertex coordinates and texture coordinates of the vertex can be packed into an array for storage, and the information in the array can be quickly retrieved through the index. Therefore, in some examples, the thinning process may be performed by extracting, from the original point cloud of the initial three-dimensional model, respective vertices corresponding to the sampled and selected texture points according to the indexes corresponding to the sampled and selected texture points to form a sparse point cloud. Of course, in other embodiments, the thinning processing may be performed by determining each vertex corresponding to the texture point selected by sampling as a sparse point, and deleting vertices other than the sparse point from the original point cloud of the initial three-dimensional model.
And 203, constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
After point cloud sparsification, the sparsified vertexes can be connected to generate a series of non-intersecting and non-overlapping polygons, namely, a polygon mesh is constructed, so that a target three-dimensional model is obtained. Alternatively, the polygon may be a Delaunay triangle, that is, this step may be implemented by automatically constructing a Delaunay triangle for the thinned vertices by using a Delaunay triangulation algorithm. The Delaunay triangulation algorithm is a triangulation algorithm following an air circumcircle criterion and a maximum and minimum angle criterion, and because most texture images of the initial three-dimensional model meet the characteristic of bilateral symmetry, the constructed Delaunay triangles can also meet the characteristic of bilateral symmetry, so that the symmetry of the constructed polygonal network is realized. The specific calculation process for constructing the delaunay triangle may refer to descriptions in related technologies, and is not described herein again. It should be noted that, because the Delaunay triangulation algorithm has a large calculation amount in a three-dimensional space, in some examples, a Delaunay triangle may be constructed according to texture points corresponding to thinned vertices, and finally a point cloud topology may be obtained based on the constructed texture topology, so that the calculation amount may be reduced, and the efficiency may be improved. In addition, in other embodiments, the polygon mesh may be of other types, such as a quadrangle patch, a pentagon patch, and the like, which is not limited in this specification.
Further, in practical applications, the regularity of the constructed polygon network is very important for service usage, as shown in fig. 4A, fig. 4A is a schematic diagram of a local effect after a triangular patch is automatically constructed by using a triangulation algorithm, a position shown by a region 41 in the diagram belongs to an outer contour of an eye, and a point at the position is often required to be annular during service usage, so that a professional needs to perform secondary adjustment for the situation of fig. 4A, which is undoubtedly very cumbersome. Based on this, in some examples, for the vertices of such key positions, constraint marks may be set in advance for the vertices to form preset constraint points, where the constraint marks may be manually recorded by a professional, or may be automatically identified and recorded by a neural network algorithm, so that, in the process of constructing the polygon mesh, if two vertices belong to the preset constraint points, the polygon may be constructed with an edge formed by the two vertices as a reference. As shown in fig. 4B, fig. 4B is a schematic diagram of a local effect of automatically constructing a triangular patch after adding a preset mark, where a position shown in a region 42 in the diagram belongs to an outer contour of an eye point, where a texture point 43 and a texture point 44 belong to preset constraint points (the texture point and a vertex are in a one-to-one correspondence, and therefore, when a vertex belongs to a preset constraint point, a texture point corresponding to the vertex also belongs to the preset constraint point), when constructing a polygon of the region 42 based on a Delaunay triangulation algorithm, it is determined whether two texture points belong to the preset constraint points for three texture points appearing in a currently constructed delo triangle, and since the texture point 43 and the texture point 44 belong to the preset constraint points, an optimal delo triangle is calculated with an edge formed by the texture point 43 and the texture point 44 as a reference, so that a topological structure of a target three-dimensional model obtained by construction meets requirements, the method has symmetry, and effectively reduces the workload of professional technicians caused by secondary adjustment.
According to the scheme of the embodiment, sampling points are selected based on texture edges of the texture image of the initial three-dimensional model, point cloud sparsification is carried out according to the sampling points, and then the target three-dimensional model is constructed according to sparsified vertexes. Therefore, the automatic adjustment of the initial three-dimensional model is realized, the workload of professional technicians is effectively reduced, meanwhile, the three-dimensional problem is converted into the two-dimensional problem, the sampling averaging is realized, and the thinned vertex is the vertex in the original point cloud, so that the uncontrollable result is effectively reduced.
To illustrate the solution of the present specification in more detail, a specific embodiment is described below:
the scheme of this embodiment is applied to a drawing software, and in a single process, the drawing software automatically adjusts a three-dimensional face model, where the three-dimensional face model is a three-dimensional mesh model obtained by performing mesh reconstruction on a point cloud model generated by scanning a real person based on a three-dimensional scanner by an art worker, as shown in fig. 5A, fig. 5A is a schematic diagram of a point cloud and a triangular patch of the three-dimensional face model. The process of the drawing software for automatically adjusting the three-dimensional face model is as follows:
s501, obtaining a texture image of the three-dimensional face model, wherein the texture image comprises a plurality of texture points, and each texture point corresponds to one vertex in the point cloud;
s502, obtaining texture edges in the texture image through minimum curvature calculation, wherein the minimum curvature calculation mode comprises the following steps: determining a texture point with the minimum curvature from all texture points as a starting point of a texture edge, determining a texture point with the minimum curvature from adjacent points of the target point as a point on the texture edge, and so on until the curvatures of all the adjacent points of a certain point are greater than or equal to a preset curvature threshold value, thus obtaining a first texture edge, then continuously selecting edges from the rest points in the same way, and obtaining a plurality of texture edges after traversing all the texture points;
s503, sampling is carried out on each texture edge according to the step length of 3, namely 1 sampling point is selected for each 3 texture points;
s504, determining vertexes corresponding to the sampling points as sparse points, and extracting the sparse points and vertexes with preset sampling marks from the original point cloud of the initial three-dimensional model to form sparse point cloud;
s505, constructing a Delaunay triangle for each texture point corresponding to the sparse point cloud by using a Delaunay triangulation algorithm, judging whether two texture points of three texture points appearing in the currently constructed Delaunay triangle belong to a preset constraint point or not when the Delaunay triangle is constructed by circularly calculating all the texture points, if so, calculating an optimal Delaunay triangle by using an edge formed by the two texture points as a reference requirement, traversing all the points to obtain a texture topological structure, and determining a point cloud topological structure according to the texture topological structure, thereby constructing and obtaining a target model.
According to the scheme of the embodiment, the automatic generation of the point cloud sparse topology can be realized, the workload of art workers is effectively reduced, and the topological structure of the target model obtained through adjustment has symmetry and regularity which meet the design requirements. In addition, the scheme of the embodiment is not only suitable for the automatic adjustment of the human face model, but also suitable for the automatic adjustment of the grid models of other objects, such as animals, electronic equipment, virtual images and the like.
Corresponding to the embodiment of the method, the specification also provides an embodiment of a three-dimensional model adjusting device and a terminal applied by the three-dimensional model adjusting device.
The embodiment of the three-dimensional model adjusting device in the specification can be applied to computer equipment, such as a server or terminal equipment. The device embodiments may be implemented by software, or by hardware, or by a combination of hardware and software. The software implementation is taken as an example, and as a logical device, the device is formed by reading corresponding computer program instructions in the nonvolatile memory into the memory for operation through the processor in which the file processing is located. From a hardware aspect, as shown in fig. 6, which is a hardware structure diagram of a computer device in which a three-dimensional model adjusting apparatus according to an embodiment of the present disclosure is located, except for the processor 610, the memory 630, the network interface 620, and the nonvolatile memory 640 shown in fig. 6, a server or an electronic device in which an apparatus 631 is located in an embodiment may also include other hardware according to an actual function of the computer device, which is not described again.
Accordingly, the embodiments of the present specification also provide a computer storage medium, in which a program is stored, and the program, when executed by a processor, implements the method in any of the above embodiments.
Embodiments of the present description may take the form of a computer program product embodied on one or more storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having program code embodied therein. Computer-usable storage media include permanent and non-permanent, removable and non-removable media, and information storage may be implemented by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of the storage medium of the computer include, but are not limited to: phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technologies, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic tape storage or other magnetic storage devices, or any other non-transmission medium, may be used to store information that may be accessed by a computing device.
As shown in fig. 7, fig. 7 is a block diagram of a three-dimensional model adjustment apparatus shown in the present specification according to an exemplary embodiment, the apparatus including:
an obtaining module 71, configured to obtain a texture image of the initial three-dimensional model, where the texture image includes a plurality of texture points;
the sparse module 72 is configured to acquire a texture edge of the texture image, sample the texture edge according to a preset sampling condition, and perform sparse processing on a vertex of the initial three-dimensional model by using a texture point selected by sampling;
and the constructing module 73 is used for constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
The implementation process of the functions and actions of each module in the above device is specifically described in the implementation process of the corresponding step in the above method, and is not described herein again.
For the device embodiments, since they substantially correspond to the method embodiments, reference may be made to the partial description of the method embodiments for relevant points. The above-described embodiments of the apparatus are merely illustrative, wherein the modules described as separate parts may or may not be physically separate, and the parts displayed as modules may or may not be physical modules, may be located in one place, or may be distributed on a plurality of network modules. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution in the specification. One of ordinary skill in the art can understand and implement it without inventive effort.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
Other embodiments of the present description will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This specification is intended to cover any variations, uses, or adaptations of the specification following, in general, the principles of the specification and including such departures from the present disclosure as come within known or customary practice within the art to which the specification pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the specification being indicated by the following claims.
It will be understood that the present description is not limited to the precise arrangements described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present description is limited only by the appended claims.
The above description is only a preferred embodiment of the present disclosure, and should not be taken as limiting the present disclosure, and any modifications, equivalents, improvements, etc. made within the spirit and principle of the present disclosure should be included in the scope of the present disclosure.

Claims (10)

1. A method for adjusting a three-dimensional model, comprising:
acquiring a texture image of an initial three-dimensional model, wherein the texture image comprises a plurality of texture points;
acquiring texture edges of the texture images, sampling the texture edges according to preset sampling conditions, and performing sparsification on vertexes of the initial three-dimensional model by using texture points selected by sampling;
and constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
2. The method of claim 1, wherein the texture edges are selected based on the curvature of each texture point; the curvature of a texture point is determined according to the included angle between the texture point and an adjacent point.
3. The method of claim 2, wherein the obtaining the texture edge of the texture image comprises:
acquiring a target point on the texture edge which is determined for the last time;
selecting target adjacent points with the smallest curvature, wherein the curvature of the target adjacent points is smaller than a preset curvature threshold value;
determining the target adjacent points as target points on the texture edge until no target adjacent points with the curvature smaller than a preset curvature threshold exist;
and determining the target point on the texture edge for the first time as a point which is not determined as any texture edge and has the smallest curvature.
4. The method of claim 1, wherein the preset sampling condition comprises a preset sampling interval.
5. The method according to claim 4, wherein the predetermined sampling condition further comprises a predetermined sampling flag, and the texture points selected by sampling comprise texture points sampled at a predetermined sampling interval and texture points with the predetermined sampling flag.
6. The method according to claim 1, wherein the thinning of the vertices of the three-dimensional model by the sampled texture points comprises:
and obtaining sparse point cloud according to each vertex corresponding to the sampled and selected texture point.
7. The method of claim 1, wherein constructing the polygon mesh from the thinned vertices comprises:
in the process of constructing the polygonal network, if two vertexes belong to preset constraint points, constructing a polygon by taking an edge formed by the two vertexes as a reference; the preset constraint points are vertexes carrying constraint marks.
8. A three-dimensional model adjustment apparatus, comprising:
the system comprises an acquisition module, a processing module and a display module, wherein the acquisition module is used for acquiring a texture image of an initial three-dimensional model, and the texture image comprises a plurality of texture points;
the sparse module is used for acquiring texture edges of the texture images, sampling the texture edges according to preset sampling conditions, and performing sparse processing on vertexes of the initial three-dimensional model by using texture points selected by sampling;
and the construction module is used for constructing a polygonal mesh according to the thinned vertexes to obtain a target three-dimensional model.
9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor when executing the program implements the method of any one of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the method of any one of claims 1 to 7.
CN202111574371.7A 2021-12-21 2021-12-21 Three-dimensional model adjusting method and device, storage medium and equipment Pending CN114283266A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111574371.7A CN114283266A (en) 2021-12-21 2021-12-21 Three-dimensional model adjusting method and device, storage medium and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111574371.7A CN114283266A (en) 2021-12-21 2021-12-21 Three-dimensional model adjusting method and device, storage medium and equipment

Publications (1)

Publication Number Publication Date
CN114283266A true CN114283266A (en) 2022-04-05

Family

ID=80873770

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111574371.7A Pending CN114283266A (en) 2021-12-21 2021-12-21 Three-dimensional model adjusting method and device, storage medium and equipment

Country Status (1)

Country Link
CN (1) CN114283266A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024002064A1 (en) * 2022-07-01 2024-01-04 维沃移动通信有限公司 Method and apparatus for constructing three-dimensional model, and electronic device and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024002064A1 (en) * 2022-07-01 2024-01-04 维沃移动通信有限公司 Method and apparatus for constructing three-dimensional model, and electronic device and storage medium

Similar Documents

Publication Publication Date Title
CN109697688B (en) Method and device for image processing
US8711143B2 (en) System and method for interactive image-based modeling of curved surfaces using single-view and multi-view feature curves
KR102210537B1 (en) Robust merge of 3d textured meshes
CN112002014A (en) Three-dimensional face reconstruction method, system and device for fine structure
CN111127623B (en) Model rendering method and device, storage medium and terminal
WO2022041437A1 (en) Plant model generating method and apparatus, computer equipment and storage medium
Yin et al. Full 3D plant reconstruction via intrusive acquisition
CN109584327B (en) Face aging simulation method, device and equipment
US9147279B1 (en) Systems and methods for merging textures
CN110084894B (en) Local amplification display method and device of three-dimensional model and electronic equipment
CN111382618B (en) Illumination detection method, device, equipment and storage medium for face image
CN107633544B (en) Processing method and device for ambient light shielding
CN111275633A (en) Point cloud denoising method, system and device based on image segmentation and storage medium
CN113327315A (en) Multi-level detail model generation method and device
US10937236B1 (en) Mesh smoothing for visual quality and analysis improvement
CN109064533A (en) A kind of 3D loaming method and system
CN113469868B (en) Live-action three-dimensional model digital watermark adding method based on structural change
CN114283266A (en) Three-dimensional model adjusting method and device, storage medium and equipment
CN116129076B (en) Building Mesh model simplification method with rule feature maintained
CN111632376B (en) Virtual model display method and device, electronic equipment and storage medium
US8948498B1 (en) Systems and methods to transform a colored point cloud to a 3D textured mesh
CN111882677A (en) Method and device for editing three-dimensional plant model, electronic equipment and storage medium
CN115311418B (en) Multi-detail-level tree model single reconstruction method and device
Pound et al. Surface reconstruction of plant shoots from multiple views
CN114529648A (en) Model display method, device, apparatus, electronic device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination