window.c 869 B
/*
// Created by Lucile on 04/04/2021.
*/
/*!
* \file window.c
* \brief Window Source File
* \authors Lucile
* \version 2
* \date 04/04/2021
*
* Window functions implementation.
*
*/
#include <stdio.h>
#include <SDL2/SDL.h>
#include <SDL2/SDL_image.h>
#include "window.h"
/*!
* \fn init_window(Window * window, int level, int time, int nb_window)
* \brief This function initializes a window.
*
* \param [in] window a pointer on a Window.
* \param [in] level Level's number, -1 if none.
* \param [in] time The level's time, -1 otherwise (no timing).
* \param [in] nb_window Window's type.
*/
void init_window(Window * window, int level, int time, int id_window) {
window->id_window=id_window;
if(id_window==LEVEL){
window->level=level;
window->time=time;
} else {
window->level=-1;
window->time=-1;
}
}