Pays-Froid.Net

Qu'est ce que Pays-Froid.Net

C - Horloge

Posez vos problèmes à propos du C et C++

C - Horloge

Messagede Geoffroy le 23 Jan 2007 20:36

voici le code que j'ai pour mon horloge, et le texte ne veut pas s'afficher et le fenêtre ne reste pas ouverte.

(l'affichage se trouve a la fin, avant le blittage)

Code: Tout sélectionner
#include <stdlib.h>
#include <stdio.h>
#include <SDL/SDL.h>
#include <SDL/SDL_image.h>
#include <SDL/SDL_ttf.h>

int main(int argc, char *argv[])
{
    SDL_Init(SDL_INIT_VIDEO| SDL_INIT_TIMER);
    TTF_Init();
    long seconde=0, minute=0, heure=0, jour=1, mois=1, an=2007, jourAn=1, semaine=0, jourSemaine;
    int continuer = 1;
    SDL_Event event;
    SDL_Surface *ecran = NULL, *texte1=NULL, *texte2=NULL, *texte3=NULL;
    TTF_Font *police = NULL;
    SDL_Color blanc = {255, 255, 255};
    char houre[100]={0}, date[100]={0};
    char nomMois[100]={0}, nomJour[100]={0};

    police = TTF_OpenFont("3_traits.ttf", 15);

    ecran = SDL_SetVideoMode(320, 240, 32, SDL_HWSURFACE | SDL_DOUBLEBUF);
    SDL_WM_SetCaption("Horloge", NULL);


    SDL_Rect positionTexte1;
    SDL_Rect positionTexte2;
    SDL_Rect positionTexte3;

    while (continuer)
    {
        SDL_PollEvent(&event);
        switch(event.type)
        {
            case SDL_QUIT:
                continuer = 0;
                break;
        }
        seconde++;
        if (seconde>=60)
        {
            seconde=0;
            minute++;
        }
        if (minute>=60)
        {
            minute=0;
            heure++;
        }
        if (heure>=24)
        {
            heure=0;
            jour++;
            jourAn++;
        }
        if (mois==1 || mois==3 || mois==5 || mois==7 || mois==8 || mois==10 || mois==12)
        {
            if (jour>=31)
            {
                jour=1;
                mois++;
            }
        }
        else if (mois==4 || mois==6 || mois==9 || mois==11)
        {
            if (jour>=30)
            {
                jour=1;
                mois++;
            }
        }
        else if(mois==2)
        {
            if (an!=2008 || an!=2012 || an!=2016)
            {
                if(jour>=29)
                {
                    jour=1;
                    mois++;
                }
            }
            else
            {
                if(jour>=28)
                {
                    jour=1;
                    mois++;
                }
            }
        }
        if (mois>=12)
        {
            mois=1;
            jourAn=1;
            an++;
        }
        switch(mois)
        {
            case 1:
                sprintf(nomMois, "Janvier");
                break;
            case 2:
                sprintf(nomMois, "Fevrier");
                break;
            case 3:
                sprintf(nomMois, "Mars");
                break;
            case 4:
                sprintf(nomMois, "Avril");
                break;
            case 5:
                sprintf(nomMois, "Mai");
                break;
            case 6:
                sprintf(nomMois, "Juin");
                break;
            case 7:
                sprintf(nomMois, "Juillet");
                break;
            case 8:
                sprintf(nomMois, "Aout");
                break;
            case 9:
                sprintf(nomMois, "Septembre");
                break;
            case 10:
                sprintf(nomMois, "Octobre");
                break;
            case 11:
                sprintf(nomMois, "Novembre");
                break;
            case 12:
                sprintf(nomMois, "Decembre");
                break;
        }
        semaine=(jourAn/7)+1;
        jourSemaine=jourAn%7;
        switch(jourSemaine)
        {
            case 1:
                sprintf(nomJour, "Lundi");
                break;
            case 2:
                sprintf(nomJour, "Mardi");
                break;
            case 3:
                sprintf(nomJour, "Mercredi");
                break;
            case 4:
                sprintf(nomJour, "Jeudi");
                break;
            case 5:
                sprintf(nomJour, "Vendredi");
                break;
            case 6:
                sprintf(nomJour, "Samedi");
                break;
            case 7:
                sprintf(nomJour, "Dimanche");
                break;
        }
        sprintf(texte1, "%ld:%ld:%ld", heure, minute, seconde);
        texte1 = TTF_RenderText_Solid(police, "texte1", blanc);
        texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
        sprintf(texte3, "Nous sommes le %s %ld %s %ld", nomJour, jour, nomMois, an);
        SDL_Delay(1000);


        positionTexte1.x=ecran->w/2-texte1->w/2;
        positionTexte1.y=ecran->h/2-texte1->h/2;

        positionTexte2.x=ecran->w/2-texte2->w/2;
        positionTexte2.y=(ecran->h/2-texte1->h/2)-20;

        positionTexte3.x=ecran->w/2-texte3->w/2;
        positionTexte3.y=50;

        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);
        SDL_Flip(ecran);
    }

    SDL_FreeSurface(texte1);
    SDL_FreeSurface(texte2);
    SDL_Quit();
    TTF_CloseFont(police);
    TTF_Quit();
    return EXIT_SUCCESS;
}
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Patoch le 23 Jan 2007 21:08

