Last active
August 29, 2015 14:21
-
-
Save jnkather/68c1d89e9519d66cf184 to your computer and use it in GitHub Desktop.
Show a CIELAB color cube composed of 15^3 balls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% JN Kather, 2015 | |
% Show a CIELAB color cube composed of 25^3 balls | |
% note: Matlab CIELAB colorspace goes approx. from -108 to +100 as measured | |
% with: colors = rgb2lab(jet(100)); min(colors(:)), max(colors(:)) | |
figure(); | |
[X,Y,Z] = meshgrid(linspace(-108,100,15)); | |
colors = lab2rgb([double(X(:)),double(Y(:)),double(Z(:))]); | |
scatter3(X(:),Y(:),Z(:),100,colors,'filled'); | |
xlabel('L'); ylabel('a'); zlabel('b'); | |
axis equal tight |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment