blob: 898123821ed7e0532a7c6a900c3cc5e63c1e9e13 [file] [log] [blame]
/*
* Copyright (c) 2014 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include <libtsm.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include "input.h"
#include "term.h"
#include "video.h"
int main()
{
int32_t width, height, pitch, scaling;
int ret;
ret = video_init(&width, &height, &pitch, &scaling);
if (ret) {
printf("Video init failed\n");
return EXIT_FAILURE;
}
ret = input_init();
if (ret) {
printf("Input init failed\n");
video_close();
return EXIT_FAILURE;
}
ret = term_init(width, height, pitch, scaling);
if (ret) {
printf("Term init failed\n");
input_close();
video_close();
return EXIT_FAILURE;
}
ret = term_run();
input_close();
term_close();
video_close();
return ret;
}