euh....
Ca du Html?? :D
Ca ressemble beaucoup plus a du C... :oops:
Image
Image
Avatar de l’utilisateur
Patoch
Administrateur
Administrateur
 
Messages: 1343
Inscription: 13 Nov 2006 1:53
Localisation: Sur la Banquise

Messagede Geoffroy le 23 Jan 2007 21:49

a oups!!!!
je crois que je me suis trompé de partie!
dsl!
c'est parce que j'apprends les deux en même temps.
Je le déplace et après efface le sujet stp!
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Patoch le 23 Jan 2007 21:50

Attends, je creer une section C ;)
Image
Image
Avatar de l’utilisateur
Patoch
Administrateur
Administrateur
 
Messages: 1343
Inscription: 13 Nov 2006 1:53
Localisation: Sur la Banquise

Messagede Geoffroy le 23 Jan 2007 21:51

merde j'ai deja postée dans la section autre!
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Geoffroy le 23 Jan 2007 21:57

alors, tu a une idée?
aucun plantage a la compilation, c'est ca le plus chiant!
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Patoch le 23 Jan 2007 22:00

Etant donné que j'ai commencé le C seulement aujourd'hui (ce qui explique pourquoi je n'ai pas créé cette section automatiquement), je ne peux pas vraiment t'aider. Yoyo86 peut etre :)
Image
Image
Avatar de l’utilisateur
Patoch
Administrateur
Administrateur
 
Messages: 1343
Inscription: 13 Nov 2006 1:53
Localisation: Sur la Banquise

Messagede Geoffroy le 23 Jan 2007 22:04

ok, merci quand même et bonne chance pour tes cours!
tu a deja commencé aujourd'hui?
tu a appris quoi?
Code: Tout sélectionner
#include <stdlib.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
     long i=0;
     for (i=0;i<100;i++)
     printf("Je ne dois pas macher de chewing gum en cours\n");
}


(la punition)

essaye la tu verra ca marche.

il y a aussi

Code: Tout sélectionner
#include <stdlib.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
     long i=0;
     for (i=0;i<100;i++)
     printf("Ta gueule pour voir! %ld edition\n", i);
}
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Patoch le 23 Jan 2007 22:48

j'ai appris comment faire un programme tres simple qui consiste a demander des mesure de jardin
puis apres je doi retourner la reponse en ayant calculé la surface et l'air. enfin c'est tres simple donc ce que tu vien d'ecrire, je le comprend a peu pres :)

par exemple : ceci "i++" qu'est ce que c'est?
Image
Image
Avatar de l’utilisateur
Patoch
Administrateur
Administrateur
 
Messages: 1343
Inscription: 13 Nov 2006 1:53
Localisation: Sur la Banquise

Messagede yoyo86 le 23 Jan 2007 22:54

N'ayant pas trop bossé sur le sdl et n'ayant pas trop de souvenir (6 mois sans toucher à du C et voilà que ma mémoire me lâche :o )je ne peux pas directement te répondre mais par contre je m'y mets de suite !!! (faut aussi que je repotasse rapidement mes progs en c pour tout me remetrre en mémoire )
Mais ne t'inquiete pas je ne laisserai pas un pingouin abandonné sur la banquise !!! :D :D :D
Image
yoyo86
Pinguin
Pinguin
 
Messages: 193
Inscription: 30 Nov 2006 0:54

Messagede Geoffroy le 24 Jan 2007 1:09

ok merci :!:
je vais essayer de chercher aussi un peu (du mieux que je peux) et bientôt je me met au C++!:D

Patoch, i++ c'est un incrémentation de la variable i (tu rajoute 1, c'est un raccourci, lache ca en cours et ton prof va être content :!: )

Et sinon for(i=0; i<500; i++)
c'est une boucle qui dit au programme de répéter tous le temps la même chose, de i=0 a i=500 en ajoutant 1 a i a chaque passage.
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede yoyo86 le 24 Jan 2007 1:12

