#include "DrawingManager.h"

#include "INativeDrawingContext.h"
#include "DrawingSurface.h"
#include "DrawingContext.h"
#include "Rasterizer.h"

#include "Grid.h"
#include "Image.h"

DrawingManager::DrawingManager()
    : mRasterizer(std::make_unique<Rasterizer>())
{

}

std::unique_ptr<DrawingManager> DrawingManager::Create()
{
    return std::make_unique<DrawingManager>();
}

void DrawingManager::InitalizeSurface(unsigned width, unsigned height)
{
    mDrawingSurface = DrawingSurface::Create();
    mDrawingSurface->SetSize(width, height);
}

void DrawingManager::InitializeContext()
{
    mDrawingContext = DrawingContext::Create();
}

void DrawingManager::AddText(TextElement* text)
{
    if (!mDrawingContext)
    {
        InitializeContext();
    }

    if (!mDrawingContext)
    {
        return;
    }
}

void DrawingManager::RenderToFile(const std::string& path)
{

}
