After two days of failure, I declared the failure. please help me!

Source: Internet
Author: User
After two days of failure, I announced the failure. please help me !! The following code directly processes the image as a garden with four corners. However, the generated image does not generate a file. you can generate a file to be processed in the specified directory .. After two days, it never works... Please help me .. Thank you! For example run Web site: http://www.xxx.com/pic.php? Gopic = 1234 has been involved for two days. if it fails to be completed, the announcement fails. please help me !!
The following code directly processes the image as a garden with four corners.
However, the generated image does not generate a file. you can generate a file to be processed in the specified directory ..
After two days, it never works... Please help me .. Thank you!
For example run Web site: http://www.xxx.com/pic.php? Gopic00001234.jpg

The pic. php code is as follows:

class RoundedCorner {  
    private $_r;  
    private $_g;  
    private $_b;  
    private $_image_path;  
    private $_radius;  
      
   function __construct($image_path, $radius, $r = 255, $g = 255, $b = 255) {   
        $this->_image_path = $image_path;  
        $this->_radius = $radius;  
        $this->_r = (int)$r;  
        $this->_g = (int)$g;  
        $this->_b = (int)$b;  
    }  
      
    private function _get_lt_rounder_corner() {  
        $radius = $this->_radius;  
        $img = imagecreatetruecolor($radius, $radius);  
        $bgcolor = imagecolorallocate($img, $this->_r, $this->_g, $this->_b);  
        $fgcolor = imagecolorallocate($img, 0, 0, 0);  
        imagefill($img, 0, 0, $bgcolor);  
        imagefilledarc($img, $radius, $radius, $radius*2, $radius*2, 180, 270, $fgcolor, IMG_ARC_PIE);  
        imagecolortransparent($img, $fgcolor);  
        return $img;  
    }  
      
    private function _load_source_image() {  
        $ext = substr($this->_image_path, strrpos($this->_image_path, '.'));  
        if (empty($ext)) {  
            return false;     

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.