protected function formatToCompressionQuality(string $format): int
    {
        switch (($ext = $this->formatToExt($format))) {
            case 'jpg':
                $quality = 85;
                break;

            default:
                $quality = 92;
        }
        return $quality;
    }