缩略图后缀是jpg，建议在web服务器中配置重写判断，如果请求头Accept支持image/webp，则重写到.webp后缀

{@inheritDoc}
@see \wf\storage\StorageInterface::getThumbPath()
772439
public function getThumbPath($path, $width, $height)
    {

        // 尺寸限制
        $allowSizeList = [0, 50, 100, 150, 200, 300, 400, 500, 640, 720, 800, 1000, 1200, 1680, 1920];
        $resetW = !in_array($width, $allowSizeList);
        $resetH = !in_array($height, $allowSizeList);

        if ($resetW || $resetH) {
            foreach ($allowSizeList as $size) {
                if ($resetW && $size > $width) {
                    $width = $size;
                    $resetW = false;
                }

                if ($resetH && $size > $height) {
                    $height = $size;
                    $resetH = false;
                }

                if (!$resetH && !$resetW) {
                    break;
                }
            }
        }

        $path = $this->getPathFromUrl($path);
        $path .= ".thumb.{$width}x{$height}.jpg";
        
        return $path;
    }
659389
public static function path($src, $tail = '', $w = 0, $h = 0) {
        if ($src == '') {
            return '';
        }
        if ($tail == '') {
            return $src;
        }
        $temp = pathinfo($src);
        $name = $temp['filename'];
        $path = $temp['dirname'];
        $exte = $temp['extension'];
        $dest = $path . '/' . $name . '_' . $tail . '.' . $exte;
        if (!file_exists(WEB_ROOT . $dest)) {
            $dest = self::image_widthin($src, $dest, $w, $h);
        }
        return $dest;
    }
953750
public function getThumbPath()
    {
        return (!empty($this->thumb_path) ? str_replace($this->getThumbRootDir(), '', DirectoryHelper::slashDirname($this->thumb_path)) : '');
    }
835185
public static Observable<Bitmap> getThumbnailFromPath(String filePath) {
    final Bitmap sourceBitmap = BitmapFactory.decodeFile(filePath);
    return Observable.fromCallable(new Func0<Bitmap>() {
      @Override
      public Bitmap call() {
        return ThumbnailUtils.
            extractThumbnail(sourceBitmap, sourceBitmap.getWidth(), sourceBitmap.getHeight());
      }
    });
  }
327636
public static function getViewFilePath($path) {
        if (empty($path)) {
            return false;
        }

        if ((strpos($path, '/') !== false || strpos($path, '\\') !== false) && is_file($result = $path)) {
            return $result;
        }

        if (self::isRelativePath($path) && is_file($result = self::mapPath($path))) {
            return $result;
        }

        if (is_file($result = PHPMVC_VIEW_PATH . PHPMVC_VIEW . PHPMVC_DS . $path)) {
            return $result;
        }
       
        if (is_file($result = PHPMVC_SHARED_PATH . $path)) {
            return $result;
        }

        if (($result = self::appendPhpExtension($path)) !== false) {
            return self::getViewFilePath($result);
        }

        return false;
    }
1153278
public function getImageUrl($sFile = null, $bSsl = null)
    {
        if ($sFile) {
            $sValue = $this->getConfig()->getImageUrl($this->isAdmin(), $bSsl, null, $sFile);
        } elseif (($sValue = $this->getViewConfigParam('imagedir')) === null) {
            $sValue = $this->getConfig()->getImageUrl($this->isAdmin(), $bSsl);
            $this->setViewConfigParam('imagedir', $sValue);
        }

        return $sValue;
    }
377025
function imagePathByNode( $contentObjectAttribute, $mainNode )
    {
        $pathString = $mainNode->pathWithNames();
        $pathString = function_exists( 'mb_strtolower' ) ? mb_strtolower( $pathString ) : strtolower( $pathString );

        $ini = eZINI::instance( 'image.ini' );
        $contentImageSubtree = $ini->variable( 'FileSettings', 'PublishedImages' );
        $attributeData = $this->originalAttributeData();
        $attributeID = $attributeData['attribute_id'];
        $attributeVersion = $attributeData['attribute_version'];
        $attributeLanguage = $attributeData['attribute_language'];
        $pathParts = array( eZSys::storageDirectory(), $contentImageSubtree );
        if ( $pathString != '' )
        {
            //Make sure that all folders are smaller than the FS limit
            foreach ( explode( '/', $pathString ) as $folder )
            {
                $pathParts[] = $this->trimToFileSystemFileName( $folder );
            }
        }
        $pathParts[] = $attributeID . '-' . $attributeVersion . '-' . $attributeLanguage;
        $imagePath = implode( '/', $pathParts );
        return $imagePath;
    }
392406
public function getUrl(string $path, ?string $packageName = null): string
    {
        if ($this->status == self::NOT_LOADED) {
            $namedPackages = $this->getNamedPackages();
            if (empty($namedPackages)) {
                $this->package = $this->getDefaultPackage();
                $this->status = self::ONE_PACKAGE;
            } else {
                $defaultPackage = $this->getDefaultPackage();
                $this->packages = new Packages($defaultPackage, $namedPackages);
                $this->status = self::MUTI_PACKAGES;
            }
        }
        if ($this->status == self::ONE_PACKAGE) {
            return $this->package->getUrl($path);
        } else {
            return $this->packages->getUrl($path, $packageName);
        }
    }
