imogen 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/imogen/iiif/region.rb +2 -2
  3. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 92c92a32465d8ae59f5e40a31c0ffd3cc2de271a3593db0dac7da1bd2954dd31
4
- data.tar.gz: 044b86d16c8c028d36864e3aa550b6aa871d9075c5d4223b198ca1ac59b511f2
3
+ metadata.gz: 4b23125bf531a9a524f745c2ff9ffed4e3bd2e1aedf26dbdcd07434c0df9bbc0
4
+ data.tar.gz: 70b706da9db53e41b691eda24c70b8211cce3073cd99eae77a4045dad7dd0bab
5
5
  SHA512:
6
- metadata.gz: dc4ae61808bb12ad97f4f3a279aa81fd048b20626422358ccfc64ed1c5706d221a97195a0807dcd882c32dbfbd8ced6fba06bfe9e361ae61abfd6a1a38aed5a2
7
- data.tar.gz: d416dd8390d144135bf5d1e4d9dc5445d0f137a6e64ce097aef8fe2e5f895214a18a4f5fd064f874ead2928db969b5dbc92fbe5a86ac20c244e199c6bca93757
6
+ metadata.gz: fa4d10b1e6aa9a00b72d73daa4796b2ffcd72bde1bfcb8dc36443bfc3f8d82d72a86abff0e1a4f8e6150d17b959c5670bc6868e83a6a40906b40b56fa1e24786
7
+ data.tar.gz: f5e43a5c25d37b0b99b0578216169d0cb0deabc5598c46bd21f50cbc546ac38250f3b658609d34751006696c10652399453a2537c12d72e710a515cafa7c5145
@@ -63,7 +63,7 @@ class Region < Transform
63
63
  crop_scale = middle_dims.min
64
64
  smart_crop_opts = {interesting: (squarish?(img) ? :centre : :entropy)}.merge(opts)
65
65
  window = img.extract_area(x_offset, y_offset, middle_dims[0], middle_dims[1])
66
- smartcrop = window.smartcrop(crop_scale, crop_scale, smart_crop_opts)
66
+ smartcrop = window.smartcrop(crop_scale, crop_scale, **smart_crop_opts)
67
67
  # Vips counts with negative offsets from left and top
68
68
  yield smartcrop.thumbnail_image(scale, height: scale)
69
69
  end
@@ -76,7 +76,7 @@ class Region < Transform
76
76
  crop_scale = middle_dims.min
77
77
  smart_crop_opts = {interesting: (squarish?(img) ? :centre : :entropy)}.merge(opts)
78
78
  window = img.extract_area(x_offset, y_offset, middle_dims[0], middle_dims[1])
79
- smartcrop = window.smartcrop(crop_scale, crop_scale, smart_crop_opts)
79
+ smartcrop = window.smartcrop(crop_scale, crop_scale, **smart_crop_opts)
80
80
  # Vips counts with negative offsets from left and top
81
81
  left = (window.xoffset + smartcrop.xoffset)*-1
82
82
  top = (window.yoffset + smartcrop.yoffset)*-1
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: imogen
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Armintor
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2021-02-26 00:00:00.000000000 Z
12
+ date: 2022-05-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: ruby-vips
@@ -96,7 +96,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
96
96
  - !ruby/object:Gem::Version
97
97
  version: '0'
98
98
  requirements: []
99
- rubygems_version: 3.0.8
99
+ rubygems_version: 3.2.32
100
100
  signing_key:
101
101
  specification_version: 4
102
102
  summary: IIIF image derivative generation helpers for Vips