I'm trying to create an RGB png image by merging three grayscale png images using pypng
. I've read the png files into numpy arrays as below
pngFile1 = png.Reader("file1.png").read()
pngFile2 = png.Reader("file2.png").read()
pngFile3 = png.Reader("file3.png").read()
pngArray1 = np.array(list(pngFile1[2]))
pngArray2 = np.array(list(pngFile2[2]))
pngArray3 = np.array(list(pngFile3[2]))
How do I combine these three arrays/images to recreate an RGB png image?