1208681
public static String getImagePath(String imageTag) {
        int indexOfSlash = imageTag.indexOf("/");
        int indexOfLastColon = imageTag.lastIndexOf(":");
        String imageName;
        String imageVersion;

        if (indexOfLastColon < 0 || indexOfLastColon < indexOfSlash) {
            imageName = imageTag.substring(indexOfSlash + 1);
            imageVersion = "latest";
        } else {
            imageName = imageTag.substring(indexOfSlash + 1, indexOfLastColon);
            imageVersion = imageTag.substring(indexOfLastColon + 1);
        }
        return imageName + "/" + imageVersion;
    }
1157974
public function initFromPath($path)
    {
        if ( ! file_exists($path)) {
            throw new \Intervention\Image\Exception\NotReadableException(
                "Unable to find file ({$path})."
            );
        }

        // get mime type of file
        $mime = finfo_file(finfo_open(FILEINFO_MIME_TYPE), $path);

        // define core
        switch (strtolower($mime)) {
            case 'image/png':
            case 'image/x-png':
                $core = @imagecreatefrompng($path);
                break;

            case 'image/jpg':
            case 'image/jpeg':
            case 'image/pjpeg':
                $core = @imagecreatefromjpeg($path);
                if (!$core) {
                    $core= @imagecreatefromstring(file_get_contents($path));
                }
                break;

            case 'image/gif':
                $core = @imagecreatefromgif($path);
                break;

            case 'image/webp':
            case 'image/x-webp':
                if ( ! function_exists('imagecreatefromwebp')) {
                    throw new \Intervention\Image\Exception\NotReadableException(
                        "Unsupported image type. GD/PHP installation does not support WebP format."
                    );
                }
                $core = @imagecreatefromwebp($path);
                break;

            default:
                throw new \Intervention\Image\Exception\NotReadableException(
                    "Unsupported image type. GD driver is only able to decode JPG, PNG, GIF or WebP files."
                );
        }

        if (empty($core)) {
            throw new \Intervention\Image\Exception\NotReadableException(
                "Unable to decode image from file ({$path})."
            );
        }

        $this->gdResourceToTruecolor($core);

        // build image
        $image = $this->initFromGdResource($core);
        $image->mime = $mime;
        $image->setFileInfoFromPath($path);

        return $image;
    }
373441
protected function getPathBreadcrumbsFileManager()
    {
        $initial_path = $this->scanner->getInitialPath();
        $breadcrumbs = array(array('text' => $this->text('Home'), 'path' => $initial_path));

        $path = '';

        foreach (explode('/', $this->data_path) as $folder) {
            $path .= "$folder/";
            $trimmed_path = trim($path, '/');
            if ($trimmed_path !== $initial_path && $this->accessPathAccessFileManager($trimmed_path)) {
                $breadcrumbs[] = array('text' => $folder, 'path' => $trimmed_path);
            }
        }

        $breadcrumbs[count($breadcrumbs) - 1]['path'] = null;
        return $breadcrumbs;
    }
802820
public function getPublicPath()
    {
        $uploadsPath = Config::get('cms.storage.uploads.path', '/storage/app/uploads');

        if ($this->isPublic()) {
            $uploadsPath .= '/public';
        }
        else {
            $uploadsPath .= '/protected';
        }

        return Url::asset($uploadsPath) . '/';
    }
529571
protected function leadPNG()
	{
		$exif  = exif_imagetype($this->file) === IMAGETYPE_PNG;

		if ($exif)
		{
			return $this->closeCase("png", "image/png");
		}

		return null;
	}
42960
public function getImage()
    {
        $this->imageWidth = null;
        $this->imageHeight = null;

        $images = $this->images;
        $bigger = (bool) $this->getConfig('choose_bigger_image');
        $minWidth = $this->getConfig('min_image_width', 1);
        $minHeight = $this->getConfig('min_image_height', 1);

        $images = array_filter($images, function ($image) use ($minWidth, $minHeight) {
            return $image['width'] >= $minWidth && $image['height'] >= $minHeight;
        });

        if (empty($images)) {
            return null;
        }

        reset($images);
        $image = current($images);

        if ($bigger) {
            $sizes = [];

            foreach ($images as $img) {
                $sizes[$img['url']] = $img['size'];
            }

            $biggest = static::getBigger($sizes);

            foreach ($images as $img) {
                if ($biggest == $img['url']) {
                    $image = $img;
                    break;
                }
            }
        }

        $this->imageWidth = $image['width'];
        $this->imageHeight = $image['height'];

        return $image['url'];
    }
317586
public function opengraphImage()
    {
        $context = $this->contextObject();

        $img = null;
        if ($context instanceof HasOpenGraphInterface) {
            $img = (string)$context['opengraph_image'];
        }

        if (!$img) {
            $img = (string)$this->fallbackOpengraphImage();
        }

        if ($img) {
            $uri = $this->baseUrl();
            return $uri->withPath(strval($img));
        }

        return $this->metaImage();
    }
1021008
protected function getImageUrlOrDefault()
    {
        $imagePath = $this->entity->path;

        if (!Storage::exists($imagePath)) {
            $imagePath = $this->imgNotFound();
        }

        return Storage::url($imagePath);
    }
242137
public function getMapFilePath()
    {
        return sprintf(
            '%s.php',
            $this->mapBasePath .
            DIRECTORY_SEPARATOR .
            $this->getLang().
            DIRECTORY_SEPARATOR .
            $this->getSystem()
        );
    }