True Color images in visit

I was thinking about Eddie's emission plots and how where there is h-alpha and sulfur 2 emission, the plot is brown instead of bright yellow - and this has to do with the way visit adds transparent pseudocolors… Basically it adds them as though they were pigments - not sources of light. Red+Green dye = brown, Red+Green light = yellow..

I thought about doing the colors in reverse - basically using anti-red (cyan) and anti-green (magenta) to get anti-yellow (blue), and then inverting the final image to get red, green and yellow - however, visit doesn't add transparent plots in a commutative fashion (the order of the semi-transparent images matters). Then I discovered visit's new true color plot which allows you to specify a rgb vector field and then plot the resulting image.

So if you create an expression for H-alpha emission and S-II emission that is scaled between 0 and 255,

H_sc=max(0, min(255, (H-Hmin)/(Hmax-Hmin)*256))) S_sc=max(0, min(255, (S-Smin)/(Smax-Smin)*256)))

then you can create a vector

{Halpha_sc, 0, SII_sc}

that you can then plot with a truecolor plot.

(I'm not sure why green is 3rd and not 2nd like 'rgb' - and I couldn't get blue to plot at all)

The following was produced by having the red value go from 0 to 255 across the left half and then stay at 255 on the right half, and the opposite for green. That way the center is at 255, 0, 255 = bright yellow….

Attachments (1)

Download all attachments as: .zip

Comments

1. ehansen -- 12 years ago

I think if you use the color() function instead of vector brackets, then the order is correct…

color(R, G, B)

color4(R, G, B, alpha)