#include "renderer.h"

#include <stdlib.h>

struct sw_renderer *
sw_renderer_create(void *data, sw_renderer_cb enter, sw_renderer_cb exit) {
	struct sw_renderer *renderer;

	renderer = malloc(sizeof(struct sw_renderer));

	renderer->data = data;
	renderer->enter = enter;
	renderer->exit = exit;
	renderer->render = 0;

	return renderer;
}

void sw_renderer_destroy(struct sw_renderer *renderer) {
	free(renderer);
}
