Three-dimensional mesh encoding method and device, and three-dimensional mesh decoding method and device
By coding the triangle pattern in the three-dimensional grid and processing additional information, the problem of low compression efficiency of the three-dimensional grid connectivity relationship is solved, and efficient three-dimensional graphics transmission and computer processing are achieved.
Patent Information
- Application Number
- PCT/CN2024/128372
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-11-17
- Filing Date
- 2024-10-30
- Publication Date
- 2025-05-22
AI Technical Summary
The prior art is difficult to efficiently compress the connectivity relationship of three-dimensional grids, resulting in inefficient transmission, storage and computer processing of three-dimensional graphics.
A three-dimensional grid encoding and decoding method is proposed. By encoding the pattern of triangles in the three-dimensional grid and determining additional information based on the setting threshold of the preset mode, it realizes efficient encoding and decoding of the three-dimensional grid connectivity relationship.
It improves the compression efficiency of the three-dimensional grid, ensures efficient transmission and storage of three-dimensional graphics, and at the same time, it realizes rapid reconstruction in computer processing, improving overall performance.
Smart Images

Figure CN2024128372_22052025_PF_FP_ABST
Abstract
Description
A three-dimensional grid encoding and decoding method and device Technical Field
[0001] The present invention belongs to the field of coding and decoding, and in particular relates to a three-dimensional grid coding and decoding method and device. Background Art
[0002] With the advancement of 3D mesh modeling and scanning technology, people have higher requirements for the accuracy and details of 3D graphics, which has also caused the amount of data of the original 3D mesh to increase exponentially. This has posed a major challenge to the transmission, storage and computer processing of 3D meshes. Therefore, it is particularly important to efficiently compress 3D meshes while ensuring quality.
[0003] A three-dimensional mesh is composed of elements at multiple levels, including vertices, edges, and faces. Vertices are the basic elements that make up a three-dimensional mesh and are described by coordinates in three-dimensional space. Edges are the parts that connect two vertices in a three-dimensional mesh. Faces are polygons connected by closed edges. Nowadays, most faces in three-dimensional meshes are triangles. A three-dimensional mesh mainly contains the following three types of information: 1. Geometric information. Geometric information mainly includes the position coordinates of all vertices in the three-dimensional mesh in three-dimensional space; 2. Connectivity relationship, also known as topological information. Connectivity relationship is used to describe the connection information between vertices and facets in a three-dimensional mesh; 3. Other optional attribute information. Attribute information includes other information attached to the three-dimensional mesh, including color information, normal vectors, texture coordinates, etc.
[0004] Connectivity is used to describe the connections between vertices in a 3D mesh, affecting both the overall shape and local details of the model. Therefore, proposing a new compression algorithm to efficiently compress the connectivity of 3D meshes is of great significance.
[0005] Summary of the Invention
[0006] In order to solve the above problems existing in the prior art, the present invention provides a three-dimensional grid encoding and decoding method and device. The technical problem to be solved by the present invention is achieved through the following technical solutions:
[0007] In a first aspect, an embodiment of the present invention provides a three-dimensional mesh encoding method, the encoding method comprising:
[0008] Encode the connection relationship and geometric information of the input 3D mesh to obtain the output code stream;
[0009] Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional grid; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of the triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
[0010] In a second aspect, an embodiment of the present invention provides a three-dimensional grid encoding device, the encoding device comprising:
[0011] The encoding module is used to encode the connection relationship and geometric information of the input 3D mesh to obtain an output code stream;
[0012] Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional grid; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of the triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
[0013] In a third aspect, an embodiment of the present invention provides a three-dimensional mesh decoding method, the decoding method comprising:
[0014] Decode the connection relationship and geometric information of the input code stream to obtain the connection relationship and geometric information respectively;
[0015] Reconstructing a three-dimensional mesh based on the obtained connection relationship and geometric information;
[0016] Among them, the connection relationship decoding includes decoding the pattern of triangles in the three-dimensional grid; for the preset pattern that meets the conditions, the connection relationship decoding also includes decoding additional information used to indicate the position relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding.
[0017] In a fourth aspect, an embodiment of the present invention provides a three-dimensional grid decoding device, the decoding device comprising:
[0018] The decoding module is used to decode the connection relationship and geometric information of the input code stream to obtain the connection relationship and geometric information respectively;
[0019] A reconstruction module, used to reconstruct a three-dimensional mesh based on the obtained connection relationship and geometric information;
[0020] Among them, the connection relationship decoding includes decoding the pattern of triangles in the three-dimensional grid; for the preset pattern that meets the conditions, the connection relationship decoding also includes decoding additional information used to indicate the position relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding.
[0021] Beneficial effects of the present invention:
[0022] In a three-dimensional mesh encoding and decoding scheme proposed in an embodiment of the present invention, at the encoder, connectivity encoding includes encoding the pattern of triangles in the three-dimensional mesh. For a preset pattern that satisfies a condition, the connectivity encoding also includes determining and encoding additional information indicating the triangle positional relationship based on a set threshold corresponding to the preset pattern. The connectivity encoding is implemented based on entropy coding of context information. Accordingly, at the decoder, connectivity decoding and geometric information decoding are performed on the input bitstream to obtain connectivity and geometric information, respectively. The three-dimensional mesh is reconstructed based on the obtained connectivity and geometric information. The connectivity decoding includes decoding the pattern of triangles in the three-dimensional mesh. For a preset pattern that satisfies a condition, the connectivity decoding also includes decoding additional information indicating the triangle positional relationship to achieve instant stitching of the current triangle. The geometric information decoding supports a decoding method parallel to the connectivity decoding. In this embodiment of the present invention, encoding and transmitting additional information indicating the triangle positional relationship at the encoder can improve entropy coding efficiency and enable the decoder to utilize the triangle positional relationship to ensure instant stitching during stitching.
[0023] As a specific example, when encoding the connection relationship, the embodiment of the present invention adds encoded connection information and stitching angle information as instant stitching information for S-mode triangles and E, R or L-mode triangles that meet the conditions and are connected to two or more S-mode triangles. When decoding the connection relationship, the decoded instant stitching information can be used to reconstruct the mesh for each decoded mode triangle, that is, the triangle is stitched to the reconstructed mesh. The vertex geometry information of the three-dimensional mesh can be decoded without waiting for the entire mesh to be reconstructed, and the connection relationship decoding and the vertex geometry information decoding can be achieved in parallel. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] FIG1 is a schematic diagram of a triangular fan structure in an existing TFAN algorithm;
[0025] FIG2 is a schematic diagram of triangle fan classification in the existing TFAN algorithm;
[0026] FIG3 is a schematic flow chart of a three-dimensional grid coding method provided by an embodiment of the present invention;
[0027] FIG4 is a schematic diagram showing the principle of applying a three-dimensional grid coding method according to an embodiment of the present invention to a separate coding frame;
[0028] FIG5 is a schematic diagram showing the principle of applying a three-dimensional grid coding method according to an embodiment of the present invention to a hybrid coding framework;
[0029] FIG6 is a schematic diagram of a framework of a connection relationship encoding method proposed in an embodiment of the present invention;
[0030] Figure 7 shows the correspondence between angles, vertices, and triangles in the Corner-Table data structure;
[0031] Figure 8 is a schematic diagram of the CLERS model;
[0032] FIG9 is a schematic diagram of an entropy coding framework according to an embodiment of the present invention;
[0033] FIG10 is a schematic diagram of a process for recording the number of vertex rotations according to an embodiment of the present invention;
[0034] FIG11 is a schematic diagram showing the zip rotation vertex and two adjacent S-shaped triangles according to an embodiment of the present invention;
[0035] Figure 12 is a schematic diagram of a handle;
[0036] FIG13 is a schematic flow chart of a three-dimensional grid decoding method provided by an embodiment of the present invention;
[0037] FIG14 is a schematic diagram showing the principle of applying a three-dimensional grid decoding method according to an embodiment of the present invention to a separate decoding framework;
[0038] FIG15 is a schematic diagram showing the principle of applying a three-dimensional grid decoding method according to an embodiment of the present invention to a hybrid decoding framework;
[0039] FIG16 is a schematic diagram of the suturing process of the L-mode according to an embodiment of the present invention;
[0040] FIG17 is a schematic diagram showing an L-mode rotation vertex and two S-mode triangles adjacent to each other according to an embodiment of the present invention;
[0041] FIG18 is a schematic diagram of the suturing process of the R mode according to an embodiment of the present invention. DETAILED DESCRIPTION
[0042] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0043] Currently, TFAN is one of the best performing connectivity encoding algorithms. In the TFAN connectivity encoding algorithm, a triangular fan structure is first defined. A triangular fan is composed of a series of triangles with the same vertex and the same direction, as shown in Figure 1. The triangular fan is defined as follows:
[0044] 1) Any two consecutive triangles in a triangle fan must be adjacent and share a common side.
[0045] 2) All triangles in a triangle fan have the same direction.
[0046] 3) All triangles in a triangle fan share a vertex, which is called the center point of the triangle fan. The shared vertex is shown as v0.
[0047] The TFAN connectivity encoding algorithm encodes vertices in a 3D mesh by traversing them. First, a first-in, first-out queue is defined, and all vertices are marked as untraversed. Then, starting with a random initial vertex, a triangular fan structure centered at the initial vertex is determined. The remaining vertices in this triangular fan are placed in the queue, marked as traversed, and encoded. Vertices are then removed from the queue and the above process is repeated until the queue is empty and all vertices in the 3D mesh are marked, at which point encoding ends.
[0048] The coding of triangular sectors is mainly based on the degree of the center point of the triangular sector (that is, the number of triangles in the triangular sectors adjacent to the center point), the direction of the triangles, and the situation of vertex traversal to classify the triangular sectors. As shown in Figure 2, different values of C represent different categories of triangular sectors. In the figure, gray triangles represent traversed triangles, white ones represent untraversed triangles, and red and black vertices represent traversed and untraversed vertices respectively (the vertex colors are not shown in Figure 2. The red vertices are the four vertices on the lower outside of the hexagon and the vertices of the protruding triangle when there is a protruding triangle on the upper left side. The other outer vertices of the hexagon are black). When coding, the category, vertex degree, and vertex traversal information of the current triangular sector are encoded, among which the vertex traversal information is an optional encoding option.
[0049] Since TFAN has many types of triangular fans and the encoding of connection relationships is relatively inefficient, in order to achieve efficient encoding of connection relationships and real-time reconstruction at the decoding end, an embodiment of the present invention proposes a new three-dimensional mesh connection relationship encoding and decoding scheme. On this basis, combined with the encoding and decoding scheme of geometric information, a complete encoding and decoding scheme for three-dimensional meshes is proposed. Specifically, an embodiment of the present invention proposes a three-dimensional mesh encoding method and device, as well as a corresponding three-dimensional mesh decoding method and device.
[0050] It should be noted that the execution entities of the three-dimensional mesh encoding method / device or three-dimensional mesh decoding method / device provided in the embodiments of the present invention can be executed in corresponding electronic devices. The electronic device can be a server or a terminal device, but is not limited to these.
[0051] In a first aspect, an embodiment of the present invention provides a three-dimensional grid encoding method, which can be applied to an encoding end. As shown in FIG3 , the encoding method may include:
[0052] Scode1 encodes the connection relationship and geometric information of the input 3D mesh to obtain the output code stream;
[0053] Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional grid; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of the triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
[0054] In an embodiment of the present invention, connection relationship encoding and geometric information encoding are performed in units of triangles, that is, they are implemented by traversing triangles. In an embodiment of the present invention, connection relationship encoding and geometric information encoding can have the same triangle traversal order, but can also have different triangle traversal orders. It can be understood that the latter method requires additional transmission of some relevant information compared to the former method, which will not be described in detail here.
[0055] The main idea of the three-dimensional mesh connection relationship encoding method proposed in an embodiment of the present invention is to first select a triangle as an initial triangle on the three-dimensional mesh to be encoded, and then start from the initial triangle according to certain traversal rules to traverse the connection relationship of the triangles by determining the pattern of the triangles one by one. In addition, for a preset pattern that meets the conditions, when encoding the connection relationship in the pattern of the encoded triangle, additional information used to indicate the position relationship of the triangles is determined according to a set threshold corresponding to the preset pattern, and the additional information is encoded.
[0056] Furthermore, in the 3D mesh coding method proposed in the embodiments of the present invention, the geometric information coding supports a parallel coding method with the connectivity relationship coding. Specifically, the 3D mesh coding method proposed in the embodiments of the present invention can be applied to a 3D mesh coding framework in which connectivity relationship and geometric information are separately coded (i.e., suitable for separate coding frameworks); it can also be applied to a 3D mesh coding framework in which connectivity relationship and geometric information are mixed (i.e., suitable for mixed coding frameworks).
[0057] Specifically, for a separate coding framework, the input 3D mesh is coded for connectivity and geometry information to obtain an output code stream, including:
[0058] (1) Traversing the triangles in the three-dimensional grid to perform connection relationship coding and obtain the connection relationship coding result;
[0059] Specifically, the connection relationship encoding can be performed by traversing the triangles in the three-dimensional grid, and the connection relationship code stream can be obtained from the connection relationship encoding results of all triangles;
[0060] (2) traversing the triangles in the three-dimensional grid to perform geometric information encoding and obtain geometric information encoding results; wherein, the connection relationship encoding and geometric information encoding are performed in units of triangles;
[0061] This step can be performed by traversing the triangles in the three-dimensional mesh according to the connection relationship coding order to perform geometric information coding, and obtaining a geometric information code stream from the geometric information coding results of all triangles;
[0062] (3) Obtaining an output code stream based on the connection relationship encoding result and the geometric information encoding result;
[0063] Specifically, the connection relationship code stream and the geometric information code stream may be mixed to obtain the output code stream.
[0064] Please refer to Figure 4 for the main processing flow of the three-dimensional mesh coding framework for separate coding of connection relationships and geometric information in the embodiment of the present invention. Under this separate coding framework, the input three-dimensional mesh will be separately coded for connection relationship and geometric information. Both codes are implemented by traversing triangles. Taking the example of the connection relationship coding and geometric information coding having the same triangle traversal order, this method is reflected in the need to utilize the connection relationship coding order for geometric information coding. This connection relationship coding order reflects the triangle traversal order in the connection relationship coding process. In other words, the connection relationship code stream is obtained after traversing all triangles to complete the connection relationship coding, and the geometric information code stream is also obtained after traversing all triangles in the same order to complete the geometric information coding. The output code stream is obtained by mixing these two code streams.
[0065] Of course, the above only illustrates the case where the connection relationship encoding and the geometric information encoding have the same triangle traversal order. For the case where the connection relationship encoding and the geometric information encoding have different triangle traversal orders, please refer to the above for understanding. It will not be explained in detail in the form of diagrams here. The connection relationship encoding in the above steps is implemented using the ideas in the previous text. For the sake of clear layout, it will be explained in detail in the following text.
[0066] Specifically, for the hybrid coding framework, the input 3D mesh is coded for connectivity and geometry information to obtain an output code stream, including:
[0067] (1) traversing each triangle in the three-dimensional mesh, performing connection relationship encoding on the traversed triangle to obtain a connection relationship encoding result of the triangle, and performing geometric information encoding on the triangle to obtain a geometric information encoding result of the triangle. The connection relationship encoding result and the geometric information encoding result of the triangle constitute the encoding result of the triangle;
[0068] (2) The output code stream is obtained from the encoding results of all triangles.
[0069] Please refer to Figure 5 for the main processing flow of the three-dimensional mesh coding framework for hybrid coding of connection relationship and geometric information applied in the embodiment of the present invention. In this hybrid coding framework, the input three-dimensional mesh is traversed, and each traversed triangle will be coded for connection relationship and geometric information, that is, when a triangle is traversed, the pattern of the triangle, any additional information that may exist, and the geometric coordinates of the vertices of the triangle that have not yet been encoded are encoded. Therefore, for the hybrid coding framework, the triangle traversal order for geometric information encoding and connection relationship encoding is consistent, and ultimately there will be only one code stream, which is a mixture of the connection relationship coding results and geometric information coding results of the triangles traversed in sequence, as the output code stream. Similarly, the connection relationship coding in the above steps is also implemented using the ideas in the previous text.
[0070] In summary, the embodiment of the present invention encodes the connection relationship and uses the information of the encoded three-dimensional mesh to encode the geometric information, that is, the geometric information of the triangles traversed by the connection relationship encoding is encoded. The connection information code stream may include the pattern information, handle information, S connection information, stitching angle information and threshold setting information of the triangle (the specific meaning of the above information will be introduced in the embodiment of the present invention later); the geometric information code stream includes starting coordinate information, geometric prediction residual, etc. The embodiment of the present invention does not limit the information arrangement order of the connection information code stream. When the S connection information is encoded independently, the arrangement order can be S connection information, stitching angle information, handle information, pattern information; when the S connection information is encoded after encoding each S pattern, the arrangement order can be stitching angle information, handle information, pattern information (the S connection information of the triangle is encoded after each S pattern).
[0071] The following describes the main process of the connection relationship encoding method proposed in an embodiment of the present invention. Please refer to Figure 6 for understanding. It can be understood that for a separate coding frame, the output of Figure 6 is a connection relationship code stream, and for a mixed coding frame, the output of Figure 6 is the connection relationship encoding result of the current triangle.
[0072] Specifically, in Scode1, the process of encoding the connectivity relationships of the input 3D mesh begins by selecting an initial triangle and traversing the triangles on the 3D mesh from that initial triangle. Based on the traversed triangles, the traversal status of the current triangle's vertices and the traversal status of the left and right triangles is determined. Different modes are used to represent the current triangle, and the corresponding direction is selected to traverse to the next triangle. After determining the mode of the current triangle, the triangle mode can be encoded.
[0073] Specifically, the process mainly includes steps A1 to A3:
[0074] Step A1, selecting an initial triangle in the three-dimensional mesh to start traversal, and determining a traversal result for each traversed triangle based on the traversed triangles;
[0075] Before encoding the connection relationship, the triangles are first traversed for initialization and the relevant data structures are established. The purpose is to extract the relevant information of the triangles in the 3D mesh, such as the relationship between vertices, corners, or edges, to facilitate subsequent traversal. In the implementation, data structures such as Corner-Table and Half-Edge can be used to store the mesh. The following uses Corner-Table as an example to describe the traversal and connection relationship encoding process.
[0076] The Corner-Table data structure contains four arrays: V, O, M, and U. The lengths of arrays V, O, and U are three times the number of mesh patches, and the length of array M is equal to the number of patches. Mesh patches are triangles. Array V stores the vertex corresponding to each corner in the 3D mesh, and array O stores the opposite angle of each corner. Arrays M and U both store binary symbols, each indicating whether the vertex and triangle in the 3D mesh have been traversed. During initialization, each corner is assigned a sequence number based on the counterclockwise order of the triangle's interior angles. This allows for quick traversal of the other two corners of the same triangle based on the sequence number of a given corner. Let's denote the current corner within the triangle as c, the first corner encountered by c in clockwise order as cp, the first corner encountered by c in counterclockwise order as cn, the vertex corresponding to c as cv, the opposite angle of c as co, and the triangle to which c belongs as ct, as shown in Figure 7 (grayscale). For the definitions and configuration rules of corners and vertices, see Understanding the Corner-Table Data Structure.
[0077] Step A1 corresponds to the "Select an initial triangle and traverse the connection relationship" and "Determine the current triangle's mode and next traversal direction based on the traversed triangles" sections in Figure 6. The traversal result of the triangle includes the triangle's mode;
[0078] In an optional embodiment, the triangle pattern may be a CLERS pattern, but this is not limited here. For ease of understanding, the following description will be made using the Corner-Table data structure and the CLERS pattern as examples.
[0079] Step A1 may specifically include: for each traversed triangle, determining the vertex corresponding to angle c of the triangle based on the angle and opposite angle in the Corner-Table data structure, as well as the relationship between angles and vertices, determining the traversal result of the triangle, including the CLERS mode of the triangle, based on the traversal of the vertex corresponding to angle c of the triangle obtained and the traversal of the triangles on the left and right sides, marking the triangle as a traversed triangle, and marking the three vertices of the triangle as traversed vertices. It can be understood that in this specific example, the current angle is angle c.
[0080] Specifically, when traversing triangles on a 3D mesh, embodiments of the present invention divide the 3D mesh into traversed and untraversed portions. An initial triangle may be selected, for example through random selection, and traversal may begin from this initial triangle. Traversed triangles are continuously inserted into the traversed portion, and additional triangles are traversed based on the relative orientation of the newly added triangles. Furthermore, a different mode is output for each triangle based on the position of the vertex corresponding to the current corner of the triangle and the traversal of the triangles to its left and right. This also determines the traversal direction for the next triangle.
[0081] Please refer to Figure 8 for understanding (the figure is a grayscale image), where X is the current triangle, and v is the vertex corresponding to the current angle of the triangle, that is, angle c. When traversing, different modes are assigned to the triangle according to the five different situations of the CLERS mode, and jump to the next triangle in a different direction.
[0082] Specifically, the traversal result of the triangle is determined based on the traversal of the vertex corresponding to the obtained angle c of the triangle and the traversal of the triangles on the left and right sides, including:
[0083] 1) For the current triangle traversed, if the vertex corresponding to the c corner of the triangle has not been traversed, determine that the CLERS mode to which the triangle belongs is C mode, and the traversal direction of the next triangle is to the right of the triangle;
[0084] Please refer to the pattern diagram marked with C in Figure 8. Pattern C indicates that v has not been traversed and should be traversed to the right of the current triangle.
[0085] 2) For the current triangle traversed, if the vertex corresponding to the c corner of the triangle has been traversed, and the triangle to the left of the triangle has been traversed, but the triangle to the right has not been traversed, the CLERS mode to which the triangle belongs is determined to be L mode, and the traversal direction of the next triangle is to the right of the triangle;
[0086] Please refer to the pattern diagram marked with L in Figure 8. The L pattern indicates that v has been traversed and should be traversed to the right of the current triangle.
[0087] 3) For the current triangle traversed, if the vertex corresponding to the c corner of the triangle has been traversed, and the triangle to the right of the triangle has been traversed, but the triangle to the left has not been traversed, the CLERS mode to which the triangle belongs is determined to be R mode, and the traversal direction of the next triangle is the left side of the triangle;
[0088] Please refer to the pattern diagram marked with R in Figure 8. The R pattern indicates that v has been traversed and should be traversed to the left of the current triangle.
[0089] 4) For the current triangle traversed, if the vertex corresponding to the c corner of the triangle has been traversed, and the left and right triangles of the triangle have not been traversed, the CLERS mode to which the triangle belongs is determined to be S mode. The traversal direction of the next triangle is to traverse the right branch of the triangle first, and then traverse the left branch of the triangle after traversing to the bottom;
[0090] Please refer to the pattern diagram marked with S in Figure 8. The S pattern indicates that v has been traversed and should first traverse the right branch, and then traverse the left branch after traversing to the end.
[0091] 5) For the current triangle traversed, if the vertex corresponding to the c corner of the triangle has been traversed, and the left and right triangles of the triangle have been traversed, it is determined that the CLERS mode to which the triangle belongs is E mode, there is no traversal direction for the next triangle, and the traversal ends.
[0092] Please refer to the pattern diagram marked with E in Figure 8. Pattern E indicates that v has been traversed and the traversal is completed.
[0093] Of course, for other modes other than the CLERS mode, the method of determining the traversal result of the triangle can be implemented in a similar way to the above process based on the traversal of the corresponding vertices of the triangle and the traversal of the triangles on both sides, and no examples are given here.
[0094] Step A2, using the relevant information of the traversed triangle as context information, entropy encoding the pattern of the triangle;
[0095] The relevant information includes at least one or more of vertex geometry information, encoded triangle mode, and the number of adjacent encoded triangles of a triangle vertex;
[0096] Step A2 corresponds to the part of “entropy encoding the triangle pattern according to relevant context information” in FIG. 6 .
[0097] In an optional implementation manner, step A2 may include step A21 and step A22:
[0098] Step A21: For each triangle pattern to be encoded, a context-based adaptive binary arithmetic coding method is used to binarize the triangle pattern to be encoded using a preset binarization method to obtain a corresponding binary character sequence;
[0099] The current triangle's pattern is strongly correlated with previously traversed triangles. This pattern can be entropy-encoded using Context-Based Adaptive Binary Arithmetic Coding (CABAC). This is achieved by using context information such as vertex geometry, the pattern of previously traversed triangles, and the number of adjacent coded triangles to obtain context information and calculate a context index. CABAC consists of three main stages: binarization, context modeling, and binary arithmetic coding.
[0100] The entropy coding framework of an embodiment of the present invention can be shown in Figure 9. The entropy coding framework first binarizes the triangle pattern, then uses the relevant information to calculate the context index, thereby determining the context model and completing the context modeling. Finally, the context model is used to implement entropy coding of the triangle pattern, and the context model also needs to be updated.
[0101] The following describes possible implementation methods of binarization and context modeling respectively.
[0102] Regarding the binarization processing, an embodiment of the present invention performs binarization processing on the triangular pattern to obtain a corresponding binary character sequence. The binarization methods used include but are not limited to truncated unary code, Golomb code and fixed-length code.
[0103] In the binarization process, the symbol with a greater probability of occurrence (i.e., the symbol corresponding to the pattern) has a shorter codeword after binarization. Table 1 shows a possible binarization code table using a truncated unary code as an example. The codewords in Table 1 represent the corresponding binary character sequences.
[0104] Table 1 CLERS pattern and binary code table of triangle
[0105] Step A22, obtain relevant information of the triangle to be encoded, use the obtained relevant information to calculate the context index corresponding to each binary character of the triangle to be encoded, and determine the corresponding context model based on the obtained context index, and use the obtained context model to perform binary arithmetic encoding on the binary character sequence of the triangle to be encoded, and update the context model.
[0106] For context index calculation, embodiments of the present invention utilize relevant information, such as vertex geometry, encoded triangle patterns, and the number of adjacent encoded triangles at a triangle vertex, as context information to calculate the context index. Two methods for calculating the context index are described below.
[0107] The first method is to calculate the context index based on the pattern of the previous triangle after the binarization of the pattern is completed. Let the codeword of the currently input binarized pattern be value, and the context index ctxIdx be initialized to 0. 1, 2, and 3 represent the respective bits of the pattern codeword, and different context models can be established for different bits, for example, ctx_bit1 (the context model used to encode the first bit), ctx_bit2 (the context model used to encode the second bit), ctx_bit03 (when the first bit is 0, the context model used to encode the third bit), and ctx_bit13 (when the first bit is 1, the context model used to encode the third bit). The context index ctxIdx of the current binary symbol can only consider the previous triangle pattern to calculate the current triangle context index, which is expressed as: ctxIdx = value (1);
[0108] The second method uses the previous triangle mode and the previous triangle entropy coding context index to calculate the current triangle context index, which is expressed as: ctxIdx=value+((ctxIdx&1)<<3)+((ctxIdx&4)<<2) (2);
[0109] After the calculation of the context index is completed, the corresponding context model is selected according to each binary character position to perform binary arithmetic coding on the binary character, and the corresponding context model is updated.
[0110] Step A3: If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to a set threshold corresponding to the preset pattern, and the additional information is encoded.
[0111] After determining the pattern of the traversed triangles, if the pattern meets the pre-set criteria, embodiments of the present invention further require special processing to obtain and encode additional information indicating the positional relationship of the triangles for transmission in the output bitstream, enabling the decoder to utilize this additional information for stitching and reconstruction. The encoding of the additional information can be implemented using any encoding method, without limitation herein.
[0112] The following describes different optional situations of step A3.
[0113] 1) Case 1
[0114] If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to the set threshold corresponding to the preset pattern, including:
[0115] Step B1: If the mode of the traversed triangle is the S mode in the CLERS mode, determine the number of vertex rotations from the preset corner vertex of the triangle to the current corner vertex to represent the position of the current corner vertex relative to the preset corner vertex;
[0116] For the Corner-Table data structure, the current corner vertex is the c corner vertex, and the preset corner vertex is the cp corner vertex.
[0117] The number of vertex rotations is recorded as follows: start the rotation from the vertex of angle cp, and continuously change the rotation vertex until the vertex position corresponding to angle c is found. In this process, the number of times the rotation vertex is changed is recorded.
[0118] In the embodiment of the present invention, the number of rotations may be used to characterize the position of the c-angle vertex relative to the cp-angle vertex.
[0119] Step B2: If the number of vertex rotations is less than the set threshold T1 of the triangle, the number of vertex rotations is used as S connection information;
[0120] In the embodiment of the present invention, a corresponding threshold T1 may be set for each triangle. Of course, all triangles may also use the same threshold T1, which is reasonable.
[0121] Step B3: if the number of vertex rotations is greater than or equal to the set threshold T1 of the triangle, obtain S-connectivity information based on the index value of the vertex-related information;
[0122] The index value of the vertex-related information includes the triangle traversal index of the current corner vertex of the triangle; the triangle traversal index of the current corner vertex of the triangle may be the triangle traversal index when the vertex corresponding to angle c is first traversed. The triangle traversal index refers to the number of the triangle when the vertex corresponding to angle c is first traversed according to the triangle traversal order of the encoded connection relationship. The index value of the vertex-related information can be used as S-connectivity information. Alternatively, the difference between the index value of the current vertex-related information and the index value of the previous vertex-related information can be used as S-connectivity information.
[0123] The S-connectivity information represents additional information of the S-mode triangle, and is used to indicate the actual position of the current corner vertex of the S-mode triangle in the three-dimensional mesh.
[0124] Because encoding and transmitting the actual information about the current corner vertex's position in the 3D mesh often requires a large amount of data, directly encoding and transmitting it increases transmission pressure. For triangles with an S-mode, embodiments of the present invention additionally encode information to indicate the actual position of the c-corner vertex in the 3D mesh. This information is referred to as S-connectivity information, including but not limited to the position of the c-corner vertex relative to the cp-corner vertex and the triangle traversal index of the c-corner vertex. Embodiments of the present invention can control the number of times vertex rotations are encoded. When the number of vertex rotations is less than the set threshold T1 corresponding to the triangle, the number of vertex rotations is directly encoded as S-connectivity information. When the number of vertex rotations is greater than or equal to the set threshold T1 corresponding to the triangle, the index value of vertex-related information, such as the triangle traversal index of the current corner vertex of the triangle, can be encoded as S-connectivity information. Encoding the number of vertex rotations only requires encoding and transmitting a small value, thereby reducing transmission pressure and improving transmission efficiency. Regardless of the type of S-connectivity information, the decoder can still use this S-connectivity information to effectively locate the position of the triangle's current corner vertex in the 3D mesh, thereby ensuring the accuracy of decoding and reconstruction. For triangles with an S-mode, S-connectivity information is also referred to as S-mode instant stitching information.
[0125] The S-connection information that needs to be encoded for the S-mode may be encoded using entropy coding. This may be encoded after encoding each S-mode, or independently. The embodiment of the present invention does not limit the entropy coding method for the above information. Possible encoding methods include, but are not limited to, differential coding, exponential Golomb coding, and context-based arithmetic coding.
[0126] For case 1, entropy coding is performed on the additional information, including:
[0127] The S-connectivity information is entropy-coded according to the number of vertex rotations.
[0128] If the number of vertex rotations is less than the set threshold T1 for the triangle, the number of vertex rotations is directly entropy-encoded as S-connectivity information. If the number of vertex rotations is greater than or equal to the set threshold T1 for the triangle, the S-connectivity information is obtained based on the index value of the vertex-related information and entropy-encoded. When encoding the S-connectivity information, the set threshold T1 must also be encoded so that the decoder can use the decoded set threshold T1 to restore the S-connectivity information and perform triangle stitching.
[0129] For the S mode, the index value of the vertex related information takes the triangle traversal index of the c-corner vertex as an example. The following is an example of the syntax of the S connection information after each S mode:
[0130] Where mesh_coded_clers_symbols_size represents the number of triangle patterns; vu(v) represents unsigned integer encoding; mesh_clers_symbol[i] represents the pattern of the i-th triangle; ae(v) represents context-based arithmetic coding; S represents the S mode; length_alignment represents byte alignment; and mesh_rotation_frequency represents S connection information. When mesh_rotation_frequency is less than T1, it represents the number of rotations. When mesh_rotation_frequency is equal to T1, S connection information is obtained from mesh_vertexS_traversal_index. T1 is the set threshold T1; mesh_rotation_frequency can use an entropy coding scheme such as exponential Golomb coding.
[0131] mesh_vertexS_traversal_index, which can represent the index value of the vertex-related information (the triangle traversal index of the c-corner vertex). This value can also represent the difference between the index value of the vertex-related information (the triangle traversal index of the c-corner vertex) and the index value of the previous vertex-related information. mesh_vertexS_traversal_index can use an entropy encoding scheme such as exponential Golomb coding.
[0132] For S mode, the syntax example when S connection information is independently encoded is:
[0133] mesh_rotation_frequency_count represents the number of S-connectivity information. mesh_coded_rotation_frequency_size represents the byte size of the arithmetic coding sequence of the S-connectivity information. mesh_rotation_frequency[i] represents the S-connectivity information. When mesh_rotation_frequency[i] is less than T1, it represents the number of vertex rotations. When mesh_rotation_frequency[i] is equal to T1, the S-connectivity information is obtained from mesh_vertexS_traversal_index[i].
[0134] mesh_vertexS_traversal_index[i], which can represent the index value of the i-th vertex related information (the triangle traversal index of the c-corner vertex). This value can also represent the difference between the index value of the i-th vertex related information (the triangle traversal index of the c-corner vertex) and the index value of the i-1-th vertex related information. When i is 0, mesh_vertexS_traversal_index[0] specifies the index value of the first vertex related information.
[0135] The above syntax information can all be encoded using an entropy coding scheme such as exponential Golomb coding.
[0136] Referring to the schematic diagram of recording the number of vertex rotations shown in FIG10 (the figure is a grayscale figure), the process of steps B1 to B3 may include the following steps:
[0137] Step a1: record the vertex corresponding to the triangle angle c as the target vertex v', v'=cv; let v t = cpv, b = c, number of rotations l = 0;
[0138] Among them, v', v t , b and l are parameters set in the embodiment of the present invention; cv and c can be understood by referring to the Corner-Table data structure, and those skilled in the art can understand from the data structure that cpv represents the vertex corresponding to the cp angle.
[0139] Step a2, let b = bop, if the vertical angle of b has been traversed, continue around v t Rotate and repeat step a2; if the vertical angle of b is not traversed, let v t =bnv, b=bp, l=l+1, go to step a3;
[0140] Similarly, according to the Corner-Table data structure, bop represents the previous corner of b (the previous corner here refers to the first corner of bo in the clockwise direction), bnv represents the vertex corresponding to the next corner of b (the next corner here refers to the first corner of b in the counterclockwise direction), and bp represents the previous corner of b (the previous corner here refers to the first corner of b in the clockwise direction). l = l + 1 means that the current l is incremented by 1 to obtain the updated l.
[0141] Step a3: Determine whether the number of rotations l is greater than or equal to the set threshold T1. If so, end the search process and encode an identifier and v' related information. The encoded identifier can be the encoded vertex rotation number value T1, and the v' related information can be the triangle traversal index of the c-angle vertex. If not, go to step 4.
[0142] Step a4, determine v t Is it equal to v'? If so, determine that the current l is the number of vertex rotations and end the rotation search process; encode the number of rotations l and T1; if not, return to step a2 and continue around vertex v t Perform a rotation search.
[0143] 2) Case 2
[0144] If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to the set threshold corresponding to the preset pattern, including:
[0145] Step C1: If the mode of the traversed triangle is E, R, or L mode in the CLERS mode, and the rotation vertex of the triangle is connected to two or more triangles in the S mode during the reconstruction operation, the relative traversal sequence number of the triangle corresponding to the fan-shaped area to which the triangle needs to be stitched is determined based on the traversal order of the triangles;
[0146] In which, the fan-shaped area is composed of one triangle or two or more adjacent triangles; the mode of the traversed triangle is the E, R or L mode in the CLERS mode, and when the reconstruction operation is performed, the rotation vertex of the triangle is connected to two or more S-mode triangles, which can be regarded as an E, R or L mode that meets the conditions.
[0147] For triangles that meet the E, R or L mode, as shown in Figure 11 (the figure is a grayscale image), if the rotation vertex is connected to two or more S-mode triangles, additional additional information needs to be encoded to indicate which traversed triangle the current triangle needs to be stitched to (hereinafter referred to as the traversed triangle as the "actually connected triangle", and the additional information that needs to be encoded is the "stitching angle information"), including but not limited to the traversal index of the actually connected triangle (hereinafter referred to as the traversal index of the triangle), and the relative traversal sequence number of the actually connected triangle (hereinafter referred to as the triangle relative traversal sequence number). Among them, each triangle is pre-set with a number representing the index, the traversal index of the triangle represents the number of the traversed triangle; the relative traversal sequence number of the triangle represents the traversed sector area where the triangle is located, and its traversal order corresponds to the number.
[0148] As shown in Figure 11, the traversal order is C1->C2->…->S1->C3->…->S2->E, where C1 is the first triangle traversed in Figure 11 and its relative traversal order number is 1. In this embodiment of the present invention, traversing from one branch of S to another is called a handle. For patterns E, R, and L, the encoder needs to detect whether they are handles. Since handle information is encoded if they are handles, there is no need to additionally determine whether the rotation vertex is connected to two or more triangles in the S pattern.
[0149] As shown in the handle diagram in Figure 12 (the original image of Figure 12 is in color, and this is a grayscale image), starting from the gray triangle (the gray triangle is the triangle at the top of the second row and third column), traverse along the direction of the black arrow. During the traversal process, traverse from the right branch of the red S triangle to the red E triangle on the left branch (the triangles marked with S and E in the fourth row and third column respectively). Therefore, for the red E triangle, the right branch is the handle, so the handle information is encoded, such as the traversal index of the red angle in the figure.
[0150] For a triangle in the E, R, or L mode that meets the conditions, the process of determining the relative traversal sequence number of the triangle corresponding to the fan-shaped area to which the triangle needs to be stitched may include:
[0151] ① If the current triangle mode is L and the left branch is a handle, record the handle information. Otherwise, determine whether the rotation vertex is connected to two or more triangles of mode S. If it is connected to two or more 3D triangles of mode S, determine the triangle's relative traversal order.
[0152] ② If the current triangle mode is R and the right branch is a handle, record the handle information. Otherwise, determine whether the rotation vertex is connected to two or more triangles of mode S. If so, determine the triangle's relative traversal order.
[0153] ③ When the current triangle mode is E, first check whether the right branch is a handle. If so, record the handle information. Otherwise, determine whether the rotation vertex is connected to two or more triangles of mode S. If so, determine the triangle's relative traversal sequence number. Then check whether the left branch is a handle. If so, record the handle information. Otherwise, determine whether the rotation vertex is connected to two or more triangles of mode S. If so, determine the triangle's relative traversal sequence number.
[0154] Step C2: If the triangle relative traversal sequence number is less than the set threshold T2 of the triangle, the triangle relative traversal sequence number is used as stitching angle information;
[0155] Step C3: If the relative traversal sequence number of the triangle is greater than or equal to the set threshold T2 of the triangle, determine the traversal index of the triangle corresponding to the triangle connected to the triangle according to the traversal order of the triangle, and obtain the stitching angle information based on the traversal index of the triangle;
[0156] In the embodiment of the present invention, a corresponding threshold T2 may be set for each triangle. Of course, all triangles may also use the same threshold T2, which is reasonable.
[0157] The embodiment of the present invention can control the size of the relative traversal sequence number of the encoded triangle. When the relative traversal sequence number of the triangle is less than the set threshold T2, the relative traversal sequence number of the triangle is directly encoded as the stitching angle information; when the relative traversal sequence number of the triangle is greater than or equal to the set threshold T2, the traversal index of the triangle corresponding to the triangle connected to the triangle can be determined according to the traversal order of the triangle, and the traversal index of the triangle is encoded as the stitching angle information.
[0158] The stitching angle information represents additional information, and is used to indicate a traversed triangle to which the triangle is connected in the three-dimensional mesh.
[0159] Similarly, embodiments of the present invention utilize a threshold T2 to determine the relative traversal order number of the encoded triangle or the traversal index of the triangle, thereby reducing transmission pressure and improving transmission efficiency. This ensures that the decoder can still effectively locate the position of the triangle's current corner vertex in the 3D mesh using the stitching angle information, thereby ensuring decoding and reconstruction accuracy. For triangles in E, R, or L modes that meet the aforementioned conditions, the stitching angle information is also referred to as the corresponding real-time stitching information.
[0160] Accordingly, for case 2, entropy coding is performed on the additional information, including:
[0161] The stitching angle information is entropy encoded according to the triangle relative traversal order number.
[0162] If the triangle's relative traversal sequence number is less than the set threshold T2 for that triangle, the triangle's relative traversal sequence number is directly entropy-encoded as the stitching angle information. If the triangle's relative traversal sequence number is greater than or equal to the set threshold T2 for that triangle, the traversal index of the triangle closest to the triangle is determined based on the triangle's traversal order. The stitching angle information is then entropy-encoded based on the triangle's traversal index. The obtained stitching angle information is then entropy-encoded. When encoding the stitching angle information, the set threshold T2 must also be encoded so that the decoder can use the decoded set threshold T2 to recover the stitching angle information for triangle stitching.
[0163] Among them, the stitching angle information that needs to be encoded in the above-mentioned E, R or L mode that meets the conditions can specifically be encoded using an entropy coding method; the embodiment of the present invention does not limit the entropy coding method of the above-mentioned information, and the coding methods that can be used include but are not limited to difference coding, exponential Golomb coding, and context-based arithmetic coding.
[0164] For the E, R, and L modes that meet the above conditions, the syntax example for encoding stitching angle information is as follows:
[0165] Among them, mesh_orderS_count represents the number of stitching angle information recorded when the rotation vertex is connected to two or more triangles of pattern S during the stitching process.
[0166] mesh_orderS_num[i] represents the stitching angle information. This value can represent the value of the i-th stitching angle information. This value can also represent the difference between the i-th stitching angle information and the i-1-th stitching angle information. When i is 0, mesh_orderS_num[0] specifies the value of the first stitching angle information.
[0167] For the E, R, and L modes that meet the above conditions, when the stitching angle information contains multiple types (such as the traversal index of the triangle and the relative traversal sequence number of the triangle), the syntax example for encoding the stitching angle information is as follows:
[0168] Among them, mesh_orderS_count represents the number of stitching angle information recorded when the rotation vertex is connected to two or more triangles of pattern S during the stitching process.
[0169] mesh_orderS_num[i] represents the stitching angle information. When mesh_orderS_num[i] is less than T2, it represents the relative traversal order of the triangle. When mesh_orderS_num[i] is equal to T2, the stitching angle information is obtained from mesh_triangle_traversal_index[i]. T2 is the set threshold T2.
[0170] mesh_triangle_traversal_index[i]: This value can represent the value of the i-th stitching angle information. This value can also represent the difference between the i-th stitching angle information and the i-1-th stitching angle information. When i is 0, mesh_triangle_traversal_index[0] specifies the value of the first sector area number.
[0171] The above syntax information can all be encoded using an entropy coding scheme such as exponential Golomb coding.
[0172] As mentioned above, the thresholds T1 and T2 can be fixed values agreed upon by the codec or variable values, and are encoded in the bitstream, specifically in the header information of the 3D grid bitstream. The syntax examples of the thresholds T1 and T2 are as follows:
[0173] Wherein, u(4) represents an unsigned integer code. The thresholds T1 and T2 are set and encoded as threshold setting information.
[0174] The above is the main content of the connection relationship encoding. After the connection relationship encoding, a connection information code stream is obtained; the connection information code stream includes the pattern information of the encoded triangle, S connection information, stitching angle information and set threshold information; wherein, the set threshold information includes the set threshold T1 and set threshold T2 of the encoded triangle; the connection information code stream can also include handle information.
[0175] The following briefly describes the process of geometric information encoding, taking a separate encoding frame as an example.
[0176] In an optional implementation, geometric information encoding is performed on triangles in a three-dimensional mesh according to a connection relationship encoding order, and a geometric information code stream is obtained from the geometric information encoding results of all triangles, including:
[0177] (1) Based on the connection relationship coding order, the geometric information of each triangle in the three-dimensional grid is predicted using the parallelogram prediction method to obtain the geometric coordinate residual;
[0178] Among them, the prediction methods include single parallelogram prediction, multi-parallelogram prediction and weighted parallelogram prediction.
[0179] (2) Perform entropy coding on the predicted geometric coordinate residuals to obtain a geometric information code stream.
[0180] Among them, the entropy coding method can be selected as needed. For the specific process, please refer to the relevant technical understanding.
[0181] Those skilled in the art will appreciate that the hybrid coding framework is similar to the geometric coordinate prediction process and entropy coding described above, and will not be described in detail here. Furthermore, the geometric information coding process of the embodiment of the present invention is not limited to the above example.
[0182] It is understandable that the geometric information code stream includes starting coordinate information and geometric prediction residuals. The output code stream includes a connection information code stream and a geometric information code stream.
[0183] A 3D mesh encoding method proposed in an embodiment of the present invention includes encoding the pattern of triangles in a 3D mesh for connection relationship encoding. For preset patterns that meet certain conditions, the connection relationship encoding further includes determining and encoding additional information indicating the triangle positional relationships as instant stitching information based on a set threshold corresponding to the preset pattern. The geometric information encoding supports parallel encoding with the connection relationship encoding. The encoding end encodes and transmits the additional information indicating the triangle positional relationships, enabling the decoding end to utilize the triangle positional relationships during stitching to ensure accurate and immediate stitching.
[0184] In an embodiment of the present invention, if the traversed triangle mode is the S mode in the CLERS mode, additional information is determined based on the number of vertex rotations. If the number of vertex rotations is less than a set threshold T1 for the current triangle, the number of vertex rotations is encoded as S-connectivity information. If the number of vertex rotations is greater than or equal to the set threshold T1 for the current triangle, the S-connectivity information is obtained and encoded based on the index value of vertex-related information, such as the triangle traversal index of the current corner vertex of the triangle. The set threshold T1 is used to determine which S-connectivity information to encode and transmit, thereby reducing transmission pressure, improving transmission efficiency, and ensuring the accuracy of decoding and reconstruction.
[0185] In an embodiment of the present invention, if the traversed triangle's mode satisfies the E, R, or L mode, i.e., if it belongs to the E, R, or L mode and its rotation vertex is connected to two or more triangles in the S mode during reconstruction, additional information is determined based on the triangle's relative traversal sequence number. If the triangle's relative traversal sequence number is less than a set threshold T2 for the current triangle, the triangle's relative traversal sequence number is encoded as stitching angle information. If the triangle's relative traversal sequence number is greater than or equal to the set threshold T2 for the current triangle, the traversal index of the triangle corresponding to the triangle most closely connected to the current triangle is determined based on the triangle's traversal order. Based on the triangle's traversal index, the stitching angle information is obtained and encoded. The set threshold T2 is used to determine which stitching angle information to encode and transmit, thereby reducing transmission pressure, improving transmission efficiency, and ensuring accuracy in decoding and reconstruction.
[0186] In a second aspect, corresponding to the three-dimensional grid encoding method provided in the first aspect, an embodiment of the present invention further provides a three-dimensional grid encoding device, applied to an encoding end, the device comprising:
[0187] The encoding module is used to encode the connection relationship and geometric information of the input 3D mesh to obtain an output code stream;
[0188] Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional grid; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of the triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
[0189] Among them, the specific processing process of the above modules can be found in the three-dimensional grid coding method described in the first aspect, which will not be repeated here.
[0190] In a third aspect, corresponding to the three-dimensional grid encoding method provided in the first aspect, an embodiment of the present invention further provides a three-dimensional grid decoding method, which is applied to a decoding end. As shown in FIG13 , the decoding method includes:
[0191] Sdecode1 decodes the connection relationship and geometric information of the input code stream to obtain the connection relationship and geometric information respectively;
[0192] Sdecode2, reconstructs the 3D mesh based on the obtained connectivity and geometric information;
[0193] Among them, the connection relationship decoding includes decoding the pattern of triangles in the three-dimensional grid; for the preset pattern that meets the conditions, the connection relationship decoding also includes decoding additional information used to indicate the position relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding.
[0194] Compared with the three-dimensional mesh encoding method provided in the first aspect of the embodiment of the present invention, which can be applied to a separate encoding framework and a hybrid encoding framework, the three-dimensional mesh decoding method provided in the third aspect of the embodiment of the present invention can also be applied to a separate decoding framework and a hybrid decoding framework. That is to say, after entropy decoding of the input code stream, there are two possible implementation methods for parsing the connection relationship and geometric information and reconstructing the mesh. The first method is to realize the decoding and reconstruction of the connection relationship and geometric information in one traversal process. The pattern of decoding a triangle is reconstructed onto the decoded triangle, a mesh is constructed, and then the geometric information of the triangle is decoded to obtain a partially reconstructed mesh. The second method is to decode the connection relationship and geometric information in parallel. After decoding a part of the connection relationship, the corresponding geometric information can be decoded in parallel to obtain a partially reconstructed mesh.
[0195] Specifically, for a separate decoding framework, the input code stream is decoded for connection information and geometric information to obtain connection relationships and geometric information respectively; and a three-dimensional mesh is reconstructed based on the obtained connection relationships and geometric information, including:
[0196] (1) De-streaming the input code stream to obtain a connection information code stream and a geometric information code stream; wherein the connection relationship code stream and the geometric information code stream are based on triangles;
[0197] (2) decoding the connection relationship of the connection information code stream to obtain the connection relationship;
[0198] (3) Decoding the geometric information code stream to obtain geometric information;
[0199] The geometric information decoding may be performed according to the decoding order of the connection relationship.
[0200] (4) Reconstruct the 3D mesh using connection relationships and geometric information.
[0201] Please refer to Figure 14 for the main processing flow of the three-dimensional mesh decoding framework for separate decoding of connection relationships and geometric information in the embodiment of the present invention. In this separate decoding framework, both connection relationship decoding and geometric information decoding are achieved by traversing triangles, but there is no restriction on whether the triangle traversal order is the same. Taking the same triangle traversal order as an example, this method is reflected in the need to utilize the connection relationship decoding order for geometric information decoding, and the connection relationship decoding order reflects the triangle traversal order in the connection relationship decoding process. In other words, the connection relationship output after the connection relationship decoding is obtained after traversing all triangles to complete the connection relationship decoding, and the geometric information is also obtained after traversing all triangles in the same order to complete the geometric information decoding. Of course, the same triangle traversal order is only used as a possible example. For the case where the triangle traversal order is different, the processing process of the embodiment of the present invention will not be described in detail here. The connection relationship decoding method in the above steps corresponds to the encoding idea in the previous text. For the sake of clarity, it is described in detail later.
[0202] Specifically, for the hybrid decoding framework, the input code stream is decoded for connection information and geometric information to obtain connection relationship and geometric information respectively; and a 3D mesh is reconstructed based on the obtained connection relationship and geometric information, including:
[0203] (1) The input code stream is traversed in triangle order, and the connection relationship and geometric information of each traversed triangle are decoded to obtain the connection relationship and geometric information of the triangle;
[0204] (2) Reconstruct the three-dimensional mesh of the triangle using the connection relationship and geometric information of the triangle.
[0205] See Figure 15 for the main processing flow of a 3D mesh decoding framework for separate connectivity and geometric information decoding, as applied in an embodiment of the present invention. In this hybrid decoding framework, the input bitstream undergoes triangle traversal, and each traversed triangle undergoes both connectivity decoding and geometric information decoding before 3D mesh reconstruction. This means that each triangle is traversed, decoding its pattern and the geometric coordinates of its undecoded vertices. Therefore, the triangle traversal order for geometric information decoding and connectivity decoding is consistent, until all triangles are traversed to obtain the final reconstructed 3D mesh.
[0206] Similarly, the connection relationship decoding method in the above steps also corresponds to the encoding idea in the previous article.
[0207] An embodiment of the present invention decodes the connection relationship and uses the decoded three-dimensional mesh information to decode the geometric information, that is, uses the geometric information of the triangles traversed by the connection relationship decoding to decode, so as to realize parallel decoding of the connection relationship and the geometric information. The connection information code stream includes mode information, handle information, S connection information, stitching angle information and set threshold information, etc. The geometric information code stream includes starting coordinate information, geometric prediction residual, etc.
[0208] The process of reconstructing the grid at the decoding end is the process of reconstructing the network data structure (such as Corner-Table, half-edge, etc.) at the encoding end. The following uses Corner-Table as an example to introduce the connection relationship reconstruction process.
[0209] The decoding end can first decode the pattern triangle based on certain context information, that is, relevant information about the triangle, such as one or more of the vertex geometry information, the encoded triangle pattern, and the number of encoded triangles adjacent to the triangle vertices, but it must be consistent with the encoding end. Then, the current triangle is connected to the reconstructed three-dimensional mesh using different stitching methods according to its pattern, and then the position of the next triangle is determined, and the pattern of the next triangle is decoded through the context information. This is executed continuously until all triangles are decoded and reconstructed to obtain a reconstructed three-dimensional mesh.
[0210] In an optional implementation manner, the process of decoding the connection relationship of the input code stream includes the following steps:
[0211] Step D1, decoding the input code stream to obtain the current triangle mode;
[0212] The decoding process at the decoder corresponds to the encoding process at the encoder. As can be understood from the previous section, if entropy encoding is used, then decoding is done using entropy decoding. The CLERS mode can be used, which is not described in detail here.
[0213] Step D2: when the current triangle mode is a preset mode that meets the conditions, the input code stream is decoded using the set threshold information to obtain additional information indicating the positional relationship of the triangles;
[0214] Corresponding to Case 1 at the encoding end, step D2 may include:
[0215] When the mode of the current triangle is the S mode in the CLERS mode, the input code stream is decoded using the set threshold T1 to determine that the additional information represented by the S connection information is the number of vertex rotations or the triangle traversal index of the vertex corresponding to the current angle.
[0216] The decoding method includes: decoding the input code stream to obtain a value of a set threshold T1 corresponding to the current triangle of the S mode; it can be understood that, in an embodiment of the present invention, the input code stream is first decoded to obtain the set threshold T1 corresponding to the current triangle of the S mode, and then the input code stream is decoded using the set threshold T1 to determine the specific content of the S connection information.
[0217] For this purpose, please refer to the syntax example for encoding S-connectivity information on the encoder side above. By comparing the value of the threshold T1 with the value of the specific parameter in the syntax example, it is determined whether the S-connectivity information is the number of vertex rotations or the triangle traversal index of the vertex corresponding to the current angle, as well as the specific value of the S-connectivity information. The details will not be repeated here.
[0218] Corresponding to Case 2 at the encoding end, step D2 may include:
[0219] When the mode of the current triangle is E, R or L mode in the CLERS mode, and the rotation vertex of the triangle is connected to two or more triangles in the S mode, the input code stream is decoded using the set threshold T2 to determine that the additional information represented by the stitching angle information is the relative traversal sequence number of the triangle or the traversal index of the triangle.
[0220] The decoding method includes: decoding the input code stream to obtain a value of a set threshold T2 corresponding to the current triangle in the E, R, or L mode. It is understood that in the embodiment of the present invention, the input code stream is first decoded to obtain the set threshold T2 corresponding to the current triangle in the E, R, or L mode, and then the input code stream is decoded using the set threshold T2 to determine the specific content of the stitching angle information.
[0221] For example, the encoding end can refer to the syntax example for encoding stitching angle information in the previous section. The threshold T2 is compared with the value of a specific parameter in the syntax example to determine whether the stitching angle information is the triangle relative traversal sequence number or the triangle traversal index, and the specific value of the stitching angle information is used. The details are not repeated here.
[0222] Step D3: Connecting the current triangle to the reconstructed three-dimensional mesh based on the preset mode and a stitching method determined by the additional information obtained according to the preset mode;
[0223] In the embodiment of the present invention, the suturing methods of various preset modes that meet the conditions are pre-designed.
[0224] Since the triangle's connectivity can be reconstructed by determining the diagonal relationship of each corner and the relationship between the corner's corresponding vertices, reconstructing the connectivity relationship essentially involves rebuilding the O and V tables in the Corner-Table. During triangle reconstruction, the diagonal relationships of some corners are updated based on the current triangle pattern. The connectivity decoding method proposed in this embodiment of the present invention can update the diagonal relationships of all corners after decoding the triangle pattern, allowing the corresponding edges of the triangle to be stitched onto the reconstructed mesh.
[0225] The following are stitching methods for different modes on the decoder side, using the Corner-Table data structure and the CLERS mode as an example.
[0226] (1) Suturing method corresponding to L mode
[0227] When the CPV does not connect S-pattern triangles or connects one S-pattern triangle, as shown in Figure 16, the triangle to be stitched can be directly obtained by rotating around the CPV. When the CPV connects multiple S-pattern triangles, as shown in Figure 17 (grayscale image), the real-time stitching information (such as the triangle relative traversal order number) is obtained from the bitstream and stitching is performed. A possible implementation method is shown in the following steps:
[0228] Step b1: Determine whether the left branch of the current triangle angle c is a handle. If so, update the diagonal information of angle c to the decoded diagonal information, update cnv, and end stitching; otherwise, jump to step b2;
[0229] The method for determining whether the left branch of the current triangle's corner c is a handle is discussed in the related technical literature and will not be explained here. If it is a handle, since the handle cannot be stitched to find the opposite corner, the encoder must transmit the opposite corner information. Updating cnv means cnv = copv. At this point, ending stitching means ending the stitching of this triangle and then proceeding to the next triangle.
[0230] Step b2, determine whether the CPV is connected to multiple S-mode triangles, if so, jump to step b6, otherwise jump to step b3;
[0231] Step b3, initialize angle b, set b = cn, as shown in the first figure in Figure 16;
[0232] Step b4: Determine whether bo is greater than 0. If so, set b = bon, as shown in the second figure in Figure 16, and repeat step b4. If bo is less than or equal to 0, as shown in the third figure in Figure 16, jump to step b5.
[0233] Step b5, set bo = c, co = b, bpv = cnv, as shown in the fourth figure in Figure 16, and end the suture;
[0234] In step b6, the instant stitching information is obtained from the bitstream, such as the triangle's relative traversal sequence number and triangle's traversal index, to obtain the t angle of the fan-shaped area. Let b = tp, as shown in Figure 17, and jump to step b5. The t angle of the fan-shaped area is the angle connecting the fan-shaped area and its rotation vertex.
[0235] To understand the L-pattern stitching process, refer to Figure 16 for a schematic diagram of the stitching process for pattern L and Figure 17 for a schematic diagram of a rotated vertex of the L-pattern adjacent to two S-pattern triangles. For the symbols used for the corners and vertices in each stitching process, refer to the Corner-Table and the encoding method described above.
[0236] (2) Suturing method corresponding to E mode
[0237] The following steps may be included:
[0238] Step c1: determine whether the right branch of the current triangle angle c is a handle. If so, update the diagonal information of angle c to the decoded diagonal information and update cvp; where updating cvp means cpv = conv;
[0239] Step c2: determine whether the left branch of angle c is a handle. If so, update cnv and end stitching; otherwise, jump to step c3;
[0240] Step c3, determine whether the cpv is connected to multiple S-mode triangles, if yes, jump to step c8, otherwise jump to step c4;
[0241] Step c4, initialize angle b, set b = cn;
[0242] Step c5, determine whether bo is greater than 0. If so, set b = bon and repeat step c5; if bo is less than or equal to 0, jump to step c6;
[0243] Step c6, let bo = c, co = b, bpv = cnv;
[0244] Step c7, let c = cp, if co is not equal to -2, jump to step c4, otherwise end suturing;
[0245] In step c8, the instant stitching information is obtained from the bitstream, such as the relative traversal sequence number and the traversal index of the triangle, to obtain the t angle of the fan-shaped area. Set b = tp and jump to step c6. The t angle of the fan-shaped area is the angle connecting the fan-shaped area and its rotation vertex.
[0246] Except for handle detection, the stitching methods of L-mode and E-mode are basically the same, which can be used as a reference for understanding.
[0247] (3) Suturing method corresponding to R mode
[0248] The suturing method for pattern R is similar to that for pattern L, but with the rotation direction reversed. As shown in Figure 18, it can include the following steps:
[0249] Step d1: determine whether the right branch of the current triangle c corner is a handle. If so, update the diagonal information of the c corner to the decoded diagonal information, update the CPV, and end the stitching; otherwise, jump to step d2;
[0250] Step d2, determine whether cnv is connected to multiple S-mode triangles, if so, jump to step d5, otherwise jump to step d3;
[0251] Step d3, initialize angle b, set b = cp, as shown in the first figure of Figure 18;
[0252] Step d4, determine whether bo is greater than 0. If so, set b = bop, as shown in the second figure of Figure 18, and repeat step d4; if bo is less than or equal to 0, as shown in the third figure of Figure 18, jump to step d5;
[0253] Step d5, set bo = c, co = b, bnv = cpv, as shown in the fourth figure of Figure 18, and end the suturing;
[0254] In step d6, stitching information is obtained from the bitstream, such as the relative traversal sequence number and the traversal index of the triangle, to obtain the t angle of the fan-shaped area. Set b = tn and jump to step d5. The t angle of the fan-shaped area is the angle connecting the fan-shaped area and its rotation vertex.
[0255] Please refer to the schematic diagram of the suturing process of mode R shown in Figure 18 to understand the suturing process of mode R.
[0256] (IV) Suturing method corresponding to S mode
[0257] For pattern S, the decoder must connect the opposite vertices of the incident edge to the mesh. S connectivity information, such as the rotation count and vertex index, is obtained from the bitstream. When the S connectivity information contains the rotation count, the same method as the encoder is used to find the vertex and update the V table, as shown in Figure 10. When the S connectivity information contains the vertex index, the V table is updated directly.
[0258] It can be understood that after executing step D3, the connection relationship decoding of the current triangle is completed, and then the position of the next triangle is determined, and the relevant information required for decoding the next triangle is obtained, and the obtained relevant information is used to return to step D1 to decode the next triangle.
[0259] The relevant information at least includes:
[0260] One or more of vertex geometry information, encoded triangle mode, and the number of adjacent encoded triangles of a triangle vertex.
[0261] The above is the process of decoding the connection relationship at the decoding end.
[0262] For geometric information decoding, taking a separate decoding framework as an example, the geometric information code stream can be decoded according to the connection relationship decoding order to obtain geometric information, including:
[0263] 1) Perform entropy decoding on the geometric information bitstream to obtain the prediction residual;
[0264] 2) Using the geometric coordinate prediction method corresponding to the encoding end to obtain the predicted geometric coordinates;
[0265] 3) The reconstructed geometric coordinates are obtained based on the sum of the predicted geometric coordinates and the prediction residuals.
[0266] Those skilled in the art will appreciate that the above decoding process corresponds to the processing process on the encoding side, and the prediction method of the geometric coordinates is consistent with that on the encoding side, which will not be described in detail here. The geometric information decoding process in the hybrid decoding framework can be similar to the above process and will not be described in detail here.
[0267] A three-dimensional mesh decoding method proposed in an embodiment of the present invention performs connection relationship decoding and geometric information decoding on an input bitstream to obtain connection relationship and geometric information, respectively; and reconstructs a three-dimensional mesh based on the obtained connection relationship and geometric information; wherein, connection relationship decoding includes decoding the pattern of triangles in the three-dimensional mesh. For preset patterns that meet the conditions, the connection relationship decoding also includes decoding the set threshold information corresponding to the preset pattern and additional information used to indicate the positional relationship of the triangles, so as to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding. The connection relationship decoding utilizes relevant information about the triangles and a decoding method corresponding to the encoding end to decode the corresponding portion of the input bitstream to obtain the pattern of the triangles. Based on the decoded triangle pattern and possible additional information, a mesh data structure is constructed to achieve three-dimensional mesh reconstruction. Therefore, context information consistent with the encoding end can be obtained for accurate decoding and mesh reconstruction.
[0268] In an embodiment of the present invention, when the mode of the current triangle is the S mode in the CLERS mode, the input code stream is entropy decoded to obtain the value of the set threshold T1 corresponding to the current triangle of the S mode; using the value of the set threshold T1, the input code stream is entropy decoded to determine whether the additional information represented by the S connection information is the number of vertex rotations or the triangle traversal index of the vertex corresponding to the current angle, which can ensure the accuracy of decoding and reconstruction.
[0269] In an embodiment of the present invention, when the mode of the current triangle is the E, R, or L mode in the CLERS mode, and the rotation vertex of the triangle is connected to two or more triangles in the S mode, the input bitstream is entropy decoded to obtain the value of the set threshold T2 corresponding to the triangle; using the value of the set threshold T2, the input bitstream is entropy decoded to determine whether the additional information represented by the stitching angle information is the relative traversal sequence number of the triangle or the traversal index of the triangle, thereby ensuring the accuracy of decoding and reconstruction.
[0270] In a fourth aspect, corresponding to the three-dimensional grid decoding method provided in the third aspect, an embodiment of the present invention further provides a three-dimensional grid decoding device, applied to a decoding end, the device comprising:
[0271] The decoding module is used to decode the connection relationship and geometric information of the input code stream to obtain the connection relationship and geometric information respectively;
[0272] A reconstruction module, used to reconstruct a three-dimensional mesh based on the obtained connection relationship and geometric information;
[0273] Among them, the connection relationship decoding includes decoding the pattern of triangles in the three-dimensional grid; for the preset pattern that meets the conditions, the connection relationship decoding also includes decoding additional information used to indicate the position relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding.
[0274] For the specific processing procedures of the above modules, please refer to the three-dimensional grid decoding method described in the third aspect, which will not be described in detail here.
[0275] The above are only preferred embodiments of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention are included in the scope of protection of the present invention.
Claims
1. A three-dimensional grid coding method, characterized in that: include: Encode the connection relationship and geometric information of the input three-dimensional grid to obtain an output code stream; Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional mesh; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
2. The three-dimensional grid coding method according to claim 1, characterized in that: The process of encoding the connection relationship of the input 3D mesh includes: Selecting an initial triangle in the three-dimensional mesh to start traversal, and for each traversed triangle, determining a traversal result of the triangle according to the traversed triangles; wherein the traversal result of the triangle includes a mode of the triangle; Using relevant information of the traversed triangle as context information, entropy encoding the pattern of the triangle; wherein the relevant information includes at least one or more of vertex geometry information, the encoded triangle pattern, and the number of adjacent encoded triangles of the triangle vertex; If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to a set threshold corresponding to the preset pattern, and the additional information is encoded.
3. The three-dimensional grid coding method according to claim 2, characterized in that: If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to a set threshold corresponding to the preset pattern, including: If the mode of the traversed triangle is the S mode in the CLERS mode, determine the number of vertex rotations from the preset corner vertex of the triangle to the current corner vertex to represent the position of the current corner vertex relative to the preset corner vertex; If the number of vertex rotations is less than the set threshold T1 of the triangle, the number of vertex rotations is used as S connection information; If the number of rotations of the vertex is greater than or equal to the set threshold T1 of the triangle, S connection information is obtained based on the index value of the vertex related information; wherein the index value of the vertex related information includes the triangle traversal index of the current corner vertex of the triangle; The S connection information represents additional information of the S-mode triangle, and is used to indicate the actual position of the current corner vertex of the S-mode triangle in the three-dimensional grid.
4. The three-dimensional grid coding method according to claim 3, characterized in that: Encoding the additional information includes: The S-connectivity information is entropy encoded according to the number of vertex rotations.
5. The three-dimensional grid coding method according to claim 3, characterized in that: If the traversed triangle pattern is a preset pattern that meets the conditions, corresponding additional information is determined according to a set threshold corresponding to the preset pattern, including: If the mode of the traversed triangle is the E, R or L mode in the CLERS mode, and the rotation vertex of the triangle is connected to more than two triangles of the S mode during the reconstruction operation, the relative traversal sequence number of the triangle corresponding to the fan-shaped area to which the triangle needs to be stitched is determined according to the traversal order of the triangle; wherein the fan-shaped area is composed of one triangle or more than two adjacent triangles; If the relative traversal sequence number of the triangle is less than the set threshold T2 of the triangle, the relative traversal sequence number of the triangle is used as stitching angle information; If the relative traversal sequence number of the triangle is greater than or equal to the set threshold T2 of the triangle, determine the traversal index of the triangle corresponding to the triangle connected to the triangle according to the traversal sequence of the triangle, and obtain the stitching angle information based on the traversal index of the triangle; The stitching angle information represents additional information, which is used to indicate a traversed triangle to which the triangle is connected in the three-dimensional mesh.
6. The three-dimensional grid coding method according to claim 5, characterized in that: Encoding the additional information includes: The stitching angle information is entropy encoded according to the relative traversal order number of the triangle.
7. The three-dimensional grid coding method according to claim 4 or 6, characterized in that: The output code stream includes a connection information code stream and a geometric information code stream; the connection information code stream includes mode information of the coded triangle, S connection information, stitching angle information and set threshold information; wherein the set threshold information includes set threshold T1 and set threshold T2 of the coded triangle; The geometric information code stream includes starting coordinate information and geometric prediction residuals.
8. A three-dimensional grid encoding device, characterized in that: include: The encoding module is used to encode the connection relationship and geometric information of the input three-dimensional grid to obtain an output code stream; Among them, the connection relationship encoding includes encoding the pattern of triangles in the three-dimensional mesh; for a preset pattern that meets the conditions, the connection relationship encoding also includes determining and encoding additional information used to indicate the position relationship of triangles based on a set threshold corresponding to the preset pattern; the geometric information encoding supports an encoding method parallel to the connection relationship encoding.
9. A three-dimensional grid decoding method, characterized in that: include: Decode the connection relationship and the geometric information of the input code stream to obtain the connection relationship and the geometric information respectively; Reconstructing a three-dimensional mesh based on the obtained connection relationship and geometric information; The connection relationship decoding includes decoding the pattern of triangles in the three-dimensional grid; for those satisfying the condition The connection relationship decoding further includes decoding additional information indicating the positional relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method in parallel with the connection relationship decoding.
10. The three-dimensional grid decoding method according to claim 9, characterized in that: The process of decoding the connection relationship of the input code stream includes: Decoding the input code stream to obtain a mode of a current triangle; When the mode of the current triangle is a preset mode that meets the condition, the input code stream is decoded by using the set threshold information to obtain additional information indicating the position relationship of the triangle; Based on the preset mode and a stitching method determined by the additional information obtained according to the preset mode, the current triangle is connected to the reconstructed three-dimensional mesh.
11. The three-dimensional grid decoding method according to claim 10, characterized in that: The relevant information at least includes: One or more of vertex geometry information, encoded triangle mode, and the number of adjacent encoded triangles of a triangle vertex.
12. The three-dimensional grid decoding method according to claim 10, characterized in that: When the current triangle mode is a preset mode that satisfies the condition, the input code stream is decoded by using the set threshold information to obtain additional information indicating the position relationship of the triangle, including: When the mode of the current triangle is the S mode in the CLERS mode, the input code stream is decoded by setting the threshold T1 to determine that the additional information represented by the S connection information is the number of vertex rotations or the triangle traversal index of the vertex corresponding to the current angle.
13. The three-dimensional grid decoding method according to claim 12, characterized in that: When the current triangle mode is a preset mode that satisfies the condition, the input code stream is decoded by using the set threshold information to obtain additional information indicating the position relationship of the triangle, including: When the mode of the current triangle is E, R or L mode in the CLERS mode, and the rotation vertex of the triangle is connected to more than two triangles in the S mode, the input code stream is decoded using the set threshold T2 to determine that the additional information represented by the stitching angle information is the relative traversal sequence number of the triangle or the traversal index of the triangle.
14. The three-dimensional grid decoding method according to claim 12, characterized in that: Decoding the input code stream to obtain a value of a set threshold T1 corresponding to the current triangle of the S mode; 15. The three-dimensional grid decoding method according to claim 13, characterized in that: Decoding the input code stream to obtain a value of a set threshold T2 corresponding to the current triangle of the E, R or L mode; 16. A three-dimensional grid decoding device, characterized in that: include: A decoding module, used for decoding the connection relationship and the geometric information of the input code stream to obtain the connection relationship and the geometric information respectively; A reconstruction module, used for reconstructing a three-dimensional mesh based on the obtained connection relationship and geometric information; Among them, the connection relationship decoding includes decoding the pattern of triangles in the three-dimensional mesh; for a preset pattern that meets the conditions, the connection relationship decoding also includes decoding additional information used to indicate the position relationship of the triangles to achieve instant stitching of the current triangle; the geometric information decoding supports a decoding method parallel to the connection relationship decoding.
Citation Information
Patent Citations
Coding and decoding method, device and equipment
CN116934880A
Coding and decoding method, device and equipment
CN116939214A
Method and system of encoding the connectivity of a triangle mesh
WO2004040517A1
Dynamic mesh coding with simplified topology
WO2023129988A2