[Gimp-developer] Copying a layer mask between images



It's easy to copy a layer to another image:

    pdb.gimp_layer_new_from_drawable(sourceLayer,targetImage)

But I cannot find an equivalent call for a Mask/Channel:

    - gimp_create_mask() won't take an existing mask, just an existing
Channel (and since it's another image I cannot even use the selection)

    - gimp_channel_new() creates n empty channel

    - gim_channel_new_from_component() only tales an image component

As far as I can tell the only way would be create an empty mask and
copy/paste? Am I missing something ? Is there a smarter way?




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]