Notifications
Clear all

[Closed] 3DSMAX SDK Q: How to save and load INode ?

Hello,
I want to save and load an INode using ISave(write) and ILoad(read) .
Can any one tell me how i can do this ?

or,Is there any alternative to do this ?

Thanks.

5 Replies

What do you want to save and load with INode?

2 Replies
(@srikanthr1991)
Joined: 11 months ago

Posts: 0

hi,
I want to store the Node itself .

because,I added few object nodes to the Tab<INode*> .I want to save the objects that are in the tab ,and,load them with the scene file .

(@denist)
Joined: 11 months ago

Posts: 0

in this case you are saving not INode, you are saving Tab<INode*>. It’s not easy. You can’t save anything abstract in the scene. It must be a part of anything built-in savable (IParamBlock, Modifier Stack, Track View, Persistent globals, etc).

you can use IRefTargContainer which has built-in automatic save/load*

You can have the node as a reference and it will be saved automatically. And if for reason you can’t have the node as a reference you could use the node’s handle, that is the way that lights stores nodes in the exclude list. I would rather use the first option though

the usual technique is to maintain any references to scene nodes within a parameter block using the TYPE_INODE_TAB data type