#include <pch.hpp>

#include <core.hpp>
#include <opengl/opengl_vertex_array.hpp>
#include <renderer/vertex_array.hpp>
#include <renderer/renderer.hpp>

namespace OpenEngine {
    Ref<VertexArray> VertexArray::Create()
    {
        switch (Renderer::GetAPI()) {
            case RendererAPI::API::None : OE_CORE_ASSERT(false, "No render API selected!"); return nullptr;
            case RendererAPI::API::OpenGL : return CreateRef<OpenGLVertexArray>();
        }

        OE_CORE_ASSERT(false, "Selected API not supported");
        return nullptr;
    }
}
