Re: 3D paint interface.

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

 



On Mon, Sep 18, 2000 at 04:24:35PM -0500, Stephen J Baker wrote:
>   1) Write a plugin for PrettyPoly that captures the
>      3D coordinate of the cursor - figures out which
>      texel in the texture map it's pointing at and
>      stuffs that into a little chunk of shared memory.
> 
>   2) Write a plugin for GIMP that grabs that texel
>      coordinate and (somehow) stuffs it into GIMP
>      so that GIMP thinks it's the current mouse position
>      within the painting area.
> 
>   3) Have that same GIMP plugin grab the current image and
>      dump it into a (large) shared memory area.
> 
>   4) Have a PrettyPoly plugin read that shared memory and
>      stuff it into the currently selected texture map.


There's no reason why you can't do #3, I guess, but you can't quite get
#2.  For that, it sounds like you would want to transmit signals
event-for-event to the gimp canvas, but with transformed coordinates...
Unfortunately, you can't communicate that tightly with the core
application from a plug-in.  You're limited to the language of the PDB.
Maybe that's close enough -- I don't know.  See the "DB Browser" under
the Xtns menu for the list of functions available to you.  You'd have to
transform events in PrettyPoly to things like
gimp-paintbrush-defaults(1,2,{0,0},{5,10})...  It'd be interesting to
see if you could get away with that.  I suspect there would be a *lot* of
latency in the interface, but I guess the only way to find out if it
would be acceptable is to test it...

> I'd want to be as close to the 'surface' of GIMP
> as possible - I'd like to see the result of all
> the layer compositing, I'd like to see the selection
> 'marching ants'...everything - I'd like to drive
> GIMP up close to where the mouse coordinates hit
> the canvas so that ALL of GIMP's power would be
> accessible through this mechanism.
> 
> However, if that's not possible, I'd settle for
> seeing just one layer...etc.

You can get the selection mask, but you'll have to draw the marching
ants yourself...

Seeing layer compositing won't be practical, because the only operation
GIMP provides to merge the layers removes them all in the process.  (I'm
tempted to call that a BUG).  So you have to tell GIMP to copy all
visible layers, send the command to merge those, send that image to
PrettyPolly, and then delete the merged layer and do the whole shebang
again the next time a brush-stroke happens...

I think this is the point where you decide that's redicilous and start
making patches to the GIMP core ;)

And of course, "you will be able to do this with GIMP 2.0", but at the
rate we're going trying to finish 1.2, it could easily be another decade
before that happens.

Good luck,
 
  - Kevin

-- 
Kevin Turner <acapnotic@xxxxxxxxxxxxxxxxxxxxx> | OpenPGP encryption welcome here
Plug-ins: They make GIMP do stuff.  http://gimp-plug-ins.sourceforge.net/
This list is archived at http://marc.theaimsgroup.com/?l=gimp-developer
To unsubscribe, mail gimp-developer-unsubscribe@xxxxxxxxxxxxxxxx


[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux