History log of /PHP-8.3/ext/gd/gd.c (Results 101 – 125 of 718)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: php-7.4.0alpha1
# 63171d88 12-Jun-2019 twosee

Add do...while(0) for RETURN_* and ZVAL_* APIs

Closes GH-4255.


Revision tags: php-7.3.7RC1, php-7.2.20RC1, php-7.2.19, php-7.3.6, php-7.1.30, php-7.2.19RC1, php-7.3.6RC1, php-7.1.29, php-7.2.18, php-7.3.5, php-7.2.18RC1, php-7.3.5RC1, php-7.2.17, php-7.3.4, php-7.1.28, php-7.3.4RC1, php-7.2.17RC1, php-7.1.27, php-7.3.3, php-7.2.16
# a31f4642 26-Feb-2019 Nikita Popov

Allow exceptions in __toString()

RFC: https://wiki.php.net/rfc/tostring_exceptions

And convert some object to string conversion related recoverable
fatal errors into Error excep

Allow exceptions in __toString()

RFC: https://wiki.php.net/rfc/tostring_exceptions

And convert some object to string conversion related recoverable
fatal errors into Error exceptions.

Improve exception safety of internal code performing string
conversions.

show more ...


# bcd11a1d 09-May-2019 Kalle Sommer Nielsen

Implemented the gdScatter filter I wrote almost 10 years ago

This filter is available as of libgd 2.1.0 which is our bare minimum for
external compilation of ext/gd.

The scatter

Implemented the gdScatter filter I wrote almost 10 years ago

This filter is available as of libgd 2.1.0 which is our bare minimum for
external compilation of ext/gd.

The scatter filter works by iterating over all pixels in the image and
shifting them randomly based on two modifier (`plus` and `sub`) values:

dest_x = (int)(x + ((rand() % (plus - sub)) + sub));
dest_y = (int)(y + ((rand() % (plus - sub)) + sub));

Additionally the scatter filter also supports by only shifting pixels where
the current pixel being iterated is one or more colors, allowing the scatter
filter to only effect solid colors in part of an image.

Note, due to the nature of randomness and implementation, pixels who were
shifted ahead of iteration will be shifted once more and therefore the
bottom right of an image may contain a slight scatter effect due to this.

show more ...


# 18a9ae41 29-Apr-2019 Christoph M. Becker

Fix #77943: imageantialias($image, false); does not work

Firstly, we must not call `gdImageSetAntiAliased()` (which sets the
color to anti-alias), but rather modify the `gdImage.AA` flag

Fix #77943: imageantialias($image, false); does not work

Firstly, we must not call `gdImageSetAntiAliased()` (which sets the
color to anti-alias), but rather modify the `gdImage.AA` flag.
Furthermore, we have to actually use the supplied boolean value.

We also make sure that we don't attempt to enable anti-aliasing for
palette images.

show more ...


# cd94cf60 29-Apr-2019 Christoph M. Becker

Fix #77943: imageantialias($image, false); does not work

Firstly, we must not call `gdImageSetAntiAliased()` (which sets the
color to anti-alias), but rather modify the `gdImage.AA` flag

Fix #77943: imageantialias($image, false); does not work

Firstly, we must not call `gdImageSetAntiAliased()` (which sets the
color to anti-alias), but rather modify the `gdImage.AA` flag.
Furthermore, we have to actually use the supplied boolean value.

We also make sure that we don't attempt to enable anti-aliasing for
palette images.

show more ...


# b6f9ade9 08-Mar-2019 Fabien Villepinte

Remove unused variables


# 345a75f5 28-Feb-2019 Christoph M. Becker

Remove dead code

`_php_image_output()` is only ever called for `PHP_GDIMG_CONVERT_WBM`,
`PHP_GDIMG_TYPE_GD` and `PHP_GDIMG_TYPE_GD2`. All other image types
solely use the more flexi

Remove dead code

`_php_image_output()` is only ever called for `PHP_GDIMG_CONVERT_WBM`,
`PHP_GDIMG_TYPE_GD` and `PHP_GDIMG_TYPE_GD2`. All other image types
solely use the more flexible `_php_image_output_ctx()`.