Allez Patoch dis-le au prof stp qu'on se fende la gueule un bon coup !!! :D :D :D
Image
yoyo86
Pinguin
Pinguin
 
Messages: 193
Inscription: 30 Nov 2006 0:54

Messagede Geoffroy le 24 Jan 2007 19:42

faut que je vous la passe un de ce sjour ma montre, par contre il va falloir que je fasse le truc par système de timer, c'est trop la merde la ca rame tellement que les secondes en prennent 10!
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Messagede Tifoo le 25 Jan 2007 11:04

Tu trouvera sur le net sans probleme des horloges déjà optimisé (souvent coder en dur), c'est pas super simple comme projet ;)
Image

En bleu : Le modo qui parle
Tifoo
Programmer
Programmer
 
Messages: 123
Inscription: 21 Nov 2006 16:09
Localisation: Dans son Igloo, devant son PC

Messagede Geoffroy le 25 Jan 2007 18:51

ben en fait j'ai quasiment fini, il y a meme un film qui passe derrière, mais maintenant il faut que j'optimise un peu le code parce que la ca rame.

un petit aperçu au cas ou si quelqu'un a besoin d'être dégoutée du C:

(faites pas gaffe au include, il ne servent pas tous mais je les met tous le temps si jamais j'en ai besoin copier collée et hop!)

Code: Tout sélectionner
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <SDL/SDL.h>
#include <SDL/SDL_image.h>
#include <SDL/SDL_ttf.h>
#include <FMOD/fmod.h>

int main(int argc, char *argv[])
{
    SDL_Init(SDL_INIT_VIDEO| SDL_INIT_TIMER);
    TTF_Init();
    long seconde=0, minute=39, heure=4, jour=24, mois=1, an=2007, jourAn=24, semaine=0, jourSemaine=1;
    int continuer = 1;
    SDL_Event event;
    SDL_Surface *ecran = NULL, *texte1=NULL, *texte2=NULL, *texte3=NULL;
    char Texte1[100]={0}, Texte2[100]={0}, Texte3[100]={0};
    TTF_Font *police = NULL;
    SDL_Color blanc = {0, 0, 0};
    char houre[100]={0}, date[100]={0};
    char nomMois[100]={0}, nomJour[100]={0};

    SDL_Surface *image = NULL;

    SDL_Rect positionImage;
    positionImage.x = 0;
    positionImage.y = 0;

    police = TTF_OpenFont("3_traits.ttf", 15);

    TTF_SetFontStyle(police, TTF_STYLE_BOLD);

    ecran = SDL_SetVideoMode(1000, 750, 32, SDL_HWSURFACE | SDL_DOUBLEBUF | SDL_FULLSCREEN);
    SDL_WM_SetCaption("Horloge", NULL);


    SDL_Rect positionTexte1;
    SDL_Rect positionTexte2;
    SDL_Rect positionTexte3;

    while (continuer)
    {
        SDL_ShowCursor(SDL_DISABLE);

        SDL_PollEvent(&event);
        switch(event.type)
        {
            case SDL_QUIT:
                continuer = 0;
                break;
            case SDL_KEYDOWN:
                switch(event.key.keysym.sym)
                    {
                        case SDLK_ESCAPE:
                            continuer = 0;
                            break;
                        case SDLK_SPACE:
                            continuer = 0;
                            break;
                        case SDLK_BACKSPACE:
                            continuer = 0;
                            break;
                        default:
                            continuer = 0;
                            break;
                    }
                break;
            case SDL_MOUSEMOTION:
                continuer = 0;
                break;

        }
        seconde++;
        if (seconde>=60)
        {
            seconde=0;
            minute++;
        }
        if (minute>=60)
        {
            minute=0;
            heure++;
        }
        if (heure>=24)
        {
            heure=0;
            jour++;
            jourAn++;
        }
        if (mois==1 || mois==3 || mois==5 || mois==7 || mois==8 || mois==10 || mois==12)
        {
            if (jour>=31)
            {
                jour=1;
                mois++;
            }
        }
        else if (mois==4 || mois==6 || mois==9 || mois==11)
        {
            if (jour>=30)
            {
                jour=1;
                mois++;
            }
        }
        else if(mois==2)
        {
            if (an!=2008 || an!=2012 || an!=2016)
            {
                if(jour>=29)
                {
                    jour=1;
                    mois++;
                }
            }
            else
            {
                if(jour>=28)
                {
                    jour=1;
                    mois++;
                }
            }
        }
        if (mois>=12)
        {
            mois=1;
            jourAn=1;
            an++;
        }
        switch(mois)
        {
            case 1:
                sprintf(nomMois, "Janvier");
                break;
            case 2:
                sprintf(nomMois, "Fevrier");
                break;
            case 3:
                sprintf(nomMois, "Mars");
                break;
            case 4:
                sprintf(nomMois, "Avril");
                break;
            case 5:
                sprintf(nomMois, "Mai");
                break;
            case 6:
                sprintf(nomMois, "Juin");
                break;
            case 7:
                sprintf(nomMois, "Juillet");
                break;
            case 8:
                sprintf(nomMois, "Aout");
                break;
            case 9:
                sprintf(nomMois, "Septembre");
                break;
            case 10:
                sprintf(nomMois, "Octobre");
                break;
            case 11:
                sprintf(nomMois, "Novembre");
                break;
            case 12:
                sprintf(nomMois, "Decembre");
                break;
        }
        semaine=(jourAn/7)+1;
        jourSemaine=jourAn%7;
        switch(jourSemaine)
        {
            case 1:
                sprintf(nomJour, "Lundi");
                break;
            case 2:
                sprintf(nomJour, "Mardi");
                break;
            case 3:
                sprintf(nomJour, "Mercredi");
                break;
            case 4:
                sprintf(nomJour, "Jeudi");
                break;
            case 5:
                sprintf(nomJour, "Vendredi");
                break;
            case 6:
                sprintf(nomJour, "Samedi");
                break;
            case 7:
                sprintf(nomJour, "Dimanche");
                break;
        }
        sprintf(Texte1, "%ld : %ld : %ld", heure, minute, seconde);
        sprintf(Texte3, "%s %ld %s %ld", nomJour, jour, nomMois, an);
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
        texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
        texte3 = TTF_RenderText_Blended(police, Texte3, blanc);


        positionTexte1.x=ecran->w/2-texte1->w/2;
        positionTexte1.y=(ecran->h/2-texte1->h/2)+20;

        positionTexte2.x=ecran->w/2-texte2->w/2;
        positionTexte2.y=(ecran->h/2-texte1->h/2)+40;

        positionTexte3.x=ecran->w/2-texte3->w/2;
        positionTexte3.y=70;

    image= SDL_LoadBMP("90.bmp");
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("85.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("80.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("75.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("70.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("65.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("60.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("55.bmp");
        texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("50.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("45.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("40.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("35.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("30.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("25.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("20.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("15.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("10.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("5.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("0.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("0.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("0.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("0.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("5.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("10.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("15.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("20.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("25.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("30.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("35.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("40.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("45.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("50.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("55.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("60.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);





    image= SDL_LoadBMP("65.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("70.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);




    image= SDL_LoadBMP("75.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);




    image= SDL_LoadBMP("80.bmp");
    texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    image= SDL_LoadBMP("85.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("90.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("90.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("90.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("90.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);


    image= SDL_LoadBMP("90.bmp");
     texte1 = TTF_RenderText_Solid(police, Texte1, blanc);
    texte2 = TTF_RenderText_Blended(police, "heure minute seconde", blanc);
    texte3 = TTF_RenderText_Blended(police, Texte3, blanc);
        SDL_FillRect(ecran, NULL, SDL_MapRGB(ecran->format, 0, 0, 0));
        SDL_BlitSurface(image, NULL, ecran, &positionImage);
        SDL_BlitSurface(texte1, NULL, ecran, &positionTexte1);
        SDL_BlitSurface(texte2, NULL, ecran, &positionTexte2);
        SDL_BlitSurface(texte3, NULL, ecran, &positionTexte3);


    SDL_Flip(ecran);
    SDL_Delay(20);



    }

    SDL_FreeSurface(image);
    SDL_FreeSurface(texte1);
    SDL_FreeSurface(texte2);
    SDL_FreeSurface(texte3);
    SDL_Quit();
    TTF_CloseFont(police);
    TTF_Quit();
    return EXIT_SUCCESS;
}
TIMTOWTDI
Avatar de l’utilisateur
Geoffroy
Crazy Pinguin
Crazy Pinguin
 
Messages: 1332
Inscription: 20 Jan 2007 23:11

Qui est en ligne

Utilisateurs parcourant ce forum: Aucun utilisateur enregistré et 0 invités

cron

Copyright © Pays-Froid.Net

Nous contacter | Notre Histoire | Plan du site | Nos partenaires | Mentions légales | Fil RSS | XHTML 1.0 | CSS 2.0

Partenaire : Waliwaloo - Darklg - Yagoort - Meilleur du Web - Hit Parade