I have 2 images:
I have 4 requirements following:
1. Covers the intersected area of DEM.tif and TPE.jpg
2. With a spatial resolution of 20 meter (i.e. each pixel represents 20m by 20m)
3. The first three channels of the image have the Red, Green and Blue values obtained from TPE.jpg
4. The fourth channel stores the elevation calculated from DEM.tif
For step 3 and 4, I want to implement both "Nearest Neighbor" and "Bi-Linear" interpolation.
Anybody can help me answer and write code.