Skip to content

Instantly share code, notes, and snippets.

#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Polygon_mesh_processing/refine.h>
#include <CGAL/Polygonal_surface_reconstruction.h>
#include <CGAL/Surface_mesh.h>
#include <CGAL/property_map.h>
int main() {
typedef CGAL::Exact_predicates_exact_constructions_kernel Epeck_kernel;
typedef Epeck_kernel::Point_3 Epeck_point;
typedef CGAL::Surface_mesh<Epeck_point> Epeck_surface_mesh;
#define CGAL_USE_GLPK
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/GLPK_mixed_integer_program_traits.h>
#include <CGAL/Polygonal_surface_reconstruction.h>
#include <CGAL/Surface_mesh.h>
#include <CGAL/property_map.h>
int main() {
typedef CGAL::Exact_predicates_inexact_constructions_kernel Epick_kernel;
#include <CGAL/Arrangement_2.h>
#include <CGAL/Arr_segment_traits_2.h>
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Polygon_with_holes_2.h>
#include <fstream>
#include <iostream>
typedef CGAL::Exact_predicates_exact_constructions_kernel Epeck_kernel;
typedef Epeck_kernel Kernel;
@pentacular
pentacular / gist:c85eea43509ce5ac83241ec1f3d5bf21
Created July 14, 2023 10:35
Arrangement producing non-simple polygons from outer ccb
#include <CGAL/Arrangement_2.h>
#include <CGAL/Arr_segment_traits_2.h>
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Polygon_with_holes_2.h>
#include <fstream>
#include <iostream>
typedef CGAL::Exact_predicates_exact_constructions_kernel Epeck_kernel;
typedef Epeck_kernel Kernel;
@pentacular
pentacular / foo.js
Created September 11, 2020 10:02
multi2 #jsxcad
import 'http://www.foo.com';
Circle(10).color('red').with(Triangle(5).color('green')).item().topView();
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:version="1.0 (4035a4fb49, 2020-05-01)"
@pentacular
pentacular / foo.js
Created September 11, 2020 08:14
Foo2 #jsxcad
import 'http://www.foo.com';
Circle(10).color('red').with(Triangle(5).color('green')).item().topView();
@pentacular
pentacular / foo.js
Created September 11, 2020 08:09
Foo #jsxcad
import 'http://www.foo.com';
Circle(10).color('red').with(Triangle(5).color('green')).item().topView();
@pentacular
pentacular / foo.js
Created September 11, 2020 07:57
undefined #jsxcad
import 'http://www.foo.com';
Circle(10).color('red').with(Triangle(5).color('green')).item().topView();
@pentacular
pentacular / script.jsxcad
Created April 1, 2020 02:25
Debug #jsxcad
md`# House`
md`## Profile`
const profile =
Union(
Triangle(20).rotate(-30),
Square(20).cut(Square(6, 12)).moveY(-15.5),
)
.topView();