[Bf-python] Problems

Willian Padovani Germano wgermano at ig.com.br
Thu Jul 31 08:02:44 CEST 2003


From: "maci_ray" <maci_ray at yahoo.de>
(...)
> But the header mechanism has the drawback, that with one header line, only
> one menu entry could be established. Imagine a .py-File with more
functions.

Personally, for gui-less scripts, I do prefer one function per file, that's
much more manageable and prevents that "monsters" grow over time.

> Programm code registering has the advantage that you haven't to check
> yourself for correctness. Python will tell you. Just expose a python
> registering framework.

Blender would check and complain about invalid headers, too.  What can be
good about headers is their simplicity: easier to code (and so maintain /
understand) in Blender and much faster to run -- no need to use the Python
Interpreter, try to import a register callback from each file, run it, clean
the global dict, etc.  In the future we may have hundreds of scripts there.

But anyway, I'm not deciding in favor of this or that idea, just discussing,
of course.  We'll take all possibilities we find to the bf-committers list
and decide there.

That's why it's important that, if you guys see other advantages to the
registering system, that you point them out.

--
Willian, wgermano at ig.com.br




More information about the Bf-python mailing list