Text archives Help
- From: "Thiago Ize" <
>
- To:
- Subject: [Manta] r2288 - in trunk: Model/Materials Model/Readers scenes scenes/csafe/src
- Date: Tue, 24 Jun 2008 15:37:40 -0600 (MDT)
Author: thiago
Date: Tue Jun 24 15:37:39 2008
New Revision: 2288
Modified:
trunk/Model/Materials/Volume.h
trunk/Model/Readers/IW.cc
trunk/scenes/csafe/src/CDTest.h
trunk/scenes/volumeTest.cc
Log:
Volume stuff:
-Removing the meters per unit variable that we decided shouldn't be
here. Of course, I can't actually compile the scene code to see if
it actually works. If you can compile it and it doesn't compile,
feel free to fix it.
Model/Readers/IW.cc:
-print out the number of materials after removing duplicates.
Modified: trunk/Model/Materials/Volume.h
==============================================================================
--- trunk/Model/Materials/Volume.h (original)
+++ trunk/Model/Materials/Volume.h Tue Jun 24 15:37:39 2008
@@ -169,7 +169,7 @@
vector<mcT> cellVector_mc; // color hashes
Volume(GridArray3<T>* data, RGBAColorMap* colorMap, const BBox& bounds,
- double cellStepSize, double metersPerUnit, int depth,
+ double cellStepSize, int depth,
double forceDataMin = -FLT_MAX, double forceDataMax = -FLT_MAX);
virtual ~Volume();
void setColorMap(RGBAColorMap* map) { _colorMap = map; }
@@ -203,7 +203,6 @@
int _depth;
int* _xsize,*_ysize,*_zsize;
double* _ixsize, *_iysize, *_izsize;
- float _metersPerUnit;
Vector _cellSize;
float _stepSize;
float _dataMin;
@@ -215,8 +214,8 @@
template<class T>
Volume<T>::Volume(GridArray3<T>* data, RGBAColorMap* colorMap,
const BBox& bounds, double cellStepSize,
- double metersPerUnit, int depth,
- double forceDataMin, double forceDataMax)
+ int depth,
+ double forceDataMin, double forceDataMax)
: _data(data), _colorMap(colorMap)
{
//slightly expand the bounds.
@@ -231,8 +230,6 @@
//_stepSize = cellStepSize*_cellSize.length()/sqrt(3.0);
_stepSize = cellStepSize;
- _metersPerUnit = metersPerUnit;
-
_maxDistance = diag.length();
float min = 0,max = 0;
Modified: trunk/Model/Readers/IW.cc
==============================================================================
--- trunk/Model/Readers/IW.cc (original)
+++ trunk/Model/Readers/IW.cc Tue Jun 24 15:37:39 2008
@@ -111,6 +111,11 @@
break;
}
}
+
+ fprintf(stderr, "compact shader :%10llu\n",
+ (unsigned long long)mesh->materials.size());
+
+
return mesh;
}
Modified: trunk/scenes/csafe/src/CDTest.h
==============================================================================
--- trunk/scenes/csafe/src/CDTest.h (original)
+++ trunk/scenes/csafe/src/CDTest.h Tue Jun 24 15:37:39 2008
@@ -346,7 +346,7 @@
{
cout << "Loading Nrrd file: " << *i << "...\n";
Group* group = new Group();
- Volume<float>* mat = new
Volume<float>(loadNRRDToGrid<float>(*i), _volCMap, BBox(_minBound,
_maxBound), 0.00125, 10, 3, _forceDataMin, _forceDataMax);
+ Volume<float>* mat = new
Volume<float>(loadNRRDToGrid<float>(*i), _volCMap, BBox(_minBound,
_maxBound), 0.00125, 3, _forceDataMin, _forceDataMax);
Cube* vol = new Cube(mat, _minBound - Vector(0.001, 0.001,
0.001), _maxBound + Vector(0.001, 0.001, 0.001));
group->add(vol);
_volAnimation->push_back(group);
@@ -425,7 +425,7 @@
numFrames1++;
Group* group2 = new Group();
- Volume<float>* mat = new Volume<float>(itr->volume,
_volCMap, BBox(_minBound, _maxBound), 0.00125, 10, 3, _forceDataMin,
_forceDataMax);
+ Volume<float>* mat = new Volume<float>(itr->volume,
_volCMap, BBox(_minBound, _maxBound), 0.00125, 3, _forceDataMin,
_forceDataMax);
Primitive* vol = new Cube(mat, _minBound - Vector(0.001,
0.001, 0.001), _maxBound + Vector(0.001, 0.001, 0.001));
group2->add(vol);
_volAnimation->push_back(group2);
Modified: trunk/scenes/volumeTest.cc
==============================================================================
--- trunk/scenes/volumeTest.cc (original)
+++ trunk/scenes/volumeTest.cc Tue Jun 24 15:37:39 2008
@@ -229,7 +229,7 @@
cMap->scaleAlphas(t_inc);
- Volume<float>* mat = new Volume<float>(loadNRRDToGrid<float>(volFile),
cMap, BBox(minBound, maxBound), t_inc, 1.0, depth, dataMin, dataMax);
+ Volume<float>* mat = new Volume<float>(loadNRRDToGrid<float>(volFile),
cMap, BBox(minBound, maxBound), t_inc, depth, dataMin, dataMax);
//double min, max;
//mat->getMinMax(&min, &max);
//cmap2->setMinMax(min, max);
- [Manta] r2288 - in trunk: Model/Materials Model/Readers scenes scenes/csafe/src, Thiago Ize, 06/24/2008
Archive powered by MHonArc 2.6.16.