Skip to content

Instantly share code, notes, and snippets.

View afabri's full-sized avatar

Andreas Fabri afabri

View GitHub Profile
@afabri
afabri / max-not-permissive.cpp
Last active November 21, 2018 16:24
Does not compile with VC2017 with option /permissive-
#include <algorithm>
template <typename T>
class A {
void fct()
{
double d = true ? 1.
: (std::max<std::ptrdiff_t>(1,2) * 1.) ;
}
#include <iostream>
#include <fstream>
#include <vector>
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/array.h>
#include <CGAL/IO/STL_reader.h>
#include <CGAL/AABB_tree.h>
#include <CGAL/AABB_traits.h>
-*- mode: compilation; default-directory: "c:/cgal/git/Periodic_4_hyperbolic_triangulation_2/test/Periodic_4_hyperbolic_triangulation_2/VC2017/" -*-
Compilation started at Tue Jan 8 08:31:04
cd VC2017; jom
jom 1.1.2 - empower your cores
jom: parallel job execution disabled for Makefile
[ 28%] Building CXX object CMakeFiles/test_p4ht2_insertion.dir/test_p4ht2_insertion.cpp.obj
test_p4ht2_insertion.cpp
#include <fstream>
#include <iostream>
#include <draco/mesh/corner_table.h>
#include <draco/mesh/mesh_misc_functions.h>
#include <draco/compression/decode.h>
int main(int argc, char **argv)
{
@afabri
afabri / Pair_partition_traits_2.h
Created March 25, 2019 08:12
partition with information associated to the polygon vertices
// Copyright (c) 2000 Max-Planck-Institute Saarbruecken (Germany).
// All rights reserved.
//
// This file is part of CGAL (www.cgal.org).
// You can redistribute it and/or modify it under the terms of the GNU
// General Public License as published by the Free Software Foundation,
// either version 3 of the License, or (at your option) any later version.
//
// Licensees holding a valid commercial license may use this file in
// accordance with the commercial license agreement provided with the software.
#include <CGAL/Epeck_d.h>
int main(){
typedef CGAL::Epeck_d<CGAL::Dimension_tag<2>> EK;
typedef typename EK::Vector_d V;
typedef typename EK::Construct_vector_d CV;
EK k;
CV cv = k.construct_vector_d_object();
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Bounded_kernel.h>
#include <CGAL/Nef_polyhedron_2.h>
#include <list>
typedef CGAL::Bounded_kernel<CGAL::Exact_predicates_exact_constructions_kernel> Extended_kernel;
typedef CGAL::Nef_polyhedron_2<Extended_kernel> Nef_polyhedron;
typedef Nef_polyhedron::Point Point; // a standard point
#include <cassert>
#include <vector>
// typedefs for the traits and the algorithm
#include <CGAL/Gmpq.h>
#include <CGAL/Segment_Delaunay_graph_2.h>
#include <CGAL/Segment_Delaunay_graph_adaptation_policies_2.h>
#include <CGAL/Segment_Delaunay_graph_adaptation_traits_2.h>
#include <CGAL/Segment_Delaunay_graph_filtered_traits_2.h>
#include <CGAL/Simple_cartesian.h>
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/Surface_mesh.h>
#include <CGAL/convex_hull_3.h>
#include <CGAL/Extreme_points_traits_adapter_3.h>
#include <vector>
#include <fstream>
typedef CGAL::Exact_predicates_inexact_constructions_kernel K;
typedef K::Point_3 Point_3;
#include <iostream>
#include <fstream>
#include <stdlib.h>
using std::cout; using std::endl;
#include "CGAL/Surface_mesh.h"
#include "CGAL/Surface_mesh_shortest_path.h"
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
typedef CGAL::Surface_mesh<Kernel::Point_3> Triangle_mesh;