show more ...


# 4be8208e 28-Feb-2019 Nikita Popov

Use zpp string argument in imagecreatefromstring()

Instead of accepting a zval and casting it.


Revision tags: php-7.3.3RC1, php-7.2.16RC1, php-7.2.15, php-7.3.2, php-7.2.15RC1
# 92ac598a 22-Jan-2019 Peter Kokot

Remove local variables

This patch removes the so called local variables defined per
file basis for certain editors to properly show tab width, and
similar settings. These are mainly

Remove local variables

This patch removes the so called local variables defined per
file basis for certain editors to properly show tab width, and
similar settings. These are mainly used by Vim and Emacs editors
yet with recent changes the once working definitions don't work
anymore in Vim without custom plugins or additional configuration.
Neither are these settings synced across the PHP code base.

A simpler and better approach is EditorConfig and fixing code
using some code style fixing tools in the future instead.

This patch also removes the so called modelines for Vim. Modelines
allow Vim editor specifically to set some editor configuration such as
syntax highlighting, indentation style and tab width to be set in the
first line or the last 5 lines per file basis. Since the php test
files have syntax highlighting already set in most editors properly and
EditorConfig takes care of the indentation settings, this patch removes
these as well for the Vim 6.0 and newer versions.

With the removal of local variables for certain editors such as
Emacs and Vim, the footer is also probably not needed anymore when
creating extensions using ext_skel.php script.

Additionally, Vim modelines for setting php syntax and some editor
settings has been removed from some *.phpt files. All these are
mostly not relevant for phpt files neither work properly in the
middle of the file.

show more ...


# e18fde1a 30-Jan-2019 Nikita Popov

Remove -1 crop mode


# 0cf7de1c 30-Jan-2019 Zeev Suraski

Remove yearly range from copyright notice


# 38c337f2 30-Jan-2019 Zeev Suraski

Remove year range from copyright notice


# e9736638 28-Jan-2019 Christoph M. Becker

Remove deprecated png2wbmp() and jpeg2wbmp()

Cf. <https://wiki.php.net/rfc/deprecate-png-jpeg-2wbmp>


# dfa6c204 28-Jan-2019 Christoph M. Becker

Remove deprecated image2wbmp()

Cf. <https://wiki.php.net/rfc/image2wbmp>.


Revision tags: php-7.3.2RC1, php-5.6.40, php-7.1.26, php-7.3.1, php-7.2.14
# 3c9af309 29-Dec-2018 Andreas Treichel

Preserve aspect ratio for width or height


Revision tags: php-7.2.14RC1, php-7.3.1RC1
# 8c781c1c 12-Dec-2018 Christoph M. Becker

Resolve imagecropauto() default $mode quirk

The `$mode` parameter of `imagecropauto()` defaults to `-1`. However,
`-1` is changed to `GD_CROP_DEFAULT` right away, so basically the
d

Resolve imagecropauto() default $mode quirk

The `$mode` parameter of `imagecropauto()` defaults to `-1`. However,
`-1` is changed to `GD_CROP_DEFAULT` right away, so basically the
default is `GD_CROP_DEFAULT`, which is rather confusing and
unnecessary.

Therefore, we change the default to `IMG_CROP_DEFAULT`, but still allow
an explicit `-1` to be passed for BC reasons, in which case we trigger
a deprecation notice, so we can rid the `-1` support eventually.

show more ...


Revision tags: php-5.6.39, php-7.1.25, php-7.2.13, php-7.0.33, php-7.3.0, php-7.1.25RC1, php-7.2.13RC1, php-7.3.0RC6, php-7.1.24, php-7.2.12, php-7.3.0RC5, php-7.1.24RC1, php-7.2.12RC1, php-7.3.0RC4
# 902d39a3 13-Oct-2018 Peter Kokot

Trim trailing whitespace in source code files


