ruby-vips 2.2.4 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,11 @@
1
+ module Vips
2
+ # The SDF to generate, see {Image.sdf}.
3
+ #
4
+ # * `:circle` a circle at @a, radius @r
5
+ # * `:box` a box from @a to @b
6
+ # * `:rounded_box` a box with rounded @corners from @a to @b
7
+ # * `:line` a line from @a to @b
8
+
9
+ class SdfShape < Symbol
10
+ end
11
+ end
@@ -0,0 +1,11 @@
1
+ module Vips
2
+ # Sets the word wrapping style for {Image#text} when used with a
3
+ # maximum width.
4
+ #
5
+ # * `:char` wrap at character boundaries
6
+ # * `:word_char` wrap at word boundaries, but fall back to character boundaries if there is not enough space for a full word
7
+ # * `:none` no wrapping
8
+
9
+ class TextWrap < Symbol
10
+ end
11
+ end
data/lib/vips/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Vips
2
- VERSION = "2.2.4"
2
+ VERSION = "2.3.0"
3
3
  end
data/lib/vips.rb CHANGED
@@ -23,13 +23,15 @@ require "logger"
23
23
  # windows:
24
24
  # The ABI number must be included, but with a hyphen. ffi does not add a
25
25
  # "lib" prefix or a ".dll" suffix.
26
- def library_name(name, abi_number)
27
- if FFI::Platform.windows?
28
- "lib#{name}-#{abi_number}.dll"
29
- elsif FFI::Platform.mac?
30
- "#{name}.#{abi_number}"
31
- else
32
- "#{name}.so.#{abi_number}"
26
+ module FFI
27
+ def self.library_name(name, abi_number)
28
+ if Platform.windows?
29
+ "lib#{name}-#{abi_number}.dll"
30
+ elsif Platform.mac?
31
+ "#{name}.#{abi_number}"
32
+ else
33
+ "#{name}.so.#{abi_number}"
34
+ end
33
35
  end
34
36
  end
35
37
 
@@ -43,7 +45,7 @@ end
43
45
  module Vips
44
46
  extend FFI::Library
45
47
 
46
- ffi_lib library_name("vips", 42)
48
+ ffi_lib FFI.library_name("vips", 42)
47
49
 
48
50
  begin
49
51
  attach_function :g_malloc, [:size_t], :pointer
@@ -67,9 +69,9 @@ module GLib
67
69
  extend FFI::Library
68
70
 
69
71
  if Vips.unified?
70
- ffi_lib library_name("vips", 42)
72
+ ffi_lib FFI.library_name("vips", 42)
71
73
  else
72
- ffi_lib library_name("glib-2.0", 0)
74
+ ffi_lib FFI.library_name("glib-2.0", 0)
73
75
  end
74
76
 
75
77
  attach_function :g_malloc, [:size_t], :pointer
@@ -163,9 +165,9 @@ module GObject
163
165
  extend FFI::Library
164
166
 
165
167
  if Vips.unified?
166
- ffi_lib library_name("vips", 42)
168
+ ffi_lib FFI.library_name("vips", 42)
167
169
  else
168
- ffi_lib library_name("gobject-2.0", 0)
170
+ ffi_lib FFI.library_name("gobject-2.0", 0)
169
171
  end
170
172
 
171
173
  # we can't just use ulong, windows has different int sizing rules
@@ -443,7 +445,7 @@ require "vips/gvalue"
443
445
  # It examines libvips and writes a summary of each operation and the arguments
444
446
  # and options that that operation expects.
445
447
  #
446
- # Use the [C API # docs](https://libvips.github.io/libvips/API/current)
448
+ # Use the [C API docs](https://www.libvips.org/API/current/)
447
449
  # for more detail.
448
450
  #
449
451
  # # Enums
@@ -452,6 +454,19 @@ require "vips/gvalue"
452
454
  # like `:uchar`. They are documented as a set of classes for convenience, see
453
455
  # {Vips::BandFormat}, for example.
