Encoding device, decoding device, and program
Adaptive deblocking filters in encoding and decoding devices control filter strength based on luminance levels to reduce block distortion in HDR and SDR signals, enhancing image quality while maintaining compression efficiency.
Patent Information
- Application Number
- JP2025002780
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2018-10-22
- Filing Date
- 2025-01-08
- Publication Date
- 2025-10-03
- Estimated Expiration
- 2039-10-21
AI Technical Summary
Conventional deblocking filters in video coding formats struggle to effectively reduce block distortion in high dynamic range (HDR) signals and standard dynamic range (SDR) signals, particularly in areas with high luminance levels, leading to increased noise and reduced compression efficiency.
An encoding and decoding device that adaptively controls deblocking filter strength based on luminance signal levels by determining luminance thresholds on a picture-by-picture or sequence-by-sequence basis, using a reference table shifted according to luminance signal levels to adjust filter coefficients and thresholds.
Reduces block distortion without compromising compression efficiency, achieving higher image quality by applying stronger filters where needed and weaker filters where less distortion is present.
Smart Images

Figure 0007749153000005 
Figure 0007749153000006 
Figure 0007749153000007
Abstract
Description
[Technical Field]
[0001] The present invention relates to an encoding device, a decoding device, and a program for performing deblocking filtering. [Background technology]
[0002] In mainstream video coding formats, such as MPEG, video units called frames (or pictures) are divided into small block-like regions, and coding (compression) is performed on a block-by-block basis using techniques such as transformation and prediction. In such coding formats, differences in coding control between adjacent blocks result in perceived quality differences at block boundaries, resulting in distortion. Recent coding formats, such as H.264 / AVC (Advanced Video Coding) and H.265 / HEVC (High Efficiency Video Coding), employ a process called a deblocking filter to reduce this coding distortion.
[0003] Block distortion is a signal degradation caused by quantization of orthogonal transform coefficients at the boundary between adjacent blocks. This causes discontinuity in the processing due to block-by-block processing, resulting in abrupt signal fluctuations in adjacent regions that should be smooth. Deblocking filters for reducing this distortion are generally designed as low-pass filters that smooth signal fluctuations. Because the amount of signal degradation varies depending on the coarseness of quantization, the strength of the filter is controlled by a quantization parameter that defines the coarseness of quantization (see, for example, Non-Patent Document 1).
[0004] Meanwhile, a new feature of video media is the standardization of HDR (high dynamic range) signals, which expand the range of black and white that cannot be expressed with conventional video signals. Compared to conventional SDR (standard dynamic range) signals, HDR signals record a wide range of light intensity (i.e., from dark to bright) within a limited bit depth, and therefore employ a more extreme signal suppression process called gamma correction. HDR methods currently include the Hybrid-Log Gamma (HLG) method specified in ARIB STD-B67 and the Perceptual Quantize (PQ) method specified in SMPTE ST.2084, both of which have been standardized as ITU-R BT.2100. It is possible that other methods may be defined in the future.
[0005] Figure 1 shows the relationship (inverse gamma correction) between the luminance signal level of an image and the display luminance level shown on a display device for SDR signals and HDR signals of the HLG and PQ formats. Note that the HLG format is a relative system in which the peak luminance of the display device is the maximum value, so in the figure, the peak luminance is set to 2000 cd / m 2 Similarly, conventional SDR signals are also relative systems with the peak luminance of the display device as the maximum value, so using a currently available display as an example, the peak luminance is shown as 500 cd / m 2 Shown as:
[0006] With HDR signals, the change in display luminance level (brightness) in response to fluctuations in luminance signal level is greater than with conventional SDR signals. As a result, in areas with high signal levels, block noise caused by quantization distortion is exaggerated compared to conventional signal degradation. In particular, with the PQ method, which has the greatest degree of signal suppression, the fluctuation in display luminance level in response to luminance signal level is significant, and the impact of signal degradation due to block distortion is also significant. To reduce this phenomenon, it is common to take measures such as reducing the quantization parameter depending on the signal level. [Prior art documents] [Non-patent literature]
[0007] [Non-Patent Document 1] Edited by Sakae Okubo, "Impress Standard Textbook Series H.265 / HEVC Textbook," Impress Japan Corporation, October 21, 2013 Summary of the Invention
[0008] In conventional deblocking filters, the threshold for switching the filter strength to achieve inter-block smoothing is predetermined for each frame according to the quantization parameter, and control is not performed according to the luminance signal level. As a result, in HDR signals, the difference between the luminance signal level and the display luminance level is highly nonlinear, making it difficult for conventional deblocking filters to sufficiently reduce block distortion. In addition, conventional SDR signals also have nonlinearity due to gamma correction, which reduces the effectiveness of the deblocking filter in areas with high luminance levels.
[0009] Furthermore, although it is possible to reduce the average error amount of a block by making the quantization parameter smaller than necessary, the effect of the deblocking filter also becomes smaller as the quantization parameter becomes smaller, and it is not possible to sufficiently improve the problem that the difference in luminance signal level at the boundary is displayed conspicuously.Furthermore, there is a problem that the amount of information increases when the quantization parameter is made smaller, which reduces the compression effect.
[0010] In view of the above circumstances, an object of the present invention is to provide an encoding device, a decoding device, and a program that are capable of reducing block distortion without impairing the compression effect.
[0011] In order to solve the above problem, the coding device of the present invention is a coding device that codes an input image, and includes: a transform unit that performs an orthogonal transform process on a residual image that indicates a difference between an input image and a predicted image of the input image to calculate orthogonal transform coefficients; a quantization unit that quantizes the orthogonal transform coefficients based on a quantization parameter to generate quantized coefficients; an entropy coding unit that encodes the quantized coefficients to generate coded data; an image decoding unit that reconstructs orthogonal transform coefficients from the quantized coefficients based on the quantization parameter, and performs an inverse orthogonal transform on the orthogonal transform coefficients to reconstruct a residual image by adding the predicted image to the reconstructed residual image to generate a pre-filtered image; and a deblocking filter unit that performs a filtering process on the pre-filtered image, wherein the deblocking filter unit compares a luminance signal level of the pre-filtered image with a luminance threshold, and controls a filter strength depending on the range of the luminance signal level.
[0012] Furthermore, in the encoding device according to the present invention, the deblocking filter unit determines the luminance threshold on a picture-by-picture or sequence-by-sequence basis.
[0013] In addition, in order to solve the above-mentioned problems, a decoding device according to the present invention is a decoding device that decodes coded data of an input image, and includes: an entropy decoding unit that decodes the coded data and obtains quantized coefficients obtained by quantizing orthogonal transform coefficients; an image decoding unit that reconstructs orthogonal transform coefficients from the quantized coefficients based on a quantization parameter, performs an inverse orthogonal transform on the orthogonal transform coefficients, and adds a predicted image to the reconstructed residual image to generate a pre-filtered image; and a deblocking filter unit that performs a filtering process on the pre-filtered image, wherein the deblocking filter unit compares a luminance signal level of the pre-filtered image with a luminance threshold, and controls a filter strength according to the range of the luminance signal level.
[0014] Furthermore, in the decoding device according to the present invention, the deblocking filter unit determines the luminance threshold value on a picture-by-picture or sequence-by-sequence basis.
[0015] In order to solve the above problem, the present invention also provides a program that causes a computer to function as the encoding device.
[0016] In order to solve the above problem, the present invention also provides a program that causes a computer to function as the above decoding device.
[0017] According to the present invention, it is possible to reduce block distortion without impairing the compression effect. [Brief explanation of the drawings]
[0018] [Figure 1] FIG. 10 is a diagram showing the correspondence between signal levels and luminance levels. [Figure 2] 1 is a block diagram showing an example of the configuration of an encoding device according to an embodiment of the present invention. [Figure 3] FIG. 10 is a diagram illustrating block boundaries on which deblocking filter processing is performed. [Figure 4] 1 is a block diagram showing an example of the configuration of a decoding device according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE INVENTION
[0019] Hereinafter, an embodiment of the present invention will be described in detail with reference to the drawings.
[0020] (encoding device) An encoding device according to an embodiment of the present invention will be described below. Fig. 2 shows an example of the configuration of an encoding device according to an embodiment of the present invention. The encoding device 1 shown in Fig. 2 includes a block division unit 11, a subtraction unit 12, a transformation unit 13, a quantization unit 14, an inverse quantization unit 15, an inverse transformation unit 16, an addition unit 17, a deblocking filter unit 18, a sample adaptive offset unit 19, a storage unit 20, an intra prediction unit 21, a motion compensation prediction unit 22, a switching unit 23, and an entropy encoding unit 24. Note that the sample adaptive offset unit 19 is not an essential component. Instead of or in addition to the sample adaptive offset unit 19, a processing unit that performs other post-filtering processing may be provided.
[0021] The block division unit 11 divides an input image, that is, a frame to be coded, into a plurality of blocks and outputs the block images to the subtraction unit 12. The size of the blocks may be variable, for example, 128×128 pixels, 64×64 pixels, 32×32 pixels, 16×16 pixels, 8×8 pixels, or 4×4 pixels.
[0022] The subtraction unit 12 subtracts each pixel value of the predicted image of the input image input from the intra prediction unit 21 or the motion compensation prediction unit 22 described later via the switching unit 23 from each pixel value of the block image input from the block division unit 11 to generate a residual image indicating the difference between the block image and the predicted image, and outputs the residual image to the conversion unit 13.
[0023] The transform unit 13 performs an orthogonal transform process on the residual image input from the subtraction unit 12 to calculate orthogonal transform coefficients, and outputs the orthogonal transform coefficients for each block to the quantization unit 14.
[0024] The quantization unit 14 quantizes the orthogonal transform coefficients for each block input from the transform unit 13 based on a quantization parameter (Qp) that defines the coarseness of quantization to generate quantization coefficients, outputs the quantization parameter to the deblocking filter unit 18, and outputs the quantization parameter and the quantization coefficients to the inverse quantization unit 15 and the entropy coding unit 24. More specifically, the quantization unit 14 generates the quantization coefficients by dividing the orthogonal transform coefficients for each block input from the transform unit 13 by a quantization step derived from the quantization parameter. For example, in HEVC, the quantization parameter ranges from 0 to 51, and the quantization parameter is associated such that an increase of 6 in the quantization parameter doubles the quantization step (i.e., the quantization parameter and the logarithm of the quantization step are proportional).
[0025] The inverse quantization unit 15 reconstructs the orthogonal transform coefficients from the quantization coefficients input from the quantization unit 14 based on the quantization parameter, and outputs the reconstructed orthogonal transform coefficients to the inverse transform unit 16. More specifically, the inverse quantization unit 15 reconstructs the orthogonal transform coefficients for each block by multiplying the quantization coefficients input from the quantization unit 14 by a quantization step derived from the quantization parameter.
[0026] The inverse transform unit 16 performs an inverse orthogonal transform on the orthogonal transform coefficients input from the inverse quantization unit 15 to generate a residual image, and outputs the generated residual image to the addition unit 17. For example, if the transform unit 13 performs a discrete cosine transform, the inverse transform unit 16 performs an inverse discrete cosine transform.
[0027] The addition unit 17 adds each pixel value of the residual image input from the inverse transformation unit 16 and the predicted image input from the switching unit 23 to generate a pre-filtered image, and outputs the generated pre-filtered image to the deblocking filter unit 18.
[0028] The deblocking filter unit 18 performs filtering on the unfiltered image input from the adder unit 17, and outputs the filtered image to the sample adaptive offset unit 19. The deblocking filter unit 18 compares the luminance signal level of the unfiltered image with a luminance threshold, and controls the filter strength according to the range of the luminance signal level. The deblocking filter unit 18 then outputs information related to the filtering (such as filter coefficients, as well as information indicating the luminance threshold and shift amounts a and b, which will be described later) to the entropy coding unit 24. Details of the processing will be described later.
[0029] The sample adaptive offset unit 19 classifies the image input from the deblocking filter unit 18 on a pixel-by-pixel basis, adds an offset according to the classification to each pixel value, and outputs the result as a decoded image to the storage unit 20. In addition, the sample adaptive offset unit 19 outputs information about the sample adaptive offset to the entropy coding unit 24.
[0030] The intra prediction unit 21 references the decoded image stored in the storage unit 20, performs intra prediction, and generates an intra prediction image, and outputs the generated intra prediction image to the switching unit 23. The intra prediction unit 21 also outputs the selected intra prediction mode to the entropy coding unit 24.
[0031] The motion compensation prediction unit 22 references the decoded image stored in the storage unit 20, generates a motion vector by a technique such as block matching, and outputs the motion compensation prediction image to the switching unit 23. The motion compensation prediction unit 22 also outputs information about the motion vector to the entropy coding unit 24. Furthermore, the motion compensation prediction unit 22 generates a motion compensation prediction image based on the motion vector, and outputs the generated motion compensation prediction image to the switching unit 23.
[0032] The switching unit 23 switches between the intra-predicted image input from the intra-prediction unit 21 and the motion-compensated predicted image input from the motion-compensated prediction unit 22, and outputs the predicted image of the decoded image (intra-predicted image or motion-compensated predicted image) to the subtraction unit 12 and the addition unit 17.
[0033] The image decoding unit 10 includes the inverse quantization unit 15, the inverse transform unit 16, the addition unit 17, the intra prediction unit 21, the motion compensation prediction unit 22, and the switching unit 23. As described above, the image decoding unit 10 reconstructs orthogonal transform coefficients from the quantized coefficients based on the quantization parameter, performs inverse orthogonal transform on the orthogonal transform coefficients, and adds a predicted image to the reconstructed residual image to generate a pre-filtered image.
[0034] The entropy coding unit 24 performs entropy coding on the quantization parameters and quantization coefficients input from the quantization unit 14, the intra prediction mode input from the intra prediction unit 21, information on the predicted motion vector input from the motion compensation prediction unit 22, information on the filter processing input from the deblocking filter unit 18, and information on the sample adaptive offset input from the sample adaptive offset unit 19, and performs data compression to generate coded data, and outputs the generated coded data to the outside of the coding device 1. For the entropy coding, any entropy coding method such as zeroth-order exponential-Golomb coding or CABAC (Context-based Adaptive Binary Arithmetic Coding) can be used.
[0035] (Deblocking filter section) Next, the deblocking filter unit 18 will be described in detail. In this embodiment, the block size on which the deblocking filter unit 18 performs processing is, for example, 8×8 pixels. The deblocking filter unit 18 first calculates a boundary strength (Bs) value indicating the strength of the smoothing process for each block. The Bs value is set to 0, 1, or 2.
[0036] Figure 3 shows block boundaries on which deblocking filtering is performed. An example of deblocking filtering in accordance with the H.265 / HEVC standard will be described with reference to Figure 3. If block P or Q is a block that performs intra prediction, the Bs value is set to 2. If blocks P and Q are blocks that perform inter prediction and satisfy at least one of the following conditions, the Bs value is set to 1; otherwise, the Bs value is set to 0. Block P or Q contains significant (non-zero) DCT coefficients and is the boundary of a transform unit TU. The number of motion vectors or reference images of blocks P and Q are different. The absolute value of the difference between the motion vectors of blocks P and Q is 4 pixels or more.
[0037] The deblocking filter unit 18 does not perform filtering when the Bs value is 0. The following description will be given taking the vertical block boundary shown in Fig. 3 as an example. When the Bs value is 1 or 2, the deblocking filter unit 18 performs filtering only when the following equation (1) is satisfied.
[0038]
number
[0039] Furthermore, when performing filtering processing, the deblocking filter unit 18 applies a strong filter when all of the following conditional expressions (2) to (7) are satisfied, and applies a weak filter in other cases.
[0040]
number
[0041] Threshold β and t C The value of the quantization parameter Qp p and Qp Q The average value of Q av =(Qp p +QpQ +1)>>1, where >>1 means a 1-bit arithmetic right shift operation. av and thresholds β and t C An example of the reference table is shown in Table 1. The threshold value β,t when the image bit depth is 8 bits C are the thresholds β',t C '. av ,β',t C ' may be a value to which an offset is added in frame or slice units.
[0042] [Table 1]
[0043] If the bit depth is B, then the thresholds β and t C are expressed by equations (8) and (9), respectively. Here, <<1 means a 1-bit arithmetic left shift operation.
[0044]
number
[0045] In the present invention, the reference table is shifted according to the luminance signal level (pixel value of the luminance component) L to set the threshold values β and t C The value of the luminance signal level L is set to, for example, (p00+p03+q00+q03) / 4 or (p00+p01+p02+p03+q00+q01+q02+q03) / 8. Note that the method for determining the luminance signal level L is just an example, and is not limited to this.
[0046] Specifically, the deblocking filter unit 18 determines a threshold value (luminance threshold value) for the luminance signal level L, and determines the shift amount of the reference table by comparing the luminance signal level L with the luminance threshold value. The deblocking filter unit 18 can determine the luminance threshold value on a picture-by-picture basis, and may determine the luminance threshold value for any picture, or may determine the luminance threshold value for multiple pictures or for a specific picture (for example, a sequence or an I-picture).
[0047] The number of steps into which the luminance signal level is divided by the luminance threshold (how many divisions to make) and whether the range of luminance signal levels is uniform or non-uniform can be determined arbitrarily. For example, an EOTF (Electro-Optical Transfer Function) function is used, and the luminance signal level at which the slope of this function is a predetermined value (e.g., 1 / 4, 1 / 2, 2, 4, or 8) is determined as the luminance threshold. Alternatively, the luminance threshold may be determined by analyzing the correspondence between the luminance signal level and the degree of block distortion. For example, if the correspondence between the luminance signal level (1-254) of an 8-bit video and the degree of block distortion is approximately linear and the luminance signal level is divided into five steps, the luminance thresholds may be set to 50, 100, 150, and 200. In this case, the range of luminance signal levels is divided into 0-49, 50-99, 100-149, 150-199, and 200-254. Furthermore, if the rate of change of the block distortion degree is large within a particular range of luminance signal levels, this range of luminance signal levels may be divided more finely than other ranges.
[0048] Specifically, the deblocking filter unit 18 uses β′ and t C ', Q AV β'[Q AV ] and t C '[Q AV ] and the index Q is calculated according to the luminance signal level L. AVFor example, the shift amount a is determined according to the criterion of equation (10), and the shift amount b is determined according to the criterion of equation (11). Here, th1 to th6 are brightness thresholds. The shift amounts a and b may be determined according to the requirements of each application, or simply a=b may be used. Furthermore, the thresholds β', t C It is also possible to shift only one of the values a and b. The shift amounts a and b correspond to filter strength control information.
[0049] if (L < th1) a=-1; else if (L >= th1 && L < th2) a=0; else if (L >= th2 && L < th3) a=1; else if (L >= th3 && L < th4) a=5; else if (L >= th4 && L < th5) a=10; else if (L >= th5 && L < th6) a=12; else if (L >= th6) a=15; (10)
[0050] if (L < th1) b=-1; else if (L >= th1 && L < th3) b=0; else if (L >= th3 && L < th4) b=1; else if (L >= th4 && L < th6) b=5; else if (L >= th6) b=7; (11)
[0051] For example, when the shift amount a=b=qpOffset, Q AV =(Qp p +Qp Q +1)>>1+qpOffset, and the index Q according to the luminance level L AV For example, if qpOffset=5, the reference table is referenced and an offset of +5 is added to the Q AV is used as an index to determine the thresholds β' and t C ' is calculated. That is, the threshold value β' and t C ' is shifted to the right by 5 relative to no offset. If qpOffset is negative, it is shifted to the left. Note that the thresholds β' and t C When ' becomes 0, the lower limit of the thresholds thereafter is also set to 0, and the thresholds β' and t C When ' reaches the upper limit of 64 or 24, it is complemented by the upper limit. AV Prepare β' and t C ' is calculated.
[0052] The deblocking filter unit 18 calculates the threshold values β′ and t C By shifting ', Q av The threshold value for switching the filter strength can be adaptively controlled according to the threshold values β' and t C ' to the right (Q with a positive offset added) AVWhen the shift amounts a and b are set to an index, the threshold values β and tc become larger, making it easier to satisfy the above conditional expressions (2) to (7), and thus easier to apply a stronger filter. Therefore, in the encoding device 1 according to the present invention, the shift amounts a and b are increased for groups with a high degree of block distortion, making it easier to apply a stronger filter, and the shift amounts a and b are set to negative for groups with a low degree of block distortion, making it harder to apply a stronger filter. This allows for a filter strength change suited to the content. As a result, it is possible to reduce the occurrence of block distortion compared to conventional methods without compromising the compression effect, thereby achieving higher image quality. Note that when the shift amounts a and b are negative, an offset may be added so that the values are equal to or greater than zero before transmission. This allows for the reduction of sign bits indicating positive and negative signs.
[0053] Information indicating the luminance threshold determined by the deblocking filter unit 18 and the shift amounts a and b defined for each range of luminance signal level is transmitted by the entropy coding unit 24. For example, in the case of the HEVC format, this can be transmitted by the entropy coding unit 24 as one of a picture-based parameter set called a PPS (Picture Parameter Set) or a sequence parameter set called an SPS (Sequence Parameter Set). At the same time, the entropy coding unit 24 may transmit an enable flag indicating whether or not to shift the reference table described above.
[0054] The information indicating the luminance thresholds may not be the luminance thresholds themselves, but may be the number of divisions of the luminance signal level by the luminance thresholds and the difference values between adjacent luminance thresholds. For example, if the luminance thresholds th1 to th4 of the luminance signal level are th1=40, th2=90, th3=150, and th4=200, the number of divisions of the luminance signal level is 5. The difference values between adjacent luminance thresholds are th1-0=40, th2-th1=50, th3-th2=60, and th4-th3=50. Note that for th1, the adjacent luminance threshold is the minimum value of the luminance signal level, and the minimum value is 0 here. Since the number of divisions of the luminance signal level is 2 or more, the actual number of divisions minus 2, "3", may be transmitted. Furthermore, since the difference values of the luminance thresholds are 1 or more, the actual difference values of the luminance thresholds minus 1, "39, 49, 59, 49", may be transmitted. By transmitting values as small as possible, the amount of coding can be reduced.
[0055] A computer can be suitably used to function as the above-described encoding device 1, and such a computer can be realized by storing in a storage unit of the computer a program describing the processing contents for realizing each function of the encoding device 1, and having the CPU of the computer read and execute this program. Note that this program can be recorded on a computer-readable recording medium.
[0056] (Decoding device) Next, a decoding device according to one embodiment of the present invention will be described. Fig. 4 is a block diagram showing an example configuration of a decoding device according to one embodiment. The decoding device 2 shown in Fig. 4 includes an entropy decoding unit 31, an inverse quantization unit 32, an inverse transform unit 33, an adder unit 34, a deblocking filter unit 35, a sample adaptive offset unit 36, a storage unit 37, an intra prediction unit 38, a motion compensation prediction unit 39, and a switching unit 40. The decoding device 2 decodes the coded data of an input image coded by the coding device 1.
[0057] The entropy decoding unit 31 decodes the coded data output by the coding device 1, and obtains the quantization parameter, the quantization coefficient, the intra prediction mode, the motion prediction information, the information on the filtering process, the information on the sample adaptive offset, etc. Then, the entropy decoding unit 31 outputs the quantization parameter and the quantization coefficient to the inverse quantization unit 32, outputs the intra prediction mode to the intra prediction unit 38, outputs the motion prediction information to the motion compensation prediction unit 39, outputs the quantization parameter and the information on the filtering process to the deblocking filter unit 35, and outputs the information on the sample adaptive offset to the sample adaptive offset unit 36.
[0058] The inverse quantization unit 32 inputs the quantization coefficients and quantization parameters from the entropy decoding unit 31, multiplies the quantization coefficients by a quantization step derived from the quantization parameters to restore orthogonal transform coefficients for each block, and outputs the restored orthogonal transform coefficients to the inverse transform unit 33.
[0059] The inverse transform unit 33 performs an inverse transform on the orthogonal transform coefficients input from the inverse quantization unit 32 to generate a residual image, and outputs the generated residual image to the adder unit .
[0060] The addition unit 34 adds each pixel value of the residual image input from the inverse transformation unit 33 and the predicted image input from the switching unit 40 to generate a pre-filtered image, and outputs the generated pre-filtered image to the deblocking filter unit 35.
[0061] The deblocking filter unit 35 performs filtering on the unfiltered image input from the adder unit 34 and outputs the filtered image to the sample adaptive offset unit 36. The deblocking filter unit 35 compares the luminance signal level of the unfiltered image with a luminance threshold and controls the filter strength according to the range of the luminance signal level. Specifically, the deblocking filter unit 35 obtains the luminance threshold for each picture or sequence, and controls the filter strength so that it is stronger for groups with a high degree of block distortion.
[0062] The sample adaptive offset unit 36 adds an offset to the image input from the deblocking filter unit 35 in accordance with the sample adaptive offset information input from the entropy decoding unit 31, and outputs the result to the memory unit 37 as a decoded image.
[0063] The storage unit 37 stores one frame of image and outputs one frame of image to the outside of the decoding device 2.
[0064] The intra prediction unit 38 refers to the decoded image stored in the memory unit 37, performs prediction processing according to the intra prediction mode input from the entropy decoding unit 31 to generate an intra prediction image, and outputs the generated intra prediction image to the switching unit 40.
[0065] The motion compensation prediction unit 39 refers to the decoded image stored in the memory unit 37, performs prediction processing according to the motion vector information input from the entropy decoding unit 31, generates a motion compensation prediction image, and outputs the generated motion compensation prediction image to the switching unit 40.
[0066] The switching unit 40 switches between the intra-predicted image input from the intra-prediction unit 38 and the motion-compensated predicted image input from the motion-compensated prediction unit 39, and outputs the predicted image (intra-predicted image or motion-compensated predicted image) to the addition unit 34.
[0067] The image decoding unit 30 is made up of the inverse quantization unit 32, the inverse transform unit 33, the addition unit 34, the intra prediction unit 38, the motion compensation prediction unit 39, and the switching unit 40. As described above, the image decoding unit 30 reconstructs orthogonal transform coefficients from the quantized coefficients based on the quantization parameter, and generates a pre-filtered image by adding a predicted image of the decoded image to the reconstructed residual image by performing an inverse orthogonal transform on the orthogonal transform coefficients.
[0068] The deblocking filter unit 35 performs the same processing as the deblocking filter unit 18. That is, the deblocking filter unit 35 calculates a boundary strength Bs value for each block, and does not perform filtering if the Bs value is 0, but performs filtering if the Bs value is 1 or 2 and only if the above formula (1) is satisfied. When performing filtering, a strong filter is applied if all of the above conditional formulas (2) to (7) are satisfied, and a weak filter is applied in other cases. The deblocking filter unit 35 acquires the brightness threshold and shift amounts a and b from the entropy decoding unit 31. When acquiring information on the difference value between adjacent brightness thresholds from the entropy decoding unit 31, the deblocking filter unit 35 determines the brightness threshold from the information. For example, if the difference values between adjacent luminance thresholds are 40, 50, 60, and 50, the luminance thresholds th1 to th4 are calculated as follows, where the lowest luminance signal level is 0: th1=0+40=40, th2=th1+50=90, th3=th2+60=150, and th4=th3+50=200. Then, similar to the deblocking filter unit 18, the deblocking filter unit 35 compares the luminance signal level L with the luminance thresholds to calculate the thresholds β' and t C ' (shift Q AV By using Qav as an index, the threshold for switching the filter strength according to Qav can be adaptively controlled.
[0069] Thresholds β' and t in the reference table C When ' is shifted to the right, the values of the thresholds β and tc become larger, making it easier to satisfy the above conditional expressions (2) to (7), and making it easier to apply a strong filter. Therefore, in the decoding device 2 according to the present invention, the shift amounts a and b are increased for groups with a high degree of block distortion, making it easier to apply a strong filter, and the shift amounts a and b are negative for groups with a low degree of block distortion, making it harder to apply a strong filter, thereby enabling a change in filter strength appropriate to the content. As a result, it is possible to reduce the occurrence of block distortion compared to conventional methods without compromising the compression effect, and to achieve high image quality.
[0070] A computer can be suitably used to function as the above-described decoding device 2. Such a computer can be realized by storing a program describing the processing content for realizing each function of the decoding device 2 in a storage unit of the computer, and having the CPU of the computer read and execute this program. This program can be recorded on a computer-readable recording medium.
[0071] Although the above-described embodiments have been described as typical examples, it will be apparent to those skilled in the art that many modifications and substitutions can be made within the spirit and scope of the present invention. Therefore, the present invention should not be construed as being limited by the above-described embodiments, and various modifications and alterations are possible without departing from the scope of the claims. For example, multiple building blocks shown in the block diagrams of the embodiments can be combined into one, or one building block can be divided.
[0072] This application claims priority from Japanese Patent Application No. 2018-198728 (filed October 22, 2018), the entire contents of which are incorporated herein by reference.
Claims
1. An encoding device for encoding an input image, comprising: a transform unit that performs an orthogonal transform process on a residual image that indicates the difference between an input image and a predicted image of the input image to calculate transform coefficients; a quantization unit that quantizes the transform coefficients based on a quantization parameter to generate quantized coefficients; an entropy coding unit that encodes the quantized coefficients to generate coded data; an image decoding unit that reconstructs transform coefficients from the quantized coefficients based on the quantization parameter, performs inverse transform on the transform coefficients, and adds the predicted image to a reconstructed residual image to generate a pre-filtered image; a deblocking filter unit that performs a filtering process on the unfiltered image, the deblocking filter unit controls a filter strength in accordance with a result of comparing a luminance signal level of the unfiltered image with a luminance threshold; the deblocking filter unit calculates a luminance signal level of the unfiltered image by averaging pixel values of a plurality of pixels in a boundary portion of a pair of adjacent blocks corresponding to the unfiltered image; The encoding device, wherein the deblocking filter unit determines the luminance threshold for each sequence.
2. A decoding device that decodes encoded data of an input image, comprising: an entropy decoding unit that decodes the encoded data and obtains quantized coefficients obtained by quantizing the transform coefficients; an image decoding unit that reconstructs transform coefficients from the quantized coefficients based on the quantization parameter, performs inverse transform on the transform coefficients, and adds a predicted image to a reconstructed residual image to generate an unfiltered image; a deblocking filter unit that performs a filtering process on the unfiltered image, the deblocking filter unit controls a filter strength in accordance with a result of comparing a luminance signal level of the unfiltered image with a luminance threshold; the deblocking filter unit calculates a luminance signal level of the unfiltered image by averaging pixel values of a plurality of pixels in a boundary portion of a pair of adjacent blocks corresponding to the unfiltered image; The decoding device, wherein the deblocking filter unit determines the luminance threshold value on a sequence-by-sequence basis.
3. A program for causing a computer to function as the encoding device according to claim 1 or the decoding device according to claim 2.
Citation Information
Patent Citations
Image encoding device, image encoding method, and image encoding program
JP2013223096A
Encoding device, decoding device, encoding method, and decoding method
WO2018097299A1