RSS/Atom feed Twitter
Site is read-only, email is disabled

Getting selection mask

This discussion is connected to the gimp-developer-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

2 of 2 messages available
Toggle history

Please log in to manage your subscriptions.

Getting selection mask Thierry Pierron 03 Oct 01:20
  Getting selection mask David Odin 03 Oct 01:50
Thierry Pierron
2004-10-03 01:20:03 UTC (over 19 years ago)

Getting selection mask

Hello,

Can someone explain basic steps to get bitmap of the selection mask of gimp inside a plugin ?

I try to play with gimp_image_get_selection(), passing the current image ID, but it always returns -1.

Any example available somewhere ?

-- Thierry Pierron

David Odin
2004-10-03 01:50:19 UTC (over 19 years ago)

Getting selection mask

On Sat, Oct 02, 2004 at 07:20:03PM -0400, Thierry Pierron wrote:

Hello,

Can someone explain basic steps to get bitmap of the selection mask of gimp inside a plugin ?

I try to play with gimp_image_get_selection(), passing the current image ID, but it always returns -1.

Any example available somewhere ?

Have a look at libgimp/gimpdrawablepreview.c, in current CVS, in the function gimp_drawable_preview_draw_area (). This function use the selection and put it into an array of guchar. Examine how the sel variable is filled.

Regards,

DindinX