WO2019135294A1 - 符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム - Google Patents

符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム Download PDF

Info

Publication number
WO2019135294A1
WO2019135294A1 PCT/JP2018/025141 JP2018025141W WO2019135294A1 WO 2019135294 A1 WO2019135294 A1 WO 2019135294A1 JP 2018025141 W JP2018025141 W JP 2018025141W WO 2019135294 A1 WO2019135294 A1 WO 2019135294A1
Authority
WO
WIPO (PCT)
Prior art keywords
classes
unit
offset
pixel
class
Prior art date
Application number
PCT/JP2018/025141
Other languages
English (en)
French (fr)
Inventor
瑛一 佐々木
Original Assignee
株式会社ソシオネクスト
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 株式会社ソシオネクスト filed Critical 株式会社ソシオネクスト
Priority to CN201880085180.4A priority Critical patent/CN111587576B/zh
Priority to JP2019563922A priority patent/JP7147788B2/ja
Publication of WO2019135294A1 publication Critical patent/WO2019135294A1/ja
Priority to US16/918,246 priority patent/US11330282B2/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/46Embedding additional information in the video signal during the compression process
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/117Filters, e.g. for pre-processing or post-processing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/119Adaptive subdivision aspects, e.g. subdivision of a picture into rectangular or non-rectangular coding blocks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/132Sampling, masking or truncation of coding units, e.g. adaptive resampling, frame skipping, frame interpolation or high-frequency transform coefficient masking
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/136Incoming video signal characteristics or properties
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/182Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a pixel
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/186Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a colour or a chrominance component
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/80Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation
    • H04N19/82Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation involving filtering within a prediction loop

