Functions | Variables
tearing.c File Reference
#include <glad/glad.h>
#include <GLFW/glfw3.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "linmath.h"
Include dependency graph for tearing.c:

Go to the source code of this file.


static void error_callback (int error, const char *description)
static void key_callback (GLFWwindow *window, int key, int scancode, int action, int mods)
int main (int argc, char **argv)
static void set_swap_interval (GLFWwindow *window, int interval)
static void update_window_title (GLFWwindow *window)


static const char * fragment_shader_text
static double frame_rate
static int swap_interval
static int swap_tear
static const char * vertex_shader_text
struct {
   float   x
   float   y
vertices [4]

Function Documentation

static void error_callback ( int  error,
const char *  description 

Definition at line 90 of file tearing.c.

static void key_callback ( GLFWwindow window,
int  key,
int  scancode,
int  action,
int  mods 

Definition at line 95 of file tearing.c.

int main ( int  argc,
char **  argv 

Definition at line 154 of file tearing.c.

static void set_swap_interval ( GLFWwindow window,
int  interval 

Definition at line 83 of file tearing.c.

static void update_window_title ( GLFWwindow window)

Definition at line 71 of file tearing.c.

Variable Documentation

const char* fragment_shader_text
Initial value:
"#version 110\n"
"void main()\n"
" gl_FragColor = vec4(1.0);\n"

Definition at line 60 of file tearing.c.

double frame_rate

Definition at line 69 of file tearing.c.

int swap_interval

Definition at line 68 of file tearing.c.

int swap_tear

Definition at line 67 of file tearing.c.

const char* vertex_shader_text
Initial value:
"#version 110\n"
"uniform mat4 MVP;\n"
"attribute vec2 vPos;\n"
"void main()\n"
" gl_Position = MVP * vec4(vPos, 0.0, 1.0);\n"

Definition at line 51 of file tearing.c.

const { ... } vertices[4]
Initial value:
{ -0.25f, -1.f },
{ 0.25f, -1.f },
{ 0.25f, 1.f },
{ -0.25f, 1.f }
float x

Definition at line 42 of file tearing.c.

float y

Definition at line 42 of file tearing.c.

Author(s): Sergey Dorodnicov , Doron Hirshberg , Mark Horn , Reagan Lopez , Itay Carpis
autogenerated on Mon May 3 2021 02:50:30