[Bf-committers] Addons Frameworks
mindrones
mindrones at gmail.com
Sat Dec 11 17:08:21 CET 2010
Hi again,
On 12/11/2010 02:56 PM, mindrones wrote:
> since commit 33597 to detect available python modules Blender checks the
> directories:
> - scripts/modules/
> - scripts/addons/modules/
>
> This means that addons developers can now develop shared modules in
> scripts/addons/modules/ !
since I got a couple of questions about this matter, I'll explain a bit
better here too.
Apparently people weren't much aware that when we do "import bpy"
Blender goes looking for the bpy module into scripts/modules/; infact:
>> import bpy
>>> bpy
<module 'bpy' from '<custom path>/2.55/scripts/modules/bpy/__init__.py'>
If we create a file like scripts/addons/modules/mymodule.py, in console
it is now possible to get:
>>> import mymodule
>>> mymodule
<module 'mymodule' from '<custom
path>/2.55/scripts/addons/modules/mymodule.py'>
Since addons/modules is in the bf-extensions repository, this opens up
the chance to develop and propose new modules without having svn rights
to bf-blender.
Hope this is now a bit clearer :)
Regards,
Luca
>
> Thanks goes to to Campbell :)
>
> This will hopefully encourage bf-extensions developers to isolate common
> functions in addons/modules/ to start building addons frameworks: we
> already have modules/extensions_framework/ by Doug Hammond and Florian
> Meyer is now working on a "add_object" framework to facilitate writing
> addons for the Add menu.
>
> Any opinion (and help) on the matter is very welcome :)
>
>
> Regards,
> Luca
>
> _____________________________
>
> http://www.mindrones.com
_____________________________
http://www.mindrones.com
More information about the Bf-committers
mailing list