src/Factory/AssetFactory.php
private static function createAssetsForImage(array $assets): array
    {
        $result = [];

        $fileName = pathinfo($assets[0]['path'], PATHINFO_FILENAME);
        $extension = pathinfo($assets[0]['path'], PATHINFO_EXTENSION);

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('480p')
            ->setSource($assets[0]['path'])
        ;

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('720p')
            ->setSource(sprintf('%s@2x%s', $fileName, $extension))
        ;

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('1080p')
            ->setSource(sprintf('%s@4x%s', $fileName, $extension))
        ;

        return $result;
    }
private static function createAssetsForImage(array $assets): array
    {
        $result = [];

        $fileName = pathinfo($assets[0]['path'], PATHINFO_FILENAME);
        $extension = pathinfo($assets[0]['path'], PATHINFO_EXTENSION);

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('480p')
            ->setSource($assets[0]['path'])
        ;

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('720p')
            ->setSource(sprintf('%s@2x%s', $fileName, $extension))
        ;

        $result[] = (new Asset())
            ->setType(Asset::TYPE_AUDIO)
            ->setScale(null)
            ->setVersion('1080p')
            ->setSource(sprintf('%s@4x%s', $fileName, $extension))
        ;

        return $result;
    }
@param array $assets

@return Asset[]