PHP imageantialias - Whether to Use the Antialias Feature
imageantialias — Whether to use the antialias feature.
Syntax
bool imageantialias ( resource $image , bool $enabled )
Enables a fast drawing antialiasing method for line segments and polygons. The alpha part is not supported. Uses direct blending operations. Only for true-color images.
Line width and style are not supported.
Using antialiasing with a transparent background color may produce unexpected results. The blending method treats the background color like any other color. The lack of alpha part support means alpha-based antialiasing methods are not allowed.
Parameters
- image: The image resource returned by an image creation function (e.g., imagecreatetruecolor()).
- ** enabled**: Whether to enable antialiasing.
Return Value
Returns TRUE on success, or FALSE on failure.
Example
The image of the output result of the example above is as follows:
PHP Image Processing