From b2257ad3263f1eaf8dcf637edb480e0c8274fd73 Mon Sep 17 00:00:00 2001 From: scuri Date: Mon, 4 Apr 2011 20:42:46 +0000 Subject: # New: function imImageMergeAttributes. --- src/lua5/imlua_image.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'src/lua5') diff --git a/src/lua5/imlua_image.c b/src/lua5/imlua_image.c index b8bc1a8..057e757 100644 --- a/src/lua5/imlua_image.c +++ b/src/lua5/imlua_image.c @@ -2,7 +2,7 @@ * \brief IM Lua 5 Binding * * See Copyright Notice in im_lib.h - * $Id: imlua_image.c,v 1.13 2010/10/25 18:29:07 scuri Exp $ + * $Id: imlua_image.c,v 1.14 2011/04/04 20:42:48 scuri Exp $ */ #include @@ -545,6 +545,18 @@ static int imluaImageCopyAttributes (lua_State *L) return 0; } +/*****************************************************************************\ + image:MergeAttributes(dst_image) +\*****************************************************************************/ +static int imluaImageMergeAttributes (lua_State *L) +{ + imImage *src_image = imlua_checkimage(L, 1); + imImage *dst_image = imlua_checkimage(L, 2); + + imImageMergeAttributes(src_image, dst_image); + return 0; +} + /*****************************************************************************\ image:MatchSize(image2) \*****************************************************************************/ @@ -1056,6 +1068,7 @@ static const luaL_reg imimage_metalib[] = { {"SetPalette", imluaImageSetPalette}, {"GetPalette", imluaImageGetPalette}, {"CopyAttributes", imluaImageCopyAttributes}, + {"MergeAttributes", imluaImageMergeAttributes}, {"MatchSize", imluaImageMatchSize}, {"MatchColor", imluaImageMatchColor}, {"MatchDataType", imluaImageMatchDataType}, -- cgit v1.2.3