View Full Version : How to get all existing DAG node in API?
gohkgohk 08-18-2009, 05:49 AM Is it use MEL "select all" first, and then iterate on the selection?
It looks like an indirect method.
Do anyone have other method?
thx
|
|
gohkgohk
08-18-2009, 09:20 AM
Is it use MEL "select all" first, and then iterate on the selection?
It looks like an indirect method.
Do anyone have other method?
thx
oops..Sorry . now i know i can use "dagIterator" to loop through all the Node.
But i have another questions now.
I find some "nodes" which shown in the Hypergraph do not iterated by "dagIterator".e.g. tweak , polyboolop....
how can i access to these "node" in api, and get/modify their data/attitude?
thx
Robert Bateman
08-18-2009, 09:41 AM
http://nccastaff.bournemouth.ac.uk/jmacey/RobTheBloke/www/research/index.htm
specifically:
http://nccastaff.bournemouth.ac.uk/jmacey/RobTheBloke/www/research/maya/mfn_traversing.htm
MItDependencyNodes it(MFn::kInvalid);
// keep looping until done
while(!it.isDone())
{
// get a handle to this node
MObject obj = it.item();
// attach function set
MFnDependencyNode fn(obj);
cout << fn.name().asChar() << ": " << obj.apiTypeStr() << endl;
// move on to next node
it.next();
}
CGTalk Moderation
08-18-2009, 09:41 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.