vtf-logo

build.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00008 #if !defined(__geom_mesh_iss_build_h__)
00009 #define __geom_mesh_iss_build_h__
00010 
00011 #include "IndSimpSetIncAdj.h"
00012 #include "set.h"
00013 #include "transform.h"
00014 
00015 #include "../quadrilateral/QuadMesh.h"
00016 
00017 #include "../../../ads/iterator/IndirectIterator.h"
00018 
00019 BEGIN_NAMESPACE_GEOM
00020 
00021 //-----------------------------------------------------------------------------
00026 
00028 
00037 template<int N, bool A, typename T, typename V, typename IF, typename IS>
00038 void
00039 buildFromQuadMesh(const QuadMesh<N,A,T,V,IF>& quadMesh,
00040                   IndSimpSet<N,2,true,T,V,IS>* mesh);
00041 
00043 
00053 template<int N, int M, bool A, typename T, typename V, typename IS,
00054          typename IntForIter>
00055 void
00056 buildFromSubsetVertices(const IndSimpSet<N,M,A,T,V,IS>& in,
00057                         IntForIter verticesBeginning, 
00058                         IntForIter verticesEnd,
00059                         IndSimpSet<N,M,true,T,V,IS>* out);
00060   
00061 
00063 
00073 template<int N, int M, bool A, typename T, typename V, typename IS,
00074          typename IntForIter>
00075 void
00076 buildFromSubsetSimplices(const IndSimpSet<N,M,A,T,V,IS>& in,
00077                          IntForIter simplicesBeginning, 
00078                          IntForIter simplicesEnd,
00079                          IndSimpSet<N,M,true,T,V,IS>* out);
00080 
00081 
00083 
00093 template<int N, int M, bool A, typename T, typename V, typename IS, class LSF>
00094 void
00095 buildFromVerticesInside(const IndSimpSet<N,M,A,T,V,IS>& in,
00096                         const LSF& f,
00097                         IndSimpSet<N,M,true,T,V,IS>* out);
00098   
00099 
00101 
00112 template<int N, int M, bool A, typename T, typename V, typename IS, class LSF>
00113 void
00114 buildFromSimplicesInside(const IndSimpSet<N,M,A,T,V,IS>& in,
00115                          const LSF& f,
00116                          IndSimpSet<N,M,true,T,V,IS>* out);
00117 
00118 
00120 
00127 template<int N, int M, bool A, typename T, typename V, 
00128          typename ISimp, typename IFace,
00129          typename IntOutputIterator>
00130 void
00131 buildBoundary(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00132               IndSimpSet<N,M-1,true,T,V,IFace>* out,
00133               IntOutputIterator usedVertexIndices);
00134 
00135 
00137 
00143 template<int N, int M, bool A, typename T, typename V, 
00144          typename ISimp, typename IFace>
00145 inline
00146 void
00147 buildBoundary(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00148               IndSimpSet<N,M-1,true,T,V,IFace>* out) {
00149   buildBoundary(in, out, ads::TrivialOutputIterator());
00150 }
00151 
00152 
00154 
00165 template<int N, int M, bool A, typename T, typename V, 
00166          typename ISimp, typename IFace,
00167          typename IntOutputIterator>
00168 void
00169 buildBoundaryWithoutPacking(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00170                             IndSimpSet<N,M-1,true,T,V,IFace>* out,
00171                             IntOutputIterator incidentSimplices);
00172 
00173 
00175 
00184 template<int N, int M, bool A, typename T, typename V, 
00185          typename ISimp, typename IFace>
00186 inline
00187 void
00188 buildBoundaryWithoutPacking(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00189                             IndSimpSet<N,M-1,true,T,V,IFace>* out) {
00190   buildBoundaryWithoutPacking(in, out, ads::constructTrivialOutputIterator());
00191 }
00192 
00193 
00194 
00196 
00209 template<int N, int M, bool A, typename T, typename V, 
00210          typename ISimp, typename IFace,
00211          typename IntOutputIterator1, typename IntOutputIterator2>
00212 void
00213 buildBoundaryOfComponentsWithoutPacking
00214 (const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00215  IndSimpSet<N,M-1,true,T,V,IFace>* out,
00216  IntOutputIterator1 delimiterIterator,
00217  IntOutputIterator2 incidentSimplices);
00218 
00219 
00220 
00222 
00233 template<int N, int M, bool A, typename T, typename V, 
00234          typename ISimp, typename IFace,
00235          typename IntOutputIterator>
00236 inline
00237 void
00238 buildBoundaryOfComponentsWithoutPacking
00239 (const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00240  IndSimpSet<N,M-1,true,T,V,IFace>* out,
00241  IntOutputIterator delimiterIterator) {
00242   buildBoundaryOfComponentsWithoutPacking
00243     (in, out, delimiterIterator, ads::constructTrivialOutputIterator());
00244 }
00245 
00246 
00247 
00249 
00259 template<int N, int M, bool A, typename T, typename V, 
00260          typename ISimp, typename IFace,
00261          typename IntOutputIterator1, typename IntOutputIterator2>
00262 inline
00263 void
00264 buildBoundaryOfComponents(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00265                           IndSimpSet<N,M-1,true,T,V,IFace>* out,
00266                           IntOutputIterator1 delimiterIterator,
00267                           IntOutputIterator2 incidentSimplices) {
00268   // First do it without packing.
00269   buildBoundaryOfComponentsWithoutPacking(in, out, delimiterIterator,
00270                                           incidentSimplices);
00271   // Pack the mesh to get rid of the interior vertices.
00272   pack(out);
00273 }
00274 
00275 
00276 
00277 
00279 
00287 template<int N, int M, bool A, typename T, typename V, 
00288          typename ISimp, typename IFace,
00289          typename IntOutputIterator>
00290 inline
00291 void
00292 buildBoundaryOfComponents(const IndSimpSetIncAdj<N,M,A,T,V,ISimp>& in,
00293                           IndSimpSet<N,M-1,true,T,V,IFace>* out,
00294                           IntOutputIterator delimiterIterator) {
00295   buildBoundaryOfComponents(in, out, delimiterIterator, 
00296                             ads::constructTrivialOutputIterator());
00297 }
00298 
00299 
00300 
00301 
00303 
00309 template<int N, int M, bool A, typename T, typename V, 
00310          typename ISimp, typename IFace>
00311 void
00312 centerPointMesh(const IndSimpSet<N,M-1,A,T,V,IFace>& boundary,
00313                 IndSimpSet<N,M,true,T,V,ISimp>* mesh);
00314 
00315 
00317 
00327 template<int N, int M, typename T, typename V, typename IS, 
00328          typename MeshInputIterator>
00329 void
00330 merge(MeshInputIterator beginning, MeshInputIterator end,
00331       IndSimpSet<N,M,true,T,V,IS>* out);
00332 
00333 
00335 
00345 template<int N, int M, bool A, typename T, typename V, typename IS>
00346 void
00347 merge2(const IndSimpSet<N,M,A,T,V,IS>& a, const IndSimpSet<N,M,A,T,V,IS>& b,
00348        IndSimpSet<N,M,true,T,V,IS>* out);
00349 
00351 
00352 END_NAMESPACE_GEOM
00353 
00354 #define __geom_mesh_iss_build_ipp__
00355 #include "build.ipp"
00356 #undef __geom_mesh_iss_build_ipp__
00357 
00358 #endif

Generated on Fri Aug 24 12:55:51 2007 for Computational Geometry Package by  doxygen 1.4.7