/*
 * demoscene-eo, an ASCII art demoscene written as a gift for Emmanuel Otton retirement 
 * Copyright (C) 2019  XXXXXX XXXXXXX <xxxxxx@xxxxxx.fr>
 *  
 * This file is part of demoscene-eo.
 *
 *  demoscene-eo is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  demoscene-eo is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with demoscene-eo.  If not, see <http://www.gnu.org/licenses/>
 */
#include "scene02.h"

int scene02_init_gl(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
	return 0;
}

int scene02_init_sdl(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
	return 0;
}

int scene02_init_caca(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
	return 0;
}

void scene02_free_gl(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
}

void scene02_free_sdl(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
}

void scene02_free_caca(graphical_env_t *ge, scene02_env_t *se) {
	TRACE("call");
}


int scene02_next_gl(graphical_env_t *ge, scene02_env_t *se) {
	static int firsttime=1; TRACE_ONCE("call");
	return 0;
}

int scene02_next_sdl(graphical_env_t *ge, scene02_env_t *se) {
	static int firsttime=1; TRACE_ONCE("call");
	return 0;
}

int scene02_next_caca(graphical_env_t *ge, scene02_env_t *se) {
	// Shorthands
	caca_canvas_t *cv = ge->cv;
	//int w = ge->w, h = ge->h;
	Uint32 frame = ge->sc_framecount;

	static int firsttime=1; TRACE_ONCE("call");

	caca_clear_canvas(cv);

	if (frame >= 100) {
		return 1;
	}
	return 0;
}