Monday, May 9, 2016

We don't see color

The names used to describe CVD (Color Vision Deficiency) confuse, but do not clarify, the functioning of the cones. There are no red cones, green cones or blue cones. RGB is a merely a human convention for describing colors by adding red, green and blue. Great for defining light sources, but not for understanding color vision.

Object colors are based on CMY (Cyan, Magenta and Yellow). The mind warping aspect of objects is understanding the difference between refraction and reflection. Forget reflection. Think refraction. The molecules in any object absorb the photons of light. Absorbing energy results in the release of energy. The release of energy is a different frequency. This is refraction. It is a subtractive process. This is why paints use CMY for mixing colors.

Vision research groups cones into three categories according to their sensitivity to different wavelengths of light. Again, we are talking about energy. The resulting wavelength graph for the different cones are as follows:


The cones that have a peak abundance of 559 nm are known as the long wavelength cones. The medium wavelength cones are those whose peak abundance centers on 531 nm. The short wavelength cones have a much higher center wavelength at 419 nm. The acronym is LMS. Many explanations refer to long wavelength cones as red, medium wavelength as green, and short wavelength as blue. The reality is that a person can have 100% protanopia (no long wavelength cones) and still visualize some shades of red. The medium wavelength still respond to shorter wavelengths of the color red.

The Quick Test feature of my Color Simulator apps provides a good demonstration of the overlapping of the wavelength response curves. Just follow color code values, as you adjust the sliders. Even a person with protanopia has some red response. Change the type to deuteranopia, and notice the similarities and differences.

Cones respond to a range of wavelengths of light. The terms red, green, and blue tend hide this phenomenon. The cones of the eye do not see color, they are receptor cells that respond to light energy of different wavelengths. The vision centers of the brain create the vision of color based on the information received from the cones.

The overlap of the long and medium wavelength curves leads to the term red-green color blindness. This is wrong. There are differences between protanopia and deuteranopia, as they represent the loss of different cones.

Sunday, May 8, 2016

Colorblind Simulator for Android released

Color Vision Deficiency (CVD) affects our ability to distinguish colors. It can impact on a child's ability to learn, the ability to select two socks that match in color, the selection of clothing, purchasing fruits and vegetables, and even careers. The purpose of the Colorblind Simulator app is to provide educators, graphic designers, and everyone who works with individuals with CVD, a way to understand their world.
The Colorblind Simulator app for Android is a collection of simulation tools. It includes tools for images, text, Material Design colors, and any single RGB color. Currently, it is the only color blindness simulation toolbox available for Android.

We do not see RGB colors. Rather, the cone cells on the retina of the eye respond to different wavelengths of light. There are three different types of cones: long wavelength (red) cones, medium wavelength (green) cones, and short wavelength (blue) cones. The following diagram illustrates the LMS wavelengths.


Simulation processing is a memory intensive task, as the app processes each pixel in an image. Each pixel is transformed to its LMS color, color loss factors are applied, and then transformed ack to RGB. The application default is for dichromatic vision, which involves 100% less loss of one cone type. These conditions are protanopia (red), deuteranopia (green), and tritanopia (blue). The most common form of color blindness is deuteranopia. A far larger number of individuals are affected by anomalous trichromacy, which means that there is a partial loss of one of the cone types. The following graphic compares (from left to right) normal, protanopia, deuteranopia and tritanopia vision for a flower.


The above images assumed 100% loss, and used the linear model. The app offers two other models. The linear model, itself, is a variation of the Brettel-Vienot-Mollon (BVM) model. The Meyer-Greenberg-Wolfmaier-Wickline (MGWW) is an alternate model that produces slightly different results. The MGWW model was developed for color monitors. A fourth, grayscale model simulates monochromatic vision, a vary rare form of color vision deficiency.
The Colorblind Simulator app is not limited to processing example images, images from galleries, or the camera. The text activity provides a way to test background colors with various text colors. Along with transforming the colors, the text activity displays the W3C contrast ratio.  While it is just a dream, it would be nice if this activity put an end to red text on a black background, and yellow text on a white background.

The material colors activity provides shows the impact of CVD on the standard Android design colors. This activity is also a good way to see the impact on groups of colors. The following screenshot illustrates what red colors look like to someone who has protanopia. The darker colors of red are much hard to distinguish.


The quick test app displays the conversion of any single color. You can just play with the scroll bars and watch the colors change. 


To see these features in action, I created a two minute video at https://youtu.be/nblzVHEbu2s. The Colorblind Simulator Pro app is available from the Google Play store, and only costs $1.29, which helps support future development of this app. If you have any questions about this app, you can contact me through the Twitter link on this page, or send an email to support@all-things-android.com.