Definitions

  • the present invention relates to a coding method, a decoding method, a coding device, a decoding device, a coding program and a decoding program.
  • H.365 / HEVC As an international standard for compression coding of moving image data, H.3. H.265 / HEVC is known. H. In the H.265 / HEVC, a pixel adaptive offset (SAO (Sample Adaptive Offset)) has been introduced as a loop filter technique for suppressing deterioration in image quality at the time of compression encoding.
  • SAO Sample Adaptive Offset
  • the pixel adaptive offset introduced in H.265 / HEVC includes an edge offset and a band offset, and any offset can be applied at the time of compression coding.
  • the band offset divides the gradation of the pixel value into 32 bands, selects four consecutive bands based on the band position determined therefrom, and belongs to each of the four bands. This is processing of adding (or subtracting) an offset value to the pixel value of the pixel.
  • the current band offset has a wide bandwidth and is not limited to the median value.
  • the offset value can not be added (or subtracted) to an appropriate target when four consecutive bands are targeted.
  • the next-generation video codec the next-generation codec following H. 265 / HEVC
  • the band offset signals SAO parameters including the determined band position and the offset value corresponding to each of the four selected bands for each block to be processed, and transmits the signal to the decoder. For this reason, there is a problem that the amount of bits of the SAO parameter transmitted to the decoder is large. As such, in the next-generation video codec currently under consideration, it is desirable to reduce the amount of bits of SAO parameters.
  • the object is to improve the image quality and reduce the amount of bits of the SAO parameter.
  • the encoding method comprises the following configuration. That is, Calculating the number of pixels belonging to each of the plurality of classes by dividing the gradation of the pixel value of the block of the encoding unit into a plurality of classes having a predetermined number of gradations; A class addition step of selecting an upper n (n is an integer of 1 or more) class having a large number of calculated pixels and adding an offset value to pixel values of pixels belonging to each of the selected n classes; And C. signaling the SAO parameter including the added offset value.
  • the bit amount of the SAO parameter can be reduced.
  • FIG. 1 is a diagram showing an application example of an encoder and a decoder.
  • FIG. 2 is a diagram showing another application example of the encoder and the decoder.
  • FIG. 3 is a diagram illustrating an example of the hardware configuration of the encoder.
  • FIG. 4 is a diagram showing an example of a functional configuration of the encoder.
  • FIG. 5 is a diagram showing an example of a functional configuration of a loop filter unit of a general encoder.
  • FIG. 6 is a flowchart showing a flow of pixel adaptive offset processing by a general encoder.
  • FIG. 7 is a diagram for explaining the processing contents of band offset processing in a general encoder.
  • FIG. 8 is a flowchart showing a flow of band offset processing by a general encoder.
  • FIG. 1 is a diagram showing an application example of an encoder and a decoder.
  • FIG. 2 is a diagram showing another application example of the encoder and the decoder.
  • FIG. 3 is a diagram
  • FIG. 9 is a flow chart showing the flow of signaling processing by a general encoder.
  • FIG. 10 is a diagram illustrating an example of a functional configuration of a loop filter unit of the encoder according to the first embodiment.
  • FIG. 11 is a first diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • FIG. 12 is a second diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • FIG. 13 is a third diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • FIG. 14 is a flowchart showing the flow of class offset processing by the encoder according to the first embodiment.
  • FIG. 15 is a flowchart showing a flow of signaling processing by the encoder according to the first embodiment.
  • FIG. 16 is a diagram showing an example of a functional configuration of the decoder.
  • FIG. 17 is a diagram showing an example of a functional configuration of a loop filter unit of a general decoder.
  • FIG. 18 is a flowchart showing a flow of pixel adaptive offset processing by a general decoder.
  • FIG. 19 is a flow chart showing the flow of band offset processing by a general decoder.
  • FIG. 20 is a diagram illustrating an example of a functional configuration of a loop filter unit of the decoder according to the first embodiment.
  • FIG. 21 is a flowchart showing the flow of class offset processing by the decoder according to the first embodiment.
  • FIG. 22 is a diagram illustrating an example of a functional configuration of a loop filter unit of the encoder according to the second embodiment.
  • FIG. 1 is a diagram showing an application example of an encoder and a decoder.
  • an image processing system 100 to which the encoder 110 and the decoder 120 are applied is formed by arranging the encoder 110 in a transmitter and the decoder 120 in a receiver and connecting them via a network 160. Can.
  • the encoder 110 disposed in the transmission device generates a data stream (coded sequence) by encoding the input moving image data. Also, the transmitting device transmits the generated data stream to the receiving device via the network 160.
  • the receiver receives the data stream. Also, the decoder 120 arranged in the receiving apparatus generates moving image data by decoding the data stream and displays the data.
  • the image processing system 100 By forming the image processing system 100, it is possible to reduce the transmission load when transmitting moving image data. Therefore, the image processing system 100 can be applied to various fields such as the Internet field, the broadcast field, and the communication field.
  • the application example 100a shows an example in which the image processing system 100 is applied to the Internet field.
  • the personal computer 121a, the smart terminal 121b, etc. which is an example of the receiving device 120, receives and displays the data stream transmitted from the server device 111, which is an example of the transmitting device 110.
  • the user of the personal computer 121a or the smart terminal 121b can view moving image data held by the server device 111 via the Internet.
  • the application example 100b shows an example in which the image processing system 100 is applied to the broadcast field.
  • the television 122 as an example of the receiving device 120 receives and displays the data stream transmitted from the broadcast transmitter 112 as an example of the transmitting device 110.
  • the user of the television 122 can view the broadcast content transmitted by the broadcast transmitter 112.
  • the application example 100c shows an example in which the image processing system 100 is applied to the communication field.
  • the video telephone 123 which is an example of the receiving device 120 receives and displays the data stream transmitted from the video telephone 113 which is an example of the transmitting device 110.
  • the user of the video telephone 123 can make a call while looking at the face of the other party.
  • FIG. 2 is a diagram showing another application example of the encoder and the decoder. As shown in FIG. 2, by integrally configuring the encoder 110 and the decoder 120, it is possible to form the storage device 200 to which the encoder 110 and the decoder 120 are applied.
  • the encoder 110 encodes the input moving image data, and stores the generated data stream in the recording medium. Further, the storage device 200 generates moving image data by decoding the data stream stored in the recording medium, and displays the moving image data.
  • the application example 200a shows an example in which the storage device 200 is applied to the storage field.
  • the video recorder 211 which is an example of the storage device 200, stores a data stream generated by encoding moving image data in the recording medium 212, the built-in encoder 110. Further, the video recorder 211 generates moving image data by decoding a data stream read from the recording medium 212 by the built-in decoder 120, and displays the moving image data on the monitor 213.
  • the user of the video recorder 211 can efficiently accumulate the acquired moving image data.
  • FIG. 3 is a diagram illustrating an example of the hardware configuration of the encoder.
  • the encoder 110 includes a central processing unit (CPU) 301, a read only memory (ROM) 302, and a random access memory (RAM) 303.
  • the CPU 301, the ROM 302, and the RAM 303 form a so-called computer.
  • the encoder 110 also includes an auxiliary storage device 304, an input device 305, a display device 306, a connection device 307, and a drive device 308.
  • the hardware of the encoder 110 is connected to one another via a bus 309.
  • the CPU 301 executes various programs (for example, a coding program (in the case of the decoder 120, a decoding program) or the like) installed in the auxiliary storage device 304.
  • various programs for example, a coding program (in the case of the decoder 120, a decoding program) or the like) installed in the auxiliary storage device 304.
  • the ROM 302 is a non-volatile memory.
  • the ROM 302 functions as a main storage device that stores various programs, data, and the like necessary for the CPU 301 to execute various programs installed in the auxiliary storage device 304.
  • the ROM 302 stores a boot program such as a BIOS (Basic Input / Output System) or an EFI (Extensible Firmware Interface).
  • BIOS Basic Input / Output System
  • EFI Extensible Firmware Interface
  • the RAM 303 is a volatile memory such as a dynamic random access memory (DRAM) or a static random access memory (SRAM).
  • the RAM 303 functions as a main storage device which provides a work area to be expanded when the various programs installed in the auxiliary storage device 304 are executed by the CPU 301.
  • the auxiliary storage device 304 is an auxiliary storage device that stores installed various programs and information used when executing the various programs.
  • the input device 305 is an input device used when inputting various instructions to the encoder 110.
  • the display device 306 is a display device that displays internal information of the encoder 110.
  • the connection device 307 is a communication device for the encoder 110 to receive moving image data from the outside, and the encoder 110 to be connected to the decoder 120 to perform communication.
  • the drive device 308 is a device for setting a computer readable recording medium 310.
  • the recording medium 310 includes a medium for optically, electrically or magnetically recording information, such as a CD-ROM, a flexible disk, a magneto-optical disk or the like.
  • the recording medium 310 may include a semiconductor memory or the like that electrically records information, such as a ROM, a flash memory, or the like.
  • the various programs installed in the auxiliary storage device 304 are installed by, for example, the distributed recording medium 310 being set in the drive device 308 and the various programs recorded in the recording medium 310 being read by the drive device 308 It may be done. Alternatively, various programs installed in the auxiliary storage device 304 are installed by being downloaded from the network 160 via the connection device 307.
  • FIG. 3 is merely an example, and depending on the application form, some of the hardware shown in FIG. 3 may be excluded or replaced with other hardware. Nor.
  • FIG. 4 is a diagram showing an example of a functional configuration of the encoder.
  • the encoder 110 includes a block division unit 401, an orthogonal transform unit 402, a quantization unit 403, and an entropy coding unit 404. Further, the encoder 110 includes an inverse quantization unit 405, an inverse orthogonal transform unit 406, a loop filter unit 407, a decoded image storage unit 408, and an intra / inter prediction unit 409.
  • the block division unit 401 divides each screen (input screen) included in the input moving image data into blocks of a fixed size by a stream. Furthermore, the block division unit 401 further divides each fixed size block into a coding unit block recursively.
  • the block division unit in the H.265 / HEVC divides the input screen into CTUs (Coding Tree Units), which are blocks of fixed size in a stream.
  • the block division unit in H.265 / HEVC divides blocks of each CTU into CUs (Coding Units), which are blocks of coding units.
  • the block division unit in the H.265 / HEVC divides the block of each CU into prediction unit (PU (Prediction Unit)) and transform unit (TU (Transform Unit)) blocks.
  • PU Prediction Unit
  • TU Transform Unit
  • the block division unit 401 is described as dividing all CTU blocks into CU blocks.
  • the block size of the CTU is up to 128 pixels ⁇ 128 pixels, so in the following, the block size of the CTU is 128 pixels ⁇ 128 pixels Explain as.
  • Each input screen divided into blocks of CUs by the block division unit 401 is notified to the intra / inter prediction unit 409 and used for calculation of a prediction residual signal.
  • the orthogonal transformation unit 402 performs orthogonal transformation processing on the prediction residual signal calculated based on the difference between the input image of the block of each CU in the input screen and the prediction image of the block of each corresponding CU. .
  • the quantization unit 403 generates a quantization signal by quantizing the prediction residual signal subjected to the orthogonal transformation process, and outputs the quantization signal to the entropy coding unit 404 and the dequantization unit 405.
  • the entropy coding unit 404 entropy-codes the quantized signal to generate and output a data stream.
  • the inverse quantization unit 405 inversely quantizes the quantized signal and outputs the result to the inverse orthogonal transform unit 406.
  • the inverse orthogonal transform unit 406 performs an inverse orthogonal transform process on the dequantized quantized signal. For example, a predicted image generated by the intra / inter prediction unit 409 is added to the signal obtained by the inverse orthogonal transform unit 406 to generate a decoded image, which is input to the loop filter unit 407.
  • the loop filter unit 407 performs filter processing to reduce coding noise of the input decoded image.
  • the loop filter unit 407 further includes Deblocking filter section, -Pixel adaptive offset (Sample Adaptive Offset) processing unit, (Details will be described later).
  • Parameters for example, a pixel adaptive offset parameter (SAO parameter) used when the pixel adaptive offset processing unit executes the pixel adaptive offset processing, etc.
  • SAO parameter pixel adaptive offset parameter
  • the parameters (including SAO parameters) signaled by the loop filter unit 407 are incorporated into the data stream by the entropy coding unit 404 as incidental information.
  • the decoded image storage unit 408 stores the decoded image filtered by the loop filter unit 407 for each screen.
  • the intra / inter prediction unit 409 performs intra prediction (in-screen prediction) of generating a predicted image of the block of the CU to be processed using the decoded image of each CU block in the screen being decoded. Also, the intra / inter prediction unit 409 performs motion compensation between screens using the decoded image of each CU block in the reference screen, and generates a predicted image of the block of the CU to be processed. Inter-prediction).
  • the intra / inter prediction unit 409 may be configured as an intra prediction image which is a prediction image of each CU block generated by intra prediction or an inter prediction image which is a prediction image of each CU block generated by motion compensation inter prediction. Output one or the other.
  • the prediction image of each CU block output from the intra / inter prediction unit 409 is used for residual calculation with the input image of each CU block in the input screen, and the calculated prediction residual signal is orthogonally transformed It is input to the part 402. Further, the predicted image output from the intra / inter prediction unit 409 is added to the signal obtained by the inverse orthogonal transform unit 406, and is input to the loop filter unit 407 as a decoded image.
  • FIG. 5 is a diagram showing an example of a functional configuration of a loop filter unit of a general encoder.
  • the loop filter unit includes a deblocking filter unit 510 and a pixel adaptive offset processing unit 520.
  • the deblocking filter unit 510 filters the decoded image of the block to be processed to reduce distortion generated at the block boundary when the input image of the block of each CU in the input screen is encoded.
  • the pixel adaptive offset processing unit 520 classifies, in pixel units, the decoded image of the block to be processed that has been subjected to the filter processing by the deblocking filter unit 510, and adds an offset value corresponding to the classification to each pixel.
  • the pixel adaptive offset processing unit 520 includes an edge offset processing unit 521, a band offset processing unit 522, and a selection unit 523.
  • the edge offset processing unit 521 classifies the edge state according to the magnitude relationship of the pixel values of three pixels continuous in the direction designated as the edge offset class. Further, the edge offset processing unit 521 adds an offset value corresponding to the classification of the edge state to the pixel value of the decoded image of the block to be processed. Furthermore, the edge offset processing unit 521 notifies the selection unit 523 of the block to be processed in which the offset value is added to the pixel value.
  • the edge offset processing unit 521 executes these processing (edge offset processing) for each of the SAO parameters while changing the SAO parameters related to the edge offset processing.
  • the band offset processing unit 522 divides the gradation of pixel values that can be taken by the decoded image of the block to be processed into 32 bands, and selects four consecutive bands based on the band position determined therefrom. Then, the band offset processing unit 522 adds (or subtracts) the offset value to the pixel value of the pixel belonging to each of the four bands.
  • the band offset processing unit 522 includes a block readout unit 541, an SAO parameter determination unit 542, and a pixel value change unit 543, as shown on the right side of FIG.
  • the block readout unit 541 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 520, and notifies the pixel value changing unit 543.
  • the SAO parameter determination unit 542 divides the gradation of pixel values that can be taken by the decoded image of the block to be processed into 32 bands, and determines SAO parameters (band position, offset value) related to band offset processing, It is output to the pixel value changing unit 543.
  • the pixel value changing unit 543 is provided for each of four consecutive bands based on the band position among the pixel values of each color component (luminance signal (Y) and color difference signals (Cb, Cr)) of the decoded image of the block to be processed.
  • the offset value is added to the pixel value of the belonging pixel. Further, the pixel value changing unit 543 notifies the selection unit 523 of the decoded image of the processing target block to which the offset value has been added, together with the SAO parameters (band position, offset value) related to the band offset processing.
  • the band offset processing unit 522 executes these processes (band offset process) for each of the SAO parameters while changing the SAO parameters (band position, offset value) related to the band offset process.
  • the selection unit 523 acquires each processing result performed by the edge offset processing unit 521 and each processing result performed by the band offset processing unit 522 for the decoded image of the block to be processed, and performs rate distortion (RD (Rate Distortion) Calculate the cost. Further, the selection unit 523 determines the processing result with the lowest calculated RD cost, and signals the SAO parameter used for calculating the determined processing result.
  • rate distortion RD (Rate Distortion) Calculate the cost.
  • FIG. 6 is a flowchart showing a flow of pixel adaptive offset processing by a general encoder.
  • the pixel adaptive offset processing unit 520 starts the pixel adaptive offset process shown in FIG.
  • processing for one block to be processed will be described.
  • step S601 the pixel adaptive offset processing unit 520 acquires a block to be processed.
  • step S602 the edge offset processing unit 521 reads the acquired block to be processed and performs edge offset processing using a predetermined SAO parameter related to the edge offset processing.
  • step S603 the selection unit 523 calculates an RD cost for the processing result of the edge offset processing in step S602.
  • step S 604 the edge offset processing unit 521 performs edge offset processing on all blocks to be processed using all SAO parameters (SAO parameters related to edge offset processing) within a predetermined range. Determine if
  • step S604 If it is determined in step S604 that there is a SAO parameter that has not been used to execute the edge offset processing (in the case of No in step S604), the process returns to step S602.
  • step S604 if it is determined in step S604 that edge offset processing has been performed using all SAO parameters within a predetermined range, the process proceeds to step S605.
  • step S605 the band offset processing unit 522 reads the block to be processed and performs band offset processing (details will be described later) using a predetermined SAO parameter related to the band offset processing.
  • step S606 the selection unit 523 calculates an RD cost for the processing result of the band offset process in step S605.
  • step S 607 the band offset processing unit 522 performs band offset processing on all blocks to be processed using all SAO parameters (SAO parameters related to band offset processing) within a predetermined range. Determine if
  • step S607 If it is determined in step S607 that there is a SAO parameter that has not been used to execute band offset processing (in the case of No in step S607), the process returns to step S605.
  • step S607 if it is determined in step S607 that the band offset process has been performed using all the SAO parameters within the predetermined range, the process proceeds to step S608.
  • step S608 the selection unit 523 compares the RD cost of each processing result performed by the edge offset processing unit 521 with each processing result performed by the band offset processing unit 522, and determines the processing result with the lowest RD cost. judge. In addition, the selection unit 523 specifies the SAO parameter used to calculate the determined processing result.
  • step S609 the selection unit 523 outputs the determined processing result as the processing result of the pixel adaptive offset processing.
  • step S610 the selection unit 523 performs a signaling process (details will be described later) for the identified SAO parameter.
  • FIG. 7 is a diagram for explaining the processing contents of band offset processing in a general encoder.
  • 700 a in FIG. 7 indicates a block to be processed.
  • band offset processing is performed on blocks in CTU units in the screen 710 during decoding.
  • the example of 700 a in FIG. 7 illustrates band offset processing is performed on a block of CTU 720 of 128 pixels ⁇ 128 pixels, and a block of CTU 720 ′ is generated as a processing result.
  • band offset processing for the color difference signal (Cr) among the color components (luminance signal (Y) and color difference signals (Cb, Cr)) of the screen 710 during decoding will be described.
  • the pixel value that the color difference signal (Cr) can obtain in the decoded image of the block to be processed is 256 tones
  • the pixel value changing unit 543 The 256 gradations are divided into 32 bands. As a result, the number of tones per band is eight.
  • the SAO parameter determination unit 542 outputs the band position indicated by the arrow 730 as the band position for the decoded image of the block of the CTU 720.
  • the pixel value changing unit 543 specifies the bands 731 to 734 as four continuous bands.
  • the pixel value changing unit 543 adds the offset value V 1 to the pixel value of the color difference signal (Cr) of the pixel belonging to the band 731 among the pixels included in the decoded image of the block of the CTU 720.
  • the pixel value changing section 543 of the pixels included in the decoded image of the block of CTU720, adding the offset value V 2 to the pixel value of the color difference signals of the pixels belonging to the band 732 (Cr).
  • the pixel value changing section 543 of the pixels included in the decoded image of the block of CTU720, adding the offset value V 4 to the pixel value of the color difference signals of the pixels belonging to the band 734 (Cr).
  • the band offset processing unit 522 performs similar band offset processing on the luminance signal (Y) and the color difference signal (Cb). Thereby, a block of CTU 720 'is generated as a processing result of band offset processing.
  • the offset values V 1 to V 4 to be added (or subtracted) to each of four consecutive bands may be different values or the same value (one kind of value).
  • FIG. 8 is a flowchart showing a flow of band offset processing by a general encoder.
  • step S801 the block readout unit 541 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 520.
  • the SAO parameter determination unit 542 sets “band position” as an SAO parameter related to band offset processing, “absolute value of offset” and “sign of offset” as offset values of four consecutive bands, as color components. Decide each time.
  • the range of SAO parameters related to the band offset processing determined by the SAO parameter determination unit 542 is assumed to be predetermined for each color component, and the SAO parameter determination unit 542 sequentially determines the SAO parameters within the range. To go.
  • the SAO parameter determination unit 542 sequentially performs SAO parameters (band positions of each color component, four offset absolute values, and four offset codes) related to the band offset processing determined for each color component, on a pixel value change unit basis. Output to 543.
  • step S 803 the pixel value changing unit 543 sets SAO parameters (band positions of each color component, four offset absolute values, four offset codes) related to the band offset process to the pixel values of the decoded image of the block to be processed. Change for each color component using.
  • FIG. 9 is a flow chart showing the flow of signaling processing by a general encoder.
  • the processing result of the band offset processing using the SAO parameter related to the band offset processing is determined to be the processing result with the lowest RD cost by RD cost comparison.
  • step S901 the selection unit 523 signals information indicating that the processing result of the band offset processing has been selected in the pixel adaptive offset processing.
  • step S902 the selection unit 523 signals four offset absolute values of each color component, which are SAO parameters related to the band offset processing when the processing result with the lowest RD cost is calculated.
  • step S 903 the selection unit 523 signals four offset codes of each color component, which are SAO parameters related to band offset processing when the processing result with the lowest RD cost is calculated.
  • step S904 the selection unit 523 signals the band position of each color component, which is an SAO parameter related to band offset processing, when the processing result with the lowest RD cost is calculated.
  • FIG. 10 is a diagram illustrating an example of a functional configuration of a loop filter unit of the encoder according to the first embodiment.
  • the same reference numerals are given to the same functions as those of the loop filter unit of the general encoder described with reference to FIG. 5, and the description thereof is omitted here.
  • the pixel adaptive offset processing unit 520 has a class offset processing unit 1001 and the function of the selection unit 1002 is different from the function of the selection unit 523.
  • the class offset processing unit 1001 can also reduce color difference distortion, and also has a function as CAR (Chroma Artifact Reduction) SAO.
  • the class offset processing unit 1001 includes a block readout unit 541, a pixel count calculation unit 1011, a class selection unit 1012, an offset determination unit 1013, and a pixel value change unit 1014.
  • the block readout unit 541 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 520, and notifies the pixel value changing unit 1014 of the decoded image.
  • the pixel number calculation unit 1011 is an example of a calculation unit.
  • the number-of-pixels calculation unit 1011 generates a plurality of groups each having a predetermined number of gradations of pixel values of each color component (luminance signal (Y) and color difference signals (Cb, Cr)) of the decoded image of the block to be processed. Divide into Hereinafter, the group is referred to as "class".
  • the pixel number calculation unit 1011 may divide the gradations of the pixel value so that each class has the same number of gradations, or may divide the gradations so as to have different numbers of gradations.
  • the number of gradations of each class is the number of gradations (pixel value is 256 gradations) of each band when divided into 32 bands by the band offset processing unit 522 shown in FIG. 5
  • the number of gradations in each band may be more or less than "8".
  • the offset value can be added to this. In this case, the effect of improving color misregistration can be increased as compared to band offset processing of a general encoder.
  • the number-of-pixels calculating unit 1011 calculates the number of pixels belonging to each class by classifying each pixel included in the decoded image of the block to be processed into each class based on the pixel value for each color component. .
  • the class selection unit 1012 selects the top n classes (n is an integer of 1 or more, for example, "3") having a large number of calculated pixels for each color component and notifies the pixel value change unit 1014 .
  • each color component It should be noted that by setting the upper n classes to be selected for each color component to less than 4 (in other words, by reducing the number of bands to which the offset value is added compared to the case of a general encoder), each color component It is possible to reduce the amount of bits when signaling the offset value of.
  • the class selection unit 1012 when each color component of the decoded image of the block to be processed is a color difference signal (Cb, Cr), the class selection unit 1012 generates the image before and after the median (1 ⁇ (bitdepth-1)) of the gradation value. Select m classes (m is an integer of 1 or more, for example, "6"), and out of m the top n classes (n is an integer of 1 or more) having a large number of calculated pixels, for example, "3" is selected and notified to the pixel value changing unit 1014.
  • the vicinity of the median of the gradation values is achromatic, and when distortion is present, the subjective image quality can be improved by selecting the vicinity of the median as fixed.
  • the upper n classes to be selected to be less than 4 (that is, by reducing the number of bands to which the offset value is added compared to the case of a general encoder)
  • the offset value of each color component is It is possible to reduce the amount of bits when signaling.
  • the offset determining unit 1013 receives n class information items selected from the class selecting unit 1012, and generates n offset values (n units) for each color component so as to minimize the squared error of the pixel value at the time of decoding. Determine the offset absolute value, n offset codes). Also, the offset determination unit 1013 notifies the pixel value change unit 1014 of the n offset values of each of the determined color components.
  • the pixel value change unit 1014 is an example of a class addition unit.
  • the pixel value changing unit 1014 is an offset determined for each color component with respect to the pixel value of the pixel belonging to the class selected by the class selection unit 1012 among the pixels included in the decoded image of the block to be processed Add the value.
  • the pixel value changing unit 1014 outputs, to the selecting unit 1002, the decoded image of the block to be processed, to which the offset value has been added for each color component.
  • the pixel value changing unit 1014 outputs, to the selecting unit 1002, an SAO parameter including an offset value of each color component as an SAO parameter related to the class offset process.
  • the selection unit 1002 is an example of a signaling unit.
  • the selection unit 1002 obtains each processing result performed by the edge offset processing unit 521 and each processing result performed by the class offset processing unit 1001 for the decoded image of the block to be processed, and calculates the RD cost. . Further, the selection unit 1002 determines the processing result with the lowest calculated RD cost, selects the determined processing result, and outputs the selected processing result to the adaptive loop filter unit 530. Furthermore, the selection unit 1002 signals the SAO parameter used to calculate the determined processing result.
  • FIG. 11 is a first diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • the pixel count calculation unit 1011 shows that the 256 gradations are equally divided into 128 classes. As a result, the number of gradations per class is two.
  • the pixel count calculation unit 1011 classifies each pixel included in the decoded image of the block of CTU 720 into each class based on the pixel value of the color difference signal (Cr). A state of generating 1101 is shown.
  • the example of 1100 b in FIG. 11 shows that the class selection unit 1012 selects the top three classes with a large number of calculated pixels. Further, in the example of 1100 b of FIG. 11, the pixel value changing unit 1014 sets offset values V 1 , V 2 , V 3 with respect to pixel values of color difference signals (Cr) of pixels belonging to the selected three classes. It shows the situation where each was added.
  • the class selection unit 1012 may select six classes fixedly around the median value of the gradation value and select three classes.
  • the class offset processing unit 1001 performs class offset processing on the decoded image of the block of the CTU 720 with the following content.
  • An offset value is added to a class of two gradations narrower than a band of eight gradations.
  • a target to which an offset value is to be added is selected based on the number of pixels belonging to each class without determining the parameter corresponding to the band position. It is also possible to select a fixed value before and after the median value of the gradation value without selecting a parameter corresponding to the band position, and to select an object to which the offset value is to be added based on the number of pixels belonging to each class.
  • the number of targets to which the offset value is added is three.
  • the class offset processing unit 1001 can add an offset value only to the color difference signal (Cr) of the specific area in which small deterioration has occurred in the decoded image of the block of the CTU 720. For this reason, compared with the band offset process of a general encoder, the improvement effect of color misregistration can be enlarged.
  • the class offset processing unit 1001 does not need to include the parameter corresponding to the band position in the SAO parameter and transmit it to the decoder side. For this reason, it is possible to reduce the amount of bits of the SAO parameter to be transmitted to the decoder, as compared to the band offset processing of a general encoder.
  • the class offset processing unit 1001 can reduce the number of offset values included in the SAO parameter. For this reason, the bit amount of the SAO parameter to be transmitted to the decoder can be further reduced as compared with the band offset processing of a general encoder.
  • FIG. 12 is a second diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • the pixel number calculation unit 1011 determines each pixel included in the decoded image of the block of CTU 720 based on the pixel value of the color difference signal (Cr), as in the example of 1100a of FIG.
  • the state of generating the histogram 1201 is shown by classifying into classes.
  • the difference from 1100a in FIG. 11 is that the top three classes having a large number of calculated pixels are not continuous.
  • the class selection unit 1012 selects the top three classes having a large number of calculated pixels regardless of whether the top three classes are continuous.
  • the pixel value changing unit 1014 adds offset values V 1 , V 2 , and V 3 to pixel values of color difference signals (Cr) of pixels belonging to the three classes selected by the class selection unit 1012. Do.
  • the class offset processing unit 1001 performs the class offset processing with the same content as the first example, regardless of the distribution of the pixel value of each pixel included in the decoded image of the block of the CTU 720. The same effect as that of the first example can be obtained.
  • the offset value can also be added to the pixel values of the pixels belonging to non-consecutive classes. For this reason, for example, since the offset value can be added to each of the areas including the background and the object including the areas where the color difference values are largely different, the improvement effect of the color misregistration can be increased. .
  • FIG. 13 is a third diagram showing a specific example of class offset processing in the encoder according to the first embodiment.
  • the number-of-pixels calculating unit 1011 classifies each pixel included in the decoded image of the block of CTU 720 into each class based on the pixel value of the color difference signal (Cr).
  • a state of generating 1301 is shown.
  • the difference from 1200a in FIG. 12 is that the top three classes having a large number of calculated pixels have different numbers of gradations (number of gradations: 2, 4 and 6).
  • the class selection unit 1012 determines whether the number of gradations in the upper three classes is the same or different, and the top three pixels having a large number of calculated pixels. Select a class The pixel value changing unit 1014 adds offset values V 1 , V 2 , and V 3 to the pixel values of the color difference signals (Cr) of the pixels belonging to each class selected by the class selection unit 1012. Alternatively, when the number of gradations included in each of the upper three classes is different, the upper three classes having the largest number of pixels are selected from the classes belonging to the gradation number having the largest number of pixels.
  • the class offset processing unit 1001 performs class offset processing with the same content as that of the above specific example (specific example 1) regardless of whether the number of gradations of each class is the same or different. The same effect as that of the first example can be obtained.
  • class selection unit 1012 selects the top 3 classes having a large number of calculated pixels.
  • the number of classes to be selected is not limited to this, and for example, the top four or more classes (for example, the top four classes or the top six classes) may be selected.
  • the pixel value of the chrominance signal (Cr) of the decoded image of the block to be processed may be, for example, 512 gradations of 0 to 511.
  • the number-of-pixels calculating unit 1011 may perform division so that the number of gradations that each class has is “4”. That is, in the case of dividing equally, the number of gradations that each class has may be changed according to the gradation.
  • the bit depth (Bit Depth) of possible pixel values of the color difference signal (Cr) in the decoded image of the block to be processed is BD (the pixel value of the color difference signal (Cr) is 2 BD gradation).
  • the number-of-pixels calculating unit 1011 may divide the number of gradations in each class so as to be 2 (BD-7) .
  • BD is an integer of 8 or more.
  • FIG. 14 is a flowchart showing the flow of class offset processing by the encoder according to the first embodiment.
  • step S1401 the block readout unit 541 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 520.
  • step S1403 the pixel number calculation unit 1011 divides the gradation of the pixel value of each color component in the decoded image of the block to be processed into a plurality of classes having a predetermined number of gradations. Further, the number-of-pixels calculating unit 1011 calculates the number of pixels belonging to each class by classifying each pixel included in the decoded image of the block to be processed into each class based on the pixel value for each color component. Do. Furthermore, the class selection unit 1012 selects, for each color component, the top n classes having a large number of calculated pixels.
  • the class selection unit 1012 selects m classes around the median value (1 ⁇ (bitdepth-1)) of the gradation value, and m From among the above, the top n classes having many calculated pixels are selected.
  • step S1404 the offset determination unit 1013 determines n offset absolute values and n offset codes for each color component as an offset value to be added to the pixel values of the pixels belonging to the selected n classes.
  • step S1405 the pixel value changing unit 1014 determines the determined n offset values (n offset absolute values, n values) for the pixel values of the pixels belonging to each of the selected n classes in each color component. Offset code) is added.
  • FIG. 15 is a flowchart showing a flow of signaling processing by the encoder according to the first embodiment.
  • the processing result of the class offset processing using the SAO parameter related to the class offset processing is determined to be the processing result with the lowest RD cost by the RD cost comparison in the selection unit 1002.
  • step S1501 the selection unit 1002 signals information indicating that the processing result of the class offset processing has been selected in the pixel adaptive offset processing.
  • step S1502 the selection unit 1002 signals the offset absolute value of each of the n classes calculated for each color component among the SAO parameters when the processing result with the lowest RD cost is calculated.
  • step S1503 the selection unit 1002 signals the offset codes of n classes calculated for each color component among the SAO parameters when the processing result with the lowest RD cost is calculated.
  • FIG. 16 is a diagram showing an example of a functional configuration of the decoder.
  • the decoder 120 includes an entropy decoding unit 1601, an inverse quantization unit 1602, an inverse orthogonal transformation unit 1603, a loop filter unit 1604, a decoded image storage unit 1605, and an intra / inter prediction unit 1606.
  • the entropy decoding unit 1601 decodes the received data stream and outputs a quantized signal. Also, the entropy decoding unit 1601 extracts additional information (including SAO parameters and the like used in the loop filter unit 1604) from the data stream, and notifies the loop filter unit 1604 of the incidental information.
  • additional information including SAO parameters and the like used in the loop filter unit 1604
  • the inverse quantization unit 1602 inversely quantizes the quantized signal and outputs the result to the inverse orthogonal transform unit 1603.
  • the inverse orthogonal transform unit 1603 performs an inverse orthogonal transform process on the dequantized quantized signal.
  • a predicted image generated by the intra / inter prediction unit 1606 is added to a signal obtained by the inverse orthogonal transform unit 1603 executing the inverse orthogonal transform process, thereby generating a decoded image, It is input to the loop filter unit 1604.
  • the loop filter unit 1604 performs filter processing to reduce coding noise of the input decoded image, using the notified additional information.
  • the loop filter unit 1604 further includes a deblocking filter unit, a pixel adaptive offset processing unit, and an adaptive loop filter unit (the details will be described later).
  • the loop filter unit 1604 outputs the filtered decoded image as a decoding result and stores the decoded image in the decoded image storage unit 1605.
  • the intra / inter prediction unit 1606 performs intra prediction which generates a predicted image of the block of the CU to be processed, using the decoded image of the block of each CU in the screen being decoded. Further, the intra / inter prediction unit 1606 performs motion compensation in the screen using the decoded image of each CU block in the reference screen, and performs inter prediction to generate a predicted image of the block of the CU to be processed.
  • the intra / inter prediction unit 1606 is configured to generate an intra prediction image which is a prediction image of each CU block generated by intra prediction, or an inter prediction image which is a prediction image of each CU block generated by motion compensation inter prediction. Output one or the other.
  • the output predicted image is added to the signal obtained by the inverse orthogonal transform unit 1603 executing the inverse orthogonal transform processing, and is added to the loop filter unit 1604 as a decoded image.
  • FIG. 17 is a diagram showing an example of a functional configuration of a loop filter unit of a general decoder. As shown in FIG. 17, the loop filter unit has a deblocking filter unit 1710 and a pixel adaptive offset processing unit 1720.
  • the deblocking filter unit 1710 filters the decoded image of the block to be processed to reduce distortion generated at block boundaries when the encoder encodes the input image of each CU block in the input screen. .
  • the pixel adaptive offset processing unit 1720 classifies, for each pixel, the decoded image of the block to be processed, which has been subjected to the filter processing by the deblocking filter unit 1710, and adds an offset value corresponding to the classification to each pixel.
  • the pixel adaptive offset processing unit 1720 includes an edge offset processing unit 1721 and a band offset processing unit 1722, and based on the incidental information notified from the entropy decoding unit 1601, any one of the processes is performed. Run the department.
  • the edge offset processing unit 1721 classifies the edge state according to the magnitude relationship between the pixel values of three pixels continuous in the direction designated as the edge offset class. Also, the edge offset processing unit 1721 adds an offset value corresponding to the classification of the edge state to the pixel value of the decoded image of the block to be processed.
  • the band offset processing unit 1722 divides the gradation of the pixel value that can be taken by the decoded image of the block to be processed into 32 bands, and selects four consecutive bands based on the band position among them. Then, the band offset processing unit 1722 adds (or subtracts) the offset value to the pixel value of the pixel belonging to each of the four bands.
  • the band offset processing unit 1722 includes a block readout unit 1741, an SAO parameter acquisition unit 1742 and a pixel value change unit 1743.
  • the block readout unit 1741 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 1720, and notifies the pixel value changing unit 1743 of the decoded image.
  • the SAO parameter acquisition unit 1742 divides the gradation of pixel values that can be taken by the decoded image of the block to be processed into 32 bands. Also, the SAO parameter acquisition unit 1742 acquires SAO parameters (band position, offset value) related to the band offset processing included in the incidental information, and outputs the acquired SAO parameters to the pixel value change unit 1743.
  • the pixel value changing unit 1743 performs band offset processing in which the pixel values of each color component (luminance signal (Y) and color difference signals (Cb, Cr)) of the decoded image of the block to be processed are output from the SAO parameter acquisition unit 1742 Change using SAO parameters related to In addition, the pixel value changing unit 1743 outputs the decoded image of the block to be processed whose pixel value has been changed.
  • the adaptive loop filter unit 530 reduces the error from the corresponding input image by filtering the decoded image of the block to be processed which has been offset-processed by the pixel adaptive offset processing unit 520.
  • FIG. 18 is a flowchart showing a flow of pixel adaptive offset processing by a general decoder.
  • the pixel adaptive offset processing unit 1720 starts the pixel adaptive offset process shown in FIG.
  • processing for one block to be processed will be described.
  • step S1801 the pixel adaptive offset processing unit 1720 acquires a block to be processed.
  • step S 1802 the pixel adaptive offset processing unit 1720 acquires incidental information from the entropy decoding unit 1601.
  • step S1803 the pixel adaptive offset processing unit 1720 determines whether the offset mode is the band offset mode or not based on the acquired supplementary information. If it is determined in step S1803 that the mode is the band offset mode (in the case of Yes in step S1803), the process proceeds to step S1804.
  • step S 1804 the band offset processing unit 1722 executes band offset processing using the SAO parameter related to the band offset processing included in the supplementary information.
  • step S1803 If it is determined in step S1803 that the mode is not the band offset mode (No in step S1803), the process proceeds to step S1805.
  • step S1805 the pixel adaptive offset processing unit 1720 determines whether the offset mode is an edge offset mode. If it is determined in step S1805 that the mode is the edge offset mode (in the case of Yes in step S1805), the process proceeds to step S1806.
  • step S1806 the edge offset processing unit 1721 executes edge offset processing using SAO parameters related to the edge offset processing included in the supplementary information.
  • step S1805 determines whether the mode is the edge offset mode (No in step S1805). If it is determined that the offset mode is off, and the pixel adaptive offset process for the block to be processed is ended. .
  • FIG. 19 is a flow chart showing the flow of band offset processing by a general decoder.
  • step S1901 the block readout unit 1741 reads the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 1720.
  • step S1902 the SAO parameter acquisition unit 1742 acquires, for each color component, a band position, four offset absolute values, and four offset codes as SAO parameters related to the band offset process included in the supplementary information.
  • step S1903 the pixel value changing unit 1743 uses pixel values of the decoded image of the block to be processed using SAO parameters (band position, 4 offset absolute values, 4 offset codes) related to band offset processing. Change for each color component.
  • SAO parameters band position, 4 offset absolute values, 4 offset codes
  • FIG. 20 is a diagram illustrating an example of a functional configuration of a loop filter unit of the decoder according to the first embodiment.
  • the same reference numerals are given to the same functions as those of the loop filter unit of the general decoder described with reference to FIG. 17, and the description thereof is omitted here.
  • the pixel adaptive offset processing unit 1720 includes a class offset processing unit 2001.
  • the class offset processing unit 2001 can also reduce color difference distortion, and also has a function as a CAR SAO.
  • the class offset processing unit 2001 includes a block readout unit 1741, a pixel count calculation unit 2011, a class selection unit 2012, an SAO parameter acquisition unit 2013, and a pixel value change unit 2014. .
  • the block readout unit 1741 reads out the decoded image of the block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 1720, and notifies the pixel value changing unit 2014.
  • the pixel number calculation unit 2011 is an example of a calculation unit.
  • the number-of-pixels calculating unit 2011 calculates a plurality of classes having a predetermined number of gradations of pixel values of each color component (luminance signal (Y) and color difference signals (Cb, Cr)) of the decoded image of the block to be processed Divide into The pixel number calculation unit 2011 may divide the gradations of the pixel values so that each class has the same number of gradations, or may divide the gradations so as to have different numbers of gradations.
  • the number of gradations in each class is the number of gradations in each band (the gradation of the pixel value is 256) when the band offset processing unit 1722 shown in FIG. 17 divides the number of bands into 32 bands.
  • the number of gradations in each band may be more or less than "8".
  • the division method when the pixel number calculation unit 2011 generates each class is the same as the division method used when the pixel number calculation unit 1011 generates each class in the encoder 110 and is determined in advance. It shall be.
  • the offset value can be added to this. In this case, the effect of improving color misregistration can be increased as compared to the band offset processing of a general decoder.
  • the number-of-pixels calculating unit 2011 classifies the pixels included in the decoded image of the block to be processed into each class based on the pixel value for each color component, thereby reducing the number of pixels belonging to each class. calculate.
  • the class selection unit 2012 selects the top n classes (n is an integer of 1 or more, for example, “3”) having a large number of calculated pixels for each color component and notifies the pixel value change unit 2014 .
  • the class selection unit 2012 may be around the median (1 ⁇ (bitdepth-1)) of the gradation value. Select m classes (m is an integer of 1 or more, for example, "6"), and out of m the top n classes (n is an integer of 1 or more) having a large number of calculated pixels, for example, "3" is selected and notified to the pixel value changing unit 1014.
  • the number of classes selected by the class selection unit 2012 is the same as the number of classes selected by the pixel count calculation unit 1011 in the encoder 110, and is determined in advance.
  • the SAO parameter acquisition unit 2013 acquires SAO parameters related to class offset processing.
  • the SAO parameter acquisition unit 2013 acquires n offset values (n offset absolute values, n offset codes) for each color component as SAO parameters.
  • the SAO parameter acquisition unit 2013 notifies the pixel value change unit 2014 of the acquired n offset values of each color component.
  • the pixel value change unit 2014 is an example of a class addition unit.
  • the pixel value changing unit 2014 is notified, for each color component, of the pixel value of the pixel belonging to the class selected by the class selection unit 2012 among the pixels included in the decoded image of the block to be processed Add the value. Also, the pixel value changing unit 2014 outputs a decoded image of the block to be processed, to which the offset value has been added for each color component.
  • FIG. 21 is a flowchart showing the flow of class offset processing by the decoder according to the first embodiment.
  • step S 2101 the block readout unit 1741 reads a decoded image of a block to be processed among the decoded images of the blocks acquired by the pixel adaptive offset processing unit 1720.
  • the pixel number calculation unit 2011 divides the gradation of the pixel value of each color component into a plurality of classes having a predetermined number of gradations in the decoded image of the block to be processed. Further, the number-of-pixels calculating unit 2011 calculates the number of pixels belonging to each class by classifying each pixel included in the decoded image of the block to be processed into each class based on the pixel value for each color component. Do. Furthermore, the class selecting unit 2012 selects, for each color component, the top n classes having a large number of calculated pixels.
  • the class selection unit 2012 selects m classes around the median value (1 ⁇ (bitdepth-1)) of the gradation value. Then, the top n classes having a large number of calculated pixels are selected from m.
  • step S2104 the SAO parameter acquisition unit 2013 acquires offset values (n offset absolute values, n offset codes) of n classes for each color component as SAO parameters included in the supplementary information.
  • step S2105 the pixel value changing unit 2014 acquires, for each color component, n acquired offset values (n offset absolute values, n values) with respect to the pixel values of the pixels belonging to each of the selected n classes. Offset code) is added.
  • the pixel adaptive offset processing unit has a class offset processing unit instead of the band offset processing unit, and the class offset processing unit .
  • the gradation of the pixel value of each color component in the decoded image of the block to be processed is divided into a plurality of classes having a predetermined number of gradations.
  • the number of pixels belonging to each of a plurality of classes is calculated, the top n classes having a large number of calculated pixels are selected, and the offset value is added to the selected n classes.
  • n selected Offset values can also be added to the classes. Signal the SAO parameter including the added offset value and send it to the decoder.
  • the encoder 110 according to the first embodiment eliminates the need to transmit the band position as the SAO parameter to the decoder. As a result, the bit amount of the SAO parameter can be reduced.
  • the class offset processing unit when the class offset processing unit performs class offset processing, By reducing the number of classes to be selected (by setting the number to 4 or less), it is possible to reduce the number of offset absolute values and offset codes included in the SAO parameter. As a result, the bit amount of the SAO parameter can be further reduced. By reducing the number of gradations that each class has, it becomes possible to add an offset value only to a specific area in which small deterioration has occurred. As a result, the effect of improving color misregistration can be increased.
  • the pixel adaptive offset processing unit has a class offset processing unit instead of the band offset processing unit, and the class offset processing unit
  • the gradation of the pixel value of each color component in the decoded image of the block to be processed is divided into a plurality of classes having a predetermined number of gradations.
  • the number of pixels belonging to each of a plurality of classes is calculated, the top n classes having a large number of calculated pixels are selected, and the offset value is added to the selected n classes.
  • n selected Offset values can also be added to the classes. • Receive an offset value from the encoder as a SAO parameter.
  • the decoder 120 according to the first embodiment eliminates the need to receive the band position via the SAO parameter. As a result, the bit amount of the SAO parameter can be reduced.
  • the class offset processing unit when the class offset processing unit performs class offset processing, By reducing the number of classes to be selected (by setting the number to 4 or less), it is possible to reduce the number of offset absolute values and offset codes included in the SAO parameter. As a result, the bit amount of the SAO parameter can be further reduced. By reducing the number of gradations that each class has, it becomes possible to add an offset value only to a specific area in which small deterioration has occurred. As a result, the effect of improving color misregistration can be increased.
  • the pixel adaptive offset processing unit has a class offset processing unit instead of the band offset processing unit.
  • the same offset process is performed on each color component in the decoded image of the block to be processed.
  • the configuration of the pixel adaptive offset processing unit is not limited to this.
  • a class offset processing unit may be provided.
  • band offset processing or class offset processing may be performed for each color component.
  • FIG. 22 is a diagram illustrating an example of a functional configuration of a loop filter unit of the encoder according to the second embodiment.
  • the difference with the functional configuration shown in FIG. 10 is that the pixel adaptive offset processing unit 2200 has a band offset processing unit 522 in addition to the edge offset processing unit 521, the class offset processing unit 1001, and the selection unit 1002. It is a point.
  • the pixel adaptive offset processing unit 2200 performs, for example, band offset processing by the band offset processing unit 522 for the luminance signal (Y) among the color components. Further, the color offset signal (Cb, Cr) is controlled to perform class offset processing by the class offset processing unit 1001. However, whether to perform band offset processing or class offset processing for each color component is set in advance.
  • FIG. 22 shows the functional configuration of the loop filter unit of the encoder 110
  • the loop filter unit of the decoder 120 can be configured in the same manner.
  • the effect of improving color misregistration can be increased by performing different offset processing for each color component.
  • the first and second embodiments do not particularly mention the transmission order of n offset values, it is assumed that n offset values are transmitted in a predetermined order.
  • the selection unit 1002 may be configured to transmit n offset values in the order of classes in which the number of pixels is large.
  • the selection unit 1002 may be configured to transmit n offset values in the order of classes with small gradation values or in the order of classes with large gradation values.
  • the selection unit 1002 may be configured to transmit n offset values in the order of classes whose tone value is close to the median.
  • the upper n classes having a large number of calculated pixels are described to be selected. However, a plurality of classes having the same number of calculated pixels (n or more) are described. It may also occur if
  • the class selection unit 1012 excludes a part of classes having the same number of calculated pixels from the selection targets so that the number of classes to be selected is n.
  • the classes having the same number of pixels may be compared, and the class having the gradation value farthest from the median may be excluded from the selection targets.
  • the processing by the pixel adaptive offset processing unit 520 is performed after the processing by the deblocking filter unit 510 is performed.
  • the processing by the deblocking filter unit 510 is performed using the pixels of the adjacent block. Therefore, when the pixel to which the offset value is to be added is not determined because the process of calculating the number of pixels is performed later, the deblocking filter unit 510 generates a pixel for which the process can not be performed. In this case, a memory for temporarily holding the pixel is required, and the memory usage increases.
  • the process of calculating the number of pixels in the process by the class offset processing unit 1001 may be performed before the process by the deblocking filter unit 510 is performed.
  • the process of calculating the number of pixels since the pixel to which the offset value is to be added is determined, an increase in memory usage can be avoided.
  • whether the process of calculating the number of pixels is performed before the process of the deblocking filter unit 510 is performed may be defined in units of streams.
  • image processing system 110 encoder 120: decoder 407: loop filter unit 520: pixel adaptive offset processing unit 521: edge offset processing unit 522: band offset processing unit 541: block readout unit 1001: class offset processing unit 1002: selection unit 1011: Pixel number calculation unit 1012: Class selection unit 1013: Offset determination unit 1014: Pixel value change unit 1720: Pixel adaptive offset processing unit 1721: Edge offset processing unit 1741: Block readout unit 2001: Class offset processing unit 2011: Number of pixels Calculation unit 2012: Class selection unit 2013: SAO parameter acquisition unit 2014: Pixel value change unit

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

