Moving image encoding apparatus, moving image decoding apparatus, and integrated circuit
The moving image decoding apparatus addresses inefficiencies in existing technologies by enabling exclusive use of tiles, wavefronts, or slices within a tile group, enhancing encoding and decoding efficiency through flexible tile division and parallel processing.
Patent Information
- Application Number
- JP2025068469
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2019-03-25
- Filing Date
- 2025-04-18
- Publication Date
- 2025-07-10
- Estimated Expiration
- 2040-02-07
AI Technical Summary
Existing moving image encoding and decoding technologies face complexity and inefficiency due to the non-exclusive use of tiles, wavefronts, and slices, which complicates processing and limits the ability to encode data in groups, and do not support flexible tile division or wavefront parallel processing suitable for tile groups.
A moving image decoding apparatus that decodes encoded data using a flag for CABAC synchronization, byte alignment, and header information to process tile groups composed of rectangular regions, allowing exclusive use of tiles, wavefronts, or slices within a tile group, enabling flexible tile size and efficient parallel processing.
This approach simplifies and enhances encoding and decoding efficiency by allowing exclusive use of tiles, wavefronts, or slices within a tile group, facilitating flexible tile division and parallel processing, thereby improving overall processing efficiency.
Smart Images

Figure 2025105675000001_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present invention relate to a moving image decoding device, a moving image encoding device, and an integrated circuit.
Background Art
[0002] In order to efficiently transmit or record a moving image, a moving image encoding device that generates encoded data by encoding the moving image, and a moving image decoding device that generates a decoded image by decoding the encoded data are used.
[0003] Specific moving image encoding methods include, for example, H.264 / AVC and HEVC (High-Efficiency Video Coding).
[0004] In such a moving image encoding method, an image (picture) constituting the moving image is managed by a hierarchical structure including a slice obtained by dividing the image, a coding tree unit (CTU) obtained by dividing the slice, a coding unit (sometimes called a coding unit (CU)) obtained by dividing the coding tree unit, and a transform unit (TU) obtained by dividing the coding unit, and is encoded / decoded for each CU.
[0005] Also, in such a moving image encoding method, usually, a predicted image is generated based on a locally decoded image obtained by notifying an input image, and a prediction error (sometimes called a "difference image" or a "residual image") obtained by subtracting the predicted image from the input image (original image) is encoded. Examples of the method for generating the predicted image include inter-picture prediction (inter prediction) and intra-picture prediction (intra prediction).
[0006] In addition, as methods for dividing a screen into a plurality of units for transmission, methods of dividing into slices, CTU rows (wavefront parallel), and tiles are known. Hereinafter, these are referred to as segments.
[0007] In addition, Non-Patent Document 1 is cited as a technology for recent video encoding and decoding, Non-Patent Document 2 discloses a technology of tile groups, and a specific syntax example of tile groups is disclosed in Non-Patent Document 3. Non-Patent Document 4 discloses a rectangular tile group called rectangle tile.
[0008] In addition, a wavefront parallelization technology in a sub-stream (hereinafter referred to as a tile group) in which a plurality of tiles are combined into one is disclosed in Non-Patent Document 5.
Prior Art Documents
Non-Patent Documents
[0009]
Non-Patent Document 1
Non-Patent Document 2
Non-Patent Document 3
[0010] In HEVC, it corresponds to tiles that divide a picture into rectangles, wavefront parallel processing (WPP) that divides into CTU rows, and slices that divide into sets of consecutive CTUs. However, for one area, since the use of tiles, wavefronts, and slices is not exclusive, there is a problem that the processing becomes complicated. Also, since it does not correspond to tile groups like Non-Patent Documents 2 and 3, when using tile or wavefront parallelization, there is a problem that the entry point indicating the start position of the encoded data can only be encoded on a picture-by-picture basis and cannot be encoded in groups obtained by dividing the screen.
[0011] In the tiles described in Non-Patent Document 2 and Non-Patent Document 3, it is possible to notify tiles in group units, but there are problems that they do not support wavefront parallel processing that realizes high efficiency and high parallelism, and slices that realize the segment division position at any position other than a rectangle. Also, the type of segment cannot be switched in tile group units.
[0012] Also, since the tile division method in the tiles described in Non-Patent Document 2 and Non-Patent Document 3 is defined in picture units, the width and height of the tiles cannot be changed in picture group units.
[0013] Also, Non-Patent Document 5 discloses a method of wavefront parallelization within a tile group, but does not disclose the case of defining a tile group in a PPS as described in Non-Patent Document 1, and wavefront parallelization suitable for the case of defining a tile group in a PPS cannot be realized.
[0014] Therefore, the present invention has been made in view of the above problems, and an object thereof is to simplify and improve the efficiency of encoding processing and decoding processing by exclusively using tiles, wavefronts, and slices within a tile group. Also, it is to change the width and height of the tiles in picture group units.
Means for Solving the Problems
[0015] The moving image decoding apparatus according to one aspect of the present invention includes a decoding unit that decodes a flag indicating whether or not context-adaptive binary arithmetic coding (CABAC) synchronization processing is performed, a 1-bit syntax element, and a bit string for byte alignment. When the value of the flag is 1, the bit string for byte alignment is decoded based on whether it is the last CTU of a tile group and whether it is the last CTU of a CTU row. Further, the moving image decoding apparatus according to one aspect of the present invention is a moving image decoding apparatus that decodes encoded data of a tile group obtained by dividing a picture into one or more rectangular regions and composed of one or more segments. The moving image decoding apparatus includes a header decoding unit that decodes the number of tiles in the target tile group, a WPP valid flag, and a slice valid flag in the target tile group, which indicate whether the segment in the target tile group is a rectangular tile, a CTU row having a height of 1 CTU, or a slice in CTU units, from the tile group header. The header decoding unit decodes only any one of the number of tiles being two or more, the WPP valid flag being 1, and the slice valid flag being 1 within one tile group.
Brief Description of the Drawings
[0016]
Figure 1
Figure 2
Figure 3
Figure 4
Figure 5
Figure 6
Figure 7
Figure 8
Figure 9
Figure 10
Figure 11
Figure 12
Figure 13
Figure 14
Figure 15
Figure 16
Figure 17
Figure 18
Figure 19
Figure 20
Figure 21
Figure 22
Figure 23
Figure 24
Figure 25
Figure 26
Figure 27
Figure 28
Figure 29
Figure 30
Figure 31
Figure 32
Figure 33
Figure 34
Figure 35
Figure 36
Figure 37
Figure 38
Figure 39
Figure 40
Figure 41
Figure 42
Embodiments for Carrying Out the Invention
[0017] (First Embodiment) Hereinafter, embodiments of the present invention will be described with reference to the drawings.
[0018] FIG. 1 is a schematic diagram showing the configuration of an image transmission system 1 according to the present embodiment.
[0019] The image transmission system 1 is a system that transmits an encoded stream obtained by encoding an image to be encoded and decodes the transmitted encoded stream to display an image. The image transmission system 1 includes a moving image encoding device (image encoding device) 11, a network 21, a moving image decoding device (image decoding device) 31, and a moving image display device (image display device) 41.
[0020] An image T is input to the moving image encoding device 11.
[0021] The network 21 transmits the encoded stream Te generated by the moving image encoding device 11 to the moving image decoding device 31. The network 21 is the Internet, a wide area network (WAN), a local area network (LAN), or a combination thereof. The network 21 is not necessarily limited to a bidirectional communication network and may be a unidirectional communication network that transmits broadcast waves such as terrestrial digital broadcasting and satellite broadcasting. Further, the network 21 may be replaced by a storage medium on which the encoded stream Te such as a DVD (Digital Versatile Disc: registered trademark) or a BD (Blue-ray Disc: registered trademark) is recorded.
[0022] The moving image decoding device 31 decodes each of the encoded streams Te transmitted by the network 21 and generates one or more decoded images Td.
[0023] The moving image display device 41 displays all or part of the one or more decoded images Td generated by the moving image decoding device 31. The moving image display device 41 includes, for example, a display device such as a liquid crystal display or an organic EL (Electro-luminescence) display. Examples of the form of the display include a stationary type, a mobile type, and an HMD. Further, when the moving image decoding device 31 has high processing power, an image with high image quality is displayed, and when it has only low processing power, an image that does not require high processing power and display ability is displayed.
[0024] <Operator> The operators used in this specification are described below.
[0025] >>>> is a right bit shift, <<< is a left bit shift, & is a bitwise AND, | is a bitwise OR, |= is an OR assignment operator, and || indicates a logical OR.
[0026] x?y:z is a ternary operator that takes y when x is true (non-zero) and z when x is false (0).
[0027] Clip3(a, b, c) is a function that clips c to a value between a and b, inclusive. It returns a if c < a, b if c > b, and c otherwise (where a <= b).
[0028] abs(a) is a function that returns the absolute value of a.
[0029] Int(a) is a function that returns the integer value of a.
[0030] floor(a) is a function that returns the largest integer less than or equal to a.
[0031] ceil(a) is a function that returns the smallest integer greater than or equal to a.
[0032] a / d represents the division of a by d, rounded down to the nearest integer.
[0033] <Structure of the Encoded Stream Te> Prior to the detailed description of the moving image encoding device 11 and the moving image decoding device 31 according to the present embodiment, the data structure of the encoded stream Te generated by the moving image encoding device 11 and decoded by the moving image decoding device 31 will be described.
[0034] FIG. 4 is a diagram showing the hierarchical structure of data in the encoded stream Te. The encoded stream Te illustratively includes a sequence and a plurality of pictures constituting the sequence. FIGS. 4(a) to (f) show, respectively, an encoded video sequence that defines the sequence SEQ, an encoded picture that defines the picture PICT, an encoded tile group that defines a tile group, a segment (e.g., an encoded tile, a CTU row, a slice) that defines a tile, an encoded tree unit included in the segment, and an encoded unit included in the encoded tree unit.
[0035] (Symbolized video sequence) In the symbolized video sequence, a set of data that the moving image decoding device 31 refers to in order to decode the sequence SEQ to be processed is defined. As shown in Fig. 4(a), the sequence SEQ includes a sequence parameter set SPS (Sequence Parameter Set), a picture parameter set PPS (Picture Parameter Set), a picture PICT, and supplemental enhancement information SEI (Supplemental Enhancement Information).
[0036] In the sequence parameter set SPS, a set of encoding parameters that the moving image decoding device 31 refers to in order to decode the target sequence is defined. For example, information regarding the width, height, and shape of a picture, and information regarding the on / off of decoding tools are defined. Note that there may be multiple SPSs. In that case, one of the multiple SPSs is selected from the PPS.
[0037] In the picture parameter set PPS, a set of encoding parameters that the moving image decoding device 31 refers to in order to decode each picture in the target sequence is defined. For example, information regarding the number, width, and height of tiles constituting a picture is included. Note that there may be multiple PPSs. In that case, one of the multiple PPSs is selected from each picture in the target sequence.
[0038] (Symbolized picture) In the symbolized picture, a set of data that the moving image decoding device 31 refers to in order to decode the picture PICT to be processed is defined. As shown in Fig. 4(b), the picture PICT includes tile groups 0 to NTG - 1 (NTG is the total number of tiles included in the picture PICT).
[0039] (Segment, tile group) A segment is a unit for dividing and transmitting a picture, and on the encoded data, it is encoded and decoded as a byte-aligned bit sequence.
[0040] A tile, a CTU row, and a slice are each a segment for dividing and transmitting a picture.
[0041] A segment group (tile group) is a group of segments that are a set of CTUs, and it may also be called a segment group. Each segment is a unit with the following characteristics and can be decoded in parallel. · Corresponds to a set of CTUs on the screen · Is aligned in byte units on the encoded data · Performs CABAC initialization at the segment start · Prediction can be restricted between segments within the same picture (reference to other segments can be restricted) Restriction of prediction means, for example, when the segment is a tile, restricting not to perform intra prediction using an image of a tile different from the target tile. Similarly, when the segment is a slice, restricting not to perform intra prediction using an image of a slice different from the target slice.
[0042] When the segment is a WPP, partial permission is given for intra prediction using an image of a CTU row different from the target CTU row. Specifically, in WPP, the CTU row above the target CTU row can be referenced. However, for CTUs beyond the horizontal coordinate of the target CTU in the CTU row above the target CTU row, they cannot be referenced. Also, the reference can be turned on or off by a flag.
[0043] In a tile group (segment group), by encoding the header common to the segments only once for each segment, it has the effect of improving the encoding efficiency.
[0044] FIG. 5 is a diagram showing a picture divided into four tile groups, TileGr0 to TileGr3. A tile group can be further divided into one or more segments. The number after TileGr (0 to 3 in the figure) is the identifier of the tile group, which is set in raster scan order from the upper left to the lower right of the picture. The tile group identifier is a different value for each tile group and is a monotonically increasing value in scan order.
[0045] FIG. 6(a) is a diagram for explaining tile addresses when a segment is a tile. The number after the tile (Tile) in the figure is the tile address in the picture (TileAddrInPic). TileAddrInPic is set in raster scan order from the upper left to the lower right of the picture. The tile group TileGr0 in the figure includes tiles Tile0, Tile1, Tile4, and Tile5. TileGr1 includes Tile2, Tile3, Tile6, and Tile7. TileGr2 includes Tile8 and Tile9. TileGr3 includes Tile10 and Tile11. When using TileAddrInPic as the tile address, the tile addresses are not continuous within a tile group.
[0046] FIG. 6(b) is another diagram for explaining tile addresses when a segment is a tile. The number after the tile (Tile) in the figure is the tile address within the tile group (TileAddrInTG). TileAddrInTG is set in raster scan order from the upper left to the lower right of the tile group. The tile group TileGr0 in the figure includes tiles Tile0, Tile1, Tile2, and Tile3. TileGr1 includes Tile4, Tile5, Tile6, and Tile7. TileGr2 includes Tile8 and Tile9. TileGr3 includes Tile10 and Tile11. When using TileAddrInTG as the tile address, the tile addresses are continuous within a tile group.
[0047] (Encoded Tile Group) In the symbolized tile group, a set of data that the moving image decoding device 31 refers to in order to decode the tile group to be processed is defined. As shown in FIG. 4(c), the tile group includes a tile group header and tile group data. Further, trailing data for byte alignment (rbsp_tile_group_trailing_bits) may be included after the tile group data.
[0048] FIG. 7 is a flowchart for explaining the encoding or decoding of the tile group of the present embodiment. The constituent members that execute each step are described in FIGS. 9 and 24, which will be described later.
[0049] S2001: The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the tile group header.
[0050] S2002: The CT information encoding unit 1111 or the CT information decoding unit 3021 encodes or decodes the tile group data.
[0051] S2003: The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the trailing data. The trailing data may include a bit string for byte alignment. Further, it may include a bit string indicating a delimiter before byte alignment.
[0052] The tile group header includes a group of encoding parameters for determining the decoding method of the target tile group and parameters common to the tiles of the tile group. The tile group data is composed of the encoded data of one or more segments included in the tile group. A segment is composed of CTUs. When the segment is a tile, the tile group data is composed of one or more encoded tiles.
[0053] (Tile group header) The tile group header may include tile group type designation information (tile_group_type).
[0054] As tile group types that can be specified by the tile group type specification information, there are (1) an I tile group that uses only intra prediction during encoding, (2) a P tile group that uses uni-directional prediction or intra prediction during encoding, (3) a B tile group that uses uni-directional prediction, bi-directional prediction, or intra prediction during encoding, and the like. Note that inter prediction is not limited to uni-prediction and bi-prediction, and a predicted image may be generated using more reference pictures. Hereinafter, when referring to P and B tile groups, it refers to a tile group including blocks that can use inter prediction.
[0055] Note that the tile group header may include a reference (tile_group_pic_parameter_set_id) to the picture parameter set PPS.
[0056] (Coded tile) In a coded tile, a set of data that the moving image decoding device 31 refers to in order to decode a tile to be processed is defined. A tile includes CTUs as shown in FIG. 4(d). A CTU is a block having a fixed size (for example, 128x128) that constitutes a tile, and is sometimes called the largest coding unit (LCU).
[0057] (Tile, WPP, Slice) FIG. 8(a) is an example of dividing a tile group TileGr0 into a plurality of tiles Tile0 to Tile3 (thick solid rectangles). A tile is a rectangular segment composed of one or more CTUs. The address of each CTU (CTU address ctbAddrTs in tile scan order) is set in raster scan order from the upper left to the lower right of each tile.
[0058] FIG. 8(b) is an example of dividing a tile group into a plurality of CTU rows. As shown in the figure, a CTU row is a segment composed of a set of CTUs in one row (height is CTU height and width is segment width). As will be described later, the segment of the CTU row is used in WPP.
[0059] Figure 8(c) is an example of dividing a tile group into a set of consecutive CTUs. As shown in the figure, a slice is a segment composed of a set of CTUs.
[0060] (Coding Tree Unit) Figure 4(e) defines a set of data that the moving image decoder 31 refers to in order to decode the CTU to be processed. A CTU is divided into coding units (CUs), which are the basic units of the encoding process, by recursive quadtree partitioning (QT (Quad Tree) partitioning), binary tree partitioning (BT (Binary Tree) partitioning), or ternary tree partitioning (TT (Ternary Tree) partitioning). The combination of BT partitioning and TT partitioning is called multi-tree partitioning (MT (Multi Tree) partitioning). The nodes of the tree structure obtained by recursive quadtree partitioning are called coding nodes. The intermediate nodes of the quadtree, binary tree, and ternary tree are coding nodes, and the CTU itself is also defined as the topmost coding node.
[0061] (Coding Unit) As shown in Figure 4(f), a set of data that the moving image decoder 31 refers to in order to decode the coding unit to be processed is defined. Specifically, a CU is composed of a CU header, prediction parameters, transformation parameters, quantized transform coefficients, etc. The prediction mode, etc. are defined in the CU header.
[0062] (Configuration of Moving Image Decoder) The configuration of the moving image decoder 31 (Figure 9) according to this embodiment will be described.
[0063] The moving image decoding apparatus 31 includes a parameter decoding unit (predicted image decoding apparatus) 302, a loop filter 305, a reference picture memory 306, a prediction parameter memory 307, a predicted image generation unit (predicted image generation apparatus) 308, an inverse quantization / inverse transformation unit 311, and an addition unit 312. Note that, in accordance with the moving image encoding apparatus 11 described later, there is also a configuration in which the moving image decoding apparatus 31 does not include the loop filter 305. The parameter decoding unit 302 further includes an entropy decoding unit 301, a header decoding unit 3020, a CT information decoding unit 3021, and a CU decoding unit 3022, and the CU decoding unit 3022 further includes a TU decoding unit 3024.
[0064] (Decoding module) The following describes the general operations of each module. The parameter decoding unit 302 performs decoding processing of parameters such as header information, segmentation information, prediction information, and quantization transformation coefficients.
[0065] The entropy decoding unit 301 decodes syntax elements from binary data. More specifically, the entropy decoding unit 301 decodes syntax elements from encoded data using an entropy encoding method such as CABAC based on the syntax elements input from the source and returns them to the source. In the example shown below, the sources of the syntax elements are the CT information decoding unit 3021 and the CU decoding unit 3022.
[0066] (Basic flow) FIG. 10 is a flowchart for explaining the general operation of the moving image decoding apparatus 31.
[0067] (S1100: Decoding of parameter set information) The header decoding unit 3020 decodes parameter set information such as SPS and PPS and tile information from the encoded data.
[0068] Information regarding the number of divisions and size of tiles is called tile information. The tile width ColWidth and height RowHeight are derived using the picture width PicWidthInCtbsY and height PicHeightInCtbsY, and the number of horizontal and vertical tiles in the picture NumTileColumns and NumTileRows. The units of ColWidth, RowHeight, PicWidthInCtbsY, and PicHeightInCtbsY are CTUs. The header decoding unit 3020 derives them using the following formula with the picture pixel unit width pic_width_in_luma_samples, height pic_height_in_luma_samples, and the value log2_ctu_size_minus2 obtained by subtracting 2 from the logarithmic value of the CTU size. pic_width_in_luma_samples, pic_height_in_luma_samples, and log2_ctu_size_minus2 are signaled in the sequence_parameter_set_rbsp() (referred to as SPS) in Figure 11(a). Hereinafter, "signaling" a certain piece of information means including the information in the encoded data (bitstream). In the video encoding device, the information is encoded, and in the video decoding device, the information is decoded.
[0069] ctuWidth = ctuHeight = 1<<(log2_ctu_size_minus2+2) PicWidthInCtbsY = Ceil(pic_width_in_luma_samples / ctuWidth) PicHeightInCtbsY = Ceil(pic_height_in_luma_samples / ctuHeight) The division ( / ) here is in decimal precision.
[0070] The number of horizontal and vertical tiles NumTileColumns and NumTileRows in the picture are signaled by PPS (pic_parameter_set_rbsp()) in Figure 11(b). For example, the tile information may be single_tile_in_pic_flag, num_tile_columns_minus1, num_tile_rows_minus1, uniform_tile_spacing_flag, tile_column_width_minus1[i], tile_row_height_minus1[i]. Here, single_tile_in_pic_flag is a flag indicating whether there are multiple tiles in the picture. If it is 1, there is one tile in the picture, and the picture corresponds to the tile. If it is 0, the picture contains multiple tiles. num_tile_columns_minus1 and num_tile_rows_minus1 are the values obtained by subtracting 1 from the number of horizontal and vertical tiles NumTileColumns and NumTileRows in the picture, respectively. uniform_spacing_flag is a flag indicating whether the picture is tiled as evenly as possible.
[0071] The header decoding unit 3020 derives the number of horizontal and vertical tiles NumTileColumns and NumTileRows in the picture, and the total number of tiles NumTilesInPic in the picture as follows.
[0072] NumTileColumns = num_tile_columns_minus1+1 NumTileRows = num_tile_rows_minus1+1 NumTilesInPic = NumTileColumns*NumTileRows The header decoding unit 3020 may derive the tile size by the following formula.
[0073] for(m=0;m<NumTileColumns;m++) ColWidth[m] = (m + 1) * PicWidthInCtbsY / NumTileColumns - m * PicWidthInCtbsY / NumTileColumns for(n = 0; n < NumTileRows; n++) RowHeight[n] = (n + 1) * PicHeightInCtbsY / NumTileRows - n * PicHeightInCtbsY / NumTileRows When the value of uniform_spacing_flag is 0, the width and height of each tile of the picture are set individually. In the moving image encoding device, the width ColWidth[m] and height RowHeight[n] of each tile are encoded for each tile. The header decoding unit 3020 of the moving image decoding device decodes ColWidth[m] and RowHeight[n] for each tile as follows.
[0074] ColWidth[m] = tile_column_width_minus1[m] + 1 (0 <= m < NumTileColumns - 1) RowHeight[n] = tile_row_height_minus1[m] + 1 (0 <= n < NumTileRows - 1) ColWidth[NumTileColumns - 1] = PicWidthInCtbsY - sum_m(ColWidth[m]) RowHeight[NumTileRows - 1] = PicHeightInCtbsY - sum_n(RowHeight[n]) Here, sum_m(ColWidth[m]) represents the sum of ColWidth[m] (0 <= m < NumTileColumns - 1), and sum_n(RowHeight[n]) represents the sum of RowHeight[n] (0 <= n < NumTileRows - 1).
[0075] (S1200: Decoding of tile group information) The header decoding unit 3020 decodes the tile group header (tile group information) from the encoded data.
[0076] Figure 12(a) shows the syntax of the tile group header of an encoded tile group. In the tile group header, tile_group_pic_parameter_set_id, tile_group_address, num_tiles_in_tile_group_minus1, tile_group_type, and entry_point() are signaled. tile_group_pic_parameter_set_id indicates the picture parameter set identifier pps_pic_parameter_set_id of the picture in which the tile group is included. tile_group_address indicates the tile address of the first tile in the tile group, and is a value in the range of 0 to NumTilesInPic - 1. The tile_group_addresses of tile groups included in the same picture have different values from each other. num_tiles_in_tile_group_minus1 + 1 indicates the number of tiles in the tile group. tile_group_type indicates the encoding type of the tile group (I tile group, P tile group, B tile group). entry_point() is the syntax of the entry point, and an example is shown in Figure 12(b).
[0077] The parameter decoding unit 302 first decodes tile_group_pic_parameter_set_id. Next, when the number of tiles NumTilesInPic in the tile group is greater than 1, it decodes tile_group_address and num_tiles_in_tile_group_minus1. Otherwise (NumTilesInPic == 1), it sets 0 to tile_group_address and num_tiles_in_tile_group_minus1, respectively. Next, it decodes tile_group_type.
[0078] When a tile group contains multiple tiles (num_tiles_in_tile_group_minus1 > 0), the parameter decoding unit 302 decodes offset_len_minus1 and NumEntryPoint entry points entry_point_offset_minus1[i]. When the segment is a tile, NumEntryPoint is set to num_tiles_in_tile_group_minus1. When there is one tile in the tile group (num_tiles_in_tile_group_minus1 = 0), the parameter decoding unit 302 does not decode the entry point.
[0079] The entry point is the starting address of the segment in the encoded data (for example, the offset position in bytes with the starting point on the encoded data of the tile group header to which the target segment belongs or the starting point of the preceding segment as the zero point), and when the segment is a tile, it is the starting address of each tile. entry_point_offset_minus1[i] + 1 may be the difference value between the (i + 1)-th entry point and the i-th entry point in the encoded data. The 0-th entry point is the starting address of the tile group header (the position of the tile group header start point, that is, the zero point), and is not notified. offset_len_minus1 + 1 is the number of bits representing entry_point_offset_minus1[i].
[0080] Expressing the offset position in bytes with the starting point on the encoded data of the tile group header to which the target segment belongs as the zero point as firstByte[k] and the offset position in bytes at the end of the segment as lastByte[k], entry_point_offset_minus1[i] can be derived as follows.
[0081] firstByte[k] = Σ(entry_point_offset_minus1[n - 1] + 1) Σ represents the sum from n = 1 to k.
[0082] Hereinafter, for each CTU included in the target picture, the moving picture decoding apparatus 31 derives a decoded picture of each CTU by repeating the processes from S1300 to S5000.
[0083] (S1300: CTU information decoding) The CT information decoding unit 3021 decodes a CTU from the encoded data. The CT (Coding Tree) information includes the splitting information of the coding tree.
[0084] FIG. 12(c) is an example of the syntax of the tile group data of the encoded tile group. In the tile group data, the CTU data coding_tree_unit() of the tile group is encoded or decoded, and the segment end bit end_of_tile_one_bit with a fixed value is encoded or decoded at the end of the segment.
[0085] When the segment is a tile, the CT information decoding unit 3021 decodes the fixed value end_of_tile_one_bit in the CTU at the tile end (lower right of the tile), and decodes the bit string byte_alignment() for byte alignment. Note that the decoding of byte_alignment() may be limited to the case where i is smaller than num_tiles_in_tile_group_minus1. That is, in the last segment (i == num_tiles_in_tile_group_minus1) in the tile group, since the trailing data for byte alignment is decoded thereafter, the decoding of byte_alignment() can be omitted.
[0086] The CT information decoding unit 3021 sets tile_group_address to tileIdx. tileIdx is the identifier of the tile, and tile_group_address is the tile address of the first tile in the tile group. In order to identify each tile of the tile group using tileIdx, the CT information decoding unit 3021 increments tileIdx by 1 every time it processes a tile.
[0087] The CT information decoding unit 3021 uses tileIdx and FirstCtbAddrTs[] to derive the CTU address ctbAddrTs in the tile scan order within the tile using the following formula. Tile scan is a scan method in which processing proceeds in order from the upper left to the lower right within the tile.
[0088] ctbAddrTs = FirstCtbAddrTs[tileIdx] FirstCtbAddrTs[] is a table that converts tileIdx to the first CTU address of the tile and is derived as follows.
[0089] for (ctbAddrTs = 0, tileIdx = 0, tileStartFlag = 1; ctbAddrTs < PicSizeInCtbsY; ctbAddrTs++) { if (tileStartFlag) { FirstCtbAddrTs[tileIdx] = ctbAddrTs tileStartFlag = 0 } tileEndFlag = (ctbAddrTs == PicSizeInCtbsY - 1) || (TileId[ctbAddrTs + 1]!= TileId[ctbAddrTs]) if (tileEndFlag) { tileIdx++ tileStartFlag = 1 } } Here, TileId[] is a table that converts the CTU address in the tile scan order to the tile identifier. An example is shown below.
[0090] for (j = 0, tileIdx = 0; j <= num_tile_rows_minus1; j++) for (i = 0; i <= num_tile_columns_minus1; i++, tileIdx++) for (y = RowBd[j]; y < RowBd[j + 1]; y++) for (x = ColBd[i]; x < ColBd[i + 1]; x++) TileId[CtbAddrRsToTs[y * PicWidthInCtbsY + x]] = TileIdx Here, RowBD[] and ColBD[] are tables that store the maximum vertical coordinates of each tile row and the maximum horizontal coordinates of each tile column, respectively, and are expressed in CTU units. An example is shown below.
[0091] For (RowBd[0] = 0, j = 0; j <= num_tile_rows_minus1; j++) RowBd[j + 1] = RowBd[j] + RowHeight[j] For (ColBd[0] = 0, i = 0; i <= num_tile_columns_minus1; i++) ColBd[i + 1] = ColBd[i] + ColWidth[i] (Method for Deriving the CTU Scan Order within a Picture 1) Also, CtbAddrRsToTs[] is a table that converts the raster scan order CTU addresses within a picture to tile scan order CTU addresses. The CT information decoding unit 3021 may derive CtbAddrRsToTs[] by the following process. This derivation method corresponds to the scan order of CTUs when performing a raster scan in tile order within a picture and then performing a raster scan in CTU order within a tile. Note that CTUs may also be referred to as CTBs. The CTU scan order may also be referred to as the CTB scan order.
[0092] for (ctbAddrRs = 0; ctbAddrRs < PicSizeInCtbsY; ctbAddrRs++) { tbX = ctbAddrRs % PicWidthInCtbsY tbY = ctbAddrRs / PicWidthInCtbsY for(i = 0; i <= num_tile_columns_minus1; i++) if(tbX >= ColBd[i]) tileX = i for(j = 0; j <= num_tile_rows_minus1; j++) if(tbY >= RowBd[j]) tileY = j CtbAddrRsToTs[ctbAddrRs] = 0 for(i = 0; i < tileX; i++) CtbAddrRsToTs[ctbAddrRs] += RowHeight[tileY] * ColWidth[i] for(j = 0; j < tileY; j++) CtbAddrRsToTs[ctbAddrRs] += PicWidthInCtbsY * RowHeight[j] CtbAddrRsToTs[ctbAddrRs] += (tbY - RowBd[tileY]) * ColWidth[tileX] + tbX - ColBd[tileX] } (Method for Deriving CTU Scan Order within Picture 0) CT information decoding unit 3021 derives the raster scan order CTU address ctbAddrRs using ctbAddrTs and CtbAddrTsToRs[] by the following formula.
[0093] ctbAddrRs = CtbAddrTsToRs[ctbAddrTs] CtbAddrTsToRs[] is a table that converts the tile scan order CTU address to the raster scan order CTU address, and is derived as follows.
[0094] for (ctbAddrRs = 0; ctbAddrRs < PicSizeInCtbsY; ctbAddrRs++) CtbAddrTsToRs[CtbAddrRsToTs[ctbAddrRs]] = ctbAddrRs Note that the derivation of CtbAddrTsToRs[] and CtbAddrTsToRs[] is performed by the CT information encoding unit 1111 in the moving image encoding apparatus 11. It may also be performed by the header encoding unit 1110 and the header decoding unit 3020.
[0095] Alternatively, CtbAddrTsToRs[] may be derived first, and CtbAddrRsToTs[] may be derived using the following formula with CtbAddrTsToRs[].
[0096] for (ctbAddrTs = 0; ctbAddrTs < PicSizeInCtbsY; ctbAddrTs++) CtbAddrRsToTs[CtbAddrTsToRs[ctbAddrTs]] = ctbAddrTs The CT information decoding unit 3021 decodes each CTU in the tile in the tile scan order, and after decoding all CTUs, decodes end_of_tile_one_bit.
[0097] (S1400: CT information decoding) The CT information decoding unit 3021 decodes CT from the encoded data.
[0098] (S1500: CU decoding) The CU decoding unit 3022 performs S1510 and S1520 to decode the CU from the encoded data.
[0099] (S1510: CU information decoding) The CU decoding unit 3022 decodes CU information, prediction information, TU split flag split_transform_flag, CU residual flags cbf_cb, cbf_cr, cbf_luma, etc. from the encoded data.
[0100] (S1520: TU information decoding) When the TU contains prediction error, the TU decoding unit 3024 decodes QP update information (quantization correction value) and quantized prediction error (residual_coding) from the encoded data. Note that the QP update information is the difference value from the quantization parameter prediction value qPpred which is the predicted value of the quantization parameter QP.
[0101] (S2000: Prediction Image Generation) The prediction image generation unit 308 generates a prediction image for each block included in the target CU based on prediction information.
[0102] (S3000: Inverse Quantization and Inverse Transformation) The inverse quantization and inverse transformation unit 311 performs inverse quantization and inverse transformation processing for each TU included in the target CU.
[0103] (S4000: Decoded Image Generation) The adder 312 generates a decoded image of the target CU by adding the prediction image supplied from the prediction image generation unit 308 and the prediction error supplied from the inverse quantization and inverse transformation unit 311.
[0104] (S5000: Loop Filter) The loop filter 305 applies loop filters such as a deblocking filter, SAO, and ALF to the decoded image to generate a decoded image.
[0105] (Modification Example 1) Example of changing the tile size for each tile group In the above example, the width and height of the tile are defined in units of pictures (PPS). However, in Modification Example 1, an example of flexibly setting the tile size for each tile group that divides the picture will be described.
[0106] FIG. 13 shows an example in which a picture is divided into four tile groups, TileGr0 to TileGr3, and each tile group is further divided into tiles. Different from the tile division in FIG. 6, it is characterized in that different tile widths and heights are set for each tile group. The number after Tile in the figure is the address of the tile within the tile group (TileAddrInTG). The tile group TileGr0 in the figure includes tiles Tile0, Tile1, Tile2, and Tile3. TileGr1 includes Tile4 and Tile5. TileGr2 includes Tile6, Tile7, and Tile8. TileGr3 includes Tile9.
[0107] FIG. 14 shows an example of the syntax of Modification Example 1. As shown in the figure, the syntax may be, for example, single_tile_group_in_pic_flag, num_tile_group_columns_minus1, num_tile_rows_group_minus1, tile_group_column_width_minus1[i], tile_group_row_height_minus1[i].
[0108] Here, single_tile_group_in_pic_flag is a flag indicating whether there are multiple tile groups in the picture. If it is 1, there is one tile group in the picture, and the picture corresponds to the tile group. If it is 0, the picture contains multiple tile groups. num_tile_group_columns_minus1 and num_tile_group_rows_minus1 are the values obtained by subtracting 1 from the number of tile groups NumTileGrColumns and NumTileGrRows in the horizontal and vertical directions in the picture, respectively.
[0109] Next, the syntax of the tiles is notified for each tile group. For example, for each tile in the j-th tile group, single_tile_in_pic_flag[j], num_tile_columns_minus1[j], num_tile_rows_minus1[j], uniform_tile_spacing_flag[j], tile_column_width_minus1[j][i], tile_row_height_minus1[j][i] are notified. The meaning of each syntax is the same as the syntax in FIG. 11(b).
[0110] The header decoding unit 3020 derives the width and height (in CTU units) of the j-th tile group as follows.
[0111] TileGrWidthInCtbsY[j] = Ceil((tile_group_column_width_minus1[j]+1) / ctuWidth) TileGrHeightInCtbsY[j] = Ceil((tile_group_rows_height_minus1[j]+1) / ctuHeight) The header decoding unit 3020 derives the number of tile groups NumTileGrColumns and NumTileGrRows in the horizontal and vertical directions within the picture, and the total number of tile groups NumTileGrsInPic in the picture as follows.
[0112] NumTileGrColumns = num_tile_group_columns_minus1+1 NumTileGrRows = num_tile_group_rows_minus1+1 NumTilesGrsInPic = NumTileGrColumns*NumTileGrRows The header decoding unit 3020 derives the number of tiles NumTileColumns[j] and NumTileRows[j] in the horizontal and vertical directions within the j-th tile group, and the total number of tiles NumTilesInPic[j] in the tile group as follows.
[0113] NumTileColumns[j] = num_tile_columns_minus1[j]+1 NumTileRows[j] = num_tile_rows_minus1[j]+1 NumTilesInPic[j] = NumTileColumns[j]*NumTileRows[j] The header decoding unit 3020 decodes the width ColWidth[j][m] and height RowHeight[j][n] of each tile in the j-th tile group as follows.
[0114] ColWidth[j][m] = tile_column_width_minus1[j][m]+1 (0<=m<NumTileColumns[j]-1) RowHeight[j][n] = tile_row_height_minus1[j][m]+1 (0<=n<NumTileRows[j]-1) ColWidth[j][NumTileColumns[j]-1] = TileGrWidthInCtbsY[j]-sum_m(ColWidth[j][m]) RowHeight[j][NumTileRows[j]-1] = TileGrHeightInCtbsY[j]-sum_n(RowHeight[j][n]) Here, sum_m(ColWidth[j][m]) represents the sum of ColWidth[j][m] (0<=m<NumTileColumns[j]-1), and sum_n(RowHeight[j][n]) represents the sum of RowHeight[j][n] (0<=n<NumTileRows[j]-1).
[0115] In Modification 1, the syntax of the tile group header and tile group data is the same as that in FIGS. 12(a) and 12(c), but the method for deriving the table TileId[] that converts the CTU address in the tile scan order into a tile identifier is different. The method for deriving this table in Modification 1 is shown below.
[0116] for (k=0; k<NumTileGrRows; k++) for (l=0; l<NumTileGrColumns; l++) for (j=0,tileIdx=0; j<=num_tile_rows_minus1[k]; j++) for(i=0; i<=num_tile_columns_minus1[l]; i++,tileIdx++) for(y=RowBd[k][j]; y<RowBd[k][j+1]; y++) for(x=ColBd[l][i]; x<ColBd[l][i+1]; x++) TileId[CtbAddrRsToTs[y*PicWidthInCtbsY + x]] = TileIdx The processing of the other header decoding section 3020 is the same as the example of defining the tile width and height in the above-mentioned PPS.
[0117] As described above, by encoding or decoding the syntax indicating the tile width and height for each tile group, tiles of different sizes can be used for each tile group, enabling more flexible tile division.
[0118] (Wavefront parallel processing) Wavefront parallel processing (WPP) can achieve parallel encoding or parallel decoding of multiple segments while suppressing a decrease in encoding efficiency by using CTU rows as segments.
[0119] (Exclusive configuration within a segment group) FIG. 15 shows an example of using different types of segments in units of tile groups (segment groups). In this example, in TileGr0 and TileGr1, tiles are used as segments, in TileGr2, CTU rows are used as segments, and in TileGr3, slices are used as segments.
[0120] In the following embodiments, within one segment group (within a tile group), the type of segment is limited to one, and it is characterized by exclusively processing tiles, CTU rows, and slices. That is, within one tile group (segment group), only one of the tile segments (multiple tile segments), CTU row segments, and slice segments can be made effective. For example, within one tile group, only one of the tile and the CTU row can be made effective. Making the tile effective as described above means that when the tile group is composed of two or more tiles (the tile group is divided into two or more tiles).
[0121] (Variant Example 2) Processing When a Segment Can Be a Tile or a CTU Row In Variant Example 2, a segment can be either a tile or a CTU row (CTU row), and a case where either a tile or a CTU is used in tile group units will be described.
[0122] FIG. 16 is a diagram for explaining an exclusive configuration of a tile segment and a CTU row segment.
[0123] The entropy_coding_sync_enabled_flag is a flag (WPP enable flag) indicating whether to use a CTU row as a segment (i.e., perform WPP). When using a CTU row as a segment, CABAC synchronization processing is performed. That is, the CABAC initialization of the first CTU in the CTU row is performed using the CABAC state at the time when the second CTU in the CTU row one level above ends. As shown in the figure, when num_tiles_in_tile_group_minus1 is greater than 0, that is, when there are multiple tiles, the entropy_coding_sync_enabled_flag only takes the value 0. In this case, only multiple tiles are valid. When num_tiles_in_tile_group_minus1 is 0, that is, when there is one tile, the entropy_coding_sync_enabled_flag can take the value 1. In this case, only multiple CTU rows (wavefronts) are valid. Finally, when num_tiles_in_tile_group_minus1 is 0 and the entropy_coding_sync_enabled_flag is 0, it means there is one tile in the tile group. As will be described later, in this case, slices may be made valid.
[0124] Note that when the entropy_coding_sync_enabled_flag is 1, the CABAC initialization of the first CTU in the CTU row may be performed using the CABAC state at the time when the processing of the first CTU in the CTU row one level above ends.
[0125] With the above configuration, one tile group (within a segment group) has the effect of enabling the sharing of the entry points of tiles and the wavefront.
[0126] Also, in one tile group, tiles (multiple tiles) can be enabled, and in another tile group, the wavefront can be enabled.
[0127] In Variation 2, in order to implement the exclusive configuration of tiles and the wavefront, when the number of tiles in the tile group is 1 (the tile group and the tile are the same, that is, multiple tiles are not enabled in the target tile group), the entropy_coding_sync_enabled_flag flag is notified to make the CTU row available as a segment, and otherwise (when the tile group includes multiple tiles), the tile is used as a segment. Therefore, when the picture is divided into four tile groups as shown in FIG. 5, each tile group may be divided into multiple tiles as shown in FIG. 8(a), divided into multiple CTU rows as shown in FIG. 8(b), or the tile group is composed of one tile (when there is one tile in the tile group and it is not divided by CTU rows).
[0128] To encode or decode multiple tiles or multiple CTU rows included in a tile group in parallel, the start address (entry point) of the tile or CTU row is encoded or decoded with the tile group header.
[0129] FIG. 17 is a diagram for explaining the operations of the header encoding unit 1110 and the header decoding unit 3020 of a configuration having an exclusive configuration of tiles and the wavefront. FIG. 18(a) shows the syntax configuration of the tile group header to be encoded and decoded in the present embodiment.
[0130] As shown in the flowchart and syntax structure of the figure, when num_tiles_in_tile_group_minus1 is 0 (YES in S3001), that is, when there is one tile in the tile group, the entropy_coding_sync_enabled_flag is encoded or decoded (S3002). Otherwise, the entropy_coding_sync_enabled_flag is set to 0 (WPP off).
[0131] if (num_tiles_in_tile_group_minus1 == 0) entropy_coding_sync_enabled_flag else entropy_coding_sync_enabled_flag=0 Figure 18(b) is a diagram showing the syntax structure of the entry point. In the figure, TileGrHeightInCtbsY is the height of the tile group in CTU units, and num_tiles_in_tile_group_minus1 is the value obtained by subtracting 1 from the number of tiles in the tile group.
[0132] The header encoding unit 1110 or the header decoding unit 3020 derives the number of entry points NumEntryPoint. When the segments included in the tile group use WPP (when entropy_coding_sync_enabled_flag = 1), the number of CTU rows - 1 included in the tile group (here TileGrHeightInCtbsY - 1) is set to NumEntryPoint.
[0133] NumEntryPoint = TileGrHeightInCtbsY-1 Otherwise, the number of tiles - 1 included in the tile group (here num_tiles_in_tile_group_minus1) is set to NumEntryPoint.
[0134] NumEntryPoint = num_tiles_in_tile_group_minus1 When NumEntryPoint is greater than 0, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entry point information (offset_len_minus1 and NumEntryPoint entry_point_offset_minus1).
[0135] FIG. 18(c) is a diagram showing the syntax structure of tile group data. coding_tree_unit() is the encoded data of the CTUs included in the CTU row. end_of_subset_one_bit is a flag indicating the end of the segment.
[0136] In the loop process (loop variable i) for processing tiles within the tile group by the CT information encoding unit 1111 or the CT information decoding unit 3021, and further in the loop process (loop variable j) for CTUs within the tile, the target CTU coding_tree_unit() is encoded or decoded.
[0137] The CT information encoding unit 1111 or the CT information decoding unit 3021 derives ctbAddrInTile using ctbAddrTs and FirstCtbAddrTs[]. ctbAddrInTile is the address of the current CTU within the tile, ctbAddrTs is the address of the current CTU in the tile scan order, and FirstCtbAddrTs[] is the address of the first CTU in the tile group.
[0138] ctbAddrInTile = ctbAddrTs - FirstCtbAddrTs[tile_group_address] Note that in the configuration where the CTUs within the tile are looped from 0 to the number of CTUs in the tile group NumCtusInTile[tileIdx] using an index j which is a certain loop variable to decode the CTU (coding_tree_unit()), ctbAddrInTile = j.
[0139] When WPP is on, the CT information encoding unit 1111 or the CT information decoding unit 3021 encodes or decodes end_of_subset_one_bit after the decoding of the CTU row is completed. end_of_subset_one_bit is a bit inserted at the end of the CTU row. Whether it is the end of the CTU row is determined by the following formula.
[0140] entropy_coding_sync_enabled_flag && (CtbAddrInTile+1)%TileWidthInCtbsY==0 That is, when (entropy_coding_sync_enabled_flag && (CtbAddrInTile+1)%TileWidthInCtbsY==0), that is, when entropy_coding_sync_enabled_flag is 1, the CT information decoding unit 3021 decodes the fixed-value end_of_subset_one_bit after CTU decoding at the right end of the CTU row. Also, when the target CTU is at the head (left end) of the CTU row, the same process can be performed by decoding the bit string indicating the end of the segment (here, the CTU row) before encoding or decoding the target CTU coding_tree_unit(). For example, before the target CTU coding_tree_unit(), end_of_subset_one_bit may be encoded or decoded by the determination of entropy_coding_sync_enabled_flag && ((CtbAddrInTile)%TileWidthInCtbsY)==0 && CtbAddrInTile!=0.
[0141] Note that the CTU width TileWidthInCtbsY of the target tile may be derived as follows. TileWidthInCtbsY = ColWidth[tileIdx % (num_tile_columns_minus1 + 1) ] Here, tileIdx is the raster scan position of the target tile. num_tile_columns_minus1 is the number of tile rows within the tile's picture. tileIdx % (num_tile_columns_minus1 + 1) derives the CTU row position of the tile. By referring to ColWidth[] using the tile's CTU row position as an index, the width of the target tile in CTU units of the target tile is derived.
[0142] Also, tileIdx may be derived using a table TgTileIdx[i] that obtains the tile index (tileIdx) within the picture from the tile address i within the tile group. In this case, TileWidthInCtbsY = ColWidth[TgTileIdx[i]%(num_tile_columns_minus1+1)] Represented using a loop variable j that is the tile index within the tile group, after the CT information encoding unit 1111 or the CT information decoding unit 3021 encodes or decodes the target CTU coding_tree_unit(), when the following equation holds, it may encode or decode end_of_subset_one_bit, which is a bit string indicating the end of a segment (here, a CTU row).
[0143] if(entropy_coding_sync_enabled_flag && ( (j+1) % ColWidth[ TgTileIdx[ i ] % (num_tile_columns_minus1 + 1) ] == 0 ) ) { end_of_subset_one_bit When j==NumCtusInTile[tileIdx]-1 (in the case of the last CTU within the tile group), the CT information encoding unit 1111 or the CT information decoding unit 3021 encodes or decodes a fixed value of end_of_subset_one_bit.
[0144] Furthermore, except for the last segment of the tile group (except when encoding trailing data immediately), the CT information encoding unit 1111 or the CT information decoding unit 3021 decodes a byte-aligned bit sequence after end_of_subset_one_bit. Note that j < NumCtusInTile[tileIdx] - 1 is other than the last CTU in the segment, i < num_tiles_in_tile_group_minus1 is other than the last segment, and the union of the two can determine the CTUs other than the last segment of the tile group.
[0145] FIG. 25 is a diagram showing another syntax configuration of tile group data in the exclusive configuration of a tile and a wavefront. The tile group header and the entry point configuration are the same as those in FIGS. 18(a) and (b). In the figure, in addition to end_of_subset_one_bit representing the end of WPP as a fixed-value segment end bit notified at the end of the segment, end_of_tile_one_bit representing the end of the tile is included. FIG. 26 is a flowchart showing the operation of the CT information decoding unit 3021 decoding the syntax of FIG. 25.
[0146] Set the identifier of the tile (S2602).
[0147] Perform the processing of S2604 to S2624 for each tile (loop variable i) in the tile group. Note that when WPP is on, the tile group consists of one tile, and the tile group and the tile are equal. As described above, even in a configuration where WPP is on when the tile group is composed of one tile, it may also be configured as one tile when WPP is on.
[0148] Set the starting CTU address of the tile group (S2604).
[0149] ctbAddrInTile = ctbAddrTs - FirstCtbAddrTs[tile_group_address] In the loop process (loop variable j) for CTUs within a tile, set the CTU address within the tile (S2606) and decode the target CTU (S2608).
[0150] Determine whether WPP is on and whether it is the last CTU in the CTU row, for example, using the following formula (S2610).
[0151] entropy_coding_sync_enabled_flag && ((CtbAddrInTile+1)%TileWidthInCtbsY)==0 If WPP is on and it is the last CTU in the CTU row, proceed to S2612. Otherwise, proceed to the next CTU decoding process. As previously explained, it is possible to derive CtbAddrInTile = j and TileWidthInCtbsY = ColWidth[ TgTileIdx[ i ] % (num_tile_columns_minus1 + 1) ] using the loop variable j indicating the CTU address within the tile. Also, before encoding or decoding the target CTU coding_tree_unit(), it is possible to encode or decode end_of_subset_one_bit with the determination of entropy_coding_sync_enabled_flag && ((CtbAddrInTile)%TileWidthInCtbsY)==0 && CtbAddrInTile!=0.
[0152] Decode end_of_subset_one_bit (S2612). end_of_subset_one_bit is the bit inserted at the end of the CTU row.
[0153] Determine whether it is the last CTU in the tile, for example, using the following formula (S2614).
[0154] j<NumCtusInTile[tileIdx]-1 If it is the last CTU in the tile group, proceed to the next CTU decoding process. Otherwise, decode the bit sequence for byte alignment (S2616).
[0155] Repeat the processes of S2606 to S2616 until the processing of all CTUs within the tile is completed.
[0156] Determine whether WPP is off (S2618). If WPP is not off, end the process. If WPP is off, proceed to S2620.
[0157] Decode end_of_tile_one_bit. end_of_tile_one_bit is the bit inserted at the end of the tile (S2620).
[0158] Determine whether it is the last tile of the tile group (S2622). If it is the last tile of the tile group, end the process. Otherwise, decode the byte-aligned bit sequence (S2624).
[0159] Repeat the above processes until the processing of all tiles within the tile group is completed.
[0160] Note that in the CT information encoding unit 1111, the process of replacing "decoding" in Fig. 26 with "encoding" is performed.
[0161] As described in Fig. 18, the determination in (S2610) and the process in (S2612) may be derived as follows. When represented using the loop variable j which is the tile index within the tile group, after the CT information encoding unit 1111 or the CT information decoding unit 3021 encodes or decodes the target CTUcoding_tree_unit(), if the following equation holds, end_of_subset_one_bit which is the bit sequence indicating the end of the segment (here, the CTU row) may be encoded or decoded.
[0162] if(entropy_coding_sync_enabled_flag && ( (j+1) % ColWidth[ TgTileIdx[ i ] % (num_tile_columns_minus1 + 1) ] == 0 ) ) { end_of_subset_one_bit In the above processing, when using WPP (when entropy_coding_sync_enabled_flag == 1), at the end of each CTU row, a bit and byte alignment indicating the end of the segment are inserted, but for the last CTU row (j == NumCtusInTile[tileIdx] - 1) corresponding to the end of the tile group, the byte alignment is omitted. Since the tile group is composed of CTU rows during WPP, the end of the tile group = the end of the last CTU row. When not using WPP (when entropy_coding_sync_enabled_flag == 0), a bit and byte alignment indicating the end of the segment are inserted at the end of the tile, but for the end of the tile group (i == num_tiles_in_tile_group_minus1), the byte alignment is omitted. This is to avoid duplication with the byte alignment inserted by the trailing data (rbsp_tile_group_trailing_bits) in the configuration including the trailing data for byte alignment after the tile group data, as already explained in Figure 4(c). In a configuration where the byte alignment is not performed by the trailing data, the byte alignment may be inserted within the tile group data even at the end of the tile group.
[0163] In FIGS. 25 and 26, by distinguishing the bit (end_of_subset_one_bit) inserted at the end of the CTU row in the wavefront and the bit (end_of_tile_one_bit) inserted at the end of the tile in the tile, the wavefront and the tile can be clearly distinguished.
[0164] As described above, by using either tiles or CTU rows in units of tile groups, multiple processes with parallel processing functions can be executed exclusively within one tile group, resulting in good coding efficiency. Also, the entry points can be commonly used for tiles and CTU rows, and since it is known which of the start address of the tile and the start address of the CTU row the entry point points to for each tile group, the processing is simple.
[0165] FIG. 19 is another example of the syntax structure of the tile group header to be encoded and decoded in the present embodiment. As shown in the figure, the entropy_coding_sync_enabled_flag may be encoded and decoded first, and when the entropy_coding_sync_enabled_flag is 0, that is, when WPP is off, num_tiles_in_tile_group_minus1 may be notified. In this case, the header encoding unit 1110 and the header decoding unit 3020 encode or decode the entropy_coding_sync_enabled_flag, and encode or decode num_tiles_in_tile_group_minus1 when NumTilesInPic is greater than 1 and the entropy_coding_sync_enabled_flag is 0. Otherwise (when NumTilesInPic is 1 or less, or the entropy_coding_sync_enabled_flag is 1), the header encoding unit 1110 and the header decoding unit 3020 set 0 to num_tiles_in_tile_group_minus1.
[0166] (Modification Example 3) Processing when a segment can take a tile and a slice Modification Example 3 describes the case where either a tile or a slice is exclusively used as a segment within a tile group.
[0167] FIG. 20 is a diagram for explaining the exclusive configuration of a tile segment and a slice segment.
[0168] The slice_enabled_flag is a flag indicating whether to use slices as segments (i.e., whether to use slices). Note that CABAC is initialized at the start of a slice. As shown in the figure, when num_tiles_in_tile_group_minus1 is greater than 0, i.e., when there are multiple tiles in a tile group, the slice_enabled_flag can only be 0. In this case, only the tiles are enabled. When num_tiles_in_tile_group_minus1 is 0, i.e., when there is one tile in a tile group, the slice_enabled_flag can be 1. In this case, only the slices are enabled. Finally, when num_tiles_in_tile_group_minus1 is 0 and the entropy_coding_sync_enabled_flag is 0, there is one tile in the tile group. In this case, WPP may be enabled.
[0169] In Variation 3, when the number of tiles in a tile group is 1 (the tile group and the tile are the same), slices can be used as segments, and when this is not the case (the tile group contains multiple tiles), tiles are used as segments. For example, when a picture is divided into four tile groups as shown in FIG. 5, each tile group may be divided into multiple tiles as shown in FIG. 8(a) or into multiple slices as shown in FIG. 8(c). It may also be divided into one tile. That is, when there is one tile in a tile group and it is not divided by CTU rows or slices, the tile group contains one tile.
[0170] In a slice, at the end of the encoded data of a CTU, by notifying a slice end-of-segment flag end_of_slice_segment_flag indicating whether it is the end of the segment, the segment can be ended at any position in the CTU unit. Such a segment whose size can be variable in CTU units is called a slice segment. For example, a slice is used when it is desired to provide a segment delimiter within a specified number of bits. Further, for the purpose of parallel decoding of slices, it may be configured to insert a marker (unique code, start code) at the head of the slice. By using the marker, the moving image decoding apparatus can search for and identify the head position of each slice on the bit stream. Note that in the configuration of inserting a marker at the head of a slice, each time a slice is inserted (that is, when end_of_slice_segment_flag is 1), the tile group may be configured to end. In this configuration, since one slice is included in the tile group, the tile group header is always added at the head of the slice and serves as the marker.
[0171] When encoding or decoding the slice head by a marker, a unique code such as "0x00000100" (32 bits) may be inserted before the slice, and the moving image decoding apparatus may search for the slice head in the encoded data by scanning the encoded data in advance.
[0172] To process tiles and slices in parallel, the head address (entry point) of the tile may be notified by the tile group header. An example of the tile group header is shown in FIG. 21(a). In FIG. 21, slice_enabled_flag is notified. slice_enabled_flag is a flag indicating whether to perform slice division.
[0173] When num_tiles_in_tile_group_minus1 is 0, that is, when there is one tile in the tile group, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the slice_enabled_flag. Otherwise, the slice_enabled_flag is set to 0 (slice off).
[0174] Note that the configuration may be such that num_slices_in_tile_minus1 is not notified in the tile group header.
[0175] The encoding and decoding order of the number of tiles num_tiles_in_tile_group_minus1 and the slice enable flag slice_enabled_flag is not limited to the above. The following processing may be performed.
[0176] (Slice, Tile) When notifying in the order of the slice enable flag slice_enabled_flag and the number of tiles num_tiles_in_tile_group_minus1, the following processing is performed. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the slice_enabled_flag in the tile group header. When the slice_enabled_flag is 0, num_tiles_in_tile_group_minus1 is encoded or decoded. When num_tiles_in_tile_group_minus1 and slice_enabled_flag are not decoded, they are each set to 0.
[0177] The header encoding unit 1110 and the header decoding unit 3020 derive NumEntryPoint. NumEntryPoint is the number of entry points, and when using tiles, num_tiles_in_tile_group_minus1 is set. When NumEntryPoint is greater than 0, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entry point information (offset_len_minus1 and NumEntryPoint entry_point_offset_minus1).
[0178] When the slice is on, the CT information decoding unit 3021 decodes the end_of_slice_segment_flag after decoding one CTU. The end_of_slice_segment_flag is the bit inserted at the end of the CTU row.
[0179] Figure 21(c) is an example of the syntax of the tile group data of the encoded tile group. The figure shows a configuration that encodes or decodes the end_of_slice_segment_flag after decoding one CTU. The end_of_slice_segment_flag is a flag indicating whether it is the end of the slice. If it is 1, it is the end of the slice; otherwise, it is not the end of the slice.
[0180] As described above, by using either tiles or slices in units of tile groups, a plurality of processes with parallel processing functions within one tile group can be executed exclusively, which is efficient.
[0181] (Modification Example 4) Processing when using entry points in slices The following example shows a configuration that designates the start position of a slice on the bitstream by encoding or decoding the start address of the slice as an entry point.
[0182] To process tiles and slices in parallel, the start addresses (entry points) of tiles and slices are notified by a tile group header. In an example of the tile group header shown in Fig. 21(a), num_slices_in_tile_minus1 may be notified after slice_enabled_flag. num_slices_in_tile_minus1 is a value obtained by subtracting 1 from the number of slices in a tile.
[0183] Also, the syntax of the entry point is shown in Fig. 21(b). Fig. 21(c) shows a configuration using slice_enabled_flag and num_slices_in_tile_minus1 for the derivation of NumEntryPoint.
[0184] When num_tiles_in_tile_group_minus1 is 0, that is, when there is one tile in the tile group, the header decoder 3020 decodes slice_enabled_flag and num_slices_in_tile_minus1. Otherwise, slice_enabled_flag is set to 0 (slice off).
[0185] The header decoder 3020 derives NumEntryPoint. NumEntryPoint is the number of entry points. When using slices, num_slices_in_tile_minus1 is set, and when using tiles, num_tiles_in_tile_group_minus1 is set. When NumEntryPoint is greater than 0, the header decoder 3020 decodes the entry point information (offset_len_minus1 and NumEntryPoint entry_point_offset_minus1).
[0186] The processing other than the above is the same as in Modification Example 2.
[0187] Next, the tile group data will be described.
[0188] FIG. 21(c) is an example of the syntax of the tile group data of the encoded tile group. FIG. 21(c) shows a configuration for encoding or decoding the end_of_slice_segment_flag after decoding of 1 CTU is completed. The end_of_slice_segment_flag is a flag (bit) indicating whether it is the end of the slice. If it is 1, it is the end of the slice; otherwise, it is not the end of the slice.
[0189] When the slice is on, the CT information decoding unit 3021 decodes the end_of_slice_segment_flag after decoding of 1 CTU is completed.
[0190] As described above, by using either the tile or the slice in units of tile groups, a plurality of processes with a parallel processing function can be exclusively executed within one tile group, which is efficient. Also, the entry points can be commonly used for the tile and the slice. Since it is known whether the entry point points to the start address of the tile or the start address of the slice for each tile group, the processing is simple. Alternatively, the start of the slice may be notified with a unique marker without using the entry point.
[0191] (Modification Example 5) Segment using tile, CTU row, and slice In Modification Example 5, an example of exclusively setting the tile, CTU row, and slice will be described. FIG. 22 is a diagram for explaining the exclusive configuration of the tile segment, CTU row segment, and slice segment. As shown in the figure, in Modification Example 5, when there are a plurality of tile segments, CTU row segments, slice segments, or a single segment (referred to as a tile here) within the tile group, any one of these cases is taken.
[0192] More specifically, when multiple tiles are included in a tile group, tiles may be used, and when the tile group consists of one tile, a CTU row or a slice may be used. When the tile group consists of one tile and neither a CTU row nor a slice is used, the tile group is set as one tile.
[0193] (Configured to notify in the order of the number of tiles, WPP enable flag, and slice enable flag) FIG. 23(a) is an example of a tile group header. In the figure, when the number of tiles is 1, the entropy_coding_sync_enabled_flag is notified, and when the entropy_coding_sync_enabled_flag is 0 (WPP off), the slice_enabled_flag is notified.
[0194] The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entropy_coding_sync_enabled_flag when num_tiles_in_tile_group_minus1 is 0. Next, when the entropy_coding_sync_enabled_flag is 0, the slice_enabled_flag is encoded or decoded. When num_tiles_in_tile_group_minus1 is not 0, the entropy_coding_sync_enabled_flag and the slice_enabled_flag are set to 0. When num_tiles_in_tile_group_minus1 is 0 and the entropy_coding_sync_enabled_flag is other than 0, the slice_enabled_flag is set to 0.
[0195] The processing other than these is the same as the example where the segment is only tiles.
[0196] FIG. 23(b) is an example of the syntax of tile group data of an encoded tile group. As shown in the figure, in this embodiment, when the segment is a tile and in the case of a CTU row (wavefront), end_of_subset_one_bit which is always 1 at the end of the segment is encoded or decoded. When the segment is a slice, end_of_slice_segment_flag which can take 0 and 1 indicating whether the CTU is the end of the segment is encoded or decoded. Since the method of encoding or decoding end_of_subset_one_bit has already been described in FIG. 18(c), the description is omitted. Also, since the method of encoding or decoding end_of_slice_segment_flag has already been described in FIG. 21(c), the description is omitted.
[0197] As described above, by exclusively using tiles, CTU rows, and slices in units of tile groups, the encoding and decoding processes of segments can be simplified. Also, it has the effect of clarifying the start and end points of the segments. For example, there is no more mixing such as being at the start of a slice, at the start of a tile, and at the start of a CTU row.
[0198] The encoding and decoding order of the number of tiles num_tiles_in_tile_group_minus1, the WPP enable flag entropy_coding_sync_enabled_flag, and the slice enable flag slice_enabled_flag is not limited to the above. It may be processed as follows.
[0199] (Tile, slice, WPP) When notifying in the order of num_tiles_in_tile_group_minus1, slice_enabled_flag, and entropy_coding_sync_enabled_flag, perform the following processing. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes num_tiles_in_tile_group_minus1. When num_tiles_in_tile_group_minus1 is 0, it encodes or decodes slice_enabled_flag. Next, when slice_enabled_flag is 0, it encodes or decodes entropy_coding_sync_enabled_flag. If num_tiles_in_tile_group_minus1, entropy_coding_sync_enabled_flag, and slice_enabled_flag are not decoded, they are each set to 0.
[0200] (WPP, Tile, Slice) When notifying in the order of entropy_coding_sync_enabled_flag, num_tiles_in_tile_group_minus1, and slice_enabled_flag, perform the following processing. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes entropy_coding_sync_enabled_flag with the tile group header. When entropy_coding_sync_enabled_flag is 0, it encodes or decodes num_tiles_in_tile_group_minus1. Next, when num_tiles_in_tile_group_minus1 is 0, it encodes or decodes slice_enabled_flag. If num_tiles_in_tile_group_minus1, entropy_coding_sync_enabled_flag, and slice_enabled_flag are not decoded, they are each set to 0.
[0201] (WPP, Slice, Tile) When notifying in the order of entropy_coding_sync_enabled_flag, slice_enabled_flag, and num_tiles_in_tile_group_minus1, perform the following processing. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes entropy_coding_sync_enabled_flag in the tile group header. If entropy_coding_sync_enabled_flag is 0, it encodes or decodes slice_enabled_flag. Next, if slice_enabled_flag is 0, it encodes or decodes num_tiles_in_tile_group_minus1. If num_tiles_in_tile_group_minus1, entropy_coding_sync_enabled_flag, and slice_enabled_flag are not decoded, they are each set to 0.
[0202] (Slice, Tile, WPP) When notifying in the order of slice_enabled_flag, num_tiles_in_tile_group_minus1, and entropy_coding_sync_enabled_flag, perform the following processing. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes slice_enabled_flag in the tile group header. If slice_enabled_flag is 0, it encodes or decodes num_tiles_in_tile_group_minus1. Next, if num_tiles_in_tile_group_minus1 is 0, it encodes or decodes entropy_coding_sync_enabled_flag. If num_tiles_in_tile_group_minus1, entropy_coding_sync_enabled_flag, and slice_enabled_flag are not decoded, they are each set to 0.
[0203] (Slice, WPP, Tile) When notifying in the order of slice_enabled_flag, entropy_coding_sync_enabled_flag, and num_tiles_in_tile_group_minus1, the following processing is performed. The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes slice_enabled_flag with the tile group header. When slice_enabled_flag is 0, entropy_coding_sync_enabled_flag is encoded or decoded. Next, when entropy_coding_sync_enabled_flag is 0, num_tiles_in_tile_group_minus1 is encoded or decoded. If num_tiles_in_tile_group_minus1, entropy_coding_sync_enabled_flag, and slice_enabled_flag are not decoded, they are each set to 0.
[0204] The entropy decoding unit 301 outputs the inter prediction parameter to the inter prediction parameter decoding unit 303. Also, the intra prediction parameter is output to the intra prediction parameter decoding unit 304. Also, the quantized transform coefficient is output to the inverse quantization / inverse transform unit 311.
[0205] The entropy decoding unit 301 includes a CABAC initialization unit 3011, a CABAC decoding unit 3012, an initialization table 3013, and a spatial prediction storage unit 3015 (including a spatial prediction table 3016). The spatial prediction storage unit 3015 stores the CABAC state in the internal spatial prediction table 3016. The stored CABAC state is referred to and used for initializing the CABAC state during decoding of segments other than the target segment, such as subsequent segments of the target picture. The CABAC decoding unit 3012 decodes the syntax from the encoded data (bitstream) according to the stored CABAC state.
[0206] The entropy decoding unit 301 initializes the CABAC state using the CABAC initialization unit 3011 at the segment start. The CABAC state includes, for example, StateIdx indicating the probability state per context unit, MpsVal indicating which of 0 and 1 has a higher probability, and coefficient StatCoeff. The context is defined for each element of the binary sequence (sequence consisting of 0 and 1) that constitutes the syntax. CABAC (Context-adaptive binary arithmetic coding) estimates the probability of being encoded as 0 or 1 for each context and encodes the binary based on that probability. At this time, it is necessary to set the initial value of the probability StateIdx and MpsVal, which is called CABAC initialization. TableStateIdx, TableMpsVal, and TableStatCoeff are tables composed of StateIdx, MpsVal, and StatCoeff.
[0207] When the segment is a tile, the above CABAC initialization unit 3011 performs initialization of the CABAC state using the initialization table at the upper left CTU of the tile. When the segment is a CTU row (when entropy_coding_sync_enabled_flag is 1, in the case of WPP), it is initialized using the CABAC state stored in the spatial prediction storage unit 3015 at the left end of the CTU row. In the case of WPP, the CABAC state of the second CTU in each CTU row is stored in the spatial prediction storage unit 3015 and used in subsequent segments. When the segment is a slice (when slice_enabled_flag is 1), the CABAC state may be initialized using the initialization table. Here, the determination of the tile boundary may use whether the identifiers of the tiles of adjacent CTUs are different (TileId[CtbAddrTs]!=TileId[CtbAddrTs-1]). Here, the determination of the left end of the CTU row may be (CtbAddrInTile%TileWidthInCtbsY==0). Also, the determination of the slice start may be whether the CTU address CtbAddrRs matches the CTU address at the slice start (CtbAddrRs==slice_segment_address).
[0208] (Configuration to initialize at the beginning of the CTU row of each tile in the tile group) Here, an example will be described in which the CTUs are raster scanned within each individual tile in the tile group, and CABAC initialization is performed at the beginning (left end) of the CTU row in the tile.
[0209] When the WPP valid flag is 1 at the end of parsing the CTU syntax, and at the position of 1 CTU (ctbAddrInTile % TileWidthInCtbsY == 1) from the beginning of the CTU row of each tile in the tile group, the entropy decoding unit 301 according to this embodiment stores the CABAC state (for example, the state TableStateIdx0Wpp, the state TableStateIdx1Wpp, and the value of MPS TableMpsValWpp) in the storage. TableStateIdx0Wpp and TableStateIdx1Wpp are the states of the CTU at the beginning of the CTU row one above the target CTU and the next CTU thereof.
[0210] However, the CTU address within the tile may be derived as follows.
[0211] ctbAddrInTile = ctbAddrTs - FirstCtbAddrTs[tile_group_address] Also, when looping through the CTUs by incrementing the CTU within the tile from j = 0 to the number of CTUs within the tile - 1, the loop variable j may be used as ctbAddrInTile.
[0212] Note that when the WPP valid flag is 1 at the end of parsing the CTU syntax, and when the position of 1 CTU from the start of the CTU row in the picture (CtbAddrInRs % PicWidthInCtbsY == 1) or the tile ID of the current position (TileId[CtbAddrInTs]) is different from the tile ID of the position two before in raster order (TileId[CtbAddrRsToTs[CtbAddrInRs - 2]]), the entropy decoding unit 301 according to this embodiment may store the CABAC state (for example, state TableStateIdx0Wpp, state TableStateIdx1Wpp, and the value of MPS TableMpsValWpp) in storage.
[0213] Note that in order to achieve lower latency, when it is the start position of the CTU row of the tile (ctbAddrInTile % TileWidthInCtbsY == 0), the CABAC state may be stored.
[0214] For example, when the WPP valid flag is 1 at the end of parsing the CTU syntax, and when the start position of the CTU row in the picture (CtbAddrInRs % PicWidthInCtbsY == 1) or the tile ID of the current position (TileId[CtbAddrInTs]) is different from the tile ID of the position one before in raster order (TileId[CtbAddrRsToTs[CtbAddrInRs - 1]]), the entropy decoding unit 301 according to this embodiment may store the CABAC state (for example, state TableStateIdx0Wpp, state TableStateIdx1Wpp, and the value of MPS TableMpsValWpp) in storage.
[0215] Also, when the WPP valid flag is 1, the entropy decoding unit 301 according to this embodiment may perform initialization using the CABAC state held in storage at the start CTU (CtbAddrInRs % PicWidthInCtbsY == 0) of the CTU row of each tile in the tile group.
[0216] Also, when the WPP valid flag is 1, the entropy decoding unit 301 according to this embodiment may perform initialization using the CABAC state held in storage if the leading CTU in the next CTU line (CtbAddrInRs % PicWidthInCtbsY == 0) or the tile ID at the current position (TileId[ CtbAddrInTs]) is different from the tile ID at the position one before in raster order (TileId[ CtbAddrRsToTs[CtbAddrInRs-1]]).
[0217] (Configuration for initializing at the beginning of each CTU row in each tile group) Here, an example of performing CABAC initialization at the beginning (left end) of each CTU row in the tile group by raster scanning the CTUs in the tile group will be described.
[0218] When the parsing of the CTU syntax ends, the entropy decoding unit 301 according to this embodiment, when the WPP valid flag is 1 and at the position of 1 CTU (ctbAddrInTileGroup % TileGroupWidthInCtbsY== 1) from the beginning of each CTU row of each tile in the tile group, stores the CABAC state (for example, state TableStateIdx0Wpp, state TableStateIdx1Wpp, and the value of MPS TableMpsValWpp) in storage.
[0219] However, the CTU address within the tile group may be derived as follows ctbAddrInTileGroup = ctbAddrTs - FirstCtbAddrTs[tile_group_address] Also, when performing loop processing on the CTUs by incrementing the CTUs within the tile from j = 0 to the number of CTUs within the tile group - 1, the loop variable j may be used as ctbAddrInTileGroup.
[0220] In order to achieve lower latency, the CABAC state may be saved when the starting position of the CTU row of the tile (ctbAddrInTileGroup % TileGroupWidthInCtbsY == 0).
[0221] For example, when the parsing of the CTU syntax ends and the WPP enable flag is 1 and the starting position of the CTU row in the tile group (ctbAddrInTileGroup % TileGroupWidthInCtbsY == 0), the entropy decoder 301 according to this embodiment may save the CABAC state (for example, state TableStateIdx0Wpp, state TableStateIdx1Wpp, and the value of MPS TableMpsValWpp) to storage.
[0222] Also, when the WPP enable flag is 1, the entropy decoder 301 according to this embodiment may perform initialization using the CABAC state held in storage at the starting CTU (ctbAddrInTileGroup % TileGroupWidthInCtbsY == 0) of the CTU row in the tile group.
[0223] The loop filter 305 is a filter provided within the encoding loop, and is a filter that removes block distortion and ringing distortion to improve image quality. The loop filter 305 performs filtering such as a deblocking filter, sample adaptive offset (SAO), and adaptive loop filter (ALF) on the decoded image of the CU generated by the adder 312.
[0224] (Rectangular tile group) FIG. 27 is a diagram for explaining a tile group including a rectangular tile group. A tile group is a technique of dividing a picture into a plurality of tiles and then grouping and transmitting the plurality of tiles. By grouping and transmitting tiles and transmitting a header in units of groups, the overhead of the header can be reduced. Further, even when extracting in units of tile groups, since it can be divided into tiles within the tile group, parallel processing is possible. The tile group may be a rectangular tile group or not a rectangular tile group, and is identified by 1 and 0 using the syntax element rect_tile_group_flag described later.
[0225] A rectangular tile group is one that groups tiles according to the definition of a parameter set, and can set a tile area that is not necessarily continuous in raster scan order. Further, it has a feature that a specific tile or tile group can be extracted without rewriting the tile group header. In addition, other than a rectangular tile group (continuous tiles) is one that groups tiles according to the definition of a tile group header, and is limited to tiles that are continuous in raster scan order.
[0226] FIG. 27(a) is a diagram showing a tile group when it is not a rectangular tile group (rect_tile_group_flag == 0). When it is not a rectangular tile group, the syntax element num_tiles_in_tile_group_minus1 indicating the number of tiles grouped as a tile group is transmitted. num_tiles_in_tile_group_minus1 + 1 tiles are grouped. In FIG. 27(a), when there are 3×2 tiles, an example is shown in which the first 3 consecutive tiles are TileGroup0, the next 2 consecutive tiles are TileGroup1, and the next 1 tile is TileGroup2.
[0227] Figure 27(b) is a diagram showing a tile group in the case of a rectangular tile group (rect_tile_group_flag == 1). In the case of a rectangular tile group, the syntax element top_left_tile_idx indicating the tile located at the upper left of the rectangular area and the syntax element bottom_right_tile_idx indicating the tile located at the lower right are transmitted, and the tiles represented by the two elements are grouped. In Figure 27(b), when there are 3×2 tiles, an example is shown where the 2×2 tiles on the left are TileGroup0, the 1×1 tile is TileGroup2, and the 1×1 tile is TileGroup2.
[0228] Figure 28 is a diagram showing the syntax configuration of the parameter set of the tile group in one form of this embodiment.
[0229] single_tile_in_pic_flag indicates whether there is one tile in the picture. When single_tile_in_pic_flag == 1, the entire picture is processed as one tile, and no more syntax elements are transmitted.
[0230] num_tile_columns_minus1 and num_tile_rows_minus1 are syntax elements transmitted when single_tile_in_pic_flag == 0, and indicate the number of columns and rows of the tiles in the picture.
[0231] uniform_tile_spacing_flag is a syntax element indicating whether to implicitly derive the size of each tile from the number of tile columns and rows. When uniform_tile_spacing_flag == 1, the tile size is implicitly derived.
[0232] tile_column_width_minus1 and tile_row_height_minus1 are syntax elements transmitted when uniform_tile_spacing_flag == 0, and explicitly indicate the horizontal and vertical tile sizes.
[0233] The single_tile_per_tile_group_flag is a syntax element indicating whether to use one tile per tile group. When the single_tile_per_tile_group_flag does not appear in the encoded data (for example, when single_tile_in_pic_flag = 1), the single_tile_per_tile_group_flag may be derived as 1 (infer rule 1).
[0234] The rect_tile_group_flag is a syntax element indicating whether to use a rectangular tile group as the tile group. When rect_tile_group_flag = 1, it indicates using a rectangular tile group. In this case, in the picture parameter set, information regarding the tile group (num_tile_groups_in_pic_minus1, top_left_tile_idx, bottom_right_tile_idx) is transmitted. When single_tile_per_tile_group_flag is 1, that is, when using one tile per tile group, the rect_tile_group_flag is not decoded from the encoded data and the rect_tile_group_flag is derived as 1 (infer rule 2).
[0235] num_tile_groups_in_pic_minus1 is a syntax element indicating the number of tile groups in a picture. For each tile group, the tiles included in the tile group are specified by transmitting top_left_tile_idx and bottom_right_tile_idx. In the PPS, when the number of tiles in a tile group is specified as 1 (when single_tile_per_tile_group_flag is 1), num_tile_groups_in_pic_minus1 is not decoded. When num_tile_groups_in_pic_minus1 is not decoded (does not appear), num_tile_groups_in_pic_minus1 is set to 0.
[0236] top_left_tile_idx is a syntax element indicating the index of the top-left tile of a tile group. bottom_right_tile_idx is a syntax element indicating the index of the bottom-right tile of a tile group.
[0237] The encoded data of a tile group consists of header information tile_group_header() and data information tile_group_data(). The tile_group_header() shown in Figure 29 transmits information common to the tiles in the tile group. Regarding the tiles, it may include the syntax elements tile_group_address and num_tiles_in_tile_group_minus1. Here, tile_group_address is included when it is not a rectangular tile group and indicates the tile index at the beginning of the tile group. num_tiles_in_tile_group_minus1 is included when it is not a rectangular tile group and indicates the number of tiles included in the tile group. When it is not a rectangular tile group, the tile group is composed of num_tiles_in_tile_group_minus1 + 1 consecutive tiles.
[0238] In addition, as a syntax element common to tile groups, tile_group_type may be included. tile_group_type corresponds to slice_type in the conventional coding syntax and identifies whether the tile group consists of only intra prediction coded data or inter prediction coded data. Even in the inter prediction coded data, it may be possible to identify a P picture that generates a predicted image from one reference picture and a B picture that generates a predicted image from two or more reference pictures.
[0239] (Tile Group and WPP Enable Flag) Both the tiles and WPP (CTU rows) in the tile group divide the tile group into segments and perform parallel processing in segment units. Intra prediction between segments is basically prohibited for tiles and basically permitted for CTU rows. Except for the head of the tile group, an entry point for indicating the byte position of the bitstream is transmitted at the head of the segment.
[0240] Configurations include the following. · Syntax for notifying the WPP enable flag entropy_coding_sync_enabled_flag · Value restriction or decoding restriction of the WPP enable flag · CTU scan order within the tile group (tile-based CTU scan order (tile scan) or tile-group-based CTU scan order) Hereinafter, the configuration for notifying the WPP enable flag entropy_coding_sync_enabled_flag in the tile group will be described, and then the configuration for notifying the entropy_coding_sync_enabled_flag in the picture parameter set will be described. The value restriction or decoding restriction of the WPP enable flag and the CTU scan order will be described as sub-configurations of each configuration.
[0241] <Configuration for Transmitting the WPP Enable Flag in the Tile Group> FIG. 30 is a diagram showing the relationship between a tile group of one form of the present embodiment and wavefront processing (CTU row segment). Here, the scan order of CTUs is the tile scan order, and raster scanning of CTUs is performed in tile units. In this figure, in the case where there are 4×3 tiles in a picture, an example is shown in which the 2×3 tiles on the left are configured as TileGroup0, the 2×1 tiles in the upper right are configured as TileGroup1, the 1×1 tile is configured as TileGroup2, the 1×1 tile is configured as TileGroup3, and the 1×2 tile is configured as TileGroup4. TileGroup2 composed of 1×1 tiles is a tile group in which wavefront processing (WPP) is on. That is, TileGroup2 is further divided into segments composed of CTU rows in the tile (tile group) and encoded. Note that tile indexes in the picture are assigned in raster scan order.
[0242] FIG. 31 is a diagram showing the syntax configuration of the header of the tile group and wavefront processing of one form of the present embodiment. Parts that are the same as the syntax elements described in FIG. 29 are omitted from the description. In the present embodiment, when the number of tiles in the tile group is 1, the entropy_coding_sync_enabled_flag is included in the encoded data and transmitted.
[0243] The header encoding unit 1110 or the header decoding unit 3020 encodes or decodes information on tiles included in the tile group using a parameter set or a tile group header. Specifically, when rect_tile_group_flag = 1, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes top_left_tile_idx and bottom_right_tile_idx, and when rect_tile_group_flag = 0, decodes tile_group_address and num_tiles_in_tile_group_minus1.
[0244] When rect_tile_group_flag = 1, the header encoding unit 1110 and the header decoding unit 3020 derive the number of tiles NumTilesInTileGroup included in the tile group from top_left_tile_idx and bottom_right_tile_idx according to the following pseudo-code. That is, by dividing the difference deltaTileIdx between the top-left tile index and the bottom-right tile index by the number of tile rows (num_tile_columns_minus1 + 1) in the picture, the number of tile rows (the number of vertical tiles) NumTileRowsInTileGroupMinus1 and the number of tile columns (the number of horizontal tiles) NumTileColumnsInTileGroupMinus1 of the tile group are derived. NumTilesInTileGroup is derived from the product of the number of horizontal tiles and the number of vertical tiles. Specifically, the difference deltaTileIdx[i] between the top-left tile index top_left_tile_idx[i] and the bottom-right tile index bottom_right_tile_idx[i] is derived. I is the identifier of the tile group. deltaTileIdx[i] = bottom_right_tile_idx[i]-top_left_tile_idx[i] Subsequently, the number of horizontal tiles and the number of vertical tiles of the tile group are derived from the difference deltaTileIdx[i] and the number of horizontal tiles (num_tile_columns_minus1 + 1) in the picture. Here, a value obtained by subtracting 1 from the number of tiles is derived. NumTileRowsInTileGroupMinus1[i] = (deltaTileIdx[i] / (num_tile_columns_minus1+1)) NumTileColumnsInTileGroupMinus1[i] = (deltaTileIdx[i]%(num_tile_columns_minus1+1)) Finally, the number of tiles NumTilesInTileGroup[i] in the tile group is derived from the product of the tile width and height of the tile group. NumTilesInTileGroup[i] = (NumTileRowsInTileGroupMinus1[i] + 1) * (NumTileColumnsInTileGroupMinus1[i] + 1) For example, in the example of FIG. 30, since the picture is a 4×3 tile, num_tile_columns_minus1 + 1 = 4. The top-left tile index top_left_tile_idx[i] and the bottom-right tile index bottom_right_tile_idx[i] of each tile group i = 0..4 are as follows. top_left_tile_idx[0] = 0, bottom_right_tile_idx[0] = 9 top_left_tile_idx[1] = 2, bottom_right_tile_idx[1] = 3 top_left_tile_idx[2] = 6, bottom_right_tile_idx[2] = 6 top_left_tile_idx[3] = 7, bottom_right_tile_idx[3] = 11 top_left_tile_idx[4] = 10, bottom_right_tile_idx[4] = 10 Therefore, TileGroup0 is NumTileRowsInTileGroupMinus1[0] = deltaTileIdx[0] = bottom_right_tile_idx[0] - top_left_tile_idx[0] / (num_tile_columns_minus1 + 1) = (9 - 0) / 4 = 2 NumTileColumnsInTileGroupMinus1[0] = (9 - 0) % 4 = 1 NumTilesInTileGroup[0] = (1 + 1) * (2 + 1) = 6 TileGroup1 is NumTileRowsInTileGroupMinus1[1] = (3 - 2) / 4 = 0 NumTileColumnsInTileGroupMinus1[1] = (3 - 2)%4 = 1 NumTilesInTileGroup[1] = (0 + 1)*(1 + 1) = 2 It is derived as follows. TileGroup2 is NumTileRowsInTileGroupMinus1[2] = (6 - 6) / 4 = 0 NumTileColumnsInTileGroupMinus1[2] = (6 - 6)%4 = 0 NumTilesInTileGroup[2] = (0 + 1)*(0 + 1) = 1 It is derived as follows. TileGroup3 is NumTileRowsInTileGroupMinus1[3] = (11 - 7) / 4 = 1 NumTileColumnsInTileGroupMinus1[3] = (11 - 7)%4 = 0 NumTilesInTileGroup[2] = (1 + 1)*(0 + 1) = 2 It is derived as follows. TileGroup4 is NumTileRowsInTileGroupMinus1[4] = (10 - 10) / 4 = 0 NumTileColumnsInTileGroupMinus1[4] = (10 - 10)%4 = 0 NumTilesInTileGroup[4] = (0 + 1)*(0 + 1) = 1 It is derived as follows.
[0245] Furthermore, the header encoding unit 1110 and the header decoding unit 3020 may derive the index TgTileIdx[tIdx] of the tiles within the tile group as follows. Here, TgTileIdx[tIdx] is a table that derives the index tileIdx of the tiles within the picture from the index tIdx of the tiles within the tile group.
[0246] tileGroupIdx = 0 while( tile_group_address != rect_tile_group_id[ tileGroupIdx ] ) tileGroupIdx++ NumTilesInCurrTileGroup = NumTilesInTileGroup[tileGroupIdx] tileIdx = top_left_tile_idx[tileGroupIdx] for(j=0, tIdx=0; j<(NumTileRowsInTileGroupMinus1[tileGroupIdx]+1); j++, tileIdx+=num_tile_columns_minus1+1) { for(i=0, currTileIdx=tileIdx; i<(NumTileColumnsInTileGroupMinus1[tileGroupIdx]+1); i++, currTileIdx++, tIdx++) { TgTileIdx[tIdx] = currTileIdx } } When rect_tile_group_flag == 0, the header encoding unit 1110 and the header decoding unit 3020 derive the number of tiles NumTilesInTileGroup included in the tile group and the index TgTileIdx[tIdx] of the tiles within the tile group from num_tiles_in_tile_group_minus1 according to the following pseudo code.
[0247] NumTilesInTileGroup = num_tiles_in_tile_group_minus1+1 TgTileIdx[0] = tile_group_address for(i=1; i<NumTilesInTileGroup; i++) TgTileIdx[i] = TgTileIdx[i-1]+1 Furthermore, the header encoding unit 1110 and the header decoding unit 3020 may derive the number of tiles included in the target tile group by the following formula when encoding and decoding the tile group header by the following formula.
[0248] NumTilesInCurrTileGroup = rect_tile_group_flag? NumTilesInTileGroup[tileGroupIdx] : (num_tiles_in_tile_group_minus1+1) When the number of tiles NumTilesInCurrTileGroup included in the tile group is 1, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entropy_coding_sync_enabled_flag.
[0249] As shown in FIG. 30, within a picture, scanning is performed in the order of each tile group. Within a tile group, each tile is scanned in raster order, and within each tile, CTBs (CTUs) are scanned in raster order (tile scan). The method for deriving the above tile scan order is as already described (in the method for deriving the CTU scan order within a picture 1). In tile groups with WPP off (entropy_coding_sync_enabled_flag == 0) (TileGroup0, TileGroup1, TileGroup3, TileGroup4), the segment is in units of tiles, and in the tile group with WPP on (entropy_coding_sync_enabled_flag == 1) (TileGroup2), the segment is in units of CTU rows within a tile. Except for the first segment of a tile group, an entry point is encoded or decoded. That is, in a tile group when WPP is off, there are NumTilesInCurrTileGroup - 1 entry points, and when WPP is on, there are TileGroupHeightInCtbsY - 1 entry points, where TileGroupHeightInCtbsY is the number of CTU rows within a tile. The entry points are notified at the positions shown in FIG. 30.
[0250] When WPP is on (entropy_coding_sync_enabled_flag == 1), the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes NumEntryPoint (= TileGroupHeightInCtbsY - 1, where TileGroupHeightInCtbsY is the number of CTU rows included in the tile group) entry points. When WPP is off (entropy_coding_sync_enabled_flag == 0), it encodes or decodes NumEntryPoint (= NumTilesInCurrTileGroup - 1, where NumTilesInCurrTileGroup is the number of tiles in the tile group) entry points. The number of entry points may be derived by the following formula.
[0251] Here, when the number of tiles included in the target tile group is 1, the number of CTU rows TileGroupHeightInCtbsY (the height of the target tile in CTU units TileHeightInCtbsY) included in the target tile group may be derived by the following formula.
[0252] ctbAddrInTs = FirstCtbAddrTs[tileIdx] CtbAddrInRs = CtbAddrTsToRs[ctbAddrInTs] tbX = CtbAddrInRs % PicWidthInCtbsY tbY = CtbAddrInRs / PicWidthInCtbsY for(j = 0; j <= num_tile_rows_minus1; j++) if(tbY >= RowBd[j]) tileY = j TileGroupHeightInCtbsY = RowHeight[tileY] TileGroupHeightInCtbsY also refers to the number of CTUs indicating the height of the tile group, and TileHeightInCtbsY also refers to the number of CTUs indicating the height of the tile.
[0253] Also, considering the case where the number of tiles in the tile group is not 1, the number of CTUs indicating the height of the tile group, TileGroupHeightInCtbsY, may be derived as follows by adding the height RowHeight of each tile in the tile group. For example, add the height RowHeight of each tile for the number of tiles (NumTileRowsInTileGroupMinus1[tileGroupIdx]+1) of the height of the tile group.
[0254] tbX = CtbAddrInRs % PicWidthInCtbsY tbY = CtbAddrInRs / PicWidthInCtbsY for(j = 0; j <= num_tile_rows_minus1; j++) if(tbY >= RowBd[j]) tileY = j TileHeightInCtbsY = RowHeight[tileY] TileGroupHeightInCtbsY = 0 for(j = 0; j < (NumTileRowsInTileGroupMinus1[tileGroupIdx] + 1); j = j + 1) TileGroupHeightInCtbsY += RowHeight[tileY + j] Here, tileY is a value indicating the position in the picture (or sub - picture) of the top - left tile of the target tile group, and it may be derived by the method described above. Note that tileY is a value in tile units.
[0255] (Derivation of TileGroupWidthInCtbsY) The number of CTUs indicating the width of the tile group, TileGroupWidthInCtbsY, may be derived as follows. For example, add the height ColWidth of each tile for the number of tiles (NumTileColsInTileGroupMinus1[tileGroupIdx] + 1) in the width of the tile group.
[0256] tbX = CtbAddrInRs % PicWidthInCtbsY tbY = CtbAddrInRs / PicWidthInCtbsY for(i = 0; i <= num_tile_columns_minus1; i++) if(tbX >= ColBd[i]) tileX = i TileWidthInCtbsY = ColWidth[tileX] TileGroupWidthInCtbsY = 0 for(j = 0; j < (NumTileColsInTileGroupMinus1[tileGroupIdx] + 1); j = j + 1) TileGroupWidthInCtbsY += ColWidth[tileX + j] Here, tileX is a value indicating the position in the picture (or sub-picture) in terms of tiles of the top-left tile of the target tile group, and it may be derived by the method described above.
[0257] With the above configuration, in one tile group (within the segment group), the effect that the entry points of the tile and the wavefront can be shared is achieved.
[0258] Also, in a certain tile group, it is possible to enable tiles (multiple tiles), and in another tile group, it is possible to enable the wavefront.
[0259] (Configuration enabling the use of WPP in the case of a rectangular tile group or when the number of tiles is 1) FIG. 32 is a diagram showing the relationship between the tile group and the wavefront processing (CTU row segment) of one form of the present embodiment. In the example of FIG. 30, the use of WPP was limited to the case where the number of tiles in the tile group was 1, but in this example, WPP can be used in the case of a rectangular tile group or when the number of tiles in the tile group is 1. In this figure, an example where the rectangular tile group is valid and WPP is enabled in TileGroup0, TileGroup2, and TileGroup4 is shown. In TileGroup0 and TileGroup4, although a plurality of tiles are included in the tile group, WPP is turned on within the tiles. Regardless of whether WPP is on or off, the tile groups are scanned in raster order for each tile, and further, the CTUs are scanned in raster order within each tile (tile scan order).
[0260] FIG. 33 is a diagram showing the syntax configuration of the headers of the tile group and the wavefront processing of one form of the present embodiment. FIG. 35(a) is a diagram for explaining the operations of the header encoding unit 1110 and the header decoding unit 3020 having an exclusive configuration of the tile and the wavefront.
[0261] As shown in the syntax structure of the figure and the flowchart, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entropy_coding_sync_enabled_flag (S3002) when the number of tiles in the picture is 1 (single_tile_in_pic_flag==1), or in the case of a rectangular tile group (rect_tile_group_flag==1), or when NumTilesInCurrTileGroup==1 (YES in S3001). Otherwise, the entropy_coding_sync_enabled_flag is set to 0 (WPP off).
[0262] if (single_tile_in_pic_flag || rect_tile_group_flag || NumTilesInCurrTileGroup==1) entropy_coding_sync_enabled_flag As shown in FIG. 32, within a picture, each tile group is scanned in order. Within a tile group, each tile is scanned in raster scan order, and within each tile, the CTUs are scanned in raster scan order. The segments are at the tile unit level for tile groups with WPP off (entropy_coding_sync_enabled_flag==0) (TileGroup1, TileGroup3), and at the CTU row unit level within a tile for tile groups with WPP on (entropy_coding_sync_enabled_flag==1) (TileGroup0, TileGroup2, TileGroup4). Except for the first segment of a tile group, the entry points are encoded or decoded. That is, there are number of tiles - 1 entry points for tile groups with WPP off, and number of CTU rows within a tile - 1 entry points for the case of WPP on. The entry points are as shown in FIG. 32.
[0263] When WPP is on (entropy_coding_sync_enabled_flag == 1), the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes -1 entry points which is the product of the number of horizontal tiles NumTileColumnsInTileGroupMinus1 + 1 included in the tile group and the number of CTU rows TileGroupHeightInCtbsY. Also, when WPP is off (entropy_coding_sync_enabled_flag == 0), it encodes or decodes -1 entry points which is the number of tiles NumTilesInCurrTileGroup - 1 in the tile group. The number of entry points may be derived by the following formula.
[0264] NumEntryPoint = entropy_coding_sync_enabled_flag? (NumTileColumnsInTileGroupMinus1+1)*TileGroupHeightInCtbsY-1 : NumTilesInCurrTileGroup-1 According to the above configuration, since the tiles in the tile group can be further divided into segments of CTU rows for processing, there is an effect that the degree of parallelism can be increased.
[0265] Also, since it is possible to select whether to further divide the tiles in the tile group into segments of CTU rows for each tile group, there is an effect that the degree of parallelism can be freely selected.
[0266] Also, the ability to divide the tiles in the tile group into segments of CTU rows is limited to the case of a rectangular tile group or when the number of tiles in the tile group is 1. Therefore, when the tile group is not rectangular, there is an effect of preventing the processing from becoming complicated by dividing it into CTU row segments.
[0267] (Configuration enabling the use of WPP in the case of a rectangular tile group) FIG. 34 is a diagram showing the syntax configuration of the tile group and the wavefront processing header in one form of this embodiment. FIG. 35(b) is a diagram for explaining the operations of the header encoding unit 1110 and the header decoding unit 3020 having an exclusive configuration of the tile and the wavefront.
[0268] As shown in the figure, when the number of tiles in the picture is 1 (single_tile_in_pic_flag == 1) or a rectangular tile group (rect_tile_group_flag == 1), the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entropy_coding_sync_enabled_flag (S3012). Otherwise, the entropy_coding_sync_enabled_flag is set to 0 (WPP off).
[0269] if (single_tile_in_pic_flag || rect_tile_group_flag) entropy_coding_sync_enabled_flag Also, when single_tile_in_pic_flag is 1, the header decoding unit 3020 may derive rect_tile_group_flag as 1. For example, when single_tile_per_tile_group_flag does not appear in the encoded data (for example, when single_tile_in_pic_flag = 1), single_tile_per_tile_group_flag may be derived as 1, and when single_tile_per_tile_group_flag is the case, rect_tile_group_flag may be derived as 1. In this case, when the rectangular tile group (rect_tile_group_flag == 1), the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes the entropy_coding_sync_enabled_flag (S3012). Otherwise, the entropy_coding_sync_enabled_flag is set to 0 (WPP off).
[0270] if (rect_tile_group_flag) entropy_coding_sync_enabled_flag According to the above configuration, since the tiles within the tile group can be further divided into segments of CTU rows for processing, there is an effect that the number of parallel operations can be increased.
[0271] Also, the fact that the tiles within the tile group can be divided into segments of CTU rows is limited to rectangular tile groups. Therefore, when the tile group is not rectangular, it has the effect of preventing the processing from becoming complicated by dividing it into CTU row segments. (Tile-based CTU scan order) FIG. 37 is a flowchart diagram showing a method for deriving the tile-based CTU scan order. The CT information decoding unit 3021 (or the parameter decoding unit 302) or the CT information encoding unit 1111 (or the header encoding unit 1110) may derive CtbAddrRsToTs[] by the following processing.
[0272] (S201) tileGroupTLCol = top_left_tile_idx[i] % (num_tile_columns_minus1+1) tileGroupTLRow = top_left_tile_idx[i] / (num_tile_columns_minus1+1) tileGroupXInCtbY = 0 tileGroupYInCtbY = 0 for (j=0; j<tileGroupTLCol; j++) tileGroupXInCtbY = tileGroupXInCtbY+ColWidth[j] for (j=0; j<tileGroupTLRow; j++) tileGroupYInCtbY = tileGroupYInCtbY+RowHeight[j] tileYInCtb = tileGroupYInCtbY (S202) for (row = 0; row <= NumTileRowsInTileGroupMinus1[i]; row++) { / / TileRasterScanInTileGroup tileYInCtb = tileYInCtb + RowHeight[tileGroupTLRow + row] tileXInCtb = tileGroupXInCtbY for (col = 0; col <= NumTileColsInTileGroupMinus1[i]; col++) { / / TileRasterScanInTileGroup tileXInCtb = tileXInCtb + ColWidth[tileGroupTLCol + col] (S203) for (y = 0; y < RowHeight[tileGroupTLRow + row]; y++) { / / CtbRasterScan in Tile for (x = 0; x < ColWidth[tileGroupTLCol + col]; x++) { / / CtbRasterScan in Tile (S204) ctbAddrRs = (x + tileXInCtb) + (y + tileYInCtb) * PicHeightInCtbsY (S205) CtbAddrRsToTs[ctbAddrRs] = ctbAddrTs CtbAddrTsToRs[ctbAddrTs] = ctbAddrRs (S206) ctbAddrTs++ } } } } S201: Derive the upper - left tile addresses tileGroupTLCol and tileGroupTLRow of the tile group. Derive the upper - left CTU addresses tileGroupXInCtbY and tileGroupYInCtbY of the tile group.
[0273] S202: Use the height (NumTileRowsInTileGroupMinus1) and width (NumTileColumnsInTileGroupMinus1) of the tile group in tile units to raster - scan the tiles of the target tile group.
[0274] S203: Use the height ColHeight and ColWidth in CTU units of the tile to raster - scan the CTUs within the tile.
[0275] S204: Derive the raster - scan CTU address ctbAddrRs within the picture of the target CTU from the X - coordinate (x + tileGroupXInCtbY) and Y - coordinate (y + tileGroupYInCtbY) in CTU units within the picture.
[0276] S205: Store the CTU address in the table that associates ctbAddrRs and ctbAddrTs. Here, both CtbAddrRsToTs[] and CtbAddrTsToRs[] are derived, but only one of them (for example, CtbAddrRsToTs[]) can be derived, and the other (CtbAddrTsToRs[]) can be derived using (Derivation method 0 of the CTU scan order within the picture).
[0277] S206: Increment ctbAddrTs by 1.
[0278] In this example, when the number of rectangular tile groups or tiles in a tile group is 1, WPP can be used. Figure 36 shows examples where WPP is enabled for rectangular tile groups, namely TileGroup0, TileGroup2, and TileGroup4. Also, when enabling WPP for a rectangular tile group, instead of scanning CTUs in raster scan order within a tile, CTUs are scanned in raster scan order within the tile group. That is, the scan order of the 2×3 tiles in TileGroup0 is as follows. When WPP is off, the tile group is scanned row by row for each tile, and then the CTUs are scanned row by row within each tile. When WPP is on, CTUs are scanned for each tile group unit without distinguishing the tiles within the tile group. For example, if the CTUs in a picture are arranged in raster order as follows and each tile is composed of 3x3 CTUs, 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 When WPP is off, the CTU scan order of TileGroup0 is as follows.
[0279] 0 1 2 12 13 14 24 25 26 3 4 5 15 16 17 27 28 29 36 37 38 48 49 50 60 61 62 39 40 41 51 52 53 63 64 65 72 73 74 84 85 86 96 97 98 75 76 77 87 88 89 99 100 101 When WPP is on, the CTU scan order of TileGroup0 is as follows.
[0280] 0 1 2 3 4 5 12 13 14 15 16 17 24 25 26 27 28 29 36 37 38 39 40 41 48 49 50 51 52 53 60 61 62 63 64 65 72 73 74 75 76 77 84 85 86 87 88 89 96 97 98 99 100 101 FIG. 39 is a diagram showing the syntax configuration of the tile group and the header of wavefront processing according to one form of the present embodiment.
[0281] Furthermore, the header encoding unit 1110 and the header decoding unit 3020 may derive the number of tiles included in the target tile group by the following formula when encoding and decoding the tile group header by the following formula.
[0282] NumTilesInCurrTileGroup = rect_tile_group_flag? NumTilesInTileGroup[ tileGroupIdx ] : (num_tiles_in_tile_group_minus1 + 1) The header encoding unit 1110 and the header decoding unit 3020 encode or decode the entropy_coding_sync_enabled_flag when the number of tiles in the picture is 1 (single_tile_in_pic_flag == 1) or in the case of a rectangular tile group (rect_tile_group_flag == 1) or when the number of tiles NumTilesInCurrTileGroup included in the tile group is 1.
[0283] if (single_tile_in_pic_flag || rect_tile_group_flag || NumTilesInCurrTileGroup == 1) entropy_coding_sync_enabled_flag Note that the header encoding unit 1110 and the header decoding unit 3020 may be configured to encode or decode the entropy_coding_sync_enabled_flag when the number of tiles in the picture is 1 (single_tile_in_pic_flag == 1) or in the case of a rectangular tile group (rect_tile_group_flag == 1).
[0284] if (single_tile_in_pic_flag || rect_tile_group_flag) entropy_coding_sync_enabled_flag (Method 2 for deriving the CTU scan order within a picture, tile group-based CTU scan order) When the entropy_coding_sync_enabled_flag notified in the picture parameter set is on, the CT information decoding unit 3021 may derive CtbAddrRsToTs[] by the following process. In this derivation method, the picture is scanned in the order of tile groups (TileGroupLoop), and further raster scanned in the order of CTUs within the tile group (CtbRasterScan in TileGroup) to derive the CTU scan order. Fig. 38(b) shows the flowchart of this configuration. When the entropy_coding_sync_enabled_flag notified on a picture-by-picture basis is off, CtbAddrRsToTs[] is derived using the tile-based CTU scan order as already described in the method 1 for deriving the CTU scan order within a picture.
[0285] According to the above configuration, when WPP is on and the tile group is composed of multiple tiles, by changing the CTU scan order, one area combining the tiles within the tile group can be divided into CTU row segments. As a result, the tile group is not divided unnecessarily, so the performance is improved. Also, in the tile group, since the segmentation of the tile and WPP (CTU row) is exclusive, there is an effect that the processing is simplified.
[0286] Note that the configuration of the tile group header is as shown in Fig. 41(a), and is the same as Fig. 39 except that it does not include the entropy_coding_sync_enabled_flag. That is, the number of entry points is derived by the following formula.
[0287] NumEntryPoint = entropy_coding_sync_enabled_flag? TileGroupHeightInCtbsY-1 : NumTilesInCurrTileGroup-1 <Configuration for transmitting the WPP enable flag in the parameter set> Next, a configuration will be described in which the WPP enable flag is notified not by the tile group header but by the parameter set. In the following configuration, at a stage before decoding the tile group, there is a common effect that it can be determined whether parallel decoding of segments is possible. Also, for selecting whether to use WPP on a picture-by-picture basis, there is an effect that the position of the entry point is clear across the entire screen. Further, there is an effect that the ability exchange can be easily performed between the moving image decoding device and the moving image encoding device or the image transmission system.
[0288] (Parameter set transmission + Tile-based CTU scan) FIG. 42 is a diagram showing the syntax configuration of the tile group and the parameter set of wavefront processing according to one embodiment of the present invention. In this configuration, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes one entropy_coding_sync_enabled_flag for a picture in the parameter set instead of the tile group header.
[0289] FIG. 40 is a diagram showing the relationship between the tile group and the wavefront processing (CTU row segment) according to one embodiment of the present invention. FIG. 40 shows an example in which WPP is used for all tile groups, TileGroup0, TileGroup1, TileGroup2, TileGroup3, and TileGroup4. In this configuration, there is an effect that the processing of the decoding device is facilitated for selecting whether to use WPP on a picture-by-picture basis.
[0290] In this embodiment, as described in Derivation Method 1 of the CTU scan order within a picture and in Fig. 37, tile-based scanning (scanning is performed on tiles within a tile group, and CTUs are scanned within a tile) is carried out. Therefore, a tile group is divided into segments having the width of the horizontal tiles included in the tile group and the CTU height. The number of segments of the tile group is the product of the number of horizontal tiles (NumTileColumnsInTileGroupMinus1 + 1) and the number of CTU rows (TileGroupHeightInCtbsY). The configuration of the tile group header is as shown in Fig. 41(b), and the entropy_coding_sync_enabled_flag is not signaled. Instead, the entropy_coding_sync_enabled_flag of the picture parameter set is referred to. Here, the number of entry points equal to the number of segments - 1 is decoded.
[0291] NumEntryPoint = entropy_coding_sync_enabled_flag? (NumTileColumnsInTileGroupMinus1 + 1)*TileGroupHeightInCtbsY - 1 : NumTilesInCurrTileGroup - 1 With this configuration, since whether it is a rectangular tile group can be identified from the picture parameter set, there is an effect that it can be determined whether parallel decoding of segments is possible before decoding the tile group.
[0292] Furthermore, in a decoding apparatus that decodes encoded data with a restriction that the entropy_coding_sync_enabled_flag is set to 1 only when the number of tiles in a picture is 1 or the number of tiles in a tile group is 1, the following number of entry points is decoded as in the configuration of Fig. 41(a).
[0293] NumEntryPoint = entropy_coding_sync_enabled_flag? TileGroupHeightInCtbsY - 1 : NumTilesInCurrTileGroup - 1 In this case, it has the effect that tiles and CTU row segments can be processed exclusively within a tile group.
[0294] (Parameter set transmission + Tile-based CTU scan + Configuration 3 of rectangular tile groups) In the case of a tile group including two or more tiles (tile index is i), in a moving image decoding apparatus that decodes encoded data with entropy_coding_sync_enabled_flag[i] always set to 1, it has the effect that tiles and CTU row segments can be processed exclusively within the tile group.
[0295] In this configuration, a tile group is divided into segments having the CTU height. The number of segments of the tile group is the number of CTU rows (TileGroupHeightInCtbsY). The configuration of the tile group header is as shown in Fig. 41(a), and the entropy_coding_sync_enabled_flag of the picture parameter set is referred to without including the entropy_coding_sync_enabled_flag. Here, entry points of the number of segments - 1 (TileGroupHeightInCtbsY - 1) are decoded.
[0296] NumEntryPoint = entropy_coding_sync_enabled_flag? TileGroupHeightInCtbsY - 1 : NumTilesInCurrTileGroup - 1 (Parameter set transmission + CTU scan order based on tile groups) Hereinafter, in a configuration where the WPP enable flag is notified in a parameter set instead of a tile group header, when the WPP enable flag is 1, a configuration will be described in which the CTU scan order within a tile group is changed from the tile-based CTU scan order to the tile-group-based CTU scan order.
[0297] (Parameter set transmission + CTU scan order based on tile groups) FIG. 42 is a diagram showing the syntax structure of a tile group and a parameter set for wavefront processing according to one form of the present embodiment. In this configuration, the header encoding unit 1110 or the header decoding unit 3020 encodes or decodes one entropy_coding_sync_enabled_flag for a picture in the parameter set instead of the tile group header.
[0298] In this configuration, the tile group is divided into segments having the CTU height. The number of segments of the tile group is the number of CTU rows (TileGroupHeightInCtbsY). The configuration of the tile group header is as shown in FIG. 41(a), and refers to the entropy_coding_sync_enabled_flag of the picture parameter set without including the entropy_coding_sync_enabled_flag. Here, the entry points of the number of segments - 1 (TileGroupHeightInCtbsY - 1) are decoded.
[0299] NumEntryPoint = entropy_coding_sync_enabled_flag? TileGroupHeightInCtbsY-1 : NumTilesInCurrTileGroup-1 The reference picture memory 306 stores the decoded image of the CU generated by the addition unit 312 at a predetermined position for each target picture and target CU.
[0300] The prediction parameter memory 307 stores the prediction parameters at a predetermined position for each CTU or CU to be decoded. Specifically, the prediction parameter memory 307 stores the parameters decoded by the parameter decoding unit 302 and the prediction mode predMode and the like separated by the entropy decoding unit 301.
[0301] The prediction image generation unit 308 is input with prediction parameters and the like. Further, the prediction image generation unit 308 reads a reference picture from the reference picture memory 306. The prediction image generation unit 308 generates a prediction image of a block or a sub-block using the prediction parameters and the reference picture (reference picture block). Here, the reference picture block is a set of pixels on the reference picture (usually a rectangle, so it is called a block), and is an area referred to for generating the prediction image.
[0302] The inverse quantization / inverse transformation unit 311 inverse-quantizes the quantized transform coefficients input from the entropy decoding unit 301 to obtain transform coefficients. These quantized transform coefficients are coefficients obtained by performing frequency conversion such as DCT (Discrete Cosine Transform) on the prediction error and then quantizing it in the encoding process. The inverse quantization / inverse transformation unit 311 performs inverse frequency conversion such as inverse DCT on the obtained transform coefficients to calculate the prediction error. The inverse quantization / inverse transformation unit 311 outputs the prediction error to the addition unit 312.
[0303] The addition unit 312 adds the prediction image of the block input from the prediction image generation unit 308 and the prediction error input from the inverse quantization / inverse transformation unit 311 for each pixel to generate a decoded image of the block. The addition unit 312 stores the decoded image of the block in the reference picture memory 306 and also outputs it to the loop filter 305.
[0304] (Configuration of the moving image encoding device) Next, the configuration of the moving image encoding device 11 according to the present embodiment will be described. FIG. 24 is a block diagram showing the configuration of the moving image encoding device 11 according to the present embodiment. The moving image encoding device 11 includes a prediction image generation unit 101, a subtraction unit 102, a transform / quantization unit 103, an inverse quantization / inverse transformation unit 105, an addition unit 106, a loop filter 107, a prediction parameter memory 109, an encoding parameter determination unit 110, a parameter encoding unit 111, and an entropy encoding unit 104.
[0305] The prediction image generation unit 101 generates a prediction image for each coding unit (CU) which is a region obtained by dividing each picture of the image T. The prediction image generation unit 101 performs the same operation as the prediction image generation unit 308 already described.
[0306] The subtraction unit 102 subtracts the pixel value of the prediction image of the block input from the prediction image generation unit 101 from the pixel value of the image T to generate a prediction error. The subtraction unit 102 outputs the prediction error to the transform and quantization unit 103.
[0307] The transform and quantization unit 103 calculates transform coefficients for the prediction error input from the subtraction unit 102 by frequency transform, and derives quantized transform coefficients by quantization. The transform and quantization unit 103 outputs the quantized transform coefficients to the entropy coding unit 104 and the inverse quantization and inverse transform unit 105.
[0308] The inverse quantization and inverse transform unit 105 is the same as the inverse quantization and inverse transform unit 311 (Fig. 9) in the moving image decoding apparatus 31. The calculated prediction error is output to the addition unit 106.
[0309] The parameter coding unit 111 includes a header coding unit 1110, a CT information coding unit 1111, a CU coding unit 1112 (prediction mode coding unit), an entropy coding unit 104, and an inter prediction parameter coding unit 112 and an intra prediction parameter coding unit 113 (not shown). The CU coding unit 1112 further includes a TU coding unit 1114.
[0310] The following is a description of the general operation of each module. The parameter coding unit 111 performs coding processing of parameters such as header information, segmentation information, prediction information, and quantized transform coefficients.
[0311] The CT information coding unit 1111 codes QT, MT (BT, TT) segmentation information, etc.
[0312] The CU coding unit 1112 codes CU information, prediction information, TU segmentation flag, CU residual flag, etc.
[0313] When the TU contains prediction errors, the TU symbolization unit 1114 encodes QP update information (quantization correction value) and quantization prediction errors (residual_coding).
[0314] The entropy encoding unit 104 converts the syntax elements input from the source into binary data, generates encoded data by an entropy encoding method such as CABAC, and outputs it. In the example shown in FIG. 24, the sources of the syntax elements are the CT information encoding unit 1111 and the CU encoding unit 1112.
[0315] The addition unit 106 adds the pixel values of the predicted image of the block input from the prediction image generation unit 101 and the prediction errors input from the inverse quantization / inverse transformation unit 105 for each pixel to generate a decoded image. The addition unit 106 stores the generated decoded image in the reference picture memory 109.
[0316] The loop filter 107 applies a deblocking filter, SAO, and ALF to the decoded image generated by the addition unit 106. Note that the loop filter 107 does not necessarily include the above three types of filters.
[0317] The prediction parameter memory 108 stores the prediction parameters generated by the encoding parameter determination unit 110 at predetermined positions for each target picture and CU.
[0318] The reference picture memory 109 stores the decoded image generated by the loop filter 107 at predetermined positions for each target picture and CU.
[0319] The encoding parameter determination unit 110 selects one set from a plurality of sets of encoding parameters. The encoding parameters are the above-described QT, BT, or TT segmentation information, prediction parameters, or parameters to be encoded generated in relation to these. The prediction image generation unit 101 generates a prediction image using these encoding parameters.
[0320] The symbolic parameter determination unit 110 calculates the RD cost value indicating the amount of information and the coding error for each of the plurality of sets, and selects the set of coding parameters that minimizes the cost value. As a result, the entropy coding unit 104 outputs the selected set of coding parameters as the coded stream Te. The symbolic parameter determination unit 110 stores the determined coding parameters in the prediction parameter memory 108.
[0321] Note that a part of the moving image encoding apparatus 11 and the moving image decoding apparatus 31 in the above-described embodiments, for example, the entropy decoding unit 301, the parameter decoding unit 302, the loop filter 305, the predicted image generation unit 308, the inverse quantization / inverse transform unit 311, the addition unit 312, the predicted image generation unit 101, the subtraction unit 102, the transform / quantization unit 103, the entropy encoding unit 104, the inverse quantization / inverse transform unit 105, the loop filter 107, the encoding parameter determination unit 110, and the parameter encoding unit 111 may be implemented by a computer. In that case, a program for realizing this control function may be recorded on a computer-readable recording medium, and the program recorded on this recording medium may be read into a computer system and executed to realize it. Here, the "computer system" is a computer system built in either the moving image encoding apparatus 11 or the moving image decoding apparatus 31 and includes hardware such as an OS and peripheral devices. Also, the "computer-readable recording medium" refers to a portable medium such as a flexible disk, a magneto-optical disk, a ROM, a CD-ROM, etc., and a storage device such as a hard disk built in a computer system. Furthermore, the "computer-readable recording medium" refers to something that holds a program dynamically for a short time, like a communication line when transmitting a program via a network such as the Internet or a communication line such as a telephone line, and also includes something that holds a program for a certain time, like a volatile memory inside a computer system that serves as a server or a client in that case. Also, the above program may be for realizing a part of the aforementioned functions, and may further be something that can be realized in combination with a program already recorded in the computer system for the aforementioned functions.
[0322] Further, part or all of the moving image encoding device 11 and the moving image decoding device 31 in the above-described embodiment may be realized as an integrated circuit such as an LSI (Large Scale Integration). Each functional block of the moving image encoding device 11 and the moving image decoding device 31 may be individually processed as a processor, or part or all of them may be integrated and processed as a processor. Further, the method of integrating into an integrated circuit is not limited to an LSI, and may be realized by a dedicated circuit or a general-purpose processor. Also, when a technology for integrating into an integrated circuit that replaces an LSI appears due to the progress of semiconductor technology, an integrated circuit using such technology may be used.
[0323] As described above, one embodiment of the present invention has been described in detail with reference to the drawings. However, the specific configuration is not limited to the above, and various design changes and the like can be made without departing from the gist of the present invention.
[0324] 〔Application Example〕 The above-described moving image encoding device 11 and moving image decoding device 31 can be mounted and used in various devices that perform transmission, reception, recording, and playback of moving images. Note that the moving image may be a natural moving image captured by a camera or the like, or an artificial moving image (including CG and GUI) generated by a computer or the like.
[0325] First, the fact that the above-described moving image encoding device 11 and moving image decoding device 31 can be used for transmission and reception of moving images will be described with reference to FIG. 2.
[0326] FIG. 2(a) is a block diagram showing the configuration of a transmission device PROD_A equipped with the moving image encoding device 11. As shown in FIG. 2(a), the transmission device PROD_A includes an encoding unit PROD_A1 that obtains encoded data by encoding a moving image, a modulation unit PROD_A2 that obtains a modulation signal by modulating a carrier wave with the encoded data obtained by the encoding unit PROD_A1, and a transmission unit PROD_A3 that transmits the modulation signal obtained by the modulation unit PROD_A2. The above-described moving image encoding device 11 is used as this encoding unit PROD_A1.
[0327] The transmitting device PROD_A may further include a camera PROD_A4 for capturing a moving image, a recording medium PROD_A5 for recording a moving image, an input terminal PROD_A6 for externally inputting a moving image, and an image processing unit A7 for generating or processing an image, as a source of the moving image input to the encoding unit PROD_A1. In FIG. 2(a), a configuration in which the transmitting device PROD_A includes all of these is illustrated, but a part of them may be omitted.
[0328] Note that the recording medium PROD_A5 may record an unencoded moving image, or may record a moving image encoded by a recording encoding method different from the transmission encoding method. In the latter case, a decoding unit (not shown) for decoding the encoded data read from the recording medium PROD_A5 according to the recording encoding method may be interposed between the recording medium PROD_A5 and the encoding unit PROD_A1.
[0329] FIG. 2(b) is a block diagram showing the configuration of the receiving device PROD_B equipped with the moving image decoding device 31. As shown in FIG. 2(b), the receiving device PROD_B includes a receiving unit PROD_B1 for receiving a modulated signal, a demodulating unit PROD_B2 for obtaining encoded data by demodulating the modulated signal received by the receiving unit PROD_B1, and a decoding unit PROD_B3 for obtaining a moving image by decoding the encoded data obtained by the demodulating unit PROD_B2. The above-described moving image decoding device 31 is used as this decoding unit PROD_B3.
[0330] The receiving device PROD_B may further include a display PROD_B4 for displaying a moving image, a recording medium PROD_B5 for recording a moving image, and an output terminal PROD_B6 for externally outputting a moving image, as a destination of the moving image output by the decoding unit PROD_B3. In FIG. 2(b), a configuration in which the receiving device PROD_B includes all of these is illustrated, but a part of them may be omitted.
[0331] Note that the recording medium PROD_B5 may be for recording unencoded moving images, or may be encoded using an encoding method for recording different from the encoding method for transmission. In the latter case, an encoding unit (not shown) for encoding the moving image obtained from the decoding unit PROD_B3 according to the encoding method for recording may be interposed between the decoding unit PROD_B3 and the recording medium PROD_B5.
[0332] Note that the transmission medium for transmitting the modulation signal may be wireless or wired. Also, the transmission mode for transmitting the modulation signal may be broadcasting (here, it refers to a transmission mode where the transmission destination is not specified in advance) or communication (here, it refers to a transmission mode where the transmission destination is specified in advance). That is, the transmission of the modulation signal may be realized by any of radio broadcasting, wired broadcasting, wireless communication, and wired communication.
[0333] For example, a broadcast station (such as broadcasting equipment) / reception station (such as a television receiver) for terrestrial digital broadcasting is an example of the transmission device PROD_A / reception device PROD_B that transmits and receives the modulation signal by radio broadcasting. Also, a broadcast station (such as broadcasting equipment) / reception station (such as a television receiver) for cable television broadcasting is an example of the transmission device PROD_A / reception device PROD_B that transmits and receives the modulation signal by wired broadcasting.
[0334] Also, a server (such as a workstation) / client (such as a television receiver, personal computer, smartphone, etc.) for a VOD (Video On Demand) service or video sharing service using the Internet is an example of the transmission device PROD_A / reception device PROD_B that transmits and receives the modulation signal by communication (usually, either wireless or wired is used as the transmission medium in a LAN, and wired is used as the transmission medium in a WAN). Here, personal computers include desktop PCs, laptop PCs, and tablet PCs. Also, smartphones include multifunctional mobile phone terminals.
[0335] In addition, the client of the video sharing service has a function of decoding the encoded data downloaded from the server and displaying it on the display, and also has a function of encoding the moving images captured by the camera and uploading them to the server. That is, the client of the video sharing service functions as both the transmission device PROD_A and the reception device PROD_B.
[0336] Next, it will be described with reference to FIG. 3 that the above-described moving image encoding device 11 and moving image decoding device 31 can be used for recording and playing back moving images.
[0337] FIG. 3(a) is a block diagram showing the configuration of the recording device PROD_C equipped with the above-described moving image encoding device 11. As shown in FIG. 3(a), the recording device PROD_C includes an encoding unit PROD_C1 that obtains encoded data by encoding moving images, and a writing unit PROD_C2 that writes the encoded data obtained by the encoding unit PROD_C1 to the recording medium PROD_M. The above-described moving image encoding device 11 is used as this encoding unit PROD_C1.
[0338] Note that the recording medium PROD_M may be of a type built into the recording device PROD_C, such as (1) an HDD (Hard Disk Drive) or an SSD (Solid State Drive), or may be of a type connected to the recording device PROD_C, such as (2) an SD memory card or a USB (Universal Serial Bus) flash memory, or may be loaded into a drive device (not shown) built into the recording device PROD_C, such as (3) a DVD (Digital Versatile Disc: registered trademark) or a BD (Blu-ray Disc: registered trademark).
[0339] Further, the recording device PROD_C may further include a camera PROD_C3 that captures a moving image, an input terminal PROD_C4 for inputting a moving image from the outside, a receiving unit PROD_C5 for receiving a moving image, and an image processing unit PROD_C6 for generating or processing an image, as a source of the moving image input to the encoding unit PROD_C1. In FIG. 3(a), a configuration in which the recording device PROD_C includes all of these is illustrated, but a part of them may be omitted.
[0340] Note that the receiving unit PROD_C5 may receive an unencoded moving image, or may receive encoded data encoded by a transmission encoding method different from the recording encoding method. In the latter case, a transmission decoding unit (not shown) for decoding the encoded data encoded by the transmission encoding method may be interposed between the receiving unit PROD_C5 and the encoding unit PROD_C1.
[0341] Examples of such a recording device PROD_C include a DVD recorder, a BD recorder, an HDD (Hard Disk Drive) recorder, etc. (in this case, the input terminal PROD_C4 or the receiving unit PROD_C5 serves as the main source of the moving image). Further, a camcorder (in this case, the camera PROD_C3 serves as the main source of the moving image), a personal computer (in this case, the receiving unit PROD_C5 or the image processing unit C6 serves as the main source of the moving image), a smartphone (in this case, the camera PROD_C3 or the receiving unit PROD_C5 serves as the main source of the moving image), etc. are also examples of such a recording device PROD_C.
[0342] FIG. 3(B) is a block diagram showing the configuration of a playback device PROD_D equipped with the above-described moving image decoding device 31. As shown in FIG. 3(b), the playback device PROD_D includes a reading unit PROD_D1 that reads the encoded data written on the recording medium PROD_M, and a decoding unit PROD_D2 that obtains a moving image by decoding the encoded data read by the reading unit PROD_D1. The above-described moving image decoding device 31 is used as this decoding unit PROD_D2.
[0343] Note that the recording medium PROD_M may be of a type built into the playback device PROD_D, such as an HDD or an SSD, or of a type connected to the playback device PROD_D, such as an SD memory card or a USB flash memory, or of a type loaded into a drive device (not shown) built into the playback device PROD_D, such as a DVD or a BD.
[0344] In addition, the playback device PROD_D may further include a display PROD_D3 that displays a moving image, an output terminal PROD_D4 for outputting the moving image externally, and a transmission unit PROD_D5 that transmits the moving image as destinations for the moving image output by the decoding unit PROD_D2. In FIG. 3(b), a configuration in which the playback device PROD_D includes all of these is illustrated, but a part thereof may be omitted.
[0345] Note that the transmission unit PROD_D5 may transmit an unencoded moving image or encoded data encoded by a transmission encoding method different from the recording encoding method. In the latter case, an encoding unit (not shown) that encodes the moving image by the transmission encoding method may be interposed between the decoding unit PROD_D2 and the transmission unit PROD_D5.
[0346] Examples of such a playback device PROD_D include, for example, a DVD player, a BD player, an HDD player, etc. (in this case, the output terminal PROD_D4 to which a television receiver or the like is connected becomes the main supply destination of the moving image). Also, a television receiver (in this case, the display PROD_D3 becomes the main supply destination of the moving image), digital signage (also referred to as an electronic signboard or an electronic bulletin board, etc., and the display PROD_D3 or the transmission unit PROD_D5 becomes the main supply destination of the moving image), a desktop PC (in this case, the output terminal PROD_D4 or the transmission unit PROD_D5 becomes the main supply destination of the moving image), a laptop or tablet PC (in this case, the display PROD_D3 or the transmission unit PROD_D5 becomes the main supply destination of the moving image), a smartphone (in this case, the display PROD_D3 or the transmission unit PROD_D5 becomes the main supply destination of the moving image), etc. are also examples of such a playback device PROD_D.
[0347] (Hardware implementation and software implementation) In addition, each block of the above-described moving image decoding device 31 and moving image encoding device 11 may be implemented hardware-wise by a logic circuit formed on an integrated circuit (IC chip), or may be implemented software-wise using a CPU (Central Processing Unit).
[0348] In the latter case, each of the above devices includes a CPU that executes instructions of a program for realizing each function, a ROM (Read Only Memory) that stores the above program, a RAM (Random Access Memory) that expands the above program, a storage device (recording medium) such as a memory that stores the above program and various data, etc. And the object of the embodiment of the present invention can also be achieved by supplying a recording medium in which program codes (executable format program, intermediate code program, source program) of control programs of each of the above devices, which are software for realizing the above-described functions, are recorded in a computer-readable manner to each of the above devices, and having the computer (or CPU or MPU) read and execute the program codes recorded in the recording medium.
[0349] Examples of the recording medium include tapes such as magnetic tapes and cassette tapes, magnetic disks such as floppy (registered trademark) disks / hard disks, and disks including optical disks such as CD-ROM (Compact Disc Read-Only Memory) / MO disks (Magneto-Optical disc) / MD (Mini Disc) / DVD (Digital Versatile Disc) / CD-R (CD Recordable) / Blu-ray Disc (registered trademark), cards such as IC cards (including memory cards) / optical cards, semiconductor memories such as mask ROM / EPROM (Erasable Programmable Read-Only Memory) / EEPROM (Electrically Erasable and Programmable Read-Only Memory: registered trademark) / flash ROM, or logic circuits such as PLD (Programmable logic device) and FPGA (Field Programmable Gate Array).
[0350] In addition, each of the above devices may be configured to be connectable to a communication network, and the above program code may be supplied via the communication network. This communication network only needs to be capable of transmitting the program code and is not particularly limited. For example, the Internet, intranet, extranet, LAN (Local Area Network), ISDN (Integrated Services Digital Network), VAN (Value-Added Network), CATV (Community Antenna television / Cable Television) communication network, virtual private network, telephone line network, mobile communication network, satellite communication network, etc. can be used. Also, the transmission medium constituting this communication network only needs to be a medium capable of transmitting the program code and is not limited to a specific configuration or type. For example, it can be wired such as IEEE (Institute of Electrical and Electronic Engineers) 1394, USB, power line carrier, cable TV line, telephone line, ADSL (Asymmetric Digital Subscriber Line) line, etc., or wireless such as infrared rays like IrDA (Infrared Data Association) and remote controls, Bluetooth (registered trademark), IEEE802.11 wireless, HDR (High Data Rate), NFC (Near Field Communication), DLNA (Digital Living Network Alliance: registered trademark), mobile phone network, satellite line, terrestrial digital broadcast network, etc. Note that the embodiments of the present invention can also be realized in the form of a computer data signal embedded in a carrier wave in which the above program code is embodied by electronic transmission.
[0351] The embodiments of the present invention are not limited to the above-described embodiments, and various modifications are possible within the scope shown in the claims. That is, embodiments obtained by combining technical means appropriately modified within the scope shown in the claims are also included in the technical scope of the present invention.
[0352] (Cross - reference to related applications) This application claims the benefit of priority to Japanese Patent Application: Japanese Patent Application No. 2019 - 021630 filed on February 8, 2019, and Japanese Patent Application: Japanese Patent Application No. 2019 - 057031 filed on March 25, 2019. By reference thereto, the entire contents thereof are incorporated herein.
Industrial applicability
[0353] Embodiments of the present invention can be preferably applied to a moving image decoding apparatus that decodes encoded data in which image data is encoded, and a moving image encoding apparatus that generates encoded data in which image data is encoded. Further, it can be preferably applied to the data structure of the encoded data generated by the moving image encoding apparatus and referred to by the moving image decoding apparatus.
Explanation of symbols
[0354] 11 Moving image encoding apparatus 31 Moving image decoding apparatus 101, 308 Predicted image generation unit 104 Entropy encoding unit (encoding unit) 107, 305 Loop filter 111 Parameter encoding unit 301 Entropy decoding unit 302 Parameter decoding unit (division unit) 3020 Header decoding unit 3021 CT information decoding unit 3022 CU decoding unit 109, 306 Reference picture memory 108, 307 Prediction parameter memory 105, 311 Inverse quantization and inverse transformation unit 102 Subtraction unit 103 Transformation and quantization unit 104 Entropy encoding unit 106 Addition unit 110 Encoded parameter determination unit 1110 Header encoding unit 1111 CT information encoding unit 1112 CU Symbolization Unit
Claims
1. In a moving image decoding apparatus for decoding encoded data, a decoding unit that decodes a flag indicating whether or not synchronization processing of Context-adaptive binary arithmetic coding (CABAC) is performed, a 1-bit syntax element, and a bit string for byte alignment is provided, when the value of the flag is 1, the bit string for byte alignment is decoded based on whether it is the last CTU of a tile group and whether it is the last CTU of a CTU row. A moving image decoding apparatus characterized by this.
2. The moving image decoding apparatus according to claim 1, wherein the bit string for byte alignment is omitted in the last CTU of the tile group.
3. when the value of the flag is 1, The moving image decoding apparatus according to claim 1, wherein the bit string for byte alignment is decoded when it is not the last CTU of the tile group and is the last CTU of the CTU row.
4. In a moving image encoding apparatus for generating encoded data, an encoding unit that encodes a flag indicating whether or not synchronization processing of Context-adaptive binary arithmetic coding (CABAC) is performed, a 1-bit syntax element, and a bit string for byte alignment is provided, when the value of the flag is 1, the bit string for byte alignment is encoded based on whether it is the last CTU of a tile group and whether it is the last CTU of a CTU row. A moving image encoding apparatus characterized by this.
5. In an integrated circuit for decoding encoded data, a decoding unit that decodes a flag indicating whether or not synchronization processing of Context-adaptive binary arithmetic coding (CABAC) is performed, a 1-bit syntax element, and a bit string for byte alignment is provided, when the value of the flag is 1, the bit string for byte alignment is decoded based on whether it is the last CTU of a tile group and whether it is the last CTU of a CTU row. An integrated circuit characterized by this.