Manta Interactive Ray Tracer Development Mailing List

Text archives Help


[Manta] r2268 - trunk/Engine/PixelSamplers


Chronological Thread 
  • From: "Thiago Ize" <thiago@sci.utah.edu>
  • To: manta@sci.utah.edu
  • Subject: [Manta] r2268 - trunk/Engine/PixelSamplers
  • Date: Sat, 24 May 2008 20:23:23 -0600 (MDT)

Author: thiago
Date: Sat May 24 20:23:22 2008
New Revision: 2268

Modified:
   trunk/Engine/PixelSamplers/TimeViewSampler.cc
Log:
Clamp the colormapped timeview to white instead of having it randomly
change to different shades of red.

Modified: trunk/Engine/PixelSamplers/TimeViewSampler.cc
==============================================================================
--- trunk/Engine/PixelSamplers/TimeViewSampler.cc       (original)
+++ trunk/Engine/PixelSamplers/TimeViewSampler.cc       Sat May 24 20:23:22 
2008
@@ -99,7 +99,14 @@
       if (state == 0 && Color::NumComponents == 3) {
         float R, G, B;
         float x = deltaTime*scale/(fragment.end()-fragment.begin());
-        HeightColorMap::hsv_to_rgb(R, G, B, x, 1, x);
+        float S = 1;
+        if (x > 2) //set to x>1 to go straight to white.
+          S = 0;
+        else if (x > 1) {
+          S = 2-x;
+          x = 1;
+        }
+        HeightColorMap::hsv_to_rgb(R, G, B, x, S, x);
         fragment.color[0][i] = R;
         fragment.color[1][i] = G;
         fragment.color[2][i] = B;


  • [Manta] r2268 - trunk/Engine/PixelSamplers, Thiago Ize, 05/24/2008

Archive powered by MHonArc 2.6.16.

Top of page