public RenderableMesh(VertexBufferObject<Vertex3V3N> vertexBuffer, VertexBufferObject<uint> elementBuffer, VertexArrayObject vertexArrayObject, int length, ResourceAllocator resourceAllocator)
 {
     _resourceAllocator = resourceAllocator;
     Faces = length;
     _vertexArrayObject = vertexArrayObject;
     _elementBuffer = elementBuffer;
     _vertexBuffer = vertexBuffer;
 }
 public RenderableMesh(VertexBufferObject <Vertex3V3N> vertexBuffer, VertexBufferObject <uint> elementBuffer, VertexArrayObject vertexArrayObject, int length, ResourceAllocator resourceAllocator)
 {
     _resourceAllocator = resourceAllocator;
     Faces = length;
     _vertexArrayObject = vertexArrayObject;
     _elementBuffer     = elementBuffer;
     _vertexBuffer      = vertexBuffer;
 }
 public RenderSystem(ICamera camera)
 {
     _camera = camera;
     _resourceAllocator = new ResourceAllocator(new OpenGlResourceFactory());
     _simpleMaterial = new SimpleMaterial();
     _simpleMaterial.Create();
     _normalDebugProgram = new NormalDebugProgram();
     _normalDebugProgram.Create();
 }
        public Cube()
        {
            _simpleMaterial = new SimpleMaterial();
            var resourceAllocator = new ResourceAllocator(new OpenGlResourceFactory());
            _simpleMaterial.Create();

            var mesh = MeshCreator.CreateXZGrid(10, 10);
            _renderable = resourceAllocator.AllocateResourceFor(mesh);
            _renderable.CreateVAO();
        }