 //    var Far:Float = 100.0
 //}
 
-public class BaseRenderer {
-    
+//public class BaseRenderer {
+
 //    var colorPixelFormat: MTLPixelFormat? = .BGRA8Unorm
 //    var depthPixelFormat: MTLPixelFormat? = .Depth32Float
 //    var stencilPixelFormat: MTLPixelFormat?
     
     // this value will cycle from 0 to kInFlightCommandBuffers whenever a display completes ensuring renderer clients
     // can synchronize between kInFlightCommandBuffers count buffers, and thus avoiding a constant buffer from being overwritten between draws
-}
+//}
 
 //class MVPRenderer: BaseRenderer, Projectable, Uniformable, Perspectable {
 //    var pipelineState: MTLRenderPipelineState?

public typealias RendererEncodeBlock = ((MTLRenderCommandEncoder) -> Void)
public typealias RenderEncoderConfigureBlock = ((MTLRenderCommandEncoder) -> Void)
public typealias RenderEncoderTransition = ((MTLRenderCommandEncoder) -> MTLRenderCommandEncoder)
public typealias RenderEncoderCreateMonad = ((MTLCommandBuffer, MTLRenderPassDescriptor) -> MTLRenderCommandEncoder)

public protocol Renderer {
    // Use enums for rendererType. use rendererTypes for transitionMap keys
    var name: String? { get set }
    var rendererType: Int { get set }
    var transitionMap: [Int:RenderEncoderTransition] { get set }
    var createRenderEncoderBlock: RenderEncoderCreateMonad? { get set }
    
    // should these kinds of properties only be set from inside blocks?


//typealias ComputeEncoderTransition = ((MTLCommandBuffer, MTLComputeCommandEncoder) -> MTLComputeCommandEncoder)

public class BaseRenderer: Renderer {
    public var name: String?
    public var transitionMap: RenderEncoderTransitionMap = [:]
    public var createRenderEncoderBlock: RenderEncoderCreateMonad? = BaseRenderer.createRenderEncoderDefault()
    public var configureRenderEncoderBlock: RenderEncoderConfigureBlock?
    
    public var cullMode: MTLCullMode = .Front