画質を向上させるとともに、SAOパラメータのビット量を削減する。符号化方法は、符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、オフセット値を加算するクラス加算工程と、加算したオフセット値を含むSAOパラメータをシグナリングする第1のシグナリング工程とを有することを特徴とする。

Description

符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム
 本発明は、符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラムに関する。
 動画像データの圧縮符号化に関する国際標準として、H.265/HEVCが知られている。H.265/HEVCでは、圧縮符号化時の画質の劣化を抑えるループフィルタ技術として、画素適応オフセット(SAO(Sample Adaptive Offset))が導入されている。
 H.265/HEVCで導入された画素適応オフセットには、エッジオフセットとバンドオフセットとが含まれ、圧縮符号化時にいずれかのオフセットを適用することができる。このうち、バンドオフセットは、画素値の階調を32個のバンドに分割し、その中から決定したバンドポジションに基づく連続した4個のバンドを選択したうえで、該4個のバンドそれぞれに属する画素の画素値にオフセット値を加算(または減算)する処理である。
 かかるバンドオフセットを適用することで、特定の連続する階調値に対応する画素値を調節することができるため、圧縮符号化時の誤差を低減させ画質を改善することができる。
特表2014-534762号公報
 しかしながら、現状のバンドオフセットは、バンド幅が広いうえに、特定の連続する階調値を対象としているため、画素値の詳細な調節を行うことが困難であり、画質の向上には限界があるという問題がある。
 例えば、色差における階調値の中央値付近は無彩色であるため、歪みがある場合、主観的画質の劣化が生じやすいが、現状のバンドオフセットでは、バンド幅が広いうえに、中央値以外の連続した4個のバンドが対象となった場合に、適切な対象にオフセット値を加算(または減算)することができない。このようなことから、現在検討中である次世代ビデオコーデック(H.265/HEVCに続く次世代コーデック)においては、バンドオフセットにおける画質の向上が望まれる。
 また、バンドオフセットは、処理対象のブロックごとに、決定したバンドポジションと、選択した4個のバンドそれぞれに対応するオフセット値とを含むSAOパラメータをシグナリングしてデコーダに送信する。このため、デコーダに送信されるSAOパラメータのビット量が大きいという問題がある。このようなことから、現在検討中である次世代ビデオコーデックにおいては、SAOパラメータのビット量を削減することが望まれる。
 一つの側面では、画質を向上させるとともに、SAOパラメータのビット量を削減することを目的としている。
 一態様によれば、符号化方法は、以下の構成を備える。すなわち、
 符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、
 算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、オフセット値を加算するクラス加算工程と、
 加算したオフセット値を含むSAOパラメータをシグナリングする第1のシグナリング工程とを有することを特徴とする。
 画質を向上させるとともに、SAOパラメータのビット量を削減することができる。
