A further question is: Can I export the modified vector result as a raster file, for example GeoTiff? Because I need to give the raster result to other applications.
No, there is currently no vector-to-raster support in Manifold 9. (That is coming.)
But even if there were, it would be wasteful (and possibly inaccurate) to use a raster-vector-raster workflow for this task. A raster-only workflow is more natural and more efficient.
So, getting back to your original question though--how to reclassify pixels in a raster.
This is very easy in Manifold 8. It only requires a few lines of SQL. At its simplest, something like:
SET [Height (I)] =
CASE [Height (I)]
WHEN 10 THEN 1010
WHEN 20 THEN 1010
ELSE [Height (I)] -- no change
That is readily adaptable to more detailed changes (including all of the adjustments available in the screenshot you have posted below).
However, it is currently more difficult in Manifold 9.
The underlying reason for the difference is that while Manifold 8's storage model gives direct access to individual pixels, Manifold 9 uses a storage model based on tiles (regular grids of pixels, sub-images if you like). The tile-based model is more efficient and faster. More importantly, helped by other features of Manifold 9, it is scalable to rasters of indefinite size, while the pixel-based model in 8 starts to become unwieldy if raster data does not fit within available RAM.
In many cases, analysis of tiles is also more efficient than analysis of individual pixels, because the super-scalar architecture of CPUs and, moreso, GPUs, allows simple operations to be carried out on a whole tile in one operation. (Usually the tile will be broken into smaller chunks during processing, but this is highly optimized, and each smaller chunk can be processed literally at the same time.)
A lot of simple tile-based functions are already built in to Manifold 9. Not everything is fully optimized yet, but on the whole it is already very efficient.
But so far, not everything is easy as it could be--and your task is a great example.
There is no reason why a really fast reclassification function could not be added to 9. It would be easy to specify, and I think it would parallelize very well. This is probably something we should think about and request. Possible syntax could be as simple as:
SET [Tile] =
TileReplace([Tile], 10, 1010),
to perform the same operation as the Manifold 8 code above, potentially much faster.
But for now, a "simple" reclassification operation is significantly more complex than it is in Manifold 9.
The detail is that we must use TileToValues to break each tile into a table of pixels, pass the table to a function to filter and reclassify, then* recombine adjusted pixels into a new tile, which we can then use to replace the original.
(*The filtering and reclassification can be done by either an SQL function or a script function. The second part, recombining pixels into a new tile, requires a script function, since we do not (yet?) have a buillt-in SQL function to build a new tile from a table, i.e. the reverse of TileToValues. We can only make a new tile with constant values using TileMakeNew.)
In summary, for now, it's a bit of work to do image reclassification in Manifold 9. There is plenty of room to make it significantly easier, and I am very confident that that will happen before very long--especially if we make feature requests along the necessary lines.