![]() |
CI image library crop problem - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: CI image library crop problem (/showthread.php?tid=28994) |
CI image library crop problem - El Forum - 03-27-2010 [eluser]bogdan3l[/eluser] Hello! I have a problem with CI image library crop. I resize & crop multiple images automatically and everything works just fine. My final image will have 200px - 133px but: When i resize an image and after resize the image will have a smaller height than 133px i will end up with a black space. Example: ------------------------------------------------------------------------- If the image has 100px after resize i will end up with black zone of 33px. And my question is: how i can transform that black in white ![]() I don't have control over the uploaded images, everything is automatically. // Crop $config['image_library'] = 'gd2'; $config['source_image'] = 'my_path_here'; $config['height'] = 133; $config['quality'] = '100%'; $config['maintain_ratio'] = FALSE; $this->image_lib->clear(); $this->image_lib->initialize($config); $this->image_lib->crop(); Thanks a lot, and sorry for my bad english! |