Changeset 483
- Timestamp:
- 12/27/05 19:32:16 (19 years ago)
- Location:
- trunk/VUT/GtpVisibilityPreprocessor
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/VUT/GtpVisibilityPreprocessor/scripts/default.env
r482 r483 13 13 #;../data/vienna/vienna-plane.x3d 14 14 # filename ../data/vienna/viewcells-25-sel.x3d 15 filename ../data/atlanta/atlanta2.x3d15 # filename ../data/atlanta/atlanta2.x3d 16 16 # filename ../data/soda/soda.dat 17 #filename ../data/soda/soda5.dat17 filename ../data/soda/soda5.dat 18 18 } 19 19 … … 146 146 loadFromFile false 147 147 #type kdTree 148 type vspKdTree148 #type vspKdTree 149 149 #type bspTree 150 #type vspBspTree150 type vspBspTree 151 151 152 152 #type sceneDependent … … 196 196 Termination { 197 197 maxDepth 40 198 minPvs 50198 minPvs 1 199 199 minRays 300 200 200 minSize 0.1 201 maxCostRatio 1.8202 missTolerance 2203 maxRayContribution 0. 5201 maxCostRatio 0.9 202 missTolerance 6 203 maxRayContribution 0.3 204 204 } 205 205 … … 214 214 PostProcess { 215 215 maxCostRatio 0.005 216 minViewCells 300216 minViewCells 50 217 217 maxPvsSize 50000 218 218 } … … 220 220 221 221 Visualization { 222 exportRays false223 exportGeometry false222 exportRays true 223 exportGeometry true 224 224 } 225 225 } … … 276 276 exportSplits true 277 277 exportRays true 278 exportGeometry false278 exportGeometry true 279 279 } 280 280 -
trunk/VUT/GtpVisibilityPreprocessor/src/Polygon3.cpp
r448 r483 1 1 #include "Polygon3.h" 2 2 #include "Mesh.h" 3 #include "ViewCellBsp.h" // TODO: erase this4 3 #include "Mesh.h" 5 4 #include "AxisAlignedBox3.h" -
trunk/VUT/GtpVisibilityPreprocessor/src/ViewCellBsp.cpp
r482 r483 1912 1912 vector<ViewCell *> &viewcells) 1913 1913 { 1914 int hits = 0; 1915 stack<BspRayTraversalData> tStack; 1916 1917 float mint = 0.0f, maxt = 1.0f; 1918 1919 Intersectable::NewMail(); 1920 1921 Vector3 entp = origin; 1922 Vector3 extp = termination; 1923 1924 BspNode *node = mRoot; 1925 BspNode *farChild = NULL; 1926 1927 while (1) { 1928 if (!node->IsLeaf()) { 1929 BspInterior *in = dynamic_cast<BspInterior *>(node); 1930 1931 Plane3 splitPlane = in->GetPlane(); 1932 const int entSide = splitPlane.Side(entp); 1933 const int extSide = splitPlane.Side(extp); 1934 1935 if (entSide < 0) { 1936 node = in->GetBack(); 1937 1938 if(extSide <= 0) // plane does not split ray => no far child 1939 continue; 1940 1941 farChild = in->GetFront(); // plane splits ray 1942 1943 } else 1944 if (entSide > 0) { 1945 node = in->GetFront(); 1946 1947 if (extSide >= 0) // plane does not split ray => no far child 1948 continue; 1949 1950 farChild = in->GetBack(); // plane splits ray 1951 } 1952 else // ray and plane are coincident 1953 { 1954 // WHAT TO DO IN THIS CASE ? 1955 //break; 1956 node = in->GetFront(); 1957 continue; 1958 } 1959 1960 // push data for far child 1961 tStack.push(BspRayTraversalData(farChild, extp, maxt)); 1962 1963 // find intersection of ray segment with plane 1964 float t; 1965 extp = splitPlane.FindIntersection(origin, extp, &t); 1966 maxt *= t; 1967 1968 } else { 1969 // reached leaf => intersection with view cell 1970 BspLeaf *leaf = dynamic_cast<BspLeaf *>(node); 1971 1972 if (!leaf->mViewCell->Mailed()) { 1973 viewcells.push_back(leaf->mViewCell); 1974 leaf->mViewCell->Mail(); 1975 hits++; 1976 } 1977 1978 //-- fetch the next far child from the stack 1979 if (tStack.empty()) 1980 break; 1981 1982 entp = extp; 1983 mint = maxt; // NOTE: need this? 1984 1985 BspRayTraversalData &s = tStack.top(); 1986 1987 node = s.mNode; 1988 extp = s.mExitPoint; 1989 maxt = s.mMaxT; 1990 1991 tStack.pop(); 1992 } 1993 } 1994 return hits; 1914 int hits = 0; 1915 stack<BspRayTraversalData> tStack; 1916 1917 float mint = 0.0f, maxt = 1.0f; 1918 1919 Intersectable::NewMail(); 1920 1921 Vector3 entp = origin; 1922 Vector3 extp = termination; 1923 1924 BspNode *node = mRoot; 1925 BspNode *farChild = NULL; 1926 1927 while (1) 1928 { 1929 if (!node->IsLeaf()) 1930 { 1931 BspInterior *in = dynamic_cast<BspInterior *>(node); 1932 1933 Plane3 splitPlane = in->GetPlane(); 1934 1935 const int entSide = splitPlane.Side(entp); 1936 const int extSide = splitPlane.Side(extp); 1937 1938 if (entSide < 0) 1939 { 1940 node = in->GetBack(); 1941 1942 if(extSide <= 0) // plane does not split ray => no far child 1943 continue; 1944 1945 farChild = in->GetFront(); // plane splits ray 1946 1947 } 1948 else if (entSide > 0) 1949 { 1950 node = in->GetFront(); 1951 1952 if (extSide >= 0) // plane does not split ray => no far child 1953 continue; 1954 1955 farChild = in->GetBack(); // plane splits ray 1956 } 1957 else // ray and plane are coincident 1958 { 1959 // WHAT TO DO IN THIS CASE ? 1960 //break; 1961 node = in->GetFront(); 1962 continue; 1963 } 1964 1965 // push data for far child 1966 tStack.push(BspRayTraversalData(farChild, extp, maxt)); 1967 1968 // find intersection of ray segment with plane 1969 float t; 1970 extp = splitPlane.FindIntersection(origin, extp, &t); 1971 maxt *= t; 1972 } 1973 else 1974 { 1975 // reached leaf => intersection with view cell 1976 BspLeaf *leaf = dynamic_cast<BspLeaf *>(node); 1977 1978 if (!leaf->mViewCell->Mailed()) 1979 { 1980 viewcells.push_back(leaf->mViewCell); 1981 leaf->mViewCell->Mail(); 1982 hits++; 1983 } 1984 1985 //-- fetch the next far child from the stack 1986 if (tStack.empty()) 1987 break; 1988 1989 entp = extp; 1990 mint = maxt; // NOTE: need this? 1991 1992 BspRayTraversalData &s = tStack.top(); 1993 1994 node = s.mNode; 1995 extp = s.mExitPoint; 1996 maxt = s.mMaxT; 1997 1998 tStack.pop(); 1999 } 2000 } 2001 return hits; 1995 2002 } 1996 2003 -
trunk/VUT/GtpVisibilityPreprocessor/src/ViewCellsManager.cpp
r482 r483 286 286 ViewCellContainer viewcells; 287 287 288 /*Vector3 origin = ray.mOrigin; 289 Vector3 termination = ray.mTermination; 290 static Ray hray; 291 float tmin = 0, tmax = 1.0; 292 hray.Init(ray.GetOrigin(), ray.GetDir(), Ray::LINE_SEGMENT); 293 GetSceneBbox().ComputeMinMaxT(hray, &tmin, &tmax); 294 if (tmin >= tmax) 295 return; 296 297 if (tmin > 0.0f) 298 origin = ray.Extrap(tmin); 299 300 if (tmax < 1.0f) 301 termination = ray.Extrap(tmax);*/ 302 288 303 CastLineSegment(ray.mOrigin, 289 304 ray.mTermination, … … 490 505 const VssRayContainer &rays) 491 506 { 492 if (mBspRays.empty())493 ConstructBspRays(rays, mConstructionSamples);494 495 507 if (!ViewCellsConstructed()) 496 508 { … … 551 563 vector<BspIntersection>::const_iterator iit; 552 564 565 if (mBspRays.empty()) 566 ConstructBspRays(rays, mPostProcessSamples); 567 553 568 for (int i = 0; i < (int)mBspRays.size(); ++ i) 554 569 { … … 614 629 615 630 if (mBspRays.empty()) 616 ConstructBspRays(sampleRays, m ConstructionSamples);631 ConstructBspRays(sampleRays, mVisualizationSamples); 617 632 618 633 if (1) // export view cells … … 881 896 ViewCellContainer viewCells; 882 897 898 // cast line segment to get intersections with bsp leaves 883 899 CastLineSegment(vssRay->mTermination, vssRay->mOrigin, viewCells); 884 900 885 901 ViewCellContainer::const_iterator vit, vit_end = viewCells.end(); 886 887 902 for (vit = viewCells.begin(); vit != vit_end; ++ vit) 888 903 { … … 1297 1312 ExportLeaves(objects, rays); 1298 1313 1314 mVspKdTree->CollectMergeCandidates(); 1299 1315 // finally merge kd leaf building blocks to view cells 1300 1316 const int merged = mVspKdTree->MergeLeaves(); … … 1408 1424 VspKdViewCell *vc = dynamic_cast<VspKdViewCell *>(mViewCells[idx]); 1409 1425 1426 cout << "Output view cell " << i << " with pvs size " << vc->GetPvs().GetSize() << endl; 1427 Debug << "Output view cell " << i << " with pvs size " << vc->GetPvs().GetSize() << endl; 1410 1428 //-- export geometry 1411 1429 Material m; … … 1429 1447 1430 1448 VssRayContainer vssRays; 1449 1450 VssRayContainer castRays; 1451 VssRayContainer initRays; 1452 1431 1453 leaf->GetRays(vssRays); 1432 1454 1433 VssRayContainer rays;1434 1455 VssRayContainer::const_iterator it, it_end = vssRays.end(); 1456 const float prop = 200.0f / (float)vssRays.size(); 1435 1457 1436 1458 for (it = vssRays.begin(); it != it_end; ++ it) 1437 rays.push_back(*it); 1438 1439 exporter->ExportRays(rays, RgbColor(1, 0, 0)); 1459 { 1460 if (RandomValue(0, 1) < prop) 1461 if ((*it)->mTerminationObject == NULL) 1462 castRays.push_back(*it); 1463 else 1464 initRays.push_back(*it); 1465 } 1466 1467 exporter->ExportRays(castRays, RgbColor(1, 0, 0)); 1468 exporter->ExportRays(initRays, RgbColor(0, 1, 0)); 1440 1469 } 1441 1470 } … … 1444 1473 m.mDiffuseColor = RgbColor(1, 0, 0); 1445 1474 exporter->SetForcedMaterial(m); 1475 1476 Intersectable::NewMail(); 1446 1477 1447 1478 ObjectPvsMap::const_iterator it, … … 1469 1500 //-- export final view cells 1470 1501 Exporter *exporter = Exporter::GetExporter("vspkdtree_merged.x3d"); 1471 exporter->SetFilled(); 1502 1503 /*if (exportGeometry) exporter->SetWireframe(); 1504 else exporter->SetFilled();*/ 1505 1472 1506 ExportViewCells(exporter); 1473 1507 … … 1492 1526 rays.push_back(sampleRays[i]); 1493 1527 } 1494 exporter->ExportRays(rays, RgbColor(1, 0, 0)); 1528 exporter->ExportRays(rays, RgbColor(1, 0, 0)); 1495 1529 } 1496 1530 … … 1644 1678 GetRaySets(rays, constructionRays, savedRays); 1645 1679 1646 mVspBspTree->Construct(constructionRays );1680 mVspBspTree->Construct(constructionRays, sceneBbox); 1647 1681 Debug << mVspBspTree->GetStatistics() << endl; 1648 1682 … … 1669 1703 ViewCellContainer viewCells; 1670 1704 1705 // cast line segment and store intersections with the rays 1671 1706 CastLineSegment(vssRay->mTermination, vssRay->mOrigin, viewCells); 1672 1707 … … 1692 1727 return 0; 1693 1728 } 1694 1695 if (mBspRays.empty())1696 ConstructBspRays(rays, mConstructionSamples);1697 1729 1698 1730 //-- post processing of bsp view cells … … 1717 1749 //exporter->SetWireframe(); 1718 1750 exporter->SetFilled(); 1719 1720 1751 ExportViewCells(exporter); 1721 1752 1722 if (0) 1753 bool exportGeometry = false; 1754 environment->GetBoolValue("VspBspTree.Visualization.exportGeometry", exportGeometry); 1755 1756 if (exportGeometry) 1723 1757 { 1724 1758 Material m; 1725 1759 m.mDiffuseColor = RgbColor(0, 1, 0); 1726 1760 exporter->SetForcedMaterial(m); 1727 exporter->Set Wireframe();1761 exporter->SetFilled(); 1728 1762 1729 1763 exporter->ExportGeometry(objects); … … 1748 1782 vector<BspIntersection>::const_iterator iit; 1749 1783 1784 // matt TODO: remove 1750 1785 if (0) 1751 for (int i = 0; i < (int)mBspRays.size(); ++ i) 1752 { 1753 BspRay *ray = mBspRays[i]; 1786 { 1787 if (mBspRays.empty()) 1788 ConstructBspRays(rays, mPostProcessSamples); 1789 1790 for (int i = 0; i < (int)mBspRays.size(); ++ i) 1791 { 1792 BspRay *ray = mBspRays[i]; 1754 1793 1755 // traverse leaves stored in the rays and compare and merge consecutive1756 // leaves (i.e., the neighbors in the tree)1757 if (ray->intersections.size() < 2)1758 continue;1794 // traverse leaves stored in the rays and compare and merge consecutive 1795 // leaves (i.e., the neighbors in the tree) 1796 if (ray->intersections.size() < 2) 1797 continue; 1759 1798 1760 iit = ray->intersections.begin(); 1761 1762 BspLeaf *previousLeaf = (*iit).mLeaf; 1763 ++ iit; 1764 1765 for (; iit != ray->intersections.end(); ++ iit) 1766 { 1767 BspLeaf *leaf = (*iit).mLeaf; 1768 1769 if (ShouldMerge(leaf, previousLeaf)) 1770 { 1771 MergeVspBspLeafViewCells(leaf, previousLeaf); 1772 1773 ++ merged; 1799 iit = ray->intersections.begin(); 1800 1801 BspLeaf *previousLeaf = (*iit).mLeaf; 1802 ++ iit; 1803 1804 for (; iit != ray->intersections.end(); ++ iit) 1805 { 1806 BspLeaf *leaf = (*iit).mLeaf; 1807 1808 if (ShouldMerge(leaf, previousLeaf)) 1809 { 1810 MergeVspBspLeafViewCells(leaf, previousLeaf); 1811 ++ merged; 1812 } 1813 previousLeaf = leaf; 1774 1814 } 1775 1776 previousLeaf = leaf;1777 1815 } 1778 1816 } … … 1808 1846 return; 1809 1847 1848 #if 1 1810 1849 if (mBspRays.empty()) 1811 ConstructBspRays(sampleRays, mConstructionSamples); 1812 1850 ConstructBspRays(sampleRays, mVisualizationSamples); 1851 #endif 1852 1813 1853 if (1) // export view cells 1814 1854 { … … 1911 1951 #endif 1912 1952 int limit = min(leafOut, (int)mViewCells.size()); 1913 1953 1914 1954 for (int i = 0; i < limit; ++ i) 1915 1955 { … … 1924 1964 cout << "creating output for view cell " << i << " ... "; 1925 1965 1926 #if 01966 #if 1 1927 1967 // check whether we can add the current ray to the output rays 1928 1968 for (int k = 0; k < raysOut; ++ k) … … 1965 2005 1966 2006 // export rays piercing this view cell 2007 #if 1 2008 exporter->ExportRays(vcRays, RgbColor(0, 1, 0)); 2009 #endif 1967 2010 #if 0 1968 exporter->ExportRays(vcRays, RgbColor(0, 1, 0));1969 #else1970 2011 vector<BspLeaf *>::const_iterator lit, lit_end = vc->mLeaves.end(); 2012 1971 2013 for (lit = vc->mLeaves.begin(); lit != lit_end; ++ lit) 1972 2014 exporter->ExportRays((*lit)->mVssRays); -
trunk/VUT/GtpVisibilityPreprocessor/src/VspBspTree.cpp
r482 r483 223 223 } 224 224 225 void VspBspTree::Construct(const VssRayContainer &sampleRays) 225 void VspBspTree::Construct(const VssRayContainer &sampleRays, 226 AxisAlignedBox3 *forcedBoundingBox) 226 227 { 227 228 mStat.nodes = 1; … … 259 260 } 260 261 261 // compute bounding box 262 Polygon3::IncludeInBox(polys, mBox); 262 //-- compute bounding box 263 if (forcedBoundingBox) 264 mBox = *forcedBoundingBox; 265 else 266 Polygon3::IncludeInBox(polys, mBox); 263 267 264 268 //-- store rays … … 269 273 float minT, maxT; 270 274 271 // TODO: not very efficient to implictly cast between rays types ...275 // TODO: not very efficient to implictly cast between rays types 272 276 if (mBox.GetRaySegment(*ray, minT, maxT)) 273 277 { … … 1858 1862 node = in->GetBack(); 1859 1863 1860 if (extSide <= 0) // plane does not split ray => no far child1864 if (extSide <= 0) // plane does not split ray => no far child 1861 1865 continue; 1862 1866 -
trunk/VUT/GtpVisibilityPreprocessor/src/VspBspTree.h
r482 r483 159 159 created in the leafs and stored in the container 160 160 */ 161 void Construct(const VssRayContainer &sampleRays); 161 void Construct(const VssRayContainer &sampleRays, 162 AxisAlignedBox3 *forcedBoundingBox); 162 163 163 164 /** Returns list of BSP leaves. -
trunk/VUT/GtpVisibilityPreprocessor/src/VspKdTree.cpp
r482 r483 810 810 811 811 //-- ray density substitute for probability 812 if ( 1)812 if (0) 813 813 { 814 814 pBack = (float)raysBack; … … 1979 1979 const Vector3 dir = termination - origin; 1980 1980 1981 stack<Line SegmentTraversalData> tStack;1981 stack<LineTraversalData> tStack; 1982 1982 1983 1983 Intersectable::NewMail(); … … 2033 2033 // case N4 or P4 2034 2034 float tdist = (position - origin[axis]) / dir[axis]; 2035 //tStack.push(RayTraversalData(farChild, extp, maxt)); //TODO2035 tStack.push(LineTraversalData(farChild, extp, maxt)); //TODO 2036 2036 extp = origin + dir * tdist; 2037 2037 maxt = tdist; … … 2050 2050 } 2051 2051 2052 if (1) //matt TODO: REMOVE LATER 2053 leaf->mRays.push_back(RayInfo(new VssRay(origin, termination, NULL, NULL, 0))); 2054 2052 2055 // get the next node from the stack 2053 2056 if (tStack.empty()) … … 2057 2060 mint = maxt; 2058 2061 2059 Line SegmentTraversalData &s = tStack.top();2062 LineTraversalData &s = tStack.top(); 2060 2063 node = s.mNode; 2061 2064 extp = s.mExitPoint; … … 2139 2142 } 2140 2143 2141 2142 2143 int VspKdTree::MergeLeaves() 2144 { 2144 void VspKdTree::CollectMergeCandidates() 2145 { 2146 MergeCandidate::sOverallCost = 0; 2145 2147 vector<VspKdLeaf *> leaves; 2146 priority_queue<MergeCandidate> mergeQueue;2147 2148 2148 2149 // collect the leaves, e.g., the "voxels" that will build the view cells 2149 2150 CollectLeaves(leaves); 2150 2151 int vcSize = (int)leaves.size();2152 int savedVcSize = vcSize;2153 2151 2154 2152 VspKdLeaf::NewMail(); … … 2178 2176 for (nit = neighbors.begin(); nit != nit_end; ++ nit) 2179 2177 { 2178 // TODO: test if at least one ray goes from one leaf to the other 2180 2179 MergeCandidate mc = MergeCandidate(leaf, *nit); 2181 m ergeQueue.push(mc);2180 mMergeQueue.push(mc); 2182 2181 2183 2182 MergeCandidate::sOverallCost += mc.GetLeaf1Cost(); … … 2186 2185 } 2187 2186 } 2188 2187 } 2188 2189 /* 2190 void VspKdTree::CollectMergeCandidates(const vector<VspKdRay *> &rays) 2191 { 2192 MergeCandidate::sOverallCost = 0; 2193 2194 vector<VspKdIntersection>::const_iterator iit; 2195 2196 for (int i = 0; i < (int)rays.size(); ++ i) 2197 { 2198 //VspKdLeaf::NewMail(); 2199 2200 VspKdRay *ray = rays[i]; 2201 2202 // traverse leaves stored in the rays and compare and merge consecutive 2203 // leaves (i.e., the neighbors in the tree) 2204 if (ray->intersections.size() < 2) 2205 continue; 2206 2207 iit = ray->intersections.begin(); 2208 2209 BspLeaf *previousLeaf = (*iit).mLeaf; 2210 2211 ++ iit; 2212 2213 for (; iit != ray->intersections.end(); ++ iit) 2214 { 2215 BspLeaf *leaf = (*iit).mLeaf; 2216 2217 // TODO: how to sort out doubles? 2218 MergeCandidate mc = MergeCandidate(leaf, previousLeaf); 2219 mMergeQueue.push(mc); 2220 2221 MergeCandidate::sOverallCost += mc.GetLeaf1Cost(); 2222 MergeCandidate::sOverallCost += mc.GetLeaf2Cost(); 2223 2224 previousLeaf = leaf; 2225 } 2226 } 2227 } 2228 */ 2229 2230 int VspKdTree::MergeLeaves() 2231 { 2189 2232 int merged = 0; 2190 2233 2234 int vcSize = mStat.nodes / 2 + 1; 2191 2235 // use priority queue to merge leaves 2192 while (!m ergeQueue.empty() && (vcSize > mMergeMinViewCells) &&2193 (m ergeQueue.top().GetMergeCost() <2236 while (!mMergeQueue.empty() && (vcSize > mMergeMinViewCells) && 2237 (mMergeQueue.top().GetMergeCost() < 2194 2238 mMergeMaxCostRatio * MergeCandidate::sOverallCost)) 2195 2239 { 2196 2240 //Debug << "mergecost: " << mergeQueue.top().GetMergeCost() / MergeCandidate::sOverallCost << " " << mMergeMaxCostRatio << endl; 2197 MergeCandidate mc = m ergeQueue.top();2198 m ergeQueue.pop();2241 MergeCandidate mc = mMergeQueue.top(); 2242 mMergeQueue.pop(); 2199 2243 2200 2244 // both view cells equal! … … 2218 2262 // validate and reinsert into queue 2219 2263 mc.SetValid(); 2220 m ergeQueue.push(mc);2264 mMergeQueue.push(mc); 2221 2265 //Debug << "validate " << mc.GetMergeCost() << endl; 2222 2266 } … … 2228 2272 RepairVcLeafLists(); 2229 2273 2230 Debug << "merged " << merged << " of " << savedVcSize<< " leaves" << endl;2274 Debug << "merged " << merged << " of " << mStat.nodes / 2 + 1 << " leaves" << endl; 2231 2275 2232 2276 //TODO: should return sample contributions -
trunk/VUT/GtpVisibilityPreprocessor/src/VspKdTree.h
r482 r483 529 529 }; 530 530 531 struct Line SegmentTraversalData531 struct LineTraversalData 532 532 { 533 533 VspKdNode *mNode; … … 536 536 float mMaxT; 537 537 538 Line SegmentTraversalData () {}539 Line SegmentTraversalData (VspKdNode *n,538 LineTraversalData () {} 539 LineTraversalData (VspKdNode *n, 540 540 const Vector3 &p, 541 541 const float maxt): … … 608 608 */ 609 609 void RefineViewCells(); 610 611 /** Collects candidates for the merge in the merge queue. 612 */ 613 void CollectMergeCandidates(); 610 614 611 615 protected: … … 770 774 771 775 ViewCellsManager *mViewCellsManager; 776 777 priority_queue<MergeCandidate> mMergeQueue; 778 772 779 773 780 ///////////////////////////// -
trunk/VUT/GtpVisibilityPreprocessor/src/X3dExporter.cpp
r482 r483 158 158 for (; ri != rays.end(); ri++) { 159 159 const Vector3 a = (*ri)->GetOrigin(); 160 const Vector3 b = (*ri)->mTerminationObject ? (*ri)->GetTermination() : a + 1000 * Normalize((*ri)->GetDir()); 161 160 //const Vector3 b = (*ri)->mTerminationObject ? (*ri)->GetTermination() : a + 1000 * Normalize((*ri)->GetDir()); 161 const Vector3 b = (*ri)->GetTermination(); // matt: change again!! 162 162 163 stream<<a.x<<" "<<a.y<<" "<<a.z<<" ,"; 163 164 stream<<b.x<<" "<<b.y<<" "<<b.z<<" ,\n";
Note: See TracChangeset
for help on using the changeset viewer.