source: antialias.png.php

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php

    
require_once"image.toolbox.inc.php" );
    require_once
"image.antialias.inc.php" );

    
//    test it ...

    
if ( $gdv gdVersion() ) {
        if ( 
$gdv >= ) {
            
$image imageCreateTrueColor300200 );
            
$color imageColorExactAlpha$image,  32216,  64,   );
            
$tmode true;

        } else {
            
$image imageCreate300200 );
            
$black imageColorAllocate$image,   0,   0,   );
            
$color imageColorAllocate$image,  32216,  64 );
            
$tmode false;
        }
    
        
imageSmoothLine$image,   0,   5300195$color$tmode );
        
imageSmoothLine$image,   0,  50300150$color$tmode );
        
imageSmoothLine$image,   0105300,  95$color$tmode );
        
imageSmoothLine$image,   0150300,  50$color$tmode );
    
        
imageSmoothLine$image,  50,   0250200$color$tmode );
        
imageSmoothLine$image100,   0200200$color$tmode );
        
imageSmoothLine$image155,   0145200$color$tmode );
        
imageSmoothLine$image200,   0100200$color$tmode );
        
imageSmoothLine$image250,   0,  50200$color$tmode );
    
        
header"Content-Type: image/png" );
        
imagePNG$image );
        
imageDestroy$image );

    } else {
        echo 
"The GD extension is not available.";
    }

?>