#include "transform.h"

SDL_Surface* transform(std::string const chaine, int const taille)
{
    // [1] Préparation du texte
    TTF_Font *police(0);
    police = TTF_OpenFont("Polices/droid.ttf",taille);
    SDL_Color couleurNoire = {0,0,0};

    // [2] Assignation de la surface
    SDL_Surface *texte(0);
    texte = TTF_RenderText_Blended(police, chaine.c_str(),couleurNoire);

    // [3] Fermeture
    TTF_CloseFont(police);

    // [3] Retourne la surface
    return texte;
}

SDL_Surface* transform(std::string const chaine)
{
    return transform(chaine,20);
}