On 1/26/06, Simon Budig <[EMAIL PROTECTED]> wrote:
Joël-Alexis Bialkiewicz ([EMAIL PROTECTED]) wrote:
> In fact I don't want to ignore selections but to use them in a different
> way. Especially, I would like to be able know, for a specific point, whether
> it is selected or not.

You can request the selection as a drawable using
gimp_image_get_selection(). You then can peek into this drawable to get
the selection value for a specific pixel. You probably need to be
careful with the offset handling a bit though.

1) What do you mean by careful with the offset handling?
2) When I read the data from the selection drawable, 1 means selected and 0 means not selected, isn't it?
3) When I call gimp_drawable_mask_bounds and there is a complex selection, what part of the image does it point out to me? Does it correspond the littlest square possible containing all selected points?
4) When I try to read a point that is not selected, will it give me the right value for this point or some dummy value?

Thanks in advance.

Joel-Alexis Bialkiewicz
Gimp-developer mailing list

Reply via email to