Thanks a lot. I solved my problem now.
Origin LabTalk script to save the colormap to a CSV file:
type -gbe "origin_colormap.csv";
loop (num, 0, layer.cmap.numColors) {
int OCOLOR = layer.cmap.color$(num);
int RGB = ocolor2rgb(OCOLOR);
type "$(num); $(OCOLOR); $(RGB)";
}
type -ge;
The CSV file will be saved in the current project folder (Help->Open folder->Current project).
Matlab script to load the colormap:
m = load('origin_colormap.csv');
val = m(:,3);
B = fix(val./65536);
G = fix(mod(val, 65536)./256);
R = fix(mod(val, 256));
map255 = [R,G,B];
mapNormalized = map255./255;
colormap(mapNormalized);
Things left to do, but that I do not need right now:
-export and use level values (I did it manually. They were linear, so easy.)
-add below/above levels
-make it easy to use