Skip to content

Commit 931882b

Browse files
committed
more vips7 compat macros
1 parent b871e67 commit 931882b

File tree

2 files changed

+56
-0
lines changed

2 files changed

+56
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
- better recover after crash sorting
1616
- fix an infobar race
1717
- program: add find unresolved syms
18+
- lots more vips7 compat macros
1819

1920
## 9.0.12 2025/08/21
2021

share/nip4/start/_vips7compat.def

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ im_clip2s x = vips_call9 "cast" [x, "short"] [];
2626
im_clip2f x = vips_call9 "cast" [x, "float"] [];
2727

2828
im_scale x = vips_call9 "scale" [x] [];
29+
im_scaleps x = vips_call9 "scale" [x] [
30+
$log => true
31+
];
32+
33+
im_invert in = vips_call9 "invert" [in] [];
2934

3035
im_replicate in across down = vips_call9 "replicate" [in, across, down] [];
3136

@@ -130,11 +135,18 @@ im_XYZ2Yxy x = vips_call9 "XYZ2Yxy" [x] [];
130135
im_Yxy2XYZ x = vips_call9 "Yxy2XYZ" [x] [];
131136

132137
im_XYZ2UCS = im_LCh2UCS @ im_Lab2LCh @ im_XYZ2Lab;
138+
im_UCS2XYZ = im_Lab2XYZ @ im_LCh2Lab @ im_UCS2LCh;
133139
im_sRGB2XYZ = im_scRGB2XYZ @ im_sRGB2scRGB;
134140
im_XYZ2sRGB = im_scRGB2sRGB @ im_XYZ2scRGB;
135141
im_Lab2UCS = im_LCh2UCS @ im_Lab2LCh;
136142
im_UCS2Lab = im_LCh2Lab @ im_UCS2LCh;
137143

144+
im_LabQ2disp in disp = vips_call9 "LabQ2sRGB" [in] [];
145+
im_Lab2disp in disp = (im_XYZ2sRGB @ im_Lab2XYZ) in;
146+
im_XYZ2disp in disp = im_XYZ2sRGB in;
147+
im_disp2Lab in disp = (im_XYZ2Lab @ im_sRGB2XYZ) in;
148+
im_disp2XYZ in disp = im_sRGB2XYZ in;
149+
138150
im_icc_import x profile intent
139151
= vips_call9 "icc_import" [x] [
140152
$intent => intent,
@@ -238,6 +250,28 @@ im_convsep_f in matrix
238250
$precision => "float"
239251
];
240252

253+
im_compass in matrix
254+
= vips_call9 "compass" [in, matrix] [
255+
$times => 8,
256+
$angle => "d45",
257+
$precision => "integer"
258+
];
259+
260+
im_lindetect in matrix
261+
= vips_call9 "compass" [in, matrix] [
262+
$times => 4,
263+
$angle => "d45",
264+
$precision => "integer"
265+
];
266+
267+
im_gradient in matrix
268+
= vips_call9 "compass" [in, matrix] [
269+
$times => 2,
270+
$angle => "d90",
271+
$combine => "sum",
272+
$precision => "integer"
273+
];
274+
241275
im_rotate_dmask45 matrix
242276
= im_vips2mask matrix'
243277
{
@@ -372,6 +406,23 @@ im_stdif in a m0 b s0 xw yw
372406
$a => a
373407
];
374408

409+
im_stdif_raw = im_stdif;
410+
411+
im_rad2float filename
412+
= vips_call9 "rad2float" [filename] [];
413+
414+
im_csv2vips filename
415+
= vips_call9 "csvload" [filename] [
416+
];
417+
418+
im_binfile filename out width height bands offset
419+
= vips_call9 "rawload" [filename, out, width, height, bands] [
420+
$offset => offset
421+
];
422+
423+
im_video_v4l1 device channel brightness colour contrast hue ngrabs
424+
= error "no v4l support";
425+
375426
im_histgr in band_number
376427
= vips_call9 "hist_find" [in] [
377428
$band => band_number
@@ -646,6 +697,10 @@ im_global_balance in gamma
646697
$int_output => true
647698
];
648699

700+
im_remosaic in old_str new_str
701+
= vips_call9 "remosaic" [in, old_str new_str] [
702+
];
703+
649704
im_system_image in in_format out_format command
650705
= vips_call9 "system" [command] [
651706
$in => [in],

0 commit comments

Comments
 (0)