| @@ 488-492 (lines=5) @@ | ||
| 485 | } |
|
| 486 | break; |
|
| 487 | case IMAGETYPE_JPEG: |
|
| 488 | if (imagetypes() & IMG_JPG) { |
|
| 489 | $this->resource = imagecreatefromjpeg($imagePath); |
|
| 490 | } else { |
|
| 491 | $this->logger->debug('OC_Image->loadFromFile, JPG images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 492 | } |
|
| 493 | break; |
|
| 494 | case IMAGETYPE_PNG: |
|
| 495 | if (imagetypes() & IMG_PNG) { |
|
| @@ 505-509 (lines=5) @@ | ||
| 502 | } |
|
| 503 | break; |
|
| 504 | case IMAGETYPE_XBM: |
|
| 505 | if (imagetypes() & IMG_XPM) { |
|
| 506 | $this->resource = imagecreatefromxbm($imagePath); |
|
| 507 | } else { |
|
| 508 | $this->logger->debug('OC_Image->loadFromFile, XBM/XPM images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 509 | } |
|
| 510 | break; |
|
| 511 | case IMAGETYPE_WBMP: |
|
| 512 | if (imagetypes() & IMG_WBMP) { |
|
| @@ 512-516 (lines=5) @@ | ||
| 509 | } |
|
| 510 | break; |
|
| 511 | case IMAGETYPE_WBMP: |
|
| 512 | if (imagetypes() & IMG_WBMP) { |
|
| 513 | $this->resource = imagecreatefromwbmp($imagePath); |
|
| 514 | } else { |
|
| 515 | $this->logger->debug('OC_Image->loadFromFile, WBMP images not supported: ' . $imagePath, array('app' => 'core')); |
|
| 516 | } |
|
| 517 | break; |
|
| 518 | case IMAGETYPE_BMP: |
|
| 519 | $this->resource = $this->imagecreatefrombmp($imagePath); |
|