You can retrieve the current colormap from the surface (or from an ILColormap instance) and simply invert the positions of the individual color mapping items within the colormap. In my example the first row of the colordata are overwritten with their mirror-view:
private void ilPanel1_Load(object sender, EventArgs e) {
ILArray<float> A = ILSpecialData.sincf(40, 50);
ilPanel1.Scene.Add(new ILPlotCube(twoDMode: false) {
new ILSurface(A) { new ILColorbar() }
});
// fetch surface
var surface = ilPanel1.Scene.First<ILSurface>();
// fetch current colormap data
ILArray<float> cmdata = surface.Colormap.Data;
// invert their positions
cmdata[":;0"] = cmdata["end:-1:0;:"];
// make new colormap and assign
surface.Colormap = new ILColormap(cmdata);
// configure after all modifications
surface.Configure();
}
The cmdata are afterwards used to create a new colormap which is than assigned to the surface.
See the relevant documentation here: http://ilnumerics.net/managing-colormaps.html