Path: blob/main/test/browser/test_glfw_minimal.c
4150 views
/*1* Copyright 2015 The Emscripten Authors. All rights reserved.2* Emscripten is available under two separate licenses, the MIT license and the3* University of Illinois/NCSA Open Source License. Both these licenses can be4* found in the LICENSE file.5*/67#include <stdio.h>8#include <stdlib.h>9#define GLFW_INCLUDE_ES210#include <GL/glfw.h>1112int main() {13printf("main function started\n");1415if (glfwInit() != GL_TRUE) {16printf("glfwInit() failed\n");17glfwTerminate();18return 1;19}2021printf("glfwInit() success\n");2223if (glfwOpenWindow(640, 480, 8, 8, 8, 8, 16, 0, GLFW_WINDOW) != GL_TRUE) {24printf("glfwOpenWindow() failed\n");25glfwTerminate();26return 1;27}2829printf("glfwOpenWindow() success\n");30return 0;31}32333435