Ejemplo n.º 1
0
void bankManager::saveZone(ofxXmlSettings & XML, ofPtr<triggerZone> z){
    
    XML.addValue("NAME", z->getName());
    
    
    XML.addValue("POS_X", z->getPos().x);
    XML.addValue("POS_Y", z->getPos().y);
    XML.addValue("POS_Z", z->getPos().z);
    
    XML.addValue("SHAPE", z->getShape());
    
    XML.addValue("DIM_X", z->getBoxDims().x);
    XML.addValue("DIM_Y", z->getBoxDims().y);
    XML.addValue("DIM_Z", z->getBoxDims().z);
    XML.addValue("RADIUS", z->getRadius());
    XML.addValue("SOUNDFILE", z->getSoundFileName());
    XML.addValue("IS_LOOP", z->getIsLoop());
    XML.addValue("IS_PLAY_TO_END", z->getIsPlayToEnd());
    XML.addValue("INVERTED", z->getIsOccInvert()); //left as is for compatability
    XML.addValue("MOV_ENABLED", z->getIsMovEnabled());
    XML.addValue("MOV_INVERTED", z->getIsMovInvert());
    XML.addValue("ENABLED", z->getIsEnabled());
    //XML.addValue("SENSITIVITY", z->getSensitivity());
    XML.addValue("MIN_REPLAY", z->getMinReplaySecs());
    XML.addValue("CHANGE_BUFF", z->getChangeBuff());
    XML.addValue("SYNTH_TYPE", z->getSynthType());
    XML.addValue("SELECTOR_TYPE", z->getSelectorType());
    
    saveSynth(XML, z);
    

}
Ejemplo n.º 2
0
void testApp::updateSceneControls(ofPtr<scene> s, ofPtr<triggerZone> zn){
    
    sc2TextInput[0]->setTextString(s->getName());
    
    fInSlid->setValue(s->getFadeIn());
    fOutSlid->setValue(s->getFadeOut());
    
    if(s->getNumTriggerZones() > 0){
        
        if(displayMode == DT_DM_3D){
            
            zoneCanvases[0]->setVisible(true);
            
            if(zn->getShape() == TZ_SPHERE){
                zoneCanvases[1]->setVisible(true);
                zoneCanvases[2]->setVisible(false);
                zoneCanvases[3]->setVisible(false);
            }else if(zn->getShape() == TZ_BOX){
                zoneCanvases[1]->setVisible(false);
                zoneCanvases[2]->setVisible(true);
                zoneCanvases[3]->setVisible(false);
            }else{
                zoneCanvases[1]->setVisible(false);
                zoneCanvases[2]->setVisible(false);
                zoneCanvases[3]->setVisible(true);
            }
        }
        
        updateTZGuiElements(zn);
        
    }else{
        for(int i = 0; i < 4; i++)zoneCanvases[i]->setVisible(false);
        sc2TextInput[1]->setTextString("none");
    }
    
    
}