It does not work. The drape layer is always on top of the contour.
To give more context (i should have started by that!):
I have an elevation layer.
I want a vector layer (continents in drape mode) to be the layer drawn first with one color.
Then I want to colorize with a specific color ramp but only when the elevation is above a given height.
To do so I customized the ContourMap plugin.
First by discarding fragments where the height is below the threshold. But in this case it is the terrain surface that is discarded, not just the color of the contourmap layer (and the contourmap layer is displayed below the vector layer).
Second try, by putting the alpha at 1 where the height is below the threshold. It works well for the contourmap layer, but remains the issue that the contourmap is displayed before the vector layer.
I wonder if i could directly colorize the vector layer with a shader according to the elevation. But to do so, i need access to oe_terrain_getElevation which i think it cannot be used in the context of a vector layer. Right?