Hi,
Is there any API ( or tool ) that access to a data in .blend file w/o using blender application, like Apache POI?
Thanks.
Hi,
Is there any API ( or tool ) that access to a data in .blend file w/o using blender application, like Apache POI?
Thanks.
I assume you mean like, get colors or vertex information or object names or something like that.
If thats the case then not really (at least I don’t know of any). .blend files are really messy because they are basically just memory dumps. If you really want to do this, your going to need to look in the blender source.
A better option, though, is to export whatever into a file format where you can see it (like .obj), and if no file format supports what you want to see just use python and write your exporter (python api here: http://www.blender.org/documentation/244PythonDoc/index.html)
Hi forTe,
Thanks for your reply.
I assume you mean like, get colors or vertex information or object names or something like that.
Yes,I want to my .blend file to own web page with some information.
but debug dump is not all I want.
$ blender -d a.blend
If you really want to do this, your going to need to look in the blender source.
…source…
A better option, though, is to export whatever into a file format where you can see it (like .obj), and if no file format supports what you want to see just use python and write your exporter
Is there any way that Python access to Blender API w/o running blender?
or use ‘-P’ option?
Thanks
It’s still at the proposal stage:
http://en.wikibooks.org/wiki/Blender_3D:_Blending_Into_Python/Custom_datablock_properties
Not sure if there are any patches available or not but some Python functionality already exists in Help >> ID Property Browser:
http://www.blender.org/development/release-logs/blender-243/more-243-features/
%<
…source…
Is there any way that Python access to Blender API w/o running blender?
or use ‘-P’ option?
Source, you can browse here: http://projects.blender.org/plugins/scmsvn/viewcvs.php/trunk/blender/?root=bf-blender
Specifically, you might want to look at things involving DNA. There have been some posts about this before on the forum, so you might want to search for them as well (somebody wrote a paper about the blender file format, but I don’t have the link off hand, but I know its one of the threads).
-p will immediately open blender and run the script, so I suppose that yes technically it is running blender. I haven’t used it much, so I don’t know exactly all the details of its operation, but it may be worth a look.
Hi Fligh ,forTe,
Thanks for your comments.
@Fligh:
Thanks for the Information about ID Property ,it sounds good.
but,IMHO, it can’t display or input directory non-English text ( via input method engine) by limitation of Blender’s UI (Blender supports Unicode string, but it is partly). even if elements of ID Property can store KANJI characters, It can’t managed on screen.
Specifically, you might want to look at things involving DNA.
Thanks,I will start on these pages :
http://www.blender.org/development/architecture/blender-file-reading/
http://www.blender.org/development/architecture/notes-on-sdna/
I’m not familar with C++ (and structure of blender file, too!!), it will be like long and winding road…
BTW,I found this page, still alive?
http://jetresourceutil.sourceforge.net/BlenderFileConverter.html
Thanks