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

Re: gEDA-user: foreign graphics overlay




Bob Paddock wrote:
What is the benefit of plug-ins for this kind of infrastructure?
IMHO, support of different image formats should be part of the
main distribution.

Someone, some place, in the future will want to support something that
none of us have ever heard of today.
If there is a easy, well documented, Plug-In system, then they can
implement what they need without having to figure out the internals of
PCB.

Also Plug-Ins make it harder for various sections of code to interact,
by design, to give a better separation of concerns.
Yes, that's the idea behind it.
I said plugin, but the more trivial version is just a method hook:
a template-ish function [renderForeign()], that gets called if a flag is set, saying
there is some foreign graphics to display.
All the function gets handed is a display transformation, a general transformation
that maps the pcb-space to foreign-graphics space and a filename(list).

Whether renderForeign() contains just some format specific rendering calls
or really uses dynamic linking to call something unknown to pcb is up to
the implementer.

The actually implementation can be a bit more complicated to allow for
preprocessing and setup, but the idea is just this.


_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user