We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 36f4de5 commit f794c0aCopy full SHA for f794c0a
2 files changed
src/vips/Image_methods.lua
@@ -497,6 +497,16 @@ function Image_method:remove(name)
497
return vips_lib.vips_image_remove(self.vimage, name) ~= 0
498
end
499
500
+function Image_method:get_gainmap()
501
+ collectgarbage("stop")
502
+ local vimage = vips_lib.vips_image_get_gainmap(self.vimage)
503
+ if vimage == ffi.NULL then
504
+ return nil
505
+ end
506
+
507
+ collectgarbage("restart")
508
+ return Image.new(vimage)
509
+end
510
-- standard header fields
511
512
function Image_method:width()
src/vips/cdefs.lua
@@ -166,6 +166,8 @@ ffi.cdef [[
166
// opaque
167
} VipsImage;
168
169
+ VipsImage *vips_image_get_gainmap(VipsImage *image);
170
171
typedef struct _VipsConnection {
172
VipsObject parent_instance;
173
0 commit comments