예제 #1
0
void Xrefutil::MergeAllXrefScenes(HWND hWnd)
{
    // *** MergeAllXrefScenes ***
    //
    // Merges ("binds") all XRef Scenes into the
    // current scene.  Just using RootNode::BindXRefFile
    // will merge in the real scene objects from the xref'd
    // scene as real modifiable objects, and delete the
    // xref scene link from the scene hierarchy.
	
    INode * pNode = NULL;
    int i, numxrefscenes;
	
    INode * pRootNode = m_pInterface->GetRootNode();
    if (!pRootNode) {
        // well, this is actually _really_ bad, but we just exit
        return;
    }
    numxrefscenes = pRootNode->GetXRefFileCount();
    for (i = 0; i < numxrefscenes; i++) {
        pRootNode->BindXRefFile(i);
    }
	
}
예제 #2
0
void Xrefutil::RefreshAllXrefScenes(HWND hWnd)
{
    // *** RefreshAllXrefScenes ***
    // 
    // Refreshes all Xref'd Scenes -- mimics 
    // MAX's "Update Now" button on XRef Scene dialog,
    // with all xref'd scenes selected.
    //
    // Simply walk through all XRef'd scenes (hanging off root)
    // and use RootNode::ReloadXRef() to reload each one.
	
    INode * pNode = NULL;
    int i, numxrefscenes;
	
    INode * pRootNode = m_pInterface->GetRootNode();
    if (!pRootNode) {
        // well, this is actually _really_ bad, but we just exit
        return;
    }
    numxrefscenes = pRootNode->GetXRefFileCount();
    for (i = 0; i < numxrefscenes; i++) {
        pRootNode->ReloadXRef(i);
    }
}