get mouse feedback within plug-in?

View: New views
5 Messages — Rating Filter:   Alert me  

get mouse feedback within plug-in?

by haenselmann :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Dear all,

recently, I implemented an alpha-matting algorithm for image
segmentation and I feel that it works pretty well so I wanted to write
a gimp plug-in. Here is a little homepage for the project:

http://www.informatik.uni-mannheim.de/pi4/projects/image_matting/

The current application needs interactive user-input with the
mouse. So far I have not found out how gimp could inform a plug-in
about mouse-movements (like the current cursor position) in a
drawable. Is a plug-in generally suitable for the task or how could I
implement such a tool? (I read the little tutorial on
developer.gimp.org. More how-tos would be welcome as well.)

Thanks in advance,

   Thomas

--
Thomas Haenselmann @ University of Mannheim
phone +49 621 181 (voice -2603) (fax -2601)


_______________________________________________
Gimp-developer mailing list
Gimp-developer@...
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

attachment0 (196 bytes) Download Attachment

Re: get mouse feedback within plug-in?

by Torsten Neuer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

> The current application needs interactive user-input with the
> mouse. So far I have not found out how gimp could inform a plug-in
> about mouse-movements (like the current cursor position) in a
> drawable. Is a plug-in generally suitable for the task or how could I
> implement such a tool? (I read the little tutorial on
> developer.gimp.org. More how-tos would be welcome as well.)

From what you write and what it looks like on your project page, you should
probably write a tool instead of a plugin (you may find fitting examples
under gimp-2.4.5/app/tools).  Also, you could then use any brush available to
the Gimp.


  Torsten


_______________________________________________
Gimp-developer mailing list
Gimp-developer@...
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

signature.asc (196 bytes) Download Attachment

Re: get mouse feedback within plug-in?

by Bugzilla from daniel.hornung@gmx.de :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Friday 11 April 2008, Torsten Neuer wrote:

> Hi,
>
> > The current application needs interactive user-input with the
> > mouse. So far I have not found out how gimp could inform a plug-in
> > about mouse-movements (like the current cursor position) in a
> > drawable. Is a plug-in generally suitable for the task or how could I
> > implement such a tool? (I read the little tutorial on
> > developer.gimp.org. More how-tos would be welcome as well.)
>
> From what you write and what it looks like on your project page, you should
> probably write a tool instead of a plugin (you may find fitting examples
> under gimp-2.4.5/app/tools).  Also, you could then use any brush available
> to the Gimp.
>
>
>   Torsten
Just have a look at the current foreground selection tool (since GIMP 2.4),
probably you can use much of its design or at least user interface.  Also
make sure that you don't accidentally use the same algorithm ;-)  Since the
usage seems to be similar, maybe this could even be made an alternative
choosable algorithm there?

Daniel


_______________________________________________
Gimp-developer mailing list
Gimp-developer@...
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

signature.asc (196 bytes) Download Attachment

Re: get mouse feedback within plug-in?

by haenselmann :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Fri, Apr 11, 2008 at 08:36:32PM +0200, Daniel Hornung wrote:

(...)

> > From what you write and what it looks like on your project page, you should
> > probably write a tool instead of a plugin (you may find fitting examples
> > under gimp-2.4.5/app/tools).  Also, you could then use any brush available
> > to the Gimp.
> >
> >   Torsten
>
> Just have a look at the current foreground selection tool (since GIMP 2.4),
> probably you can use much of its design or at least user interface.  Also
> make sure that you don't accidentally use the same algorithm ;-)  Since the
> usage seems to be similar, maybe this could even be made an alternative
> choosable algorithm there?
>
> Daniel
Thanks for your hints. I'll try to understand what a tools is at the
week-end. Concerning the algorithm, I actually wondered why such an
alpha-matting approach was not implemented before. The most recent
thing I've seen on in gimp is a graph-cut approach which I consider to
be among the most advanced approaches available at the moment.

Alpha-matting is kind of orthogonal to segmentation. At least in my
version, it requires the user to define what is to be segmented (a
very rough silhouette) but then, the results are sometimes of very
high quality, especially for fuzzy objects because an individual alpha
values is calculated for every pixel, individually. This is something
that Photoshop does but which I have not yet seem on Gimp.

BTW: I tried to avoid any possible patent issues in that area. Did you
ever get feedback or into trouble with Adobe?

Thomas

> _______________________________________________
> Gimp-developer mailing list
> Gimp-developer@...
> https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer


--
Dr. Thomas Haenselmann @ University of Mannheim
phone +49 621 181 (voice -2603) (fax -2601)


_______________________________________________
Gimp-developer mailing list
Gimp-developer@...
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

attachment0 (196 bytes) Download Attachment

Re: get mouse feedback within plug-in?

by Sven Neumann :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

On Fri, 2008-04-11 at 23:43 +0200,
haenselmann@... wrote:

> Alpha-matting is kind of orthogonal to segmentation. At least in my
> version, it requires the user to define what is to be segmented (a
> very rough silhouette) but then, the results are sometimes of very
> high quality, especially for fuzzy objects because an individual alpha
> values is calculated for every pixel, individually. This is something
> that Photoshop does but which I have not yet seem on Gimp.

This sounds like something that would be nice to have as a
post-processing step in the SIOX Foreground Selection tool. Have you had
a look at the refinement brush that the SIOX guys have suggested? Sounds
similar to your approach and still awaits implementation in GIMP. So far
we don't have anyone working on it, even though most of the code is
already in place.


Sven


_______________________________________________
Gimp-developer mailing list
Gimp-developer@...
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer