| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
Interesting! |
Sorry, something went wrong.
|
@aclark4life Not sure the work will be finished ) Right now I just need various test environments from this PR. |
Sorry, something went wrong.
|
Is there any way in the build we can declare the minimum C version? pyproject.toml has requires-python = ">=3.9" for the Python version, but I don't see a setting that can be used for C. NumPy uses Meson, so their minimum C version is declared in the meson.build file. |
Sorry, something went wrong.
|
Build with python ./setup.py develop --pillow-configuration=parallel=1. Currently, the _imaging extension contains a batch of very useful functions and types that are not available in other extensions (such as _webp or _imagingcms). As a result, these other extensions do not utilize the useful functions from _imaging (for example, _webp is the only extension that uses ImagingSectionEnter/Leave) and do not perform any type checking. Here is a typical code example from extensions that use the Imaging type: static PyObject *
cms_transform_apply(CmsTransformObject *self, PyObject *args) {
Py_ssize_t idIn;
Py_ssize_t idOut;
Imaging im;
Imaging imOut;
int result;
if (!PyArg_ParseTuple(args, "nn:apply", &idIn, &idOut)) {
return NULL;
}
im = (Imaging)idIn;
imOut = (Imaging)idOut;
result = pyCMSdoTransform(im, imOut, self->transform);
return Py_BuildValue("i", result);
}So, it just converts an arbitrary Py_ssize_t to a pointer, which is not safe. What I'm trying to achieve is to use the _imaging extension as a library for other extensions. Unfortunately, as I see it, this is only possible by changing the name to lib_imaging since gcc -l always appends the lib prefix and there is no way to specify the full library name. |
Sorry, something went wrong.
|
_imaging also contains a bunch of things for the imaging module though, which aren't needed elsewhere. I think it would be cleaner to leave _imaging as it is, and create a new library that _imaging depends on. Then code can be moved from _imaging to the new library, and the other extensions can also be changed to use the new library. |
Sorry, something went wrong.
|
@Yay295 This involves massive extension redesign, I'm not ready for this ) |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
No description provided.