From 7365c67c5659710b1b21d8ca61ff9e3c049c1a2d Mon Sep 17 00:00:00 2001 From: Sven Panne Date: Fri, 27 Mar 2009 16:20:40 +0000 Subject: [PATCH] Make Visual C happy by including stddef.h and explicitly marking some literals as float. git-svn-id: svn+ssh://svn.code.sf.net/p/freeglut/code/trunk/freeglut/freeglut@808 7f0cb862-5218-0410-a997-914c9d46530a --- ChangeLog | 5 +++++ progs/demos/smooth_opengl3/smooth_opengl3.c | 5 +++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 45122f0..2410cd8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-03-27 Sven Panne + + * progs/demos/smooth_opengl3/smooth_opengl3.c: Make Visual C happy by + including stddef.h and explicitly marking some literals as float. + 2009-03-26 Sven Panne * src/freeglut_init.c,src/freeglut_input_devices.c: Unbreak the build: diff --git a/progs/demos/smooth_opengl3/smooth_opengl3.c b/progs/demos/smooth_opengl3/smooth_opengl3.c index a671a53..74e4e78 100755 --- a/progs/demos/smooth_opengl3/smooth_opengl3.c +++ b/progs/demos/smooth_opengl3/smooth_opengl3.c @@ -45,6 +45,7 @@ #include #include #include +#include #include /* report GL errors, if any, to stderr */ @@ -397,9 +398,9 @@ void reshape (int w, int h) { glViewport (0, 0, (GLsizei) w, (GLsizei) h); if (w <= h) { - loadOrtho2Df (projectionMatrix, 0.0, 30.0, 0.0, 30.0 * (GLfloat) h/(GLfloat) w); + loadOrtho2Df (projectionMatrix, 0.0f, 30.0f, 0.0f, 30.0f * (GLfloat) h/(GLfloat) w); } else { - loadOrtho2Df (projectionMatrix, 0.0, 30.0 * (GLfloat) w/(GLfloat) h, 0.0, 30.0); + loadOrtho2Df (projectionMatrix, 0.0f, 30.0f * (GLfloat) w/(GLfloat) h, 0.0f, 30.0f); } checkError ("reshape"); } -- 1.7.10.4