MATLAB Answers

Does anyone have any experience with luminance changes in a visual display?

6 views (last 30 days)
Adam Vilanova-Goldstein
Adam Vilanova-Goldstein on 13 Dec 2020
Commented: Image Analyst on 15 Dec 2020
I am a visual cognitive psychologist and I use Matlab and PsychToolBox for some visual search experiments. I am attempting to change the luminance of black stimuli at random intervals. I have considered using a grey as the baseline and then changing the color to make it darker or lighter randomly but have been unable to get the color to change. Any suggestions on how I should think about this?
  1 Comment
Image Analyst
Image Analyst on 14 Dec 2020
When you mean "color" you mean the brightness (intensity) of a gray scale image, right? Not the color like a non-gray/tinted RGB image?
Also, when you say "random intervals" do you mean intervals of gray level, or time intervals?

Sign in to comment.

Answers (2)

Matt Gaidica
Matt Gaidica on 13 Dec 2020
'Value' is, I believe, the same as 'luminance' in your case. If so, you could create images based on HSV values and change the value variable dynamically.
h = zeros(200,200);
s = zeros(200,200);
v = ones(200,200);
RGB1 = hsv2rgb(h,s,v*0.3);
RGB2 = hsv2rgb(h,s,v*0.5);
RGB3 = hsv2rgb(h,s,v*0.8);
close all

Sign in to comment.

Image Analyst
Image Analyst on 13 Dec 2020
You should probably calibrate your displays with this device:
In addition, there are ASTM guidelines for viewing (target brightesses, surround brightness, clothing, room brightness, etc.) that you may want to look at.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!