I have a 1-band TIFF/raster file showing a value for each raster cell. I want to get those cell/pixel values of the TIFF extracted to a CSV file.
I guess there are two ways of doing this.
First, generate centroids of pixel/cell values of the tiff and then get the underlaying values of the raster, or Second, generate the values directly out of the TIFF (without the centroids first).
In the end I would like to have a CSV or tabular file format showing x, y and the values.
I want to use the QGIS console and a script or create a QGIS plugin. Any ideas?