global sRGBGamut AdobeRGBGamut ax;
popup = uicontrol('Style', 'popup',...
'String', {'sRGB','AdobeRGB','P3','Rec2020'},...
'Position', [10 10 100 50],'background','green',...
'Value',1,'Callback',@popupCallback);
[r,g,b] = meshgrid(linspace(0,1,20));
rgb = [r(:), g(:), b(:)];
lab2 = rgb2lab(rgb,'ColorSpace','adobe-rgb-1998');
sRGBGamut = trisurf(k,a,b,L,'FaceColor','interp', 'FaceVertexCData',rgb,'EdgeColor','none');
axis([-128 128 -128 128 0 100]);
title('sRGB gamut surface', 'in L*a*b* space');
ax.TitleHorizontalAlignment = 'left';
AdobeRGBGamut = trisurf(k,a,b,L,'FaceColor','interp', 'FaceVertexCData',rgb,'EdgeColor','none');
function popupCallback(popup,event)
sels = get(popup,'String');
idx = get(popup,'Value');
title('sRGB gamut surface', 'in L*a*b* space');
set(AdobeRGBGamut, 'Visible', 'off');
set(sRGBGamut, 'Visible', 'on');
title('AdobeRGB gamut surface', 'in L*a*b* space');
set(sRGBGamut, 'Visible', 'off');
set(AdobeRGBGamut, 'Visible', 'on');
title('Display P3 gamut surface', 'in L*a*b* space');
set(sRGBGamut, 'Visible', 'off');
title('Rec2020 gamut surface', 'in L*a*b* space');
set(sRGBGamut, 'Visible', 'off');