imagejpeg

Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Output image to browser or file
imagejpeg(GdImage $imageresource|string|null $file nullint $quality = -1): bool
    protected function processJpeg()

    {

        
ob_start();

        
imagejpeg($this->image->getCore(), null$this->quality);

        
$this->image->mime image_type_to_mime_type(IMAGETYPE_JPEG);

        
$buffer ob_get_contents();

        
ob_end_clean();