18 declare(strict_types=1);
40 imagejpeg($image,
null, $quality ?? 75);
41 $stringdata = ob_get_contents();
50 if ($stream->getSize() > $this->getSizeLimitInBytes()) {
60 return match ($mime) {
61 'image/jpeg' => imagecreatefromjpeg(
$filename),
62 'image/png' => imagecreatefrompng(
$filename),
63 'image/gif' => imagecreatefromgif(
$filename),
64 'image/bmp' => imagecreatefrombmp(
$filename),
65 'image/webp' => imagecreatefromwebp(
$filename),
66 default => imagecreatefromstring((
string) $stream)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static ofString(string $string)
Creates a new stream with an initial value.
to(\GdImage $image, ?int $quality=null)
Currently this is the only way to make a FileStream from a GD image resource.
The base interface for all filesystem streams.