[Bf-committers] Another library data question, and a suggestion on documentation

Branan Riley branan at gmail.com
Tue Jul 25 00:09:01 CEST 2006


Let me just make sure I understand you...

Since my shader nodes are being saved as library data, Blender will handle
the pointers in the material structure automatically? Or is there still a
function that needs to be called to re-link those pointers to the proper
library data?

branan


On 7/24/06, Joe Eagar <joeedh at gmail.com> wrote:
>
> Branan Riley wrote:
> > Alright, more questions about the library. I've been trying to figure
> > out how to properly save and load library data that's linked
> > elsewhere. Here's what I think I need to do. As soon as this is
> > figured out, I'll know just about everything I need to do to make it
> > all work.
> >
> > SAVING
> > -Save the library data for my shader nodes
> > -Save the new pointers along with everything else in the Material
> > structure
> >
> > What else is there to do in here? Are there any weird functions that
> > need to be called to make sure that when the data is loaded, it can be
> > re-pointed to the right location?
> One of the arguments in the struct you use to define nodes, is the name
> DNA struct that get's automatically saved by the node system.  If the
> struct has pointers to other data then you have to insert custom code
> into source/blender/blenloader/read(and write)file.c.
>
> See makesdna/DNA_node_types.h.
> >
> > LOADING
> > I have no idea about loading. The loading code is much more complex
> > than the saving code. It kind of scares me, actually.
> >
> Again, so long as there is no pointers or such in the DNA struct you
> make, then saving/loading should be fairly automatic.
>
> Joe
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at projects.blender.org
> http://projects.blender.org/mailman/listinfo/bf-committers
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.blender.org/pipermail/bf-committers/attachments/20060724/4d0374fd/attachment.html


More information about the Bf-committers mailing list