454
456
  #
457
+ # # Flags
458
+ #
459
+ # Some operations take a set of flags as an argument, for example
460
+ # {Image#pngsave} can be given a set of filters to use. These are documented
461
+ # as a set of classes, see {Vips::ForeignPngFilter}, for
462
+ # example.
463
+ #
464
+ # You can set flag arguments with an array of symbols, perhaps:
465
+ #
466
+ # ```ruby
467
+ # image.pngsave "x.png", filter: [:sub, :up]
468
+ # ```
469
+ #
455
470
  # # Draw operations
456
471
  #
457
472
  # There are two ways of calling the libvips draw operations, like
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-vips
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.4
4
+ version: 2.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Cupitt
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-06-05 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: ffi
@@ -163,13 +163,29 @@ files:
163
163
  - lib/vips/bandformat.rb
164
164
  - lib/vips/blend_mode.rb
165
165
  - lib/vips/coding.rb
166
+ - lib/vips/combine.rb
166
167
  - lib/vips/compass_direction.rb
167
168
  - lib/vips/connection.rb
168
169
  - lib/vips/direction.rb
169
170
  - lib/vips/extend.rb
171
+ - lib/vips/fail_on.rb
172
+ - lib/vips/foreign_dz_container.rb
173
+ - lib/vips/foreign_dz_depth.rb
174
+ - lib/vips/foreign_dz_layout.rb
175
+ - lib/vips/foreign_heif_compression.rb
176
+ - lib/vips/foreign_heif_encoder.rb
177
+ - lib/vips/foreign_keep.rb
178
+ - lib/vips/foreign_png_filter.rb
179
+ - lib/vips/foreign_ppm_format.rb
180
+ - lib/vips/foreign_subsample.rb
181
+ - lib/vips/foreign_tiff_compression.rb
182
+ - lib/vips/foreign_tiff_predictor.rb
183
+ - lib/vips/foreign_tiff_resunit.rb
184
+ - lib/vips/foreign_webp_preset.rb
170
185
  - lib/vips/gobject.rb
171
186
  - lib/vips/gvalue.rb
172
187
  - lib/vips/image.rb
188
+ - lib/vips/intent.rb
173
189
  - lib/vips/interesting.rb
174
190
  - lib/vips/interpolate.rb
175
191
  - lib/vips/interpretation.rb
@@ -178,6 +194,7 @@ files:
178
194
  - lib/vips/mutableimage.rb
179
195
  - lib/vips/object.rb
180
196
  - lib/vips/operation.rb
197
+ - lib/vips/operation_morphology.rb
181
198
  - lib/vips/operationboolean.rb
182
199
  - lib/vips/operationcomplex.rb
183
200
  - lib/vips/operationcomplex2.rb
@@ -186,12 +203,17 @@ files:
186
203
  - lib/vips/operationmath2.rb
187
204
  - lib/vips/operationrelational.rb
188
205
  - lib/vips/operationround.rb
206
+ - lib/vips/pcs.rb
207
+ - lib/vips/precision.rb
189
208
  - lib/vips/region.rb
209
+ - lib/vips/region_shrink.rb
210
+ - lib/vips/sdf_shape.rb
190
211
  - lib/vips/size.rb
191
212
  - lib/vips/source.rb
192
213
  - lib/vips/sourcecustom.rb
193
214
  - lib/vips/target.rb
194
215
  - lib/vips/targetcustom.rb
216
+ - lib/vips/text_wrap.rb
195
217
  - lib/vips/version.rb
196
218
  - ruby-vips.gemspec
197
219
  homepage: http://github.com/libvips/ruby-vips
@@ -218,7 +240,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
218
240
  - !ruby/object:Gem::Version
219
241
  version: '0'
220
242
  requirements: []
221
- rubygems_version: 3.6.3
243
+ rubygems_version: 3.6.7
222
244
  specification_version: 4
223
245
  summary: A fast image processing library with low memory needs
224
246
  test_files: []