plib-cvs Mailing List for PLIB (Page 41)
Brought to you by:
sjbaker
You can subscribe to this list here.
2002 |
Jan
(25) |
Feb
(10) |
Mar
(60) |
Apr
(49) |
May
(54) |
Jun
(94) |
Jul
(82) |
Aug
(251) |
Sep
(366) |
Oct
(17) |
Nov
(20) |
Dec
(14) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(12) |
Feb
(8) |
Mar
(2) |
Apr
(4) |
May
(5) |
Jun
(8) |
Jul
(23) |
Aug
(8) |
Sep
(7) |
Oct
(5) |
Nov
(20) |
Dec
(20) |
2004 |
Jan
(19) |
Feb
(70) |
Mar
(108) |
Apr
(24) |
May
(6) |
Jun
(5) |
Jul
|
Aug
(8) |
Sep
(18) |
Oct
(27) |
Nov
|
Dec
(13) |
2005 |
Jan
(19) |
Feb
(13) |
Mar
(1) |
Apr
|
May
(10) |
Jun
(1) |
Jul
(10) |
Aug
(5) |
Sep
(2) |
Oct
(2) |
Nov
(6) |
Dec
(4) |
2006 |
Jan
(9) |
Feb
|
Mar
(3) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Sebastian U. <ud...@us...> - 2002-08-30 18:21:15
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv6431/src/ssgAux Modified Files: ssgAux.h Log Message: Don't include OpenGL header files from ul.h any longer Index: ssgAux.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgAux.h,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- ssgAux.h 28 Aug 2002 00:14:34 -0000 1.13 +++ ssgAux.h 30 Aug 2002 18:21:12 -0000 1.14 @@ -25,6 +25,14 @@ #ifndef _SSGAUX_H_ #define _SSGAUX_H_ 1 +#ifdef __APPLE__ +# include <OpenGL/gl.h> +# include <OpenGL/glu.h> +#else +# include <GL/gl.h> +# include <GL/glu.h> +#endif + #include "sg.h" #include "ssg.h" #include "ssgaShapes.h" |
From: Sebastian U. <ud...@us...> - 2002-08-30 18:21:15
|
Update of /cvsroot/plib/plib/src/ssg In directory usw-pr-cvs1:/tmp/cvs-serv6431/src/ssg Modified Files: ssg.h Log Message: Don't include OpenGL header files from ul.h any longer Index: ssg.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssg/ssg.h,v retrieving revision 1.143 retrieving revision 1.144 diff -u -d -r1.143 -r1.144 --- ssg.h 28 Aug 2002 04:58:03 -0000 1.143 +++ ssg.h 30 Aug 2002 18:21:12 -0000 1.144 @@ -25,6 +25,14 @@ #ifndef _INCLUDED_SSG_H_ #define _INCLUDED_SSG_H_ +#ifdef __APPLE__ +# include <OpenGL/gl.h> +# include <OpenGL/glu.h> +#else +# include <GL/gl.h> +# include <GL/glu.h> +#endif + #include "ul.h" #include "sg.h" #include "ssgconf.h" |
From: Sebastian U. <ud...@us...> - 2002-08-30 18:21:14
|
Update of /cvsroot/plib/plib/src/pui In directory usw-pr-cvs1:/tmp/cvs-serv6431/src/pui Modified Files: pu.h Log Message: Don't include OpenGL header files from ul.h any longer Index: pu.h =================================================================== RCS file: /cvsroot/plib/plib/src/pui/pu.h,v retrieving revision 1.117 retrieving revision 1.118 diff -u -d -r1.117 -r1.118 --- pu.h 3 Aug 2002 22:44:48 -0000 1.117 +++ pu.h 30 Aug 2002 18:21:11 -0000 1.118 @@ -24,6 +24,14 @@ #ifndef _PU_H_ #define _PU_H_ 1 +#ifdef __APPLE__ +# include <OpenGL/gl.h> +# include <OpenGL/glu.h> +#else +# include <GL/gl.h> +# include <GL/glu.h> +#endif + #include "sg.h" #include "fnt.h" |
From: Sebastian U. <ud...@us...> - 2002-08-30 18:21:14
|
Update of /cvsroot/plib/plib/src/fnt In directory usw-pr-cvs1:/tmp/cvs-serv6431/src/fnt Modified Files: fnt.h Log Message: Don't include OpenGL header files from ul.h any longer Index: fnt.h =================================================================== RCS file: /cvsroot/plib/plib/src/fnt/fnt.h,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- fnt.h 15 Aug 2002 00:04:42 -0000 1.6 +++ fnt.h 30 Aug 2002 18:21:11 -0000 1.7 @@ -25,6 +25,14 @@ #ifndef _FNT_H_ #define _FNT_H_ 1 +#ifdef __APPLE__ +# include <OpenGL/gl.h> +# include <OpenGL/glu.h> +#else +# include <GL/gl.h> +# include <GL/glu.h> +#endif + #include "sg.h" #define FNTMAX_CHAR 256 |
From: Sebastian U. <ud...@us...> - 2002-08-30 16:45:43
|
Update of /cvsroot/plib/plib/demos/exposer/src In directory usw-pr-cvs1:/tmp/cvs-serv7337 Modified Files: exposer.dsp Log Message: Exposer MSVC project file fixes Index: exposer.dsp =================================================================== RCS file: /cvsroot/plib/plib/demos/exposer/src/exposer.dsp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- exposer.dsp 30 Aug 2002 14:50:28 -0000 1.5 +++ exposer.dsp 30 Aug 2002 16:45:40 -0000 1.6 @@ -113,7 +113,7 @@ SOURCE=.\exposer.h # End Source File -# End Target +# Begin Source File SOURCE=.\floor.cxx # End Source File @@ -153,6 +153,5 @@ SOURCE=.\vertices.h # End Source File -# Begin Source File - +# End Target # End Project |
From: Sebastian U. <ud...@us...> - 2002-08-30 14:50:32
|
Update of /cvsroot/plib/plib/demos/exposer/src In directory usw-pr-cvs1:/tmp/cvs-serv31583 Added Files: exposer.dsp Log Message: Re-added exposer.dsp in binary mode |
From: Sebastian U. <ud...@us...> - 2002-08-30 14:49:40
|
Update of /cvsroot/plib/plib/demos/exposer/src In directory usw-pr-cvs1:/tmp/cvs-serv31160 Removed Files: exposer.dsp Log Message: Re-added exposer.dsp in binary mode --- exposer.dsp DELETED --- |
From: Wolfram K. <wol...@us...> - 2002-08-30 14:07:25
|
Update of /cvsroot/plib/plib/demos/ttt3d/src In directory usw-pr-cvs1:/tmp/cvs-serv12438 Modified Files: cell.cxx gfx.cxx gui.cxx material.cxx ttt3d.cxx Log Message: Removing compiler warnings due to implicit type conversions. Index: cell.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/ttt3d/src/cell.cxx,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- cell.cxx 18 Aug 2002 00:09:46 -0000 1.3 +++ cell.cxx 30 Aug 2002 14:05:59 -0000 1.4 @@ -48,10 +48,10 @@ sgSetVec3 ( normal [ 0 ], 0, 0, 1 ) ; - sgSetVec3 ( scoord [ 0 ], -60, -60, -5.6 ) ; - sgSetVec3 ( scoord [ 1 ], 60, -60, -5.6 ) ; - sgSetVec3 ( scoord [ 2 ], 60, 60, -5.6 ) ; - sgSetVec3 ( scoord [ 3 ], -60, 60, -5.6 ) ; + sgSetVec3 ( scoord [ 0 ], -60, -60, -5.6f ) ; + sgSetVec3 ( scoord [ 1 ], 60, -60, -5.6f ) ; + sgSetVec3 ( scoord [ 2 ], 60, 60, -5.6f ) ; + sgSetVec3 ( scoord [ 3 ], -60, 60, -5.6f ) ; ssgVTable *vt1 = new ssgVTable ( (GLenum) GL_TRIANGLE_FAN, 4, scoord, @@ -242,7 +242,7 @@ { ssgaSphere *OOO = new ssgaSphere ( 300 ) ; - OOO -> setSize ( 0.7 ) ; + OOO -> setSize ( 0.7f ) ; OOO -> setKidState ( O_gst ) ; return OOO ; Index: gfx.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/ttt3d/src/gfx.cxx,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- gfx.cxx 18 Aug 2002 00:09:46 -0000 1.4 +++ gfx.cxx 30 Aug 2002 14:05:59 -0000 1.5 @@ -102,9 +102,9 @@ sgVec4 skycol ; sgVec4 white = { 1.0, 1.0, 1.0, 1.0 } ; - sgSetVec3 ( sunposn, -0.2, -0.5, 0.2 ) ; + sgSetVec3 ( sunposn, -0.2f, -0.5f, 0.2f ) ; - sgSetVec4 ( skycol, 0.4, 0.4, 0.8, 1.0 ) ; + sgSetVec4 ( skycol, 0.4f, 0.4f, 0.8f, 1.0f ) ; ssgGetLight ( 0 ) -> setPosition ( sunposn ) ; ssgGetLight ( 0 ) -> setColour ( GL_AMBIENT , white ) ; @@ -118,7 +118,7 @@ glEnable ( GL_DEPTH_TEST ) ; - glFogf ( GL_FOG_DENSITY, 3.0 / 100.0f ) ; + glFogf ( GL_FOG_DENSITY, 3.0f / 100.0f ) ; glFogfv( GL_FOG_COLOR , skycol ) ; glFogf ( GL_FOG_START , 0.0 ) ; glFogi ( GL_FOG_MODE , GL_EXP ) ; Index: gui.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/ttt3d/src/gui.cxx,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- gui.cxx 18 Aug 2002 00:09:46 -0000 1.2 +++ gui.cxx 30 Aug 2002 14:05:59 -0000 1.3 @@ -128,7 +128,7 @@ puFont ff ( font, 15 ) ; puSetDefaultFonts ( ff, ff ) ; puSetDefaultStyle ( PUSTYLE_SMALL_SHADED ) ; - puSetDefaultColourScheme ( 0.8, 0.8, 0.8, 0.6 ) ; + puSetDefaultColourScheme ( 0.8f, 0.8f, 0.8f, 0.6f ) ; /* Make the menu bar */ Index: material.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/ttt3d/src/material.cxx,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- material.cxx 18 Aug 2002 00:09:46 -0000 1.3 +++ material.cxx 30 Aug 2002 14:05:59 -0000 1.4 @@ -29,11 +29,11 @@ static Material gs_setup [] = { /* gst texture_map clamp, trans,aref,light,frctn,0 */ - { &default_gst, "", FALSE, TRUE , 0.0, FALSE, 1.0, 0 }, - { & ground_gst, "images/ground.rgb", FALSE, FALSE, 0.2, FALSE, 1.0, 0 }, - { & ctrls_gst, "images/controls.rgb",FALSE, TRUE , 0.2, FALSE, 1.0, 0 }, - { & X_gst, "images/X.rgb" , FALSE, FALSE, 0.2, TRUE , 1.0, 0 }, - { & O_gst, "images/O.rgb" , FALSE, FALSE, 0.2, TRUE , 1.0, 0 }, + { &default_gst, "", FALSE, TRUE , 0.0f, FALSE, 1.0, 0 }, + { & ground_gst, "images/ground.rgb", FALSE, FALSE, 0.2f, FALSE, 1.0, 0 }, + { & ctrls_gst, "images/controls.rgb",FALSE, TRUE , 0.2f, FALSE, 1.0, 0 }, + { & X_gst, "images/X.rgb" , FALSE, FALSE, 0.2f, TRUE , 1.0, 0 }, + { & O_gst, "images/O.rgb" , FALSE, FALSE, 0.2f, TRUE , 1.0, 0 }, { NULL, "", FALSE, FALSE, 0.0, FALSE, 1.0, 0 } } ; @@ -62,7 +62,7 @@ (*gst) -> disable ( GL_COLOR_MATERIAL ) ; (*gst) -> enable ( GL_CULL_FACE ) ; (*gst) -> setColourMaterial ( GL_AMBIENT_AND_DIFFUSE ) ; - (*gst) -> setMaterial ( GL_AMBIENT, 0.3, 0.3, 0.3, 1 ) ; + (*gst) -> setMaterial ( GL_AMBIENT, 0.3f, 0.3f, 0.3f, 1 ) ; (*gst) -> setMaterial ( GL_DIFFUSE, 1, 1, 1, 1 ) ; (*gst) -> setMaterial ( GL_EMISSION, 0, 0, 0, 1 ) ; (*gst) -> setMaterial ( GL_SPECULAR, 0, 0, 0, 1 ) ; Index: ttt3d.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/ttt3d/src/ttt3d.cxx,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- ttt3d.cxx 18 Aug 2002 00:09:46 -0000 1.4 +++ ttt3d.cxx 30 Aug 2002 14:05:59 -0000 1.5 @@ -196,7 +196,7 @@ void zoomIn () { - zoom *= 1.1 ; + zoom *= 1.1f ; if ( zoom > 160 ) zoom = 160 ; @@ -207,7 +207,7 @@ { if ( zoom < 6 ) zoom = 6 ; - zoom /= 1.1 ; + zoom /= 1.1f ; ssgSetFOV ( zoom, zoom * 3.0f/4.0f ) ; } |
From: Wolfram K. <wol...@us...> - 2002-08-30 14:02:42
|
Update of /cvsroot/plib/plib/demos/p-guide/src In directory usw-pr-cvs1:/tmp/cvs-serv10670 Modified Files: pGuide.dsp Log Message: propertieswindow, opengl, glu, glut was missing. Index: pGuide.dsp =================================================================== RCS file: /cvsroot/plib/plib/demos/p-guide/src/pGuide.dsp,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- pGuide.dsp 12 Jul 2002 03:05:18 -0000 1.3 +++ pGuide.dsp 30 Aug 2002 14:01:20 -0000 1.4 @@ -39,6 +39,7 @@ # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" +# PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c # ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c @@ -49,7 +50,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib opengl32.lib glu32.lib glut32.lib /nologo /subsystem:console /machine:I386 !ELSEIF "$(CFG)" == "pGuide - Win32 Debug" @@ -73,7 +74,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 pui_d.lib sg_d.lib fnt_d.lib ul_d.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /nodefaultlib:"LIBCMTD" /pdbtype:sept /libpath:"c:\plib" +# ADD LINK32 pui_d.lib sg_d.lib fnt_d.lib ul_d.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib opengl32.lib glu32.lib glut32.lib /nologo /subsystem:console /debug /machine:I386 /nodefaultlib:"LIBCMTD" /pdbtype:sept /libpath:"c:\plib" # SUBTRACT LINK32 /pdb:none !ENDIF @@ -92,6 +93,10 @@ # Begin Source File SOURCE=.\pGuide.cxx +# End Source File +# Begin Source File + +SOURCE=.\PropertiesWindow.cxx # End Source File # Begin Source File |
From: Wolfram K. <wol...@us...> - 2002-08-30 14:01:46
|
Update of /cvsroot/plib/plib/demos/p-guide/src In directory usw-pr-cvs1:/tmp/cvs-serv10280 Modified Files: pGuide.cxx PropertiesWindow.cxx StatusWindow.cxx WidgetWindow.cxx Log Message: Removing compiler warnings due to implicit type conversions. Index: pGuide.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/p-guide/src/pGuide.cxx,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- pGuide.cxx 18 Aug 2002 01:05:58 -0000 1.8 +++ pGuide.cxx 30 Aug 2002 14:00:17 -0000 1.9 @@ -893,7 +893,7 @@ #endif puSetDefaultStyle ( PUSTYLE_SMALL_SHADED ) ; - puSetDefaultColourScheme ( 0.8, 0.8, 0.8, 1.0 ) ; + puSetDefaultColourScheme ( 0.8f, 0.8f, 0.8f, 1.0f ) ; // Add the properties context menu context_menu = new puPopupMenu( 0, 0 ) ; Index: PropertiesWindow.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/p-guide/src/PropertiesWindow.cxx,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- PropertiesWindow.cxx 18 Aug 2002 01:05:58 -0000 1.4 +++ PropertiesWindow.cxx 30 Aug 2002 14:00:18 -0000 1.5 @@ -83,7 +83,7 @@ /* Clear the screen */ - glClearColor ( 0.1, 0.1, 0.1, 1.0 ) ; + glClearColor ( 0.1f, 0.1f, 0.1f, 1.0f ) ; glClear ( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ) ; puDisplay () ; Index: StatusWindow.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/p-guide/src/StatusWindow.cxx,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- StatusWindow.cxx 18 Aug 2002 01:05:58 -0000 1.6 +++ StatusWindow.cxx 30 Aug 2002 14:00:18 -0000 1.7 @@ -244,7 +244,7 @@ /* Clear the screen */ - glClearColor ( 0.1, 0.1, 0.1, 1.0 ) ; + glClearColor ( 0.1f, 0.1f, 0.1f, 1.0f ) ; glClear ( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ) ; puDisplay () ; @@ -261,7 +261,7 @@ /* Clear the screen */ - glClearColor ( 0.1, 0.1, 0.1, 1.0 ) ; + glClearColor ( 0.1f, 0.1f, 0.1f, 1.0f ) ; glClear ( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ) ; puDisplay () ; @@ -1018,7 +1018,7 @@ window_color_r = new puSpinBox ( 270, 285, 320, 305 ) ; window_color_r->setMinValue(0.0); window_color_r->setMaxValue(1.0); - window_color_r->setStepSize(0.05); + window_color_r->setStepSize(0.05f); window_color_r->setLabel ( "Red" ) ; window_color_r->setLabelPlace ( PUPLACE_TOP_CENTERED ) ; window_color_r->setValuator ( &main_window_color_r ) ; @@ -1027,7 +1027,7 @@ window_color_g = new puSpinBox ( 320, 285, 370, 305 ) ; window_color_g->setMinValue(0.0); window_color_g->setMaxValue(1.0); - window_color_g->setStepSize(0.05); + window_color_g->setStepSize(0.05f); window_color_g->setLabel ( "Green" ) ; window_color_g->setLabelPlace ( PUPLACE_TOP_CENTERED ) ; window_color_g->setValuator ( &main_window_color_g ) ; @@ -1036,7 +1036,7 @@ window_color_b = new puSpinBox ( 370, 285, 420, 305 ) ; window_color_b->setMinValue(0.0); window_color_b->setMaxValue(1.0); - window_color_b->setStepSize(0.05); + window_color_b->setStepSize(0.05f); window_color_b->setLabel ( "Blue" ) ; window_color_b->setLabelPlace ( PUPLACE_TOP_CENTERED ) ; window_color_b->setValuator ( &main_window_color_b ) ; @@ -1045,7 +1045,7 @@ window_color_a = new puSpinBox ( 420, 285, 470, 305 ) ; window_color_a->setMinValue(0.0); window_color_a->setMaxValue(1.0); - window_color_a->setStepSize(0.05); + window_color_a->setStepSize(0.05f); window_color_a->setLabel ( "Alpha" ) ; window_color_a->setLabelPlace ( PUPLACE_TOP_CENTERED ) ; window_color_a->setValuator ( &main_window_color_a ) ; Index: WidgetWindow.cxx =================================================================== RCS file: /cvsroot/plib/plib/demos/p-guide/src/WidgetWindow.cxx,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- WidgetWindow.cxx 18 Aug 2002 01:05:58 -0000 1.6 +++ WidgetWindow.cxx 30 Aug 2002 14:00:18 -0000 1.7 @@ -86,7 +86,7 @@ /* Clear the screen */ - glClearColor ( 0.1, 0.1, 0.1, 1.0 ) ; + glClearColor ( 0.1f, 0.1f, 0.1f, 1.0f ) ; glClear ( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ) ; puDisplay () ; |
From: Wolfram K. <wol...@us...> - 2002-08-30 13:14:20
|
Update of /cvsroot/plib/plib/examples/src/ssg/load_save In directory usw-pr-cvs1:/tmp/cvs-serv26888 Modified Files: save.dsp Log Message: glut32.lib was missing Index: save.dsp =================================================================== RCS file: /cvsroot/plib/plib/examples/src/ssg/load_save/save.dsp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- save.dsp 25 Aug 2002 15:36:45 -0000 1.13 +++ save.dsp 30 Aug 2002 13:13:23 -0000 1.14 @@ -50,7 +50,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ssg.lib sg.lib ul.lib opengl32.lib glu32.lib /nologo /subsystem:console /machine:I386 /out:"save.exe" /libpath:"..\..\..\..\..\plib" +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ssg.lib sg.lib ul.lib opengl32.lib glu32.lib glut32.lib /nologo /subsystem:console /machine:I386 /out:"save.exe" /libpath:"..\..\..\..\..\plib" !ELSEIF "$(CFG)" == "save - Win32 Debug" @@ -74,7 +74,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ssg_d.lib sg_d.lib ul_d.lib opengl32.lib glu32.lib /nologo /subsystem:console /debug /machine:I386 /out:"save.exe" /pdbtype:sept /libpath:"..\..\..\..\..\plib" +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ssg_d.lib sg_d.lib ul_d.lib opengl32.lib glu32.lib glut32.lib /nologo /subsystem:console /debug /machine:I386 /out:"save.exe" /pdbtype:sept /libpath:"..\..\..\..\..\plib" !ENDIF |
From: Wolfram K. <wol...@us...> - 2002-08-30 13:12:38
|
Update of /cvsroot/plib/plib/examples/src/ssg/water In directory usw-pr-cvs1:/tmp/cvs-serv26118 Modified Files: water.cxx Log Message: Removing compiler warnings due to implicit type conversions. Index: water.cxx =================================================================== RCS file: /cvsroot/plib/plib/examples/src/ssg/water/water.cxx,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- water.cxx 28 Aug 2002 04:58:02 -0000 1.20 +++ water.cxx 30 Aug 2002 13:11:11 -0000 1.21 @@ -602,13 +602,13 @@ float c = ((float)(rand()%100)/100.0f) * (256.0f-163.0f)/255.0f ; sgSetVec4 ( p -> col, 96.0f/255.0f+c, 147.0f/255.0f+c, 163.0f/255.0f+c, 0.5); - sgSetVec3 ( p -> pos, -2.4, -0.1, 1.9 ) ; + sgSetVec3 ( p -> pos, -2.4f, -0.1f, 1.9f ) ; sgSetVec3 ( p -> vel, -(float)(rand()%1000)/200.0f, (float)(rand()%1000 - 500)/400.0f, (float)(rand()%1000)/1000.0f + 3.0f ) ; sgAddScaledVec3 ( p -> pos, p -> vel, (float)(rand()%1000)/20000.0f ) ; - sgSetVec3 ( p -> acc, 0, 0, -9.8 ) ; + sgSetVec3 ( p -> acc, 0, 0, -9.8f ) ; p -> time_to_live = 1 ; } @@ -681,14 +681,14 @@ init_states () ; - sgVec4 TRANSLUCENT_WHITE = { 1.0, 1.0, 1.0, 0.8 } ; + sgVec4 TRANSLUCENT_WHITE = { 1.0f, 1.0f, 1.0f, 0.8f } ; sgVec3 pos = { 0, 0, 0 } ; sgCoord pedpos = { { 0, 0, -1.5 }, { 0, 0, 0 } } ; /* Create a the scene content. */ fountain = new ssgaParticleSystem ( 1000, 100, 500, TRUE, - 0.2, 1000, + 0.2f, 1000, droplet_create ) ; fountain -> setState ( splash_state ) ; @@ -775,7 +775,7 @@ puSetDefaultFonts ( *sorority, *sorority ) ; puSetDefaultStyle ( PUSTYLE_SMALL_SHADED ) ; - puSetDefaultColourScheme ( 0.2, 0.5, 0.2, 0.5 ) ; + puSetDefaultColourScheme ( 0.2f, 0.5f, 0.2f, 0.5f ) ; puGroup *window_group = new puGroup ( 0, 0 ) ; |
From: Wolfram K. <wol...@us...> - 2002-08-30 13:08:40
|
Update of /cvsroot/plib/plib/examples/src/ssg/majik In directory usw-pr-cvs1:/tmp/cvs-serv24645 Modified Files: majik_demo.cxx Log Message: Removing compiler warnings due to implicit type conversions. Index: majik_demo.cxx =================================================================== RCS file: /cvsroot/plib/plib/examples/src/ssg/majik/majik_demo.cxx,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- majik_demo.cxx 9 Sep 2001 22:35:02 -0000 1.4 +++ majik_demo.cxx 30 Aug 2002 13:07:32 -0000 1.5 @@ -217,7 +217,7 @@ Set up some fog */ - glFogf ( GL_FOG_DENSITY, 0.015 / 100.0f ) ; + glFogf ( GL_FOG_DENSITY, 0.015f / 100.0f ) ; glFogfv( GL_FOG_COLOR , fogcol ) ; glFogf ( GL_FOG_START , 0.0 ) ; glFogi ( GL_FOG_MODE , GL_EXP2 ) ; |
From: Wolfram K. <wol...@us...> - 2002-08-30 13:07:20
|
Update of /cvsroot/plib/plib/examples/src/ssg/dynamics In directory usw-pr-cvs1:/tmp/cvs-serv23952 Modified Files: dynamics.cxx Log Message: Using the same include syntax as all other files use. Now MSVC finds ssg.h. Work around the MSVC for(int i=... bug Index: dynamics.cxx =================================================================== RCS file: /cvsroot/plib/plib/examples/src/ssg/dynamics/dynamics.cxx,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- dynamics.cxx 11 Aug 2002 19:52:07 -0000 1.4 +++ dynamics.cxx 30 Aug 2002 13:05:48 -0000 1.5 @@ -143,25 +143,26 @@ -#define RESTITUTION 0.9 +#define RESTITUTION 0.9f void updateSMD ( float dt ) { - for ( int i = 0 ; i < num_particles ; i++ ) + int i; + for ( i = 0 ; i < num_particles ; i++ ) { sgVec3 friction ; - sgScaleVec3 ( friction, particle[i]->getVel (), 0.1 ) ; + sgScaleVec3 ( friction, particle[i]->getVel (), 0.1f ) ; particle [ i ] -> gravityOnly () ; particle [ i ] -> subForce ( friction ) ; } - for ( int i = 0 ; i < num_springs ; i++ ) + for ( i = 0 ; i < num_springs ; i++ ) spring [ i ] -> update () ; - for ( int i = 0 ; i < num_particles ; i++ ) + for ( i = 0 ; i < num_particles ; i++ ) { particle [ i ] -> update ( dt ) ; @@ -176,7 +177,7 @@ } } - for ( int i = 0 ; i < num_particles ; i++ ) + for ( i = 0 ; i < num_particles ; i++ ) cube [ i ] -> setTransform ( particle[i] -> getPos () ) ; } |
From: Wolfram K. <wol...@us...> - 2002-08-30 12:53:01
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv19475 Modified Files: ssgaShapes.h Log Message: Using the same include syntax as all other files use. Now MSVC finds ssg.h. Index: ssgaShapes.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaShapes.h,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- ssgaShapes.h 30 Aug 2002 03:18:46 -0000 1.12 +++ ssgaShapes.h 30 Aug 2002 12:52:03 -0000 1.13 @@ -25,7 +25,7 @@ #ifndef _SSGASHAPES_H_ #define _SSGASHAPES_H_ 1 -#include <plib/ssg.h> +#include "ssg.h" typedef float sgVec9 [ 9 ] ; /* Needed for ssgaPatch */ |
From: Wolfram K. <wol...@us...> - 2002-08-30 12:52:34
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv19312 Modified Files: ssgaFire.cxx ssgaLensFlare.cxx ssgaWaveSystem.cxx Log Message: Removing compiler warning due to implicit type conversion. Index: ssgaFire.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaFire.cxx,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- ssgaFire.cxx 28 Aug 2002 17:35:39 -0000 1.3 +++ ssgaFire.cxx 30 Aug 2002 12:51:21 -0000 1.4 @@ -43,7 +43,7 @@ if ( sizeTable [ i ] >= 1.5 ) sizeTable [ i ] = 1.5 ; sgScaleVec3 ( & colourTable [ i * 4 ], - & colourTable [ (i-1)* 4 ], 0.90 ) ; + & colourTable [ (i-1)* 4 ], 0.90f ) ; colourTable [ i * 4 + 3 ] = 1.0f ; } @@ -53,7 +53,7 @@ void ssgaFire::createParticle ( int idx, ssgaParticle *p ) { float xx = (float)(rand()%1000)/500.0f * radius - radius ; - float yy = sqrt ( radius * radius - xx * xx ) ; + float yy = (float)sqrt ( radius * radius - xx * xx ) ; yy = (float)(rand()%1000)/500.0f * yy - yy ; Index: ssgaLensFlare.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaLensFlare.cxx,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- ssgaLensFlare.cxx 24 Aug 2002 17:49:12 -0000 1.2 +++ ssgaLensFlare.cxx 30 Aug 2002 12:51:21 -0000 1.3 @@ -93,12 +93,12 @@ static float flareTexCoords [ 6 ][ 4 ][ 2 ] = { - { { 0.00, 0.50 }, { 0.25, 0.50 }, { 0.25, 1.00 }, { 0.00, 1.00 } }, - { { 0.25, 0.50 }, { 0.50, 0.50 }, { 0.50, 1.00 }, { 0.25, 1.00 } }, - { { 0.27, 0.70 }, { 0.48, 0.70 }, { 0.48, 0.80 }, { 0.27, 0.80 } }, - { { 0.50, 0.50 }, { 0.75, 0.50 }, { 0.75, 1.00 }, { 0.50, 1.00 } }, - { { 0.75, 0.50 }, { 1.00, 0.50 }, { 1.00, 1.00 }, { 0.75, 1.00 } }, - { { 0.75, 0.00 }, { 1.00, 0.00 }, { 1.00, 0.50 }, { 0.75, 0.50 } } + { { 0.00f, 0.50f }, { 0.25f, 0.50f }, { 0.25f, 1.00f }, { 0.00f, 1.00f } }, + { { 0.25f, 0.50f }, { 0.50f, 0.50f }, { 0.50f, 1.00f }, { 0.25f, 1.00f } }, + { { 0.27f, 0.70f }, { 0.48f, 0.70f }, { 0.48f, 0.80f }, { 0.27f, 0.80f } }, + { { 0.50f, 0.50f }, { 0.75f, 0.50f }, { 0.75f, 1.00f }, { 0.50f, 1.00f } }, + { { 0.75f, 0.50f }, { 1.00f, 0.50f }, { 1.00f, 1.00f }, { 0.75f, 1.00f } }, + { { 0.75f, 0.00f }, { 1.00f, 0.00f }, { 1.00f, 0.50f }, { 0.75f, 0.50f } } } ; @@ -213,9 +213,9 @@ #ifndef CONTINUOUS_DISPLAY_SURFACE vt -> getBSphere () -> setCenter ( 0, 0, 0 ) ; - vt -> getBSphere () -> setRadius ( 0.1 ) ; + vt -> getBSphere () -> setRadius ( 0.1f ) ; getBSphere () -> setCenter ( 0, 0, 0 ) ; - getBSphere () -> setRadius ( 0.1 ) ; + getBSphere () -> setRadius ( 0.1f ) ; #else vt -> recalcBSphere () ; recalcBSphere () ; Index: ssgaWaveSystem.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaWaveSystem.cxx,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- ssgaWaveSystem.cxx 11 Aug 2002 19:23:48 -0000 1.8 +++ ssgaWaveSystem.cxx 30 Aug 2002 12:51:21 -0000 1.9 @@ -54,9 +54,9 @@ { adjSpeed [num_trains] = train [ i ] -> getSpeed () * G * tim / windSpeed ; - sinHeading [num_trains] = -sin ( train[i]->getHeading () * + sinHeading [num_trains] = (float) -sin ( train[i]->getHeading () * SG_DEGREES_TO_RADIANS ) ; - cosHeading [num_trains] = cos ( train[i]->getHeading () * + cosHeading [num_trains] = (float) cos ( train[i]->getHeading () * SG_DEGREES_TO_RADIANS ) ; length [num_trains] = train [ i ] -> getLength () ; lambda [num_trains] = train [ i ] -> getLambda () ; |
From: Wolfram K. <wol...@us...> - 2002-08-30 12:51:25
|
Update of /cvsroot/plib/plib/src/ssg In directory usw-pr-cvs1:/tmp/cvs-serv18809 Modified Files: ssgVtxArray.cxx Log Message: Removing compiler warning due to implicit type conversion. Index: ssgVtxArray.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssg/ssgVtxArray.cxx,v retrieving revision 1.23 retrieving revision 1.24 diff -u -d -r1.23 -r1.24 --- ssgVtxArray.cxx 22 Jul 2002 14:31:38 -0000 1.23 +++ ssgVtxArray.cxx 30 Aug 2002 12:49:56 -0000 1.24 @@ -224,7 +224,7 @@ for(i=0; i<indices->getNum(); i++) { oldIndex = *indices->get(i); if (oldIndex2NewIndex[ oldIndex ] != -1) - indices->set(oldIndex2NewIndex[ oldIndex ], i); + indices->set((short)oldIndex2NewIndex[ oldIndex ], i); else { newIndex = newVL->getNum(); indices->set(newIndex , i); |
From: Wolfram K. <wol...@us...> - 2002-08-30 10:06:18
|
Update of /cvsroot/plib/plib/src/sg In directory usw-pr-cvs1:/tmp/cvs-serv2976 Modified Files: sg.cxx sg.h sgdIsect.cxx sgPerlinNoise.cxx Log Message: Removing compiler warnings due to double to float conversion. Index: sg.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/sg/sg.cxx,v retrieving revision 1.35 retrieving revision 1.36 diff -u -d -r1.35 -r1.36 --- sg.cxx 11 Aug 2002 14:07:09 -0000 1.35 +++ sg.cxx 30 Aug 2002 10:04:47 -0000 1.36 @@ -1786,7 +1786,7 @@ SGfloat s = lenC * lenC + lenA * lenA - SG_TWO * lenC * lenA * sgCos( angB ) ; - SGfloat lb = ( s <= SG_ZERO ) ? SG_ZERO : sqrt ( s ) ; + SGfloat lb = ( s <= SG_ZERO ) ? SG_ZERO : (SGfloat) sqrt ( s ) ; if ( lenB ) *lenB = lb ; Index: sg.h =================================================================== RCS file: /cvsroot/plib/plib/src/sg/sg.h,v retrieving revision 1.45 retrieving revision 1.46 diff -u -d -r1.45 -r1.46 --- sg.h 24 Aug 2002 23:22:13 -0000 1.45 +++ sg.h 30 Aug 2002 10:04:47 -0000 1.46 @@ -2788,7 +2788,7 @@ sgVec3 dP ; sgSubVec3 ( dP, p0->getPos(), p1->getPos() ) ; sgVec3 dV ; sgSubVec3 ( dV, p0->getVel(), p1->getVel() ) ; - float L = sgLengthVec3 ( dP ) ; if ( L == 0.0f ) L = 0.0000001 ; + float L = sgLengthVec3 ( dP ) ; if ( L == 0.0f ) L = 0.0000001f ; float H = ( L - restLength ) * stiffness ; float D = sgScalarProductVec3 ( dV, dP ) * damping / L ; Index: sgdIsect.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/sg/sgdIsect.cxx,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- sgdIsect.cxx 18 Dec 2001 04:06:04 -0000 1.1 +++ sgdIsect.cxx 30 Aug 2002 10:04:47 -0000 1.2 @@ -216,7 +216,7 @@ return FLT_MAX ; } - float s = - ( sgdScalarProductVec3 ( plane, v1 ) + plane[3] ) / p ; + float s = (float) (- ( sgdScalarProductVec3 ( plane, v1 ) + plane[3] ) / p) ; sgdScaleVec3 ( dst, delta, s ) ; sgdAddVec3 ( dst, dst, v1 ) ; Index: sgPerlinNoise.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/sg/sgPerlinNoise.cxx,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- sgPerlinNoise.cxx 25 Aug 2002 11:59:34 -0000 1.2 +++ sgPerlinNoise.cxx 30 Aug 2002 10:04:47 -0000 1.3 @@ -60,7 +60,7 @@ though -cos(x * PI) * 0.5 + 0.5 would work too */ -inline SGfloat easeCurve ( SGfloat t ) { return t * t * (3.0 - 2.0 * t) ; } +inline SGfloat easeCurve ( SGfloat t ) { return (SGfloat) (t * t * (3.0 - 2.0 * t)) ; } inline SGfloat dot2 ( SGfloat rx, SGfloat ry, sgVec2 q ) { @@ -91,7 +91,7 @@ *g0 = it & SG_PERLIN_NOISE_MOD_MASK ; *g1 = (*g0 + 1) & SG_PERLIN_NOISE_MOD_MASK ; *d0 = t - it ; - *d1 = *d0 - 1.0 ; + *d1 = *d0 - 1.0f ; } |
From: Steve B. <sj...@us...> - 2002-08-30 03:18:49
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv32614/plib/src/ssgAux Modified Files: ssgaShapes.h Log Message: Added an include for ssg.h Index: ssgaShapes.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaShapes.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- ssgaShapes.h 4 Aug 2002 05:53:44 -0000 1.11 +++ ssgaShapes.h 30 Aug 2002 03:18:46 -0000 1.12 @@ -25,6 +25,8 @@ #ifndef _SSGASHAPES_H_ #define _SSGASHAPES_H_ 1 +#include <plib/ssg.h> + typedef float sgVec9 [ 9 ] ; /* Needed for ssgaPatch */ class ssgaShape : public ssgBranch |
From: Sebastian U. <ud...@us...> - 2002-08-28 17:35:44
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv22582 Modified Files: ssgaFire.cxx Log Message: Fix by Erik Hofman Index: ssgaFire.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaFire.cxx,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- ssgaFire.cxx 28 Aug 2002 04:58:03 -0000 1.2 +++ ssgaFire.cxx 28 Aug 2002 17:35:39 -0000 1.3 @@ -117,9 +117,9 @@ } ssgaFire::ssgaFire ( int num, - float _radius = 1.0f, - float height = 5.0f, - float speed = 2.0f ) + float _radius, + float height, + float speed ) : ssgaParticleSystem ( num/2, 0, 0, // <== Don't Change this!! TRUE, 1.0f, height * 2.0f, |
From: Sebastian U. <ud...@us...> - 2002-08-28 12:41:44
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv2391 Modified Files: ssgAux.dsp Log Message: Added ssgaFire Index: ssgAux.dsp =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgAux.dsp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- ssgAux.dsp 25 Aug 2002 12:14:34 -0000 1.15 +++ ssgAux.dsp 28 Aug 2002 12:41:39 -0000 1.16 @@ -54,7 +54,7 @@ # Begin Special Build Tool SOURCE="$(InputPath)" PostBuild_Desc=Copy Library to plib directory -PostBuild_Cmds=copy release\*.lib ..\..\*.* copy ssgAux.h ..\..\ssgAux.h copy ssgaLensFlare.h ..\..\ssgaLensFlare.h copy ssgaParticleSystem.h ..\..\ssgaParticleSystem.h copy ssgaShapes.h ..\..\ssgaShapes.h copy ssgaWaveSystem.h ..\..\ssgaWaveSystem.h +PostBuild_Cmds=copy release\*.lib ..\..\*.* copy ssgAux.h ..\..\ssgAux.h copy ssgaFire.h ..\..\ssgaFire.h copy ssgaLensFlare.h ..\..\ssgaLensFlare.h copy ssgaParticleSystem.h ..\..\ssgaParticleSystem.h copy ssgaShapes.h ..\..\ssgaShapes.h copy ssgaWaveSystem.h ..\..\ssgaWaveSystem.h # End Special Build Tool !ELSEIF "$(CFG)" == "ssgAux - Win32 Debug" @@ -83,7 +83,7 @@ # Begin Special Build Tool SOURCE="$(InputPath)" PostBuild_Desc=Copy Library to plib directory -PostBuild_Cmds=copy debug\*.lib ..\..\*.* copy ssgAux.h ..\..\ssgAux.h copy ssgaLensFlare.h ..\..\ssgaLensFlare.h copy ssgaParticleSystem.h ..\..\ssgaParticleSystem.h copy ssgaShapes.h ..\..\ssgaShapes.h copy ssgaWaveSystem.h ..\..\ssgaWaveSystem.h +PostBuild_Cmds=copy debug\*.lib ..\..\*.* copy ssgAux.h ..\..\ssgAux.h copy ssgaFire.h ..\..\ssgaFire.h copy ssgaLensFlare.h ..\..\ssgaLensFlare.h copy ssgaParticleSystem.h ..\..\ssgaParticleSystem.h copy ssgaShapes.h ..\..\ssgaShapes.h copy ssgaWaveSystem.h ..\..\ssgaWaveSystem.h # End Special Build Tool !ENDIF @@ -97,6 +97,10 @@ # PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" # Begin Source File +SOURCE=.\ssgaFire.cxx +# End Source File +# Begin Source File + SOURCE=.\ssgaLensFlare.cxx # End Source File # Begin Source File @@ -131,6 +135,10 @@ # Begin Group "Header Files" # PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\ssgaFire.h +# End Source File # Begin Source File SOURCE=.\ssgaLensFlare.h |
From: Steve B. <sj...@us...> - 2002-08-28 05:09:47
|
Update of /cvsroot/plib/plib/doc/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv30268/plib/doc/ssgAux Modified Files: index.html Log Message: Added documentation for ssgaFire. Index: index.html =================================================================== RCS file: /cvsroot/plib/plib/doc/ssgAux/index.html,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- index.html 27 Aug 2002 22:29:20 -0000 1.10 +++ index.html 28 Aug 2002 05:09:44 -0000 1.11 @@ -35,6 +35,7 @@ <li><A HREF="#ssgaCylinder">ssgaCylinder - Makes a Cylinder.</A> <li><A HREF="#ssgaWaveSystem">ssgaWaveSystem - Simulates Water Waves</A> <li><A HREF="#ssgaParticleSystem">ssgaParticleSystem - Implements a spray of particles</A> +<li><A HREF="#ssgaFire">ssgaFire - Simulates Fire</A> <li><A HREF="#ssgaLensFlare">ssgaLensFlare - Simulates Lens Flare for drawing bright lights.</A> </ul> </TD> @@ -523,6 +524,54 @@ applied instead of the droplet texture - it was absolutely hilarious to see 2000 tiny penguins shooting up in a fountain and falling gently to earth! +<A NAME="ssgaFire"></A> +<H1>ssgaFire</H1> +This class is actually a highly specialised particle system. +You have to construct it quite carefully in order to get a nice +looking fire: +<pre> + + class ssgaFire : public ssgaParticleSystem + { + ssgaFire ( int num_tris, + float radius = 1.0f, + float height = 5.0f, + float speed = 2.0f ) ; + + virtual ~ssgaFire () ; + + virtual void update ( float t ) ; + + void setUpwardSpeed ( float spd ) + void setHeight ( float hgt ) + void setRadius ( float rad ) + void setHotColour ( sgVec4 col ) + } ; + +</pre> +In the constructor, you set the number of triangles you wish to +generate, the radius and height of the approximately cylindrical +fire and the speed at which the flames head up towards the sky. +<p> +The number of polygons you use tends to be rather critical - too +many and your fire will look too 'smooth' and will be mostly +white-hot. Too few and it'll look like a number of detached +reddish blobs floating upwards. For the default radius, between +100 and 200 triangles seems to look good - for a 10 meter patch +of fire, you may need as many as 2000 triangles to make it look +effective. All three parameters (speed, height and radius) can +be manipulated in realtime - but since the number of polygons +is fixed, there is a limit to the amount of realtime tweaking +you can do without making it look silly. +<p> +The 'setHotColour' function allows you to set the colour +of the hottest flames (at the base of the fire). Since many +layers of polygons add up to form the colour, you'll tend to +want to use a primary colour with about 10% of one or two of +the other primaries. The default colour is (1.0, 0.2, 0.1, 1.0) +which produces red flames with yellow and white in the hotter +regions. +<p> <A NAME="ssgaLensFlare"></A> <H1>ssgaLensFlare</H1> When you view the sun (or some other very bright light source) through |
From: Steve B. <sj...@us...> - 2002-08-28 04:58:06
|
Update of /cvsroot/plib/plib/examples/src/ssg/water In directory usw-pr-cvs1:/tmp/cvs-serv26519/plib/examples/src/ssg/water Modified Files: water.cxx Log Message: Added much tweakability and ease-of-setup to ssgaFire. Index: water.cxx =================================================================== RCS file: /cvsroot/plib/plib/examples/src/ssg/water/water.cxx,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- water.cxx 28 Aug 2002 00:14:33 -0000 1.19 +++ water.cxx 28 Aug 2002 04:58:02 -0000 1.20 @@ -455,7 +455,7 @@ sgSetCoord ( & tptpos, 0.0f, 0.0f, 0.6f, t * 60, 0.0f, 0.0f ) ; ssgSetCamera ( & campos ) ; teapot -> setTransform ( & tptpos ) ; - sgSetCoord ( & tptpos, 0.0f, 0.0f, 2.0f, 0.0f, 0.0f, 0.0f ) ; + sgSetCoord ( & tptpos, 0.0f, 0.0f, 3.0f, 0.0f, 0.0f, 0.0f ) ; fire -> setTransform ( & tptpos ) ; } @@ -734,7 +734,7 @@ tpt_obj -> setKidState ( teapot_state ) ; tpt_obj -> regenerate () ; - fire_obj = new ssgaFire ( 300, 1, 60.0f, 100000.0f ) ; + fire_obj = new ssgaFire ( 200 ) ; /* Build the scene graph */ |
From: Steve B. <sj...@us...> - 2002-08-28 04:58:06
|
Update of /cvsroot/plib/plib/src/ssgAux In directory usw-pr-cvs1:/tmp/cvs-serv26519/plib/src/ssgAux Modified Files: ssgaFire.cxx ssgaFire.h ssgaParticleSystem.cxx ssgaParticleSystem.h Log Message: Added much tweakability and ease-of-setup to ssgaFire. Index: ssgaFire.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaFire.cxx,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ssgaFire.cxx 28 Aug 2002 00:14:34 -0000 1.1 +++ ssgaFire.cxx 28 Aug 2002 04:58:03 -0000 1.2 @@ -2,30 +2,101 @@ #include "ssg.h" #include "ssgAux.h" +#define EMBER_SCALE 3.0f + void _ssgaFireParticleCreate ( ssgaParticleSystem *ps, - int index, - ssgaParticle *p ) + int idx, ssgaParticle *p ) { - sgSetVec4 ( p -> col, 1.0f, 0.2f, 0.06f, 0.3 ) ; [...154 lines suppressed...] + colourTable = NULL ; + sizeTable = NULL ; + + sgSetVec4 ( hot_colour, 1.0f, 0.2f, 0.1f, 1.0f ) ; + + setHeight ( height ) ; /* Forces a reInit */ + setState ( fireState ) ; setCallback ( SSG_CALLBACK_PREDRAW , preFireDraw ) ; setCallback ( SSG_CALLBACK_POSTDRAW, postFireDraw ) ; @@ -94,6 +176,9 @@ ssgaFire::~ssgaFire () { + tableSize = 0 ; + delete [] colourTable ; + delete [] sizeTable ; } Index: ssgaFire.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaFire.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ssgaFire.h 28 Aug 2002 00:14:34 -0000 1.1 +++ ssgaFire.h 28 Aug 2002 04:58:03 -0000 1.2 @@ -4,16 +4,52 @@ class ssgaFire : public ssgaParticleSystem { + int tableSize ; + float *colourTable ; + float *sizeTable ; + + sgVec4 hot_colour ; + float max_ttl ; + float start_size ; + float upward_speed ; + float radius ; + + void reInit () ; + public: - ssgaFire ( int num, - int initial_num, - float _create_rate, - float bsphere_size ) ; + void createParticle ( int idx, ssgaParticle *p ) ; + void updateParticle ( int idx, ssgaParticle *p ) ; + + ssgaFire ( int num_tris, float _radius = 1.0f, + float height = 5.0f, + float speed = 2.0f ) ; virtual ~ssgaFire () ; virtual void update ( float t ) ; + + void setUpwardSpeed ( float spd ) + { + upward_speed = spd ; + } + + void setHeight ( float hgt ) + { + max_ttl = hgt / upward_speed ; + getBSphere () -> setRadius ( hgt * 2.0f ) ; + getBSphere () -> setCenter ( 0, 0, 0 ) ; + reInit () ; + } + + void setHotColour ( sgVec4 col ) + { + sgCopyVec4 ( hot_colour, col ) ; + reInit () ; + } + + void getHotColour ( sgVec4 col ) { sgCopyVec4 ( col, hot_colour ) ; } + } ; unsigned char *_ssgaGetFireTexture () ; Index: ssgaParticleSystem.cxx =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaParticleSystem.cxx,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- ssgaParticleSystem.cxx 28 Aug 2002 00:14:34 -0000 1.7 +++ ssgaParticleSystem.cxx 28 Aug 2002 04:58:03 -0000 1.8 @@ -7,12 +7,11 @@ ssgaParticleCreateFunc _particle_create, ssgaParticleUpdateFunc _particle_update, ssgaParticleDeleteFunc _particle_delete ) : - ssgVtxArray ( GL_QUADS, + ssgVtxTable ( GL_QUADS, new ssgVertexArray ( num * 4, new sgVec3 [ num * 4 ] ), new ssgNormalArray ( num * 4, new sgVec3 [ num * 4 ] ), new ssgTexCoordArray ( num * 4, new sgVec2 [ num * 4 ] ), - new ssgColourArray ( num * 4, new sgVec4 [ num * 4 ] ), - new ssgIndexArray ( num * 4, new short [ num * 4 ] ) ) + new ssgColourArray ( num * 4, new sgVec4 [ num * 4 ] ) ) [...82 lines suppressed...] - (*particle_update) ( t, this, i, & particle [ i ] ) ; + if ( particle [ i ] . time_to_live > 0.0f ) + { + particle [ i ] . update ( t ) ; + (*particle_update) ( t, this, i, & particle [ i ] ) ; + } + } + else + for ( i = 0 ; i < num_particles ; i++ ) + if ( particle [ i ] . time_to_live > 0.0f ) + particle [ i ] . update ( t ) ; /* Check for death of particles */ for ( i = 0 ; i < num_particles ; i++ ) - if ( particle [ i ] . time_to_live < 0.0 ) + if ( particle [ i ] . time_to_live <= 0.0 ) { if ( particle_delete ) (*particle_delete) ( this, i, & particle [ i ] ) ; Index: ssgaParticleSystem.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssgAux/ssgaParticleSystem.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- ssgaParticleSystem.h 27 Aug 2002 22:40:11 -0000 1.4 +++ ssgaParticleSystem.h 28 Aug 2002 04:58:03 -0000 1.5 @@ -50,7 +50,7 @@ int index, ssgaParticle *p ) ; -class ssgaParticleSystem : public ssgVtxArray +class ssgaParticleSystem : public ssgVtxTable { int num_particles ; int num_verts ; @@ -84,8 +84,11 @@ void draw_geometry () ; - int getNumActiveParticles () { return num_active ; } + void setCreationRate ( float cr ) { create_rate = cr ; } + float getCreationRate () { return create_rate ; } + int getNumParticles () { return num_particles ; } + int getNumActiveParticles () { return num_active ; } } ; |
From: Steve B. <sj...@us...> - 2002-08-28 04:58:06
|
Update of /cvsroot/plib/plib/src/ssg In directory usw-pr-cvs1:/tmp/cvs-serv26519/plib/src/ssg Modified Files: ssg.h Log Message: Added much tweakability and ease-of-setup to ssgaFire. Index: ssg.h =================================================================== RCS file: /cvsroot/plib/plib/src/ssg/ssg.h,v retrieving revision 1.142 retrieving revision 1.143 diff -u -d -r1.142 -r1.143 --- ssg.h 4 Aug 2002 05:53:44 -0000 1.142 +++ ssg.h 28 Aug 2002 04:58:03 -0000 1.143 @@ -443,6 +443,11 @@ int getSizeOf (void) { return size_of ; } int getNum (void) { return total ; } + void rawSetNum ( unsigned int n ) /* Better know what you're doing!! */ + { + total = n ; + } + void setNum ( unsigned int n ) { if ( total < n ) @@ -1413,6 +1418,9 @@ int getNumNormals () { return normals -> getNum () ; } int getNumColours () { return colours -> getNum () ; } int getNumTexCoords () { return texcoords -> getNum () ; } + + /* Don't call this unless you know what you are doing!! */ + void rawSetNumVertices ( unsigned int n ) { vertices -> rawSetNum ( n ) ; } int getNumTriangles () ; void getTriangle ( int n, short *v1, short *v2, short *v3 ) ; |