1.try to search for resize/re-sampling algorithms
- like bilinear filtering ...
2.average color will do it too
- make nested for loops x0,y0 through pixelated image (small resolution)
- compute average color of the pixel area in source image (big resolution)
- this is also done by 2 nested for loops x1,y1 through pixel area
- just sum all R,G,B values separately
- then divide them by number of pixels
- store resulting color to pixelated image pixel(x0,y0)
[Notes]
if your pixelated image is the same resolution (or pixels' are area of pixels)
- then instead of pixelated pixel fill entire pixel area by average color