mirror of
				https://github.com/python-pillow/Pillow.git
				synced 2025-11-01 00:17:27 +03:00 
			
		
		
		
	Move import math.h to ImagingPlatform
This commit is contained in:
		
							parent
							
								
									ff7c29ced9
								
							
						
					
					
						commit
						039869fe77
					
				|  | @ -85,8 +85,6 @@ | |||
| 
 | ||||
| #include "libImaging/Imaging.h" | ||||
| 
 | ||||
| #define _USE_MATH_DEFINES | ||||
| #include <math.h> | ||||
| #include <stddef.h> | ||||
| 
 | ||||
| #undef VERBOSE | ||||
|  |  | |||
|  | @ -15,7 +15,6 @@ | |||
| 
 | ||||
| #include "libImaging/Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| #include <float.h> | ||||
| 
 | ||||
| #define MAX_INT32 2147483647.0 | ||||
|  |  | |||
|  | @ -1,5 +1,4 @@ | |||
| #include "Imaging.h" | ||||
| #include <math.h> | ||||
| 
 | ||||
| /* 8 bits for result. Table can overflow [0, 1.0] range,
 | ||||
|    so we need extra bits for overflow and negative values. | ||||
|  |  | |||
|  | @ -34,8 +34,6 @@ | |||
| 
 | ||||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| #define CEIL(v) (int)ceil(v) | ||||
| #define FLOOR(v) ((v) >= 0.0 ? (int)(v) : (int)floor(v)) | ||||
| 
 | ||||
|  |  | |||
|  | @ -17,8 +17,6 @@ | |||
| 
 | ||||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| Imaging | ||||
| ImagingEffectMandelbrot(int xsize, int ysize, double extent[4], int quality) { | ||||
|     /* Generate a Mandelbrot set covering the given extent */ | ||||
|  |  | |||
|  | @ -17,8 +17,6 @@ | |||
| 
 | ||||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include "math.h" | ||||
| 
 | ||||
| Imaging | ||||
| ImagingFill(Imaging im, const void *colour) { | ||||
|     int x, y; | ||||
|  |  | |||
|  | @ -16,10 +16,6 @@ | |||
| extern "C" { | ||||
| #endif | ||||
| 
 | ||||
| #ifndef M_PI | ||||
| #define M_PI 3.1415926535897932384626433832795 | ||||
| #endif | ||||
| 
 | ||||
| /* -------------------------------------------------------------------- */ | ||||
| 
 | ||||
| /*
 | ||||
|  |  | |||
|  | @ -10,6 +10,9 @@ | |||
| #define PY_SSIZE_T_CLEAN | ||||
| #include <Python.h> | ||||
| 
 | ||||
| #define _USE_MATH_DEFINES | ||||
| #include <math.h> | ||||
| 
 | ||||
| /* Check that we have an ANSI compliant compiler */ | ||||
| #ifndef HAVE_PROTOTYPES | ||||
| #error Sorry, this library requires support for ANSI prototypes. | ||||
|  |  | |||
|  | @ -18,8 +18,6 @@ | |||
| 
 | ||||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| ImagingPalette | ||||
| ImagingPaletteNew(const char *mode) { | ||||
|     /* Create a palette object */ | ||||
|  |  | |||
|  | @ -1428,7 +1428,6 @@ quantize( | |||
|     } | ||||
| 
 | ||||
| #ifdef TEST_NEAREST_NEIGHBOUR | ||||
| #include <math.h> | ||||
|     { | ||||
|         uint32_t bestmatch, bestdist, dist; | ||||
|         HashTable *h2; | ||||
|  |  | |||
|  | @ -1,7 +1,5 @@ | |||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| #define ROUND_UP(f) ((int)((f) >= 0.0 ? (f) + 0.5F : (f) - 0.5F)) | ||||
| 
 | ||||
| UINT32 | ||||
|  |  | |||
|  | @ -1,7 +1,5 @@ | |||
| #include "Imaging.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| #define ROUND_UP(f) ((int)((f) >= 0.0 ? (f) + 0.5F : (f) - 0.5F)) | ||||
| 
 | ||||
| struct filter { | ||||
|  |  | |||
|  | @ -28,8 +28,6 @@ | |||
| #include "libImaging/Imaging.h" | ||||
| #include "thirdparty/pythoncapi_compat.h" | ||||
| 
 | ||||
| #include <math.h> | ||||
| 
 | ||||
| /* compatibility wrappers (defined in _imaging.c) */ | ||||
| extern int | ||||
| PyImaging_CheckBuffer(PyObject *buffer); | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user