sharp 0.26.1 → 0.27.1

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.
package/src/pipeline.h CHANGED
@@ -40,6 +40,7 @@ struct Composite {
40
40
  int gravity;
41
41
  int left;
42
42
  int top;
43
+ bool hasOffset;
43
44
  bool tile;
44
45
  bool premultiplied;
45
46
 
@@ -47,8 +48,9 @@ struct Composite {
47
48
  input(nullptr),
48
49
  mode(VIPS_BLEND_MODE_OVER),
49
50
  gravity(0),
50
- left(-1),
51
- top(-1),
51
+ left(0),
52
+ top(0),
53
+ hasOffset(false),
52
54
  tile(false),
53
55
  premultiplied(false) {}
54
56
  };
@@ -79,6 +81,7 @@ struct PipelineBaton {
79
81
  int cropOffsetLeft;
80
82
  int cropOffsetTop;
81
83
  bool premultiplied;
84
+ bool tileCentre;
82
85
  std::string kernel;
83
86
  bool fastShrinkOnLoad;
84
87
  double tintA;
@@ -118,6 +121,13 @@ struct PipelineBaton {
118
121
  int extendRight;
119
122
  std::vector<double> extendBackground;
120
123
  bool withoutEnlargement;
124
+ std::vector<double> affineMatrix;
125
+ std::vector<double> affineBackground;
126
+ double affineIdx;
127
+ double affineIdy;
128
+ double affineOdx;
129
+ double affineOdy;
130
+ vips::VInterpolate affineInterpolator;
121
131
  int jpegQuality;
122
132
  bool jpegProgressive;
123
133
  std::string jpegChromaSubsampling;
@@ -151,6 +161,8 @@ struct PipelineBaton {
151
161
  double tiffYres;
152
162
  int heifQuality;
153
163
  VipsForeignHeifCompression heifCompression;
164
+ int heifSpeed;
165
+ std::string heifChromaSubsampling;
154
166
  bool heifLossless;
155
167
  std::string err;
156
168
  bool withMetadata;
@@ -230,6 +242,13 @@ struct PipelineBaton {
230
242
  extendRight(0),
231
243
  extendBackground{ 0.0, 0.0, 0.0, 255.0 },
232
244
  withoutEnlargement(false),
245
+ affineMatrix{ 1.0, 0.0, 0.0, 1.0 },
246
+ affineBackground{ 0.0, 0.0, 0.0, 255.0 },
247
+ affineIdx(0),
248
+ affineIdy(0),
249
+ affineOdx(0),
250
+ affineOdy(0),
251
+ affineInterpolator(vips::VInterpolate::new_from_name("bicubic")),
233
252
  jpegQuality(80),
234
253
  jpegProgressive(false),
235
254
  jpegChromaSubsampling("4:2:0"),
@@ -261,8 +280,10 @@ struct PipelineBaton {
261
280
  tiffTileWidth(256),
262
281
  tiffXres(1.0),
263
282
  tiffYres(1.0),
264
- heifQuality(80),
265
- heifCompression(VIPS_FOREIGN_HEIF_COMPRESSION_HEVC),
283
+ heifQuality(50),
284
+ heifCompression(VIPS_FOREIGN_HEIF_COMPRESSION_AV1),
285
+ heifSpeed(5),
286
+ heifChromaSubsampling("4:2:0"),
266
287
  heifLossless(false),
267
288
  withMetadata(false),
268
289
  withMetadataOrientation(-1),
package/src/sharp.cc CHANGED
@@ -22,6 +22,7 @@
22
22
  #include "stats.h"
23
23
 
24
24
  static void* sharp_vips_init(void*) {
25
+ g_setenv("VIPS_MIN_STACK_SIZE", "2m", FALSE);
25
26
  vips_init("sharp");
26
27
  return nullptr;
27
28
  }