     }
     
     func setupObjects() {
-        // parse Cube.XML
-        
+// parse Cube.XML
 //        let cubeXml = try! xml["root"]["mesh"].withAttr("id", cubeKey)
 //        setupCube(cubeKey, xml: cubeXml)
     }

        setupScene()
    }
    
    func loadVertexDescriptorMap() {
        vertexDescriptorMap["common"] = VertexDescriptorGenerator.commonVertexDescriptor()
    }
    
    func loadPipelineStateMap() {
        let pipelineGenerator = Spectra.RenderPipelineGenerator(library: spectraView.defaultLibrary)
        pipelineStateMap = pipelineGenerator.generatePipelineMap(spectraView.device!, functionMap: CubeViewController.renderFunctionMap, setupDescriptor: { (desc) in
            desc.colorAttachments[0].pixelFormat = .BGRA8Unorm
            desc.vertexDescriptor = self.vertexDescriptorMap["common"]
            return desc
        })
    }
    
    func loadDepthStencilMap() {
        let depthStateDesc = MTLDepthStencilDescriptor()
        depthStateDesc.depthCompareFunction = .Always
        depthStateDesc.depthWriteEnabled = true
        depthStencilStateMap["default"] = spectraView.device?.newDepthStencilStateWithDescriptor(depthStateDesc)
    }
    
    func setupPerspective() {

    
    @IBOutlet weak var spectraView: Spectra.BaseView! //TODO: weak?
    var scene: Spectra.Scene?
    var descMan: Spectra.SpectraDescriptorManager!
    var stateMan: Spectra.SpectraStateManager!
    
    // i wish i could more strongly constrain the keys for these maps
    // - but i can't create a protocol for enums 
