1. An image processing apparatus comprising: an additional effective pixel appending unit configured to generate an image appended with additional effective pixels by executing appending processing for appending additional effective pixels required to extend image data of a first hierarchy in a scanning direction using pixels at an end portion of the image data in the scanning direction; a first generating unit configured to generate image data of a second hierarchy obtained by reducing the image data of the first hierarchy by applying filtering to the image appended with the additional effective pixels generated by said additional effective pixel appending unit; and a second generating unit configured to generate image data of a third hierarchy obtained by reducing the image data of the second hierarchy by applying filtering to the image data of the second hierarchy.