CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Paraview & paraFoam (http://www.cfd-online.com/Forums/openfoam-paraview/)
-   -   Paraview gray scale from white to black (http://www.cfd-online.com/Forums/openfoam-paraview/105630-paraview-gray-scale-white-black.html)

enoch August 4, 2012 12:36

Paraview gray scale from white to black
 
1 Attachment(s)
I wanted to create a contour plot with the gray scale from white (lowest value) to black (highest value) in paraview.
The default gray scale is opposite to what I want.
How can I make a contour plot with white to black?
Thanks in advance for your help.

wyldckat August 4, 2012 15:23

Greetings Jeong,

Simple:
  1. You export the gray one to an XML file.
  2. Switch the values for "x" in the saved file.
  3. Import the modified file.
Here's the modified file contents:
Code:

<ColorMap name="Grayscale" space="RGB">
  <Point x="0" o="1" r="1" g="1" b="1"/>
  <Point x="1" o="0" r="0" g="0" b="0"/>
  <NaN r="1" g="0" b="0"/>
</ColorMap>

I also swapped the lines of the two "Point" elements.
You can also change the "name" of the "ColorMap".

Best regards,
Bruno

enoch August 4, 2012 19:16

thanks. This works.
 
Thanks a lot for your tip.


Quote:

Originally Posted by wyldckat (Post 375397)
Greetings Jeong,

Simple:
  1. You export the gray one to an XML file.
  2. Switch the values for "x" in the saved file.
  3. Import the modified file.
Here's the modified file contents:
Code:

<ColorMap name="Grayscale" space="RGB">
  <Point x="0" o="1" r="1" g="1" b="1"/>
  <Point x="1" o="0" r="0" g="0" b="0"/>
  <NaN r="1" g="0" b="0"/>
</ColorMap>

I also swapped the lines of the two "Point" elements.
You can also change the "name" of the "ColorMap".

Best regards,
Bruno


wyldckat March 2, 2014 08:51

4 Attachment(s)
OK, so somebody who I won't mention, has asked me for more details on this topic.
So here goes a quick step-by-step guide:
  1. Start ParaView.
  2. Load your data file(s).
  3. Turn on the data set you want to represent. Example, see first attached image.
  4. Click on the "Edit Color Map" button, shown in the second image.
  5. Click on the "Choose Preset" button, shown in the third image.
  6. As shown in the fourth image, you can either choose one of the presets or click on the "Import" button to load a manually created file.
  7. Once the preset is chosen, by clicking on it, then click on the OK button and you're good to go!
Best regards,
Bruno


All times are GMT -4. The time now is 02:30.