An image encoding device comprising: circuitry configured to obtain a position of an image block based on a block size of the image block, generate a filter block flag configured to control whether or not the filtering process is performed on the image block, generate a boundary control flag configured to control whether the filtering process, performed on a target pixel, which is adjacent to a slice boundary separating a slice including said target pixel and a neighboring slice and which is provided within the image block of the slice, uses pixels of said neighboring slice after the pixels of said neighboring slice become available or whether the filtering process, performed on the target pixel, uses pixels of the slice alone, the pixels to be used are surrounding pixels surrounding said target pixel, generate block size information of the image block, perform a filtering process on the image block at the position according to the filter block flag, the boundary control flag, and the block size information, and encode the image block on which filtering processing is performed and the filter block flag, the boundary control flag and the block size information, thereby generating encoded data, wherein, in the event that the boundary control flag indicates to use the pixels of the slice alone, said filter processing as to said target pixel to be processed is performed assuming a dummy value for each of the surrounding pixels that are in said neighboring slice, whereby the assumed dummy value is based on pixels of the slice alone. circuitry configured to obtain a position of an image block based on a block size of the image block, generate a filter block flag configured to control whether or not the filtering process is performed on the image block, generate a boundary control flag configured to control whether the filtering process, performed on a target pixel, which is adjacent to a slice boundary separating a slice including said target pixel and a neighboring slice and which is provided within the image block of the slice, uses pixels of said neighboring slice after the pixels of said neighboring slice become available or whether the filtering process, performed on the target pixel, uses pixels of the slice alone, the pixels to be used are surrounding pixels surrounding said target pixel, generate block size information of the image block, generate a filter block flag configured to control whether or not the filtering process is performed on the image block, generate a boundary control flag configured to control whether the filtering process, performed on a target pixel, which is adjacent to a slice boundary separating a slice including said target pixel and a neighboring slice and which is provided within the image block of the slice, uses pixels of said neighboring slice after the pixels of said neighboring slice become available or whether the filtering process, performed on the target pixel, uses pixels of the slice alone, the pixels to be used are surrounding pixels surrounding said target pixel, generate block size information of the image block, perform a filtering process on the image block at the position according to the filter block flag, the boundary control flag, and the block size information, and encode the image block on which filtering processing is performed and the filter block flag, the boundary control flag and the block size information, thereby generating encoded data, wherein, in the event that the boundary control flag indicates to use the pixels of the slice alone, said filter processing as to said target pixel to be processed is performed assuming a dummy value for each of the surrounding pixels that are in said neighboring slice, whereby the assumed dummy value is based on pixels of the slice alone.