Hello, I want to modify every single pixel of a 1 band GeoTiff file, following a formula (multiply each pixel for a value and then add another value).
output_pixel[i][j] = input_pixel[i][j] * K[i][j] + C[i][j] I can't apply a linear scale (it would be as easier as -scale option in gdal_translate). Sounds more like applying a mask to the band's data. My first approach is to get every data block of the raster (IReadBlock call), apply the transformation to every single pixel ( = apply a mask to the data block), and put the block in the output raster. Is there any other faster/smarter approach? Many thanks in advance, -- Jorge Arevalo http://www.krop.com/jorgearevalo _______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev