| @@ 512-516 (lines=5) @@ | ||
| 509 | } |
|
| 510 | break; |
|
| 511 | case IMAGETYPE_JPEG: |
|
| 512 | if (imagetypes() & IMG_JPG) { |
|
| 513 | $this->resource = imagecreatefromjpeg($imagePath); |
|
| 514 | } else { |
|
| 515 | $this->logger->debug('OC_Image->loadFromFile, JPG images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 516 | } |
|
| 517 | break; |
|
| 518 | case IMAGETYPE_PNG: |
|
| 519 | if (imagetypes() & IMG_PNG) { |
|
| @@ 529-533 (lines=5) @@ | ||
| 526 | } |
|
| 527 | break; |
|
| 528 | case IMAGETYPE_XBM: |
|
| 529 | if (imagetypes() & IMG_XPM) { |
|
| 530 | $this->resource = imagecreatefromxbm($imagePath); |
|
| 531 | } else { |
|
| 532 | $this->logger->debug('OC_Image->loadFromFile, XBM/XPM images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 533 | } |
|
| 534 | break; |
|
| 535 | case IMAGETYPE_WBMP: |
|
| 536 | if (imagetypes() & IMG_WBMP) { |
|
| @@ 536-540 (lines=5) @@ | ||
| 533 | } |
|
| 534 | break; |
|
| 535 | case IMAGETYPE_WBMP: |
|
| 536 | if (imagetypes() & IMG_WBMP) { |
|
| 537 | $this->resource = imagecreatefromwbmp($imagePath); |
|
| 538 | } else { |
|
| 539 | $this->logger->debug('OC_Image->loadFromFile, WBMP images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 540 | } |
|
| 541 | break; |
|
| 542 | case IMAGETYPE_BMP: |
|
| 543 | $this->resource = $this->imagecreatefrombmp($imagePath); |
|