/
githubmirror
/
nbs
Обзор
Документация
Войти
/
githubmirror
/
nbs
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
contrib/python/Pillow/py3/libImaging/Negative.c
42 строки
779 B
Anton Myagkov
Update ydb version to 24.4 (#4579)
07 фев 2026, 11:59
Не верифицирован
07 фев 2026, 11:59
2c21cae
Код
Авторство
О чём код?
/* * The Python Imaging Library * $Id$ * * negate image * * to do: * FIXME: Maybe this should be implemented using ImagingPoint() * * history: * 95-11-27 fl: Created * * Copyright (c) Fredrik Lundh 1995. * Copyright (c) Secret Labs AB 1997. * * See the README file for information on usage and redistribution. */ #include "Imaging.h" Imaging ImagingNegative(Imaging im) { Imaging imOut; int x, y; if (!im) { return (Imaging)ImagingError_ModeError(); } imOut = ImagingNewDirty(im->mode, im->xsize, im->ysize); if (!imOut) { return NULL; } for (y = 0; y < im->ysize; y++) { for (x = 0; x < im->linesize; x++) { imOut->image[y][x] = ~im->image[y][x]; } } return imOut; }