diff --git a/models/PhotoMosaic.php b/models/PhotoMosaic.php index 3f75407..68089ba 100644 --- a/models/PhotoMosaic.php +++ b/models/PhotoMosaic.php @@ -32,6 +32,10 @@ class PhotoMosaic // Single panorama 'panorama' => [Image::TYPE_PANORAMA], + // A whopping six landscapes? + 'sixLandscapes' => [Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE, + Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE], + // Big-small juxtapositions 'sidePortrait' => [Image::TYPE_PORTRAIT, Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE, Image::TYPE_LANDSCAPE], diff --git a/templates/PhotosIndex.php b/templates/PhotosIndex.php index 537078b..c9fe715 100644 --- a/templates/PhotosIndex.php +++ b/templates/PhotosIndex.php @@ -137,6 +137,13 @@ class PhotosIndex extends Template } } + protected function sixLandscapes(array $photos, $altLayout) + { + $chunks = array_chunk($photos, 3); + $this->sideLandscape($chunks[0], $altLayout); + $this->threeLandscapes($chunks[1], $altLayout); + } + protected function sidePortrait(array $photos, $altLayout) { $image = array_shift($photos);