図1は、エンコーダ及びデコーダの適用例を示す図である。 図2は、エンコーダ及びデコーダの他の適用例を示す図である。 図3は、エンコーダのハードウェア構成の一例を示す図である。 図4は、エンコーダの機能構成の一例を示す図である。 図5は、一般的なエンコーダのループフィルタ部の機能構成の一例を示す図である。 図6は、一般的なエンコーダによる画素適応オフセット処理の流れを示すフローチャートである。 図7は、一般的なエンコーダにおけるバンドオフセット処理の処理内容を説明するための図である。 図8は、一般的なエンコーダによるバンドオフセット処理の流れを示すフローチャートである。 図9は、一般的なエンコーダによるシグナリング処理の流れを示すフローチャートである。 図10は、第1の実施形態に係るエンコーダのループフィルタ部の機能構成の一例を示す図である。 図11は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第1の図である。 図12は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第2の図である。 図13は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第3の図である。 図14は、第1の実施形態に係るエンコーダによるクラスオフセット処理の流れを示すフローチャートである。 図15は、第1の実施形態に係るエンコーダによるシグナリング処理の流れを示すフローチャートである。 図16は、デコーダの機能構成の一例を示す図である。 図17は、一般的なデコーダのループフィルタ部の機能構成の一例を示す図である。 図18は、一般的なデコーダによる画素適応オフセット処理の流れを示すフローチャートである。 図19は、一般的なデコーダによるバンドオフセット処理の流れを示すフローチャートである。 図20は、第1の実施形態に係るデコーダのループフィルタ部の機能構成の一例を示す図である。 図21は、第1の実施形態に係るデコーダによるクラスオフセット処理の流れを示すフローチャートである。 図22は、第2の実施形態に係るエンコーダのループフィルタ部の機能構成の一例を示す図である。
 以下、各実施形態について添付の図面を参照しながら説明する。なお、本明細書及び図面において、実質的に同一の機能構成を有する構成要素については、同一の符号を付することにより重複した説明を省略する。
 [第1の実施形態]
 <1.エンコーダ及びデコーダの適用例>
 はじめに、エンコーダ(符号化装置)及びデコーダ(復号装置)の適用例について説明する。図1は、エンコーダ及びデコーダの適用例を示す図である。
 図1に示すように、エンコーダ110を送信装置に、デコーダ120を受信装置にそれぞれ配し、ネットワーク160を介して接続することで、エンコーダ110及びデコーダ120を適用した画像処理システム100を形成することができる。
 画像処理システム100において、送信装置に配されたエンコーダ110は、入力された動画像データを符号化することでデータストリーム(符号化列)を生成する。また、送信装置は生成されたデータストリームを、ネットワーク160を介して受信装置に送信する。
 受信装置はデータストリームを受信する。また、受信装置に配されたデコーダ120は、データストリームを復号することで動画像データを生成し、表示する。
 かかる画像処理システム100を形成することで、動画像データを送信する際の送信負荷を低減できる。このため、画像処理システム100は、インタネット分野、放送分野、通信分野等の種々の分野に適用することができる。
 適用例100aは、画像処理システム100をインタネット分野に適用した例を示している。適用例100aの場合、送信装置110の一例であるサーバ装置111より送信されたデータストリームを、受信装置120の一例であるパーソナルコンピュータ121a、スマート端末121b等が受信し、表示する。これにより、パーソナルコンピュータ121aやスマート端末121bのユーザは、サーバ装置111が保持する動画像データをインタネットを介して視聴することができる。
 適用例100bは、画像処理システム100を放送分野に適用した例を示している。適用例100bの場合、送信装置110の一例である放送用送信機112より送信されたデータストリームを、受信装置120の一例であるテレビ122が受信し、表示する。これにより、例えば、テレビ122のユーザは、放送用送信機112が送信する放送内容を視聴することができる。
 適用例100cは、画像処理システム100を通信分野に適用した例を示している。適用例100cの場合、送信装置110の一例であるテレビ電話機113より送信されたデータストリームを、受信装置120の一例であるテレビ電話機123が受信し、表示する。これにより、テレビ電話機123のユーザは、通話相手の顔を見ながら通話することができる。
 図2は、エンコーダ及びデコーダの他の適用例を示す図である。図2に示すように、エンコーダ110とデコーダ120とを一体的に構成することで、エンコーダ110及びデコーダ120を適用した蓄積装置200を形成することができる。
 蓄積装置200は、入力された動画像データをエンコーダ110が符号化し、生成したデータストリームを記録媒体に格納する。また、蓄積装置200は、記録媒体に格納されたデータストリームを、デコーダ120が復号することで動画像データを生成し、表示する。
 かかる蓄積装置200を形成することで、動画像データを格納する際の容量を低減できるため、例えば、蓄積分野に適用することができる。適用例200aは蓄積装置200を蓄積分野に適用した例を示している。適用例200aの場合、蓄積装置200の一例であるビデオレコーダ211は、内蔵するエンコーダ110が、動画像データを符号化することで生成したデータストリームを記録媒体212に格納する。また、ビデオレコーダ211は、内蔵するデコーダ120が、記録媒体212より読み出したデータストリームを復号することで動画像データを生成し、モニタ213に表示する。これにより、ビデオレコーダ211のユーザは、取得した動画像データを効率的に蓄積することができる。
 <2.エンコーダ及びデコーダのハードウェア構成>
 次に、エンコーダ及びデコーダのハードウェア構成について説明する。なお、エンコーダ110及びデコーダ120は、同様のハードウェア構成を有していることから、ここでは、エンコーダ110のハードウェア構成について説明する。
 図3は、エンコーダのハードウェア構成の一例を示す図である。図3に示すように、エンコーダ110は、CPU(Central Processing Unit)301、ROM(Read Only Memory)302、RAM(Random Access Memory)303を有する。CPU301、ROM302、RAM303は、いわゆるコンピュータを形成する。また、エンコーダ110は、補助記憶装置304、入力装置305、表示装置306、接続装置307、ドライブ装置308を有する。なお、エンコーダ110の各ハードウェアは、バス309を介して相互に接続される。
 CPU301は、補助記憶装置304にインストールされた各種プログラム(例えば、符号化プログラム(デコーダ120の場合にあっては、復号プログラム)等)を実行する。
 ROM302は、不揮発性メモリである。ROM302は、補助記憶装置304にインストールされた各種プログラムをCPU301が実行するために必要な各種プログラム、データ等を記憶する、主記憶デバイスとして機能する。具体的には、ROM302はBIOS(Basic Input/Output System)やEFI(Extensible Firmware Interface)等のブートプログラム等を記憶する。
 RAM303は、DRAM(Dynamic Random Access Memory)やSRAM(Static Random Access Memory)等の揮発性メモリである。RAM303は、補助記憶装置304にインストールされた各種プログラムがCPU301によって実行される際に展開される作業領域を提供する、主記憶デバイスとして機能する。
 補助記憶装置304は、インストールされた各種プログラムや、各種プログラムを実行する際に用いる情報を記憶する補助記憶デバイスである。
 入力装置305は、エンコーダ110に対して各種指示を入力する際に用いる入力デバイスである。
 表示装置306は、エンコーダ110の内部情報を表示する表示デバイスである。接続装置307は、エンコーダ110が外部からの動画像データを受け付けたり、エンコーダ110がデコーダ120と接続し、通信を行うための通信デバイスである。
 ドライブ装置308はコンピュータ読み取り可能な記録媒体310をセットするためのデバイスである。ここでいう記録媒体310には、CD-ROM、フレキシブルディスク、光磁気ディスク等のように情報を光学的、電気的あるいは磁気的に記録する媒体が含まれる。あるいは、記録媒体310には、ROM、フラッシュメモリ等のように情報を電気的に記録する半導体メモリ等が含まれていてもよい。
 なお、補助記憶装置304にインストールされる各種プログラムは、例えば、配布された記録媒体310がドライブ装置308にセットされ、該記録媒体310に記録された各種プログラムがドライブ装置308により読み出されることでインストールされてもよい。あるいは、補助記憶装置304にインストールされる各種プログラムは、接続装置307を介してネットワーク160からダウンロードされることでインストールされる。
 なお、図3に示すハードウェア構成は、あくまで一例にすぎず、適用形態によっては、図3に示すハードウェアの一部を除外して、あるいは他のハードウェアに置き換えてもよいことはいうまでもない。
 <3.エンコーダの機能構成>
 次に、符号化プログラムを実行することで実現される、エンコーダ110の機能構成について説明する。図4は、エンコーダの機能構成の一例を示す図である。図4に示すように、エンコーダ110は、ブロック分割部401、直交変換部402、量子化部403、エントロピ符号化部404を有する。また、エンコーダ110は、逆量子化部405、逆直交変換部406、ループフィルタ部407、復号画像記憶部408、イントラ/インタ予測部409を有する。
 ブロック分割部401は、入力された動画像データに含まれる各画面(入力画面)をストリームで固定サイズのブロックに分割する。更に、ブロック分割部401は、固定サイズのブロックそれぞれを、更に再帰的に、符号化単位のブロックに分割する。
 なお、H.265/HEVCにおけるブロック分割部では、入力画面をストリームで固定サイズのブロックであるCTU(Coding Tree Unit)に分割する。また、H.265/HEVCにおけるブロック分割部では、各CTUのブロックを符号化単位のブロックであるCU(Coding Unit)に分割する。更に、H.265/HEVCにおけるブロック分割部では、各CUのブロックを予測ユニット(PU(Prediction Unit))と変換ユニット(TU(Transform Unit))のブロックに分割する。
 しかしながら、H.265/HEVCに続く次世代コーデックでは、PU、TUを廃止し、全てCUのブロックに分割することが見込まれている。このため、本実施形態では、ブロック分割部401が、CTUのブロックを、全てCUのブロックに分割するものとして説明する。なお、H.265/HEVCに続く次世代コーデックにおいて検討されている内容によれば、CTUのブロックのサイズは、最大128画素×128画素であるので、以下では、CTUのブロックのサイズは、128画素×128画素として説明する。
 ブロック分割部401によりCUのブロックに分割された各入力画面は、イントラ/インタ予測部409に通知されるとともに、予測残差信号の算出に用いられる。
 直交変換部402は、入力画面内の各CUのブロックの入力画像と、対応する各CUのブロックの予測画像との差分に基づいて算出された予測残差信号に対して直交変換処理を実行する。
 量子化部403は、直交変換処理が実行された予測残差信号を量子化することで量子化信号を生成し、エントロピ符号化部404及び逆量子化部405に出力する。
 エントロピ符号化部404は、量子化信号をエントロピ符号化することで、データストリームを生成し、出力する。
 逆量子化部405は、量子化信号を逆量子化し、逆直交変換部406に出力する。逆直交変換部406は、逆量子化された量子化信号に対して逆直交変換処理を実行する。逆直交変換部406により得られた信号に対しては、例えば、イントラ/インタ予測部409が生成した予測画像が加算されることで復号画像が生成され、ループフィルタ部407に入力される。
 ループフィルタ部407は、入力された復号画像の符号化ノイズを低減するフィルタ処理を行う。なお、ループフィルタ部407は、更に、
