utlib / IiifItems

Embed Mirador in Omeka Classic 2.3+ for building rich IIIF-compliant exhibits
Apache License 2.0
17 stars 9 forks source link

Manifests generate with height and width set to 0 when using S3 storage adapter #24

Closed jaguillette closed 6 months ago

jaguillette commented 3 years ago

We use the S3 storage adapter in our installation of Omeka, and found that when using less permissive versions of Mirador, manifests were not accepted by the viewer because they lacked an image height and width. Looking at the code, it seems that when there isn't an existing canvas JSON, the height and width are determined with a php getimagesize call that assumes the images are stored locally. Since ours aren't the call fails, and the height and width remain at their initial value of zero. It seems possible to fix by generating the height and width from the image metadata already stored in Omeka instead.

dicksonlaw583 commented 6 months ago

Fixed: https://github.com/utlib/IiifItems/commit/ee004e9ea60288fe9556ab609bf958f80de112ae