Re: [Gegl-developer] bump-map operation



On Wed, 2013-06-26 at 12:05 +0300, Dov Grobgeld wrote:
The filter certainly is local as it is only using a 3×3 neighborhood.
What example op can I look at in order to see exactly what
requirements I need to fulfill to make the op into an "area filter"
and make it work with Gimp's GEGL tool? Is this documented anywhere?

I'm not the über-expert myself, but look at the last two functions in
gegl-operation-area-filter.c, I think that's all you need to implement
in bump-map.

I thought about looking at the NewsPrint plugin next. Or is there some
other plugin that is more urgent?

That plug-in has a very complex GUI and we have no way just yet to
easily do that with the GEGL tool (with on-canvas preview), also
it's rather esoteric so it probably falls in the category "port
the GIMP plug-in to the new GeglBuffer API in libgimp and done".

My personal favorite is the mosaic plugin because I really like
the effect. That doesn't make it "urgent" tho ;) (If you really
want to do that, there is a patch in bugzilla that adds a configurable
random seed to the GIMP plugin, maybe the port should be done from
a version that includes that patch).

IMO dilate and erode are in the "must have" section for commonly
known generic operations that are missing.

Opinions from anyone?

Regards,
--Mitch

Regards,
Dov


On Wed, Jun 26, 2013 at 1:30 AM, Michael Natterer <mitch gimp org> wrote:
On Tue, 2013-06-25 at 23:05 +0300, Dov Grobgeld wrote:
I just added a bump-map operation. It is heavily based on the
corresponding gimp code, but modified according to my understanding of
gegl. The fact that the bumpmap is in floating point makes the
resulting "surface" much smoother than the original gimp operation, as
8-bit is too little to get accurate surface normals.

Please let me know your comments about the code and update wiki
"Hacking:Porting filters to GEGL" page. (I would have done it myself
if the maintainer of the wiki would have answered my email requesting
write access.)

Thanks Dov, that's cool :)

I pushed a small whitespace cleanup to bump-map.c, and the last
parameter of the chanted properties is supposed to be a human readable
blurb that appears as tooltip in GIMP, so should be human readable :)

Also, does the op really need the entire input? Can't it be done
like an area filter? Requiring the entire input makes it impossible to
adjust parameters interactively in GIMP's GEGL tool.

Regards,
--Mitch






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