Last active
January 12, 2016 11:15
-
-
Save pranavkantgaur/8f90bf095a61c5d8e3b8 to your computer and use it in GitHub Desktop.
Creates LCC having LCC::Dart_handle type attributes associated with 2-cells.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <CGAL/Linear_cell_complex.h> | |
#include <CGAL/Linear_cell_complex_constructors.h> | |
using namespace std; | |
using namespace CGAL; | |
typedef Exact_predicates_inexact_constructions_kernel K; | |
typedef Linear_cell_complex_traits<3, K> Traits; | |
typedef Linear_cell_complex<3, 3, Traits> LCC; | |
typedef Point_3<K> Point; | |
struct DartInfo | |
{ | |
template<class C> | |
struct Dart_wrapper | |
{ | |
typedef CGAL::Dart<3, C > Dart; | |
typedef Cell_attribute<C, LCC::Dart_handle> Facet_attribute; | |
typedef cpp11::tuple<void, void, Facet_attribute> Attributes; | |
}; | |
}; | |
typedef Linear_cell_complex<3, 3, Traits, DartInfo> LCCWithFacetAttribute; | |
int main() | |
{ | |
LCCWithFacetAttribute testLCC; | |
Point p[3]; | |
p[0] = Point(0.0, 0.0, 1.0); | |
p[1] = Point(1.0, 0.0, 0.0); | |
p[2] = Point(0.0, 1.0, 0.0); | |
testLCC.make_triangle(p[0], p[1], p[2]); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment