A method of video decoding, the method comprising: obtaining, from a bitstream, information about a correction type of pixel values; when the information about a correction type of pixel values indicates one of a band type and an edge type, obtaining a compensation value from the bitstream; characterised in that: when the information about a correction type of pixel values indicates the band type, adding the compensation value to a pixel in a band among pixels of a current block, wherein a total range of values of the pixels are uniformly split into a plurality of bands, the band is one of a plurality of bands, a value of the pixel is in a range of pixel values corresponding to the band, and the compensation value corresponds to the band among the plurality of bands; and when the information about a correction type of pixel values indicates the edge type, adding the compensation value to a pixel corresponding to an edge value level among the pixels of a current block, wherein the edge value level is determined based on whether the value of the pixel is larger or smaller than -values of neighboring restored pixels (31, 32, 33, 34, 35, 36, 37 and 38) on a vertical, a horizontal or a diagonal direction, and the compensation value corresponds to the edge value level among the plurality of edge value levels. obtaining, from a bitstream, information about a correction type of pixel values; when the information about a correction type of pixel values indicates one of a band type and an edge type, obtaining a compensation value from the bitstream; characterised in that: when the information about a correction type of pixel values indicates the band type, adding the compensation value to a pixel in a band among pixels of a current block, wherein a total range of values of the pixels are uniformly split into a plurality of bands, the band is one of a plurality of bands, a value of the pixel is in a range of pixel values corresponding to the band, and the compensation value corresponds to the band among the plurality of bands; and when the information about a correction type of pixel values indicates the edge type, adding the compensation value to a pixel corresponding to an edge value level among the pixels of a current block, wherein the edge value level is determined based on whether the value of the pixel is larger or smaller than -values of neighboring restored pixels (31, 32, 33, 34, 35, 36, 37 and 38) on a vertical, a horizontal or a diagonal direction, and the compensation value corresponds to the edge value level among the plurality of edge value levels. when the information about a correction type of pixel values indicates the band type, adding the compensation value to a pixel in a band among pixels of a current block, wherein a total range of values of the pixels are uniformly split into a plurality of bands, the band is one of a plurality of bands, a value of the pixel is in a range of pixel values corresponding to the band, and the compensation value corresponds to the band among the plurality of bands; and when the information about a correction type of pixel values indicates the edge type, adding the compensation value to a pixel corresponding to an edge value level among the pixels of a current block, wherein the edge value level is determined based on whether the value of the pixel is larger or smaller than -values of neighboring restored pixels (31, 32, 33, 34, 35, 36, 37 and 38) on a vertical, a horizontal or a diagonal direction, and the compensation value corresponds to the edge value level among the plurality of edge value levels.