・デブロッキングフィルタ(Deblocking Filter)部、
・画素適応オフセット(Sample Adaptive Offset)処理部、
を有する(詳細は後述)。ループフィルタ部407が有するこれらの各部が処理を実行する際に用いるパラメータ(例えば、画素適応オフセット処理部が画素適応オフセット処理を実行する際に用いる画素適応オフセットパラメータ(SAOパラメータ)等)はシグナリングされる。ループフィルタ部407によりシグナリングされたパラメータ(SAOパラメータを含む)は、付帯情報としてエントロピ符号化部404によりデータストリームに組み込まれる。
 復号画像記憶部408は、ループフィルタ部407によりフィルタ処理された復号画像を画面ごとに記憶する。
 イントラ/インタ予測部409は、復号中の画面内の各CUのブロックの復号画像を用いて処理対象のCUのブロックの予測画像を生成するイントラ予測(画面内予測)を行う。また、イントラ/インタ予測部409は、参照画面内の各CUのブロックの復号画像を用いて画面間で動き補償を行い、処理対象のCUのブロックの予測画像を生成する動き補償インタ予測(画面間予測)を行う。
 更に、イントラ/インタ予測部409は、イントラ予測により生成された各CUのブロックの予測画像であるイントラ予測画像または動き補償インタ予測により生成された各CUのブロックの予測画像であるインタ予測画像のいずれか一方を出力する。
 イントラ/インタ予測部409より出力された各CUのブロックの予測画像は、入力画面内の各CUのブロックの入力画像との残差計算に用いられ、算出された予測残差信号は、直交変換部402に入力される。また、イントラ/インタ予測部409より出力された予測画像は、逆直交変換部406により得られた信号に加算され、復号画像としてループフィルタ部407に入力される。
 <4.ループフィルタ部の説明>
 続いて、エンコーダ110のループフィルタ部407の詳細について説明する。なお、エンコーダ110のループフィルタ部407の詳細を説明するにあたっては、まず、比較対象として、一般的な(H.265/HEVCにおける)エンコーダのループフィルタ部について詳細を説明する。以下、「4.1」~「4.4」までは、一般的なエンコーダのループフィルタ部について詳細を説明する。その後、「4.5」~「4.8」において、第1の実施形態に係るエンコーダ110のループフィルタ部407について詳細を説明する。
 <4.1 一般的なエンコーダのループフィルタ部の機能構成>
 図5は、一般的なエンコーダのループフィルタ部の機能構成の一例を示す図である。図5に示すように、ループフィルタ部は、デブロッキングフィルタ部510、画素適応オフセット処理部520を有する。
 デブロッキングフィルタ部510は、処理対象のブロックの復号画像をフィルタ処理することで、入力画面内の各CUのブロックの入力画像を符号化した際にブロック境界で生じた歪を減少させる。画素適応オフセット処理部520は、デブロッキングフィルタ部510によりフィルタ処理された処理対象のブロックの復号画像を、画素単位で分類し、各画素に対して分類に応じたオフセット値を加算する。
 なお、画素適応オフセット処理部520は、具体的には、エッジオフセット処理部521、バンドオフセット処理部522、選択部523を有する。
 エッジオフセット処理部521は、エッジオフセットクラスとして指定された方向に連続する3画素の画素値の大小関係によりエッジ状態を分類する。また、エッジオフセット処理部521は、エッジ状態の分類に対応するオフセット値を処理対象のブロックの復号画像の画素値に加算する。更に、エッジオフセット処理部521は、画素値にオフセット値が加算された処理対象のブロックを、選択部523に通知する。
 なお、エッジオフセット処理部521は、これらの処理(エッジオフセット処理)を、エッジオフセット処理に関わるSAOパラメータを変更しながら、それぞれのSAOパラメータについて実行する。
 バンドオフセット処理部522は、処理対象のブロックの復号画像が取り得る画素値の階調を32個のバンドに分割し、その中から決定したバンドポジションに基づく連続した4個のバンドを選択する。そして、バンドオフセット処理部522は、該4個のバンドそれぞれに属する画素の画素値に、オフセット値を加算(または減算)する。
 具体的には、バンドオフセット処理部522は、図5の右側に示すように、ブロック読み出し部541、SAOパラメータ決定部542、画素値変更部543を有する。ブロック読み出し部541は、画素適応オフセット処理部520が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出し、画素値変更部543に通知する。SAOパラメータ決定部542は、処理対象のブロックの復号画像が取り得る画素値の階調を32個のバンドに分割するとともに、バンドオフセット処理に関わるSAOパラメータ(バンドポジション、オフセット値)を決定し、画素値変更部543に出力する。
 画素値変更部543は、処理対象のブロックの復号画像の各色成分(輝度信号(Y)、色差信号(Cb、Cr))の画素値のうち、バンドポジションに基づく連続した4個のバンドそれぞれに属する画素の画素値に、オフセット値を加算する。また、画素値変更部543はオフセット値が加算された処理対象のブロックの復号画像を、バンドオフセット処理に関わるSAOパラメータ(バンドポジション、オフセット値)とともに選択部523に通知する。
 なお、バンドオフセット処理部522は、これらの処理(バンドオフセット処理)を、バンドオフセット処理に関わるSAOパラメータ(バンドポジション、オフセット値)を変更しながら、それぞれのSAOパラメータについて実行する。
 選択部523は、処理対象のブロックの復号画像に対して、エッジオフセット処理部521が行った各処理結果、及び、バンドオフセット処理部522が行った各処理結果をそれぞれ取得し、レート歪(RD(Rate Distortion))コストを算出する。また、選択部523は、算出したRDコストが最も低い処理結果を判定し、判定した処理結果の算出に用いられたSAOパラメータをシグナリングする。
 <4.2 一般的なエンコーダの画素適応オフセット処理部による画素適応オフセット処理の流れ>
 次に、一般的なエンコーダの画素適応オフセット処理部520による画素適応オフセット処理の流れについて説明する。図6は、一般的なエンコーダによる画素適応オフセット処理の流れを示すフローチャートである。
 処理対象のブロックについてデブロッキングフィルタ部510によるデブロッキングフィルタ処理が完了すると、画素適応オフセット処理部520は、図6に示す画素適応オフセット処理を開始する。なお、ここでは説明の簡略化のため、処理対象のブロック1個分の処理について説明する。
 ステップS601において、画素適応オフセット処理部520は、処理対象のブロックを取得する。
 ステップS602において、エッジオフセット処理部521は、取得された処理対象のブロックを読み出し、エッジオフセット処理に関わる所定のSAOパラメータを用いて、エッジオフセット処理を行う。
 ステップS603において、選択部523は、ステップS602におけるエッジオフセット処理の処理結果について、RDコストを算出する。
 ステップS604において、エッジオフセット処理部521は、処理対象のブロックに対して、予め定められた範囲内の全てのSAOパラメータ(エッジオフセット処理に関わるSAOパラメータ)を用いてエッジオフセット処理を実行したか否かを判定する。
 ステップS604において、エッジオフセット処理の実行に用いられていないSAOパラメータがあると判定した場合には(ステップS604においてNoの場合には)、ステップS602に戻る。
 一方、ステップS604において、予め定められた範囲内の全てのSAOパラメータを用いてエッジオフセット処理を実行したと判定した場合には、ステップS605に進む。
 ステップS605において、バンドオフセット処理部522は、処理対象のブロックを読み出し、バンドオフセット処理に関わる所定のSAOパラメータを用いて、バンドオフセット処理(詳細は後述)を行う。
 ステップS606において、選択部523は、ステップS605におけるバンドオフセット処理の処理結果について、RDコストを算出する。
 ステップS607において、バンドオフセット処理部522は、処理対象のブロックに対して、予め定められた範囲内の全てのSAOパラメータ(バンドオフセット処理に関わるSAOパラメータ)を用いてバンドオフセット処理を実行したか否かを判定する。
 ステップS607において、バンドオフセット処理の実行に用いられていないSAOパラメータがあると判定した場合には(ステップS607においてNoの場合には)、ステップS605に戻る。
 一方、ステップS607において、予め定められた範囲内の全てのSAOパラメータを用いてバンドオフセット処理を実行したと判定した場合には、ステップS608に進む。
 ステップS608において、選択部523は、エッジオフセット処理部521が行った各処理結果、及び、バンドオフセット処理部522が行った各処理結果それぞれのRDコストを比較し、RDコストが最も低い処理結果を判定する。また、選択部523は、判定した処理結果の算出に用いられたSAOパラメータを特定する。
 ステップS609において、選択部523は、判定した処理結果を、画素適応オフセット処理の処理結果として出力する。
 ステップS610において、選択部523は、特定したSAOパラメータについてシグナリング処理(詳細は後述)を行う。
 <4.3 一般的なエンコーダにおけるバンドオフセット処理(ステップS605)の詳細>
 次に、一般的なエンコーダにおけるバンドオフセット処理(ステップS605)の詳細について説明する。
 (1)バンドオフセット処理の処理内容
 はじめに、バンドオフセット処理(ステップS605)の処理内容について説明する。図7は、一般的なエンコーダにおけるバンドオフセット処理の処理内容を説明するための図である。このうち、図7の700aは、処理対象のブロックを示している。図7の700aに示すように、一般的なエンコーダの場合、バンドオフセット処理は、復号中の画面710においてCTU単位のブロックに対して実行される。図7の700aの例は、128画素×128画素のCTU720のブロックに対してバンドオフセット処理が実行され、処理結果として、CTU720'のブロックが生成された様子を示している。
 図7の700bは、バンドオフセット処理の具体例を示している。ここでは、復号中の画面710の各色成分(輝度信号(Y)、色差信号(Cb、Cr))のうち、色差信号(Cr)に対するバンドオフセット処理について説明する。
 図7の700bに示すように、復号中の画面710において、処理対象のブロックの復号画像における色差信号(Cr)の取り得る画素値が256階調であった場合、画素値変更部543では、当該256階調を、32個のバンドに分割する。これにより、1バンドあたりの階調数は8階調となる。
 ここで、SAOパラメータ決定部542が、CTU720のブロックの復号画像に対するバンドポジションとして、矢印730で示すバンドポジションを出力したとする。この場合、画素値変更部543は、連続する4個のバンドとして、バンド731~734を特定する。
 そして、画素値変更部543は、CTU720のブロックの復号画像に含まれる各画素のうち、バンド731に属する画素の色差信号(Cr)の画素値にオフセット値Vを加算する。同様に、画素値変更部543は、CTU720のブロックの復号画像に含まれる各画素のうち、バンド732に属する画素の色差信号(Cr)の画素値にオフセット値Vを加算する。同様に、画素値変更部543は、CTU720のブロックの復号画像に含まれる各画素のうち、バンド733に属する画素の色差信号(Cr)の画素値にオフセット値Vを加算する。同様に、画素値変更部543は、CTU720のブロックの復号画像に含まれる各画素のうち、バンド734に属する画素の色差信号(Cr)の画素値にオフセット値Vを加算する。
 このように、バンドオフセット処理部522では、バンドオフセット処理に関わるSAOパラメータ=(矢印730で示すバンドポジション、オフセット値V~V)を用いて、CTU720のブロックの復号画像に対してバンドオフセット処理を行う。なお、バンドオフセット処理部522では、輝度信号(Y)、色差信号(Cb)に対しても同様のバンドオフセット処理を行うものとする。これにより、バンドオフセット処理の処理結果として、CTU720'のブロックが生成される。
 なお、連続する4個のバンドそれぞれに加算(または減算)するオフセット値V~Vは、異なる値であっても同じ値(1種類の値)であってもよい。
 (2)バンドオフセット処理の流れ
 続いて、一般的なエンコーダによるバンドオフセット処理(ステップS605)の詳細なフローチャートについて説明する。図8は、一般的なエンコーダによるバンドオフセット処理の流れを示すフローチャートである。
 ステップS801において、ブロック読み出し部541は、画素適応オフセット処理部520が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出す。
 ステップS802において、SAOパラメータ決定部542は、バンドオフセット処理に関わるSAOパラメータとして、"バンドポジション"、連続する4個のバンドのオフセット値として"オフセットの絶対値"及び"オフセットの符号"を色成分ごとに決定する。なお、SAOパラメータ決定部542によって決定されるバンドオフセット処理に関わるSAOパラメータの範囲は色成分ごとに予め定められているものとし、SAOパラメータ決定部542は、当該範囲内のSAOパラメータを順次決定していく。また、SAOパラメータ決定部542は、色成分ごとに決定したバンドオフセット処理に関わるSAOパラメータ(各色成分のバンドポジション、4個のオフセット絶対値、4個のオフセット符号)を、順次、画素値変更部543に出力していく。
 ステップS803において、画素値変更部543は、処理対象のブロックの復号画像の画素値を、バンドオフセット処理に関わるSAOパラメータ(各色成分のバンドポジション、4個のオフセット絶対値、4個のオフセット符号)を用いて色成分ごとに変更する。
 <4.4 一般的なエンコーダによるシグナリング処理(ステップS610)の詳細>
 次に、一般的なエンコーダによるシグナリング処理(ステップS610)の詳細について説明する。図9は、一般的なエンコーダによるシグナリング処理の流れを示すフローチャートである。なお、ここでは、RDコスト比較により、バンドオフセット処理に関わるSAOパラメータを用いたバンドオフセット処理の処理結果が、最もRDコストが低い処理結果であると判定されたものとして説明する。
 ステップS901において、選択部523は、画素適応オフセット処理において、バンドオフセット処理の処理結果が選択されたことを示す情報をシグナリングする。
 ステップS902において、選択部523は、最もRDコストが低い処理結果が算出された際の、バンドオフセット処理に関わるSAOパラメータである、各色成分の4個のオフセット絶対値をシグナリングする。
 ステップS903において、選択部523は、最もRDコストが低い処理結果が算出された際の、バンドオフセット処理に関わるSAOパラメータである、各色成分の4個のオフセット符号をシグナリングする。
 ステップS904において、選択部523は、最もRDコストが低い処理結果が算出された際の、バンドオフセット処理に関わるSAOパラメータである、各色成分のバンドポジションをシグナリングする。
 <4.5 第1の実施形態に係るエンコーダのループフィルタ部の機能構成>
 続いて、第1の実施形態に係るエンコーダ110のループフィルタ部407の機能構成について説明する。
 図10の右側は、第1の実施形態に係るエンコーダのループフィルタ部の機能構成の一例を示す図である。なお、図5を用いて説明した、一般的なエンコーダのループフィルタ部と同様の機能については同じ符号を付すこととし、ここでは説明を省略する。
 図5との相違点は、画素適応オフセット処理部520がクラスオフセット処理部1001を有する点と、選択部1002の機能が選択部523の機能とは異なる点である。なお、後述するように、クラスオフセット処理部1001は、色差歪みを削減することも可能であり、CAR(Chroma Artifact Reduction) SAOとしての機能も有する。
 図10に示すように、クラスオフセット処理部1001は、ブロック読み出し部541と、画素数算出部1011と、クラス選択部1012と、オフセット決定部1013と、画素値変更部1014とを有する。
 ブロック読み出し部541は、画素適応オフセット処理部520が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出し、画素値変更部1014に通知する。
 画素数算出部1011は算出部の一例である。画素数算出部1011は、処理対象のブロックの復号画像の各色成分(輝度信号(Y)、色差信号(Cb、Cr))の画素値の階調を、所定の階調数を有する複数のグループに分割する。以降、当該グループを、「クラス」と称する。画素数算出部1011は、画素値の階調を、各クラスが同じ階調数を有するように分割してもよいし、異なる階調数を有するように分割してもよい。
 また、各クラスが有する階調数は、図5で示したバンドオフセット処理部522により32個のバンドに分割された際の、各バンドが有する階調数(画素値が256階調であった場合、各バンドが有する階調数は"8")よりも多くても少なくてもよい。
 なお、各クラスが有する階調数を、各バンドが有する階調数よりも少なくした場合(つまり、バンド幅を狭くした場合)、処理対象のブロック内において、小さな劣化が起こっている特定領域に対してオフセット値を加算することができる。この場合、一般的なエンコーダのバンドオフセット処理と比較して、色ずれの改善効果を大きくすることができる。
 画素数算出部1011は、処理対象のブロックの復号画像に含まれる各画素を、色成分ごとに、画素値に基づいて、各クラスに分類することで、各クラスに属する画素の数を算出する。
 クラス選択部1012は、算出された画素の数の多い上位n個のクラス(nは1以上の整数。例えば、"3")を色成分ごとに選択して、画素値変更部1014に通知する。
 なお、色成分ごとに選択する上位n個のクラスを4個未満とすることで(つまり、一般的なエンコーダの場合と比較してオフセット値を加算するバンド数を少なくすることで)、各色成分のオフセット値をシグナリングした際のビット量を減らすことができる。
 クラス選択部1012は、別例として、処理対象のブロックの復号画像の各色成分が色差信号(Cb、Cr)の場合は、階調値の中央値(1<<(bitdepth-1))前後のm個のクラス(mは1以上の整数。例えば"6")を選択し、m個の中から、算出された画素の数の多い上位n個のクラス(nは1以上の整数。例えば、"3")を選択して、画素値変更部1014に通知する。
 なお、階調値の中央値付近は無彩色であり、歪みがある場合、中央値付近を固定で選択することで、主観的な画質を向上させることができる。また、選択する上位n個のクラスを4個未満とすることで(つまり、一般的なエンコーダの場合と比較してオフセット値を加算するバンド数を少なくすることで)、各色成分のオフセット値をシグナリングした際のビット量を減らすことができる。
 オフセット決定部1013は、クラス選択部1012から選択したn個のクラス情報を受け、復号時の画素値の2乗誤差が最小となるように、色成分ごとにn個のオフセット値(n個のオフセット絶対値、n個のオフセット符号)を決定する。また、オフセット決定部1013は、決定した各色成分のn個のオフセット値を画素値変更部1014に通知する。
 画素値変更部1014はクラス加算部の一例である。画素値変更部1014は、処理対象のブロックの復号画像に含まれる各画素のうち、クラス選択部1012により選択されたクラスに属する画素の画素値に対して、色成分ごとに、決定されたオフセット値を加算する。また、画素値変更部1014は、色成分ごとにオフセット値を加算した処理対象のブロックの復号画像を選択部1002に出力する。また、画素値変更部1014は、クラスオフセット処理に関わるSAOパラメータとして、各色成分のオフセット値を含むSAOパラメータを選択部1002に出力する。
 選択部1002はシグナリング部の一例である。選択部1002は、処理対象のブロックの復号画像に対して、エッジオフセット処理部521が行った各処理結果、及び、クラスオフセット処理部1001が行った各処理結果を取得し、RDコストを算出する。また、選択部1002は、算出したRDコストが最も低い処理結果を判定し、判定した処理結果を選択して、適応ループフィルタ部530に出力する。更に、選択部1002は、判定した処理結果の算出に用いられたSAOパラメータをシグナリングする。
 <4.6 第1の実施形態に係るエンコーダにおけるクラスオフセット処理の詳細>
 次に、第1の実施形態に係るエンコーダ110におけるクラスオフセット処理の詳細について説明する。
 (1)クラスオフセット処理の具体例
 はじめに、クラスオフセット処理の具体例について説明する。なお、図7の説明と同様に、ここでも、色差信号(Cr)に対するクラスオフセット処理について説明する。
 (1-1)クラスオフセット処理の具体例その1
 図11は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第1の図である。
 図11の1100aの例は、復号中の画面710において、処理対象のブロックの復号画像における色差信号(Cr)の取り得る画素値が256階調であった場合に、画素数算出部1011が、当該256階調を128個のクラスに均等に分割した様子を示している。これにより、1クラスあたりの階調数は2階調となる。
 また、図11の1100aの例は、画素数算出部1011が、CTU720のブロックの復号画像に含まれる各画素を、色差信号(Cr)の画素値に基づいて各クラスに分類することで、ヒストグラム1101を生成した様子を示している。
 図11の1100bの例は、クラス選択部1012が、算出された画素の数が多い上位3個のクラスを選択した様子を示している。また、図11の1100bの例は、画素値変更部1014が、選択された3個のクラスに属する画素の色差信号(Cr)の画素値に対して、オフセット値V、V、Vをそれぞれ加算した様子を示している。
 図11の1100bの別例として、クラス選択部1012は、階調値の中央値前後の6個のクラスを固定で選択し、3個のクラスを選択するようにしてもよい。
 このように、図11の例の場合、クラスオフセット処理部1001は、CTU720のブロックの復号画像に対して、下記の内容で、クラスオフセット処理を行っている。
・オフセット値を加算する対象を、8階調のバンドよりも狭い2階調のクラスとしている。
・バンドポジションに相当するパラメータを決定せず、各クラスに属する画素の数に基づいて、オフセット値を加算する対象を選択している。また、バンドポジションに相当するパラメータを決定せず、階調値の中央値前後を固定で選択し、各クラスに属する画素の数に基づいて、オフセット値を加算する対象を選択することもできる。
・オフセット値を加算する対象の数を、3個としている。
 これにより、クラスオフセット処理部1001では、CTU720のブロックの復号画像において、小さな劣化が起こっている特定領域の色差信号(Cr)に対してのみオフセット値を加算することができる。このため、一般的なエンコーダのバンドオフセット処理と比較して、色ずれの改善効果を大きくすることができる。
 また、クラスオフセット処理部1001では、バンドポジションに相当するパラメータを、SAOパラメータに含めてデコーダ側に送信する必要がない。このため、一般的なエンコーダのバンドオフセット処理と比較して、デコーダに送信するSAOパラメータのビット量を削減することができる。
 更に、クラスオフセット処理部1001では、SAOパラメータに含めるオフセット値の個数を減らすことができる。このため、一般的なエンコーダのバンドオフセット処理と比較して、デコーダに送信するSAOパラメータのビット量を更に削減することができる。
 (1-2)クラスオフセット処理の具体例その2
 次に、クラスオフセット処理の他の具体例について説明する。図12は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第2の図である。
 図12の1200aの例は、図11の1100aの例と同様に、画素数算出部1011が、CTU720のブロックの復号画像に含まれる各画素を、色差信号(Cr)の画素値に基づいて各クラスに分類することで、ヒストグラム1201を生成した様子を示している。図11の1100aとの相違点は、算出した画素の数が多い上位3個のクラスが、連続していない点である。
 なお、図12の1200bに示すように、クラス選択部1012は、上位3個のクラスが連続しているか否かに関わらず、算出した画素の数が多い上位3個のクラスを選択する。また、画素値変更部1014では、クラス選択部1012により選択された3個のクラスに属する画素の色差信号(Cr)の画素値に対して、オフセット値V、V、Vをそれぞれ加算する。
 このように、クラスオフセット処理部1001では、CTU720のブロックの復号画像に含まれる各画素の画素値の分布に関わらず、上記具体例その1と同様の内容でクラスオフセット処理を行うことで、上記具体例その1と同様の効果を得ることができる。
 加えて、一般的なエンコーダのバンドオフセット処理とは異なり、連続していないクラスに属する画素の画素値に対してもオフセット値を加算することができる。このため、例えば、背景と物体のような色差の値が大きく異なるものが含まれる領域に対しても、それぞれにオフセット値を加算することができるため、色ずれの改善効果を大きくすることができる。
 (1-3)クラスオフセット処理の具体例その3
 次に、クラスオフセット処理の他の具体例について説明する。図13は、第1の実施形態に係るエンコーダにおけるクラスオフセット処理の具体例を示す第3の図である。
 図13の1300aの例は、復号中の画面710において、処理対象のブロックの復号画像における色差信号(Cr)の取り得る画素値が256階調であった場合に、画素数算出部1011が、当該256階調を異なる階調数のクラスに分割した様子を示している。具体的には、画素数算出部1011は、階調数=2のクラスから階調数=16のクラスまで含む複数のクラスに分割している。
 また、図13の1300aの例は、画素数算出部1011が、CTU720のブロックの復号画像に含まれる各画素を、色差信号(Cr)の画素値に基づいて各クラスに分類することで、ヒストグラム1301を生成した様子を示している。図12の1200aとの相違点は、算出した画素の数が多い上位3個のクラスが、それぞれ、異なる階調数(階調数:2、4、6)を有している点である。
 なお、クラス選択部1012は、図13の1300bに示すように、上位3個のクラスそれぞれが有する階調数が同じであるか異なるかに関わらず、算出した画素の数が多い上位3個のクラスを選択する。また、画素値変更部1014では、クラス選択部1012により選択された各クラスに属する画素の色差信号(Cr)の画素値に対して、オフセット値V、V、Vをそれぞれ加算する。または、上位3個のクラスそれぞれが有する階調数が異なる場合には、画素の数が最も多い階調数に属するクラスから、画素の数が多い上位3個のクラスを選択する。
 このように、クラスオフセット処理部1001では、各クラスが有する階調数が同じであるか異なるかに関わらず、上記具体例(具体例その1)と同様の内容でクラスオフセット処理を行うことで、上記具体例その1と同様の効果を得ることができる。
 加えて、一般的なエンコーダのバンドオフセット処理とは異なり、オフセット値を加算する階調数を階調値に応じて変えることができるため、色ずれの改善効果を大きくすることができる。
 (1-4)クラスオフセット処理の具体例その4
 上記(1-1)~(1-3)の例(具体例その1~その3)では、クラス選択部1012が、算出した画素の数が多い上位3個のクラスを選択するものとして説明した。しかしながら、選択するクラスの数は、これに限定されず、例えば、上位4個以上のクラス(例えば、上位4個のクラスあるいは上位6個のクラス)を選択するようにしてもよい。
 また、上記(1-1)~(1-2)の例では、復号中の画面710において、処理対象のブロックの復号画像における色差信号(Cr)の取り得る画素値が256階調であった場合に、各クラスが有する階調数が"2"となるように分割する場合について説明した。
 一方で、復号中の画面710において、処理対象のブロックの復号画像の色差信号(Cr)の画素値は、例えば、0~511の512階調であってもよい。この場合、画素数算出部1011は、各クラスそれぞれが有する階調数が"4"となるように分割してもよい。つまり、均等に分割る場合、各クラスが有する階調数を、階調に応じて変更してもよい。例えば、復号中の画面710において、処理対象のブロックの復号画像における色差信号(Cr)の取り得る画素値のビット深さ(Bit Depth)をBDとおく(色差信号(Cr)の画素値を2BD階調とする)。この場合、画素数算出部1011は、各クラスが有する階調数が、2(BD-7)となるように分割してもよい。ただし、BDは、8以上の整数とする。
 (2)クラスオフセット処理の流れ
 続いて、一般的なエンコーダによるバンドオフセット処理(図6のステップS605)に代わる処理として、第1の実施形態に係るエンコーダ110によるクラスオフセット処理の詳細な流れについて説明する。図14は、第1の実施形態に係るエンコーダによるクラスオフセット処理の流れを示すフローチャートである。
 ステップS1401において、ブロック読み出し部541は、画素適応オフセット処理部520が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出す。
 ステップS1403において、画素数算出部1011は、処理対象のブロックの復号画像において各色成分の画素値の階調を、所定の階調数を有する複数のクラスに分割する。また、画素数算出部1011は、処理対象のブロックの復号画像に含まれる各画素を、色成分ごとに、画素値に基づいて各クラスに分類することで、各クラスに属する画素の数を算出する。更に、クラス選択部1012は、色成分ごとに、算出した画素の数が多い上位n個のクラスを選択する。あるいは、クラス選択部1012は、色成分が色差信号(Cb、Cr)の場合は、階調値の中央値(1<<(bitdepth-1))前後のm個のクラスを選択し、m個の中から、算出した画素の数が多い上位n個のクラスを選択する。
 ステップS1404において、オフセット決定部1013は、選択したn個のクラスに属する画素の画素値に加算するオフセット値として、色成分ごとにn個のオフセット絶対値とn個のオフセット符号とを決定する。
 ステップS1405において、画素値変更部1014は、各色成分において、選択したn個のクラスそれぞれに属する画素の画素値に対して、決定したn個のオフセット値(n個のオフセット絶対値、n個のオフセット符号)を加算する。
 <4.7 第1の実施形態に係るエンコーダによるシグナリング処理の詳細>
 次に、第1の実施形態に係るエンコーダ110によるシグナリング処理の詳細について説明する。図15は、第1の実施形態に係るエンコーダによるシグナリング処理の流れを示すフローチャートである。なお、ここでは、選択部1002におけるRDコスト比較により、クラスオフセット処理に関わるSAOパラメータを用いたクラスオフセット処理の処理結果が、最もRDコストが低い処理結果であると判定されたものとして説明する。
 ステップS1501において、選択部1002は、画素適応オフセット処理において、クラスオフセット処理の処理結果が選択されたことを示す情報をシグナリングする。
 ステップS1502において、選択部1002は、最もRDコストが低い処理結果が算出された際のSAOパラメータのうち、各色成分について算出された、n個のクラスそれぞれのオフセット絶対値をシグナリングする。
 ステップS1503において、選択部1002は、最もRDコストが低い処理結果が算出された際のSAOパラメータのうち、各色成分について算出された、n個のクラスそれぞれのオフセット符号をシグナリングする。
 <5.デコーダの機能構成>
 次に、復号プログラムを実行することで実現される、デコーダ120の機能構成について説明する。図16は、デコーダの機能構成の一例を示す図である。図16に示すように、デコーダ120は、エントロピ復号部1601、逆量子化部1602、逆直交変換部1603、ループフィルタ部1604、復号画像記憶部1605、イントラ/インタ予測部1606を有する。
 エントロピ復号部1601は、受信したデータストリームを復号し、量子化信号を出力する。また、エントロピ復号部1601は、データストリームより付帯情報(ループフィルタ部1604において用いられるSAOパラメータ等を含む)を抽出し、ループフィルタ部1604に通知する。
 逆量子化部1602は、量子化信号を逆量子化し、逆直交変換部1603に出力する。逆直交変換部1603は、逆量子化された量子化信号に対して逆直交変換処理を実行する。
 逆直交変換部1603により逆直交変換処理が実行されることで得られた信号に対しては、例えば、イントラ/インタ予測部1606が生成した予測画像が加算されることで復号画像が生成され、ループフィルタ部1604に入力される。
 ループフィルタ部1604は、通知された付帯情報を用いて、入力された復号画像の符号化ノイズを低減するフィルタ処理を行う。なお、ループフィルタ部1604は、更に、デブロッキングフィルタ部と、画素適応オフセット処理部、適応ループフィルタ部とを有する(詳細は後述)。
 また、ループフィルタ部1604は、フィルタ処理した復号画像を復号結果として出力するとともに、復号画像記憶部1605に記憶する。
 イントラ/インタ予測部1606は、復号中の画面内の各CUのブロックの復号画像を用いて処理対象のCUのブロックの予測画像を生成するイントラ予測を行う。また、イントラ/インタ予測部1606は、参照画面内の各CUのブロックの復号画像を用いて画面内で動き補償を行い、処理対象のCUのブロックの予測画像を生成するインタ予測を行う。
 更に、イントラ/インタ予測部1606は、イントラ予測により生成された各CUのブロックの予測画像であるイントラ予測画像または動き補償インタ予測により生成された各CUのブロックの予測画像であるインタ予測画像のいずれか一方を出力する。出力された予測画像は、逆直交変換部1603により逆直交変換処理が実行されることで得られた信号に加算され、復号画像としてループフィルタ部1604に入力される。
 <6.ループフィルタ部の説明>
 続いて、デコーダ120のループフィルタ部1604の詳細について説明する。なお、デコーダ120のループフィルタ部1604の詳細を説明するにあたっては、まず、比較対象として、一般的な(H.265/HEVCにおける)デコーダのループフィルタ部について詳細を説明する。以下、「6.1」~「6.3」までは、一般的なデコーダのループフィルタ部について詳細を説明する。その後、「6.4」~「6.5」において、第1の実施形態に係るデコーダ120のループフィルタ部1604について詳細を説明する。
 <6.1 一般的なデコーダのループフィルタ部の機能構成>
 図17は、一般的なデコーダのループフィルタ部の機能構成の一例を示す図である。図17に示すように、ループフィルタ部は、デブロッキングフィルタ部1710、画素適応オフセット処理部1720を有する。
 デブロッキングフィルタ部1710は、処理対象のブロックの復号画像をフィルタ処理することで、エンコーダが、入力画面内の各CUのブロックの入力画像を符号化した際にブロック境界で生じた歪を減少させる。画素適応オフセット処理部1720は、デブロッキングフィルタ部1710によりフィルタ処理された処理対象のブロックの復号画像を、画素単位で分類し、各画素に対して分類に応じたオフセット値を加算する。
 なお、画素適応オフセット処理部1720は、具体的には、エッジオフセット処理部1721、バンドオフセット処理部1722を有しており、エントロピ復号部1601より通知された付帯情報に基づいて、いずれかの処理部を実行させる。
 エッジオフセット処理部1721は、エッジオフセットクラスとして指定された方向に連続する3画素の画素値の大小関係によりエッジ状態を分類する。また、エッジオフセット処理部1721は、エッジ状態の分類に対応するオフセット値を処理対象のブロックの復号画像の画素値に加算する。
 バンドオフセット処理部1722は、処理対象のブロックの復号画像が取り得る画素値の階調を32個のバンドに分割し、その中からバンドポジションに基づく連続した4個のバンドを選択する。そして、バンドオフセット処理部1722は、該4個のバンドそれぞれに属する画素の画素値に、オフセット値を加算(または減算)する。
 具体的には、バンドオフセット処理部1722は、図17の右側に示すように、ブロック読み出し部1741、SAOパラメータ取得部1742、画素値変更部1743を有する。ブロック読み出し部1741は、画素適応オフセット処理部1720が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出し、画素値変更部1743に通知する。SAOパラメータ取得部1742は、処理対象のブロックの復号画像が取り得る画素値の階調を32個のバンドに分割する。また、SAOパラメータ取得部1742は、付帯情報に含まれるバンドオフセット処理に関わるSAOパラメータ(バンドポジション、オフセット値)を取得し、画素値変更部1743に出力する。
 画素値変更部1743は、処理対象のブロックの復号画像の各色成分(輝度信号(Y)、色差信号(Cb、Cr))の画素値を、SAOパラメータ取得部1742より出力された、バンドオフセット処理に関わるSAOパラメータを用いて変更する。また、画素値変更部1743は画素値を変更した処理対象のブロックの復号画像を出力する。
 適応ループフィルタ部530は、画素適応オフセット処理部520によりオフセット処理された処理対象のブロックの復号画像をフィルタ処理することで、対応する入力画像との誤差を低減させる。
 <6.2 一般的なデコーダの画素適応オフセット処理部による画素適応オフセット処理の流れ>
 次に、一般的なデコーダの画素適応オフセット処理部1720による画素適応オフセット処理の流れについて説明する。図18は、一般的なデコーダによる画素適応オフセット処理の流れを示すフローチャートである。
 処理対象のブロックについてデブロッキングフィルタ部1710によるデブロッキングフィルタ処理が完了すると、画素適応オフセット処理部1720は、図18に示す画素適応オフセット処理を開始する。なお、ここでは説明の簡略化のため、処理対象のブロック1個分の処理について説明する。
 ステップS1801において、画素適応オフセット処理部1720は、処理対象のブロックを取得する。
 ステップS1802において、画素適応オフセット処理部1720は、エントロピ復号部1601より付帯情報を取得する。
 ステップS1803において、画素適応オフセット処理部1720は、取得した付帯情報に基づいて、オフセットモードがバンドオフセットモードか否かを判定する。ステップS1803においてバンドオフセットモードであると判定した場合には(ステップS1803においてYesの場合には)、ステップS1804に進む。
 ステップS1804において、バンドオフセット処理部1722は、付帯情報に含まれるバンドオフセット処理に関わるSAOパラメータを用いて、バンドオフセット処理を実行する。
 一方、ステップS1803においてバンドオフセットモードではないと判定した場合には(ステップS1803においてNoの場合には)、ステップS1805に進む。
 ステップS1805において、画素適応オフセット処理部1720は、オフセットモードがエッジオフセットモードか否かを判定する。ステップS1805においてエッジオフセットモードであると判定した場合には(ステップS1805においてYesの場合には)、ステップS1806に進む。
 ステップS1806において、エッジオフセット処理部1721は、付帯情報に含まれるエッジオフセット処理に関わるSAOパラメータを用いてエッジオフセット処理を実行する。
 一方、ステップS1805において、エッジオフセットモードでないと判定した場合には(ステップS1805においてNoの場合には)、オフセットモードがオフであると判定して、処理対象のブロックに対する画素適応オフセット処理を終了する。
 <6.3 一般的なデコーダの画素適応オフセット処理部のバンドオフセット処理部によるバンドオフセット処理の流れ>
 続いて、一般的なデコーダによるバンドオフセット処理(ステップS1804)の詳細なフローチャートについて説明する。図19は、一般的なデコーダによるバンドオフセット処理の流れを示すフローチャートである。
 ステップS1901において、ブロック読み出し部1741は、画素適応オフセット処理部1720が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出す。
 ステップS1902において、SAOパラメータ取得部1742は、付帯情報に含まれるバンドオフセット処理に関わるSAOパラメータとして、バンドポジションと、4個のオフセット絶対値と、4個のオフセット符号を色成分ごとに取得する。
 ステップS1903において、画素値変更部1743は、処理対象のブロックの復号画像の画素値を、バンドオフセット処理に関わるSAOパラメータ(バンドポジション、4個のオフセット絶対値、4個のオフセット符号)を用いて色成分ごとに変更する。
 <6.4 第1の実施形態に係るデコーダのループフィルタ部の機能構成>
 次に、第1の実施形態に係るデコーダ120のループフィルタ部1604の機能構成について説明する。
 図20は、第1の実施形態に係るデコーダのループフィルタ部の機能構成の一例を示す図である。なお、図17を用いて説明した、一般的なデコーダのループフィルタ部と同様の機能については同じ符号を付すこととし、ここでは説明を省略する。
 図17との相違点は、画素適応オフセット処理部1720がクラスオフセット処理部2001を有する点である。なお、後述するように、クラスオフセット処理部2001は、色差歪みを削減することも可能であり、CAR SAOとしての機能も有する。図20の右側に示すように、クラスオフセット処理部2001は、ブロック読み出し部1741と、画素数算出部2011と、クラス選択部2012と、SAOパラメータ取得部2013と、画素値変更部2014とを有する。
 ブロック読み出し部1741は、画素適応オフセット処理部1720が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出し、画素値変更部2014に通知する。
 画素数算出部2011は算出部の一例である。画素数算出部2011は、処理対象のブロックの復号画像の各色成分(輝度信号(Y)、色差信号(Cb、Cr))の画素値の階調を、所定の階調数を有する複数のクラスに分割する。画素数算出部2011は、画素値の階調を、各クラスが同じ階調数を有するように分割してもよいし、異なる階調数を有するように分割してもよい。
 また、各クラスが有する階調数は、図17で示したバンドオフセット処理部1722により32個のバンドに分割された際の、各バンドが有する階調数(画素値の階調が256階調であった場合、各バンドが有する階調数は"8")よりも多くても少なくてもよい。
 ただし、画素数算出部2011が各クラスを生成する際の分割方法は、エンコーダ110において、画素数算出部1011が各クラスを生成する際に用いた分割方法と同じであり、予め決められているものとする。
 なお、各クラスが有する階調数を、各バンドが有する階調数よりも少なくした場合(つまり、バンド幅を狭くした場合)、処理対象のブロック内において、小さな劣化が起こっている特定領域に対してオフセット値を加算することができる。この場合、一般的なデコーダのバンドオフセット処理と比較して、色ずれの改善効果を大きくすることができる。
 更に、画素数算出部2011は、処理対象のブロックの復号画像に含まれる各画素を、色成分ごとに、画素値に基づいて、各クラスに分類することで、各クラスに属する画素の数を算出する。
 クラス選択部2012は、算出された画素の数が多い上位n個のクラス(nは1以上の整数。例えば、"3")を色成分ごとに選択して、画素値変更部2014に通知する。
 クラス選択部2012は、別例として、処理対象のブロックの復号画像の各色成分が色差信号(Cb、Cr)の場合は、階調値の中央値(1<<(bitdepth-1))前後のm個のクラス(mは1以上の整数。例えば"6")を選択し、m個の中から、算出された画素の数の多い上位n個のクラス(nは1以上の整数。例えば、"3")を選択して、画素値変更部1014に通知する。
 ただし、クラス選択部2012が選択するクラスの数は、エンコーダ110において、画素数算出部1011が選択するクラスの数と同じであり、予め決められているものとする。
 SAOパラメータ取得部2013は、クラスオフセット処理に関わるSAOパラメータを取得する。なお、本実施形態において、SAOパラメータ取得部2013は、SAOパラメータとして、色成分ごとにn個のオフセット値(n個のオフセット絶対値、n個のオフセット符号)を取得する。また、SAOパラメータ取得部2013は、取得した各色成分のn個のオフセット値を画素値変更部2014に通知する。
 画素値変更部2014はクラス加算部の一例である。画素値変更部2014は、処理対象のブロックの復号画像に含まれる各画素のうち、クラス選択部2012により選択されたクラスに属する画素の画素値に対して、色成分ごとに、通知されたオフセット値を加算する。また、画素値変更部2014は、色成分ごとにオフセット値を加算した処理対象のブロックの復号画像を出力する。
 <6.5 第1の実施形態に係るデコーダによるクラスオフセット処理の詳細>
 次に、一般的なデコーダによるバンドオフセット処理(図18のステップS1804)に代わる処理として、第1の実施形態に係るデコーダ120によるクラスオフセット処理の詳細な流れについて説明する。図21は、第1の実施形態に係るデコーダによるクラスオフセット処理の流れを示すフローチャートである。
 ステップS2101において、ブロック読み出し部1741は、画素適応オフセット処理部1720が取得した各ブロックの復号画像のうち、処理対象のブロックの復号画像を読み出す。
 ステップS2103において、画素数算出部2011は、処理対象のブロックの復号画像において、各色成分の画素値の階調を、所定の階調数を有する複数のクラスに分割する。また、画素数算出部2011は、処理対象のブロックの復号画像に含まれる各画素を、色成分ごとに、画素値に基づいて各クラスに分類することで、各クラスに属する画素の数を算出する。更に、クラス選択部2012は、色成分ごとに、算出した画素の数が多い上位n個のクラスを選択する。あるいは、別例として、クラス選択部2012は、色成分が色差信号(Cb、Cr)の場合は、階調値の中央値(1<<(bitdepth-1))前後のm個のクラスを選択し、m個の中から、算出した画素の数が多い上位n個のクラスを選択する。
 ステップS2104において、SAOパラメータ取得部2013は、付帯情報に含まれるSAOパラメータとして、n個のクラスそれぞれのオフセット値(n個のオフセット絶対値、n個のオフセット符号)を色成分ごとに取得する。
 ステップS2105において、画素値変更部2014は、各色成分において、選択したn個のクラスそれぞれに属する画素の画素値に対して、取得したn個のオフセット値(n個のオフセット絶対値、n個のオフセット符号)を加算する。
 <7.まとめ>
 以上の説明から明らかなように、第1の実施形態に係るエンコーダ110において、画素適応オフセット処理部は、バンドオフセット処理部に代えてクラスオフセット処理部を有しており、該クラスオフセット処理部は、
・処理対象のブロックの復号画像における各色成分の画素値の階調を、所定の階調数を有する複数のクラスに分割する。
・複数のクラスそれぞれに属する画素の数を算出し、算出した画素の数が多い上位n個のクラスを選択し、選択したn個のクラスにオフセット値を加算する。または、階調値の中央値前後を固定で選択し、選択された複数のクラスそれぞれに属する画素の数を算出し、算出した画素の数が多い上位n個のクラスを選択し、選択したn個のクラスにオフセット値を加算することもできる。
・加算したオフセット値を含むSAOパラメータをシグナリングしてデコーダに送信する。
 このように、画素の数に応じてクラスを選択し、オフセット値を加算することで、第1の実施形態に係るエンコーダ110によれば、SAOパラメータとしてバンドポジションをデコーダに送信する必要がなくなる。この結果、SAOパラメータのビット量を削減することができる。
 また、第1の実施形態に係るエンコーダ110は、クラスオフセット処理部がクラスオフセット処理を行う際に、
・選択するクラスの数を減らすことで(4個未満とすることで)、SAOパラメータに含めるオフセット絶対値、オフセット符号の数を減らすことが可能となる。この結果、SAOパラメータのビット量を更に削減することができる。
・各クラスが有する階調数を小さくすることで、小さな劣化が起こっている特定領域に対してのみオフセット値を加算することが可能となる。この結果、色ずれの改善効果を大きくすることができる。
 同様に、第1の実施形態に係るデコーダ120において、画素適応オフセット処理部はバンドオフセット処理部に代えてクラスオフセット処理部を有しており、該クラスオフセット処理部は、
・処理対象のブロックの復号画像における各色成分の画素値の階調を、所定の階調数を有する複数のクラスに分割する。
・複数のクラスそれぞれに属する画素の数を算出し、算出した画素の数が多い上位n個のクラスを選択し、選択したn個のクラスにオフセット値を加算する。または、階調値の中央値前後を固定で選択し、選択された複数のクラスそれぞれに属する画素の数を算出し、算出した画素の数が多い上位n個のクラスを選択し、選択したn個のクラスにオフセット値を加算することもできる。
・SAOパラメータとして、オフセット値をエンコーダより受信する。
 このように、画素の数に応じてクラスを選択し、オフセット値を加算することで、第1の実施形態に係るデコーダ120によれば、SAOパラメータを介してバンドポジションを受信する必要がなくなる。この結果、SAOパラメータのビット量を削減することができる。
 また、第1の実施形態に係るデコーダ120は、クラスオフセット処理部がクラスオフセット処理を行う際に、
・選択するクラスの数を減らすことで(4個未満とすることで)、SAOパラメータに含めるオフセット絶対値、オフセット符号の数を減らすことが可能となる。この結果、SAOパラメータのビット量を更に削減することができる。
・各クラスが有する階調数を小さくすることで、小さな劣化が起こっている特定領域に対してのみオフセット値を加算することが可能となる。この結果、色ずれの改善効果を大きくすることができる。
 [第2の実施形態]
 上記第1の実施形態では、画素適応オフセット処理部が、バンドオフセット処理部に代えて、クラスオフセット処理部を有する構成とした。また、上記第1の実施形態では、処理対象のブロックの復号画像において、各色成分に対して、同様のオフセット処理を行うものとして説明した。
 しかしながら、画素適応オフセット処理部の構成はこれに限定されず、例えば、バンドオフセット処理部に加えて、クラスオフセット処理部を有する構成としてもよい。また、色成分ごとに、バンドオフセット処理またはクラスオフセット処理のいずれかを行うように構成してもよい。以下、第2の実施形態について、上記第1の実施形態との相違点を中心に説明する。
 図22は、第2の実施形態に係るエンコーダのループフィルタ部の機能構成の一例を示す図である。図10に示した機能構成との相違点は、画素適応オフセット処理部2200が、エッジオフセット処理部521、クラスオフセット処理部1001、選択部1002に加えて、バンドオフセット処理部522を有している点である。
 図22に示す機能構成のもと、画素適応オフセット処理部2200では、例えば、各色成分のうち、輝度信号(Y)については、バンドオフセット処理部522によるバンドオフセット処理を行うよう制御する。また、色差信号(Cb、Cr)については、クラスオフセット処理部1001によるクラスオフセット処理を行うよう制御する。ただし、各色成分について、バンドオフセット処理を行うか、クラスオフセット処理を行うかは、予め設定されているものとする。
 なお、図22では、エンコーダ110のループフィルタ部の機能構成について示したが、デコーダ120のループフィルタ部についても同様に構成することができる。
 このように、色成分ごとに、異なるオフセット処理を行う構成とすることで、色ずれの改善効果を大きくすることができる。
 [その他の実施形態]
 上記第1及び第2の実施形態では、n個のオフセット値の送信順序について特に言及しなかったが、n個のオフセット値は、予め定められた順序で送信されるものとする。例えば、選択部1002は、画素の数が多いクラスの順に、n個のオフセット値を送信するように構成してもよい。あるいは、選択部1002は、階調値の小さいクラスの順または階調値の大きいクラスの順に、n個のオフセット値を送信するように構成してもよい。あるいは、選択部1002は、階調値が中央値に近いクラスの順に、n個のオフセット値を送信するように構成してもよい。
 また、上記第1及び第2の実施形態では、算出した画素の数が多い上位n個のクラスを選択するものとして説明したが、算出した画素の数が同数のクラスが複数(n個以上)となる場合も発生しうる。
 このような場合、クラス選択部1012では、選択されるクラスの数がn個になるように、算出した画素の数が同数のクラスの一部を、選択対象から除外する。例えば、画素の数が同数のクラスを比較して、階調値が中央値から最も離れているクラスを、選択対象から除外するようにしてもよい。
 また、上記第1及び第2の実施形態では、デブロッキングフィルタ部510による処理が実行された後に、画素適応オフセット処理部520による処理が実行されるものとして説明した。
 しかしながら、デブロッキングフィルタ部510による処理は、隣接するブロックの画素を利用して行われる。このため、画素の数を算出する処理が後に実行されることでオフセット値が加算される画素が確定しない場合、デブロッキングフィルタ部510では処理を実行することができない画素が生じる。この場合、当該画素を一時的に保持するメモリが必要となり、メモリ使用量が増大する。
 そこで、クラスオフセット処理部1001による処理のうち、画素の数を算出する処理を、デブロッキングフィルタ部510による処理が実行される前に実行するように構成してもよい。これにより、オフセット値が加算される画素が確定するため、メモリ使用量の増大を回避することができる。なお、画素の数を算出する処理を、デブロッキングフィルタ部510による処理が実行される前に実行するか否かは、ストリーム単位で定義するように構成してもよい。
 なお、上記実施形態に挙げた構成等に、その他の要素との組み合わせ等、ここで示した構成に本発明が限定されるものではない。これらの点に関しては、本発明の趣旨を逸脱しない範囲で変更することが可能であり、その応用形態に応じて適切に定めることができる。
 本出願は、2018年1月5日に出願された米国特許第62/613920号に基づきその優先権を主張するものであり、同米国特許出願の全内容を参照することにより本願に援用する。
100      :画像処理システム
110      :エンコーダ
120      :デコーダ
407      :ループフィルタ部
520      :画素適応オフセット処理部
521      :エッジオフセット処理部
522      :バンドオフセット処理部
541      :ブロック読み出し部
1001     :クラスオフセット処理部
1002     :選択部
1011     :画素数算出部
1012     :クラス選択部
1013     :オフセット決定部
1014     :画素値変更部
1720     :画素適応オフセット処理部
1721     :エッジオフセット処理部
1741     :ブロック読み出し部
2001     :クラスオフセット処理部
2011     :画素数算出部
2012     :クラス選択部
2013     :SAOパラメータ取得部
2014     :画素値変更部

Claims (12)

  1.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、オフセット値を加算するクラス加算工程と、
     加算したオフセット値を含むSAOパラメータをシグナリングする第1のシグナリング工程と
     を有することを特徴とする符号化方法。
  2.  前記画素値の階調が2BD階調(BDは8以上の整数)であった場合、前記算出工程は、前記画素値の階調を、少なくとも2(BD-7)の階調数を有する複数のクラスに分割することを特徴とする請求項1に記載の符号化方法。
  3.  前記クラス加算工程は、算出した画素の数が多い上位4個または6個のクラスを選択することを特徴とする請求項1または2に記載の符号化方法。
  4.  符号化単位のブロックの画素値の階調を、32個のバンドに分割するバンド分割工程と、
     前記32個のバンドの中からバンドポジションを決定し、決定したバンドポジションに応じて特定される4個のバンドそれぞれに属する画素の画素値に、オフセット値を加算するバンド加算工程と、
     決定したバンドポジションと、加算したオフセット値とを含むSAOパラメータをシグナリングする第2のシグナリング工程と
     を更に有することを特徴とする請求項1乃至3のいずれか1項に記載の符号化方法。
  5.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、
     シグナリングされたSAOパラメータに含まれるオフセット値を取得する第1の取得工程と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、取得したオフセット値を加算するクラス加算工程と
     を有することを特徴とする復号方法。
  6.  前記画素値の階調が2BD階調(BDは8以上の整数)であった場合、前記算出工程は、前記画素値の階調を、少なくとも2(BD-7)の階調数を有する複数のクラスに分割することを特徴とする請求項5に記載の復号方法。
  7.  前記クラス加算工程は、算出した画素の数が多い上位4個または6個のクラスを選択することを特徴とする請求項5または6に記載の復号方法。
  8.  符号化単位のブロックの画素値の階調を、32個のバンドに分割するバンド分割工程と、
     シグナリングされたSAOパラメータに含まれるバンドポジションとオフセット値とを取得する第2の取得工程と、
     取得したバンドポジションに応じて特定される4個のバンドそれぞれに属する画素の画素値に、取得したオフセット値を加算するバンド加算工程と
     を更に有することを特徴とする請求項5乃至7のいずれか1項に記載の復号方法。
  9.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出部と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、オフセット値を加算するクラス加算部と、
     加算したオフセット値を含むSAOパラメータをシグナリングするシグナリング部と
     を有することを特徴とする符号化装置。
  10.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出部と、
     シグナリングされたSAOパラメータに含まれるオフセット値を取得する取得部と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、取得したオフセット値を加算するクラス加算部と
     を有することを特徴とする復号装置。
  11.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、オフセット値を加算するクラス加算工程と、
     加算したオフセット値を含むSAOパラメータをシグナリングするシグナリング工程と
     をコンピュータに実行させるための符号化プログラム。
  12.  符号化単位のブロックの画素値の階調を、所定の階調数を有する複数のクラスに分割し、該複数のクラスそれぞれに属する画素の数を算出する算出工程と、
     シグナリングされたSAOパラメータに含まれるオフセット値を取得する取得工程と、
     算出した画素の数が多い上位n個(nは1以上の整数)のクラスを選択し、選択したn個のクラスそれぞれに属する画素の画素値に、取得したオフセット値を加算するクラス加算工程と
     をコンピュータに実行させるための復号プログラム。
PCT/JP2018/025141 2018-01-05 2018-07-03 符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム WO2019135294A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
CN201880085180.4A CN111587576B (zh) 2018-01-05 2018-07-03 编码方法、解码方法、编码装置、解码装置以及记录介质
JP2019563922A JP7147788B2 (ja) 2018-01-05 2018-07-03 符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム
US16/918,246 US11330282B2 (en) 2018-01-05 2020-07-01 Encoding and decoding with signaling of SAO parameters

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US201862613920P 2018-01-05 2018-01-05
US62/613920 2018-01-05

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/918,246 Continuation US11330282B2 (en) 2018-01-05 2020-07-01 Encoding and decoding with signaling of SAO parameters

Publications (1)

Publication Number Publication Date
WO2019135294A1 true WO2019135294A1 (ja) 2019-07-11

Family

ID=67143767

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2018/025141 WO2019135294A1 (ja) 2018-01-05 2018-07-03 符号化方法、復号方法、符号化装置、復号装置、符号化プログラム及び復号プログラム

Country Status (4)

Country Link
US (1) US11330282B2 (ja)
JP (1) JP7147788B2 (ja)
CN (1) CN111587576B (ja)
WO (1) WO2019135294A1 (ja)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113099230B (zh) * 2021-02-22 2022-09-06 浙江大华技术股份有限公司 编码方法、装置、电子设备及计算机可读存储介质
CN113194315B (zh) * 2021-04-01 2022-05-31 Tcl华星光电技术有限公司 图像压缩方法及压缩装置

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014533048A (ja) * 2011-11-04 2014-12-08 クゥアルコム・インコーポレイテッドQualcomm Incorporated ビデオコーディングのための適応的な中心帯域オフセットフィルタ
US20150195534A1 (en) * 2011-06-24 2015-07-09 Lg Electronics Inc. Image information encoding and decoding method
JP2017005504A (ja) * 2015-06-10 2017-01-05 日本電信電話株式会社 画像符号化装置、画像復号装置、画像符号化プログラム及び画像復号プログラム

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101826215B1 (ko) 2011-06-23 2018-03-22 후아웨이 테크놀러지 컴퍼니 리미티드 오프셋 복호 장치, 오프셋 부호화 장치, 화상 필터 장치 및 데이터 구조
WO2013046990A1 (ja) 2011-09-29 2013-04-04 シャープ株式会社 オフセット復号装置、オフセット符号化装置、画像フィルタ装置、および、データ構造
GB201119206D0 (en) 2011-11-07 2011-12-21 Canon Kk Method and device for providing compensation offsets for a set of reconstructed samples of an image
WO2013103892A1 (en) * 2012-01-05 2013-07-11 General Instrument Corporation Devices and methods for sample adaptive offset coding and/or selection of edge offset parameters
TWI524739B (zh) * 2012-02-10 2016-03-01 美國博通公司 根據視頻編碼的採樣點自適應偏移(sao)
US9282328B2 (en) 2012-02-10 2016-03-08 Broadcom Corporation Sample adaptive offset (SAO) in accordance with video coding
CN103647975B (zh) * 2013-12-02 2017-01-11 国家广播电影电视总局广播科学研究院 基于直方图分析的改进样本自适应偏移滤波方法
CN103761726B (zh) * 2013-12-25 2017-03-08 河海大学 基于fcm的分块自适应图像分割方法
CN106817583B (zh) * 2015-12-02 2020-01-10 福州瑞芯微电子股份有限公司 一种hevc sao计算方法和装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150195534A1 (en) * 2011-06-24 2015-07-09 Lg Electronics Inc. Image information encoding and decoding method
JP2014533048A (ja) * 2011-11-04 2014-12-08 クゥアルコム・インコーポレイテッドQualcomm Incorporated ビデオコーディングのための適応的な中心帯域オフセットフィルタ
JP2017005504A (ja) * 2015-06-10 2017-01-05 日本電信電話株式会社 画像符号化装置、画像復号装置、画像符号化プログラム及び画像復号プログラム

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
COHEN, R. ET AL.: "Description of screen content coding technology proposal by Mitsubishi Electric Corporation", JOINT COLLABORATIVE TEAM ON VIDEO CODING (JCT-VC) OF ITU-T SG 16 WP3, no. JCTVC-Q0036_r2, 28 March 2014 (2014-03-28), Valencia, ES, pages 6 - 8, XP030115926 *

Also Published As

Publication number Publication date
CN111587576B (zh) 2023-03-31
US11330282B2 (en) 2022-05-10
JPWO2019135294A1 (ja) 2020-12-17
CN111587576A (zh) 2020-08-25
US20200336754A1 (en) 2020-10-22
JP7147788B2 (ja) 2022-10-05

Similar Documents

Publication Publication Date Title
US11601687B2 (en) Method and device for providing compensation offsets for a set of reconstructed samples of an image
US11330282B2 (en) Encoding and decoding with signaling of SAO parameters
WO2020002117A2 (en) Methods and devices for performing sample adaptive offset (sao) filtering
WO2019233997A1 (en) Prediction of sao parameters
WO2019233999A1 (en) Video coding and decoding
WO2019234000A1 (en) Prediction of sao parameters
US10992942B2 (en) Coding method, decoding method, and coding device
US11240535B2 (en) Method and device for filtering image in image coding system
GB2574426A (en) Video coding and decoding
WO2019233998A1 (en) Video coding and decoding
WO2019234001A1 (en) Video coding and decoding

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18898040

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2019563922

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18898040

Country of ref document: EP

Kind code of ref document: A1