#ifndef _NUMmetrics_h_ #define _NUMmetrics_h_ /* NUMmetrics.h * * Copyright (C) 1992-2018 Paul Boersma * * This code is free software; 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 2 of the License, or (at * your option) any later version. * * This code is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this work. If not, see . */ /********** Metrics **********/ int NUMrotationsPointInPolygon (double x0, double y0, integer n, double x [], double y []); /* Returns the number of times that the closed polygon (x [1], y [1]), (x [2], y [2]),..., (x [n], y [n]), (x [1], y [1]) encloses the point (x0, y0). The result is positive if the polygon encloses the point in the anti-clockwise direction, and negative if the direction is clockwise. The result is 0 if the point is outside the polygon. If the point is on the polygon, the result is unpredictable. */ /* End of file NUMmetrics.h */ #endif