Revision tags: php-7.1.23, php-7.2.11, php-7.3.0RC3, php-7.1.23RC1, php-7.2.11RC1, php-7.3.0RC2, php-5.6.38, php-7.1.22, php-7.3.0RC1, php-7.2.10, php-7.0.32, php-7.1.22RC1, php-7.3.0beta3, php-7.2.10RC1, php-7.1.21, php-7.2.9, php-7.3.0beta2
# 9d7c5108 02-Aug-2018 Anatol Belski

Cleanup unused items


Revision tags: php-7.1.21RC1, php-7.3.0beta1, php-7.2.9RC1, php-5.6.37, php-7.1.20, php-7.3.0alpha4, php-7.0.31, php-7.2.8, php-7.1.20RC1, php-7.2.8RC1, php-7.3.0alpha3
# 8d3f8ca1 03-Jul-2018 Peter Kokot

Remove unused Git attributes ident

The $Id$ keywords were used in Subversion where they can be substituted
with filename, last revision number change, last changed date, and last
use

Remove unused Git attributes ident

The $Id$ keywords were used in Subversion where they can be substituted
with filename, last revision number change, last changed date, and last
user who changed it.

In Git this functionality is different and can be done with Git attribute
ident. These need to be defined manually for each file in the
.gitattributes file and are afterwards replaced with 40-character
hexadecimal blob object name which is based only on the particular file
contents.

This patch simplifies handling of $Id$ keywords by removing them since
they are not used anymore.

show more ...


Revision tags: php-7.3.0alpha2, php-7.1.19, php-7.2.7
# 3cbf594d 09-Jun-2018 Christoph M. Becker

Deprecate image2wbmp()

According to https://wiki.php.net/rfc/image2wbmp, we deprecate
`image2wbmp()`, rename the `$threshold` parameter to `$foreground`, and
remove superfluous code.


Revision tags: php-7.1.19RC1, php-7.3.0alpha1, php-7.2.7RC1
# 5eb1f92f 28-May-2018 Dmitry Stogov

Use zend_string_release_ex() instread of zend_string_release() in places, where we sure about string persistence.


Revision tags: php-7.1.18, php-7.2.6, php-7.2.6RC1, php-7.1.18RC1
# 027dd861 06-May-2018 Christoph M. Becker

Dump obsolete EBCDIC support

As already suggested by Thies this code won't compile anymore, because
php3_rqst has been removed in 1999[1]. Since apparently nobody
complained about t

Dump obsolete EBCDIC support

As already suggested by Thies this code won't compile anymore, because
php3_rqst has been removed in 1999[1]. Since apparently nobody
complained about that, we assume that EBCDIC support isn't required
here, and rid the respective code.

Furthermore, the code appears to be erroneous anyway, since at least
XBM isn't a binary file format.

[1] <https://github.com/php/php-src/commit/3cd0af11eea32f802228004af8fe424c62c8fbfb#diff-1a9cfc6173e3a434387996e46086da56L258>

show more ...


Revision tags: php-5.6.36, php-7.2.5, php-7.1.17, php-7.0.30, php-7.1.17RC1, php-7.2.5RC1, php-5.6.35, php-7.0.29, php-7.2.4, php-7.1.16, php-7.1.16RC1, php-7.2.4RC1
# f1b358c9 09-Mar-2018 Christoph M. Becker

Fix #73957: signed integer conversion in imagescale()

We must not pass values to `gdImageScale()` which cannot be represented
by an `unsigned int`. Instead we return FALSE, according to

Fix #73957: signed integer conversion in imagescale()

We must not pass values to `gdImageScale()` which cannot be represented
by an `unsigned int`. Instead we return FALSE, according to what we
already did for negative integers.

show more ...


Revision tags: php-7.1.15, php-5.6.34, php-7.2.3, php-7.0.28
# 5f54f480 23-Feb-2018 Gabriel Caruso

[ci skip] Remove space between function name and open parentheses


# a358211a 24-Feb-2018 Gabriel Caruso

Fix imagesetinterpolation arginfo

imagesetinterpolation only requires one parameter.


12345678910>>...29