Update of /cvsroot/csp/APPLICATIONS/CSPFlightSim/Source In directory sc8-pr-cvs1:/tmp/cvs-serv1608/Source Modified Files: BaseObject.cpp Platform.cpp VirtualBattlefield.cpp sky.cpp Added Files: Makefile.am Makefile.orig Removed Files: Makefile Log Message: very minor fixes initial autoconf/automake support for linux --- NEW FILE: Makefile.am --- # WARNING: # I have almost no prior experience with GNU autoconf/automake and this # is very much a work in progress. The original Makefile for Linux can # be found in Source/Makefile.orig. If you have trouble with building # CSPFlightSim with this configure script or autmake files, and know # how to fix them, please do so and commit the changes to CVS. Thanks! # # -OS bin_PROGRAMS = CSPFlightSim CSPFlightSim_SOURCES = \ AAAController.cpp \ AAAObject.cpp \ AeroParam.cpp \ AeroParamSymbol.cpp \ AIAirplaneController.cpp \ AirplaneController.cpp \ AirplaneInput.cpp \ AirplaneObject.cpp \ AirplanePhysics.cpp \ BaseController.cpp \ base.cpp \ BaseObject.cpp \ BaseSymbol.cpp \ CockpitDrawable.cpp \ Config.cpp \ ConsoleCommands.cpp \ CSPFlightSim.cpp \ DirVectorDrawable.cpp \ GameScreen.cpp \ GlobalCommands.cpp \ global.cpp \ Hud.cpp \ HudElement.cpp \ HudGeometricElement.cpp \ HudTextElement.cpp \ LogoScreen.cpp \ logstream.cpp \ main.cpp \ MenuScreen.cpp \ Message.cpp \ MessageQueue.cpp \ MissileController.cpp \ MissileObject.cpp \ mmgr.cpp \ ObjectFactory.cpp \ ObjectRangeInfo.cpp \ ObjectSymbol.cpp \ ObjectTypeSymbol.cpp \ ParticleObject.cpp \ Platform.cpp \ ProjectileController.cpp \ ProjectileObject.cpp \ SimTime.cpp \ sky.cpp \ StaticObject.cpp \ stdinc.cpp \ SymbolTable.cpp \ TankController.cpp \ TankObject.cpp \ TerrainObject.cpp \ TerrainSymbol.cpp \ Tools.cpp \ trees.cpp \ TypesMath.cpp \ TypesMatrix3.cpp \ TypesMatrix4.cpp \ TypesQuaternion.cpp \ TypesVector3.cpp \ TypesVector4.cpp \ VirtualBattlefield.cpp \ VirtualBattlefieldScene.cpp # You should not need to edit anything below here. OSG_INCLUDES=$(OSG_PREFIX)/include DEMETER_INCLUDES=$(DEMETER_PREFIX) DEMETER_LIB_PREFIX=$(DEMETER_PREFIX) DEMETER_LIBS=-L$(DEMETER_LIB_PREFIX) -ldemeter_csp CSPFlightSim_LDADD = $(DEMETER_LIBS) AM_CPPFLAGS=-I@top_srcdir@/Include -I$(DEMETER_INCLUDES) -I$(OSG_INCLUDES) @SDL_FLAGS@ @GDAL_FLAGS@ CXXFLAGS=-g #-Wall #CFLAGS+=-funroll-loops # -fomit-frame-pointer # not stable? #CFLAGS+=-march=pentiumpro -mcpu=pentiumpro # not stable? #CFLAGS+=-Wno-missing-braces -Wno-multichar -fsigned-char --- NEW FILE: Makefile.orig --- # Makefile for CSPFlightSim # Clement Bourdarias <phn...@ic...> # last changed on Sunday, November 17th. # Edit these lines to match your system configuration CC=g++ OSG_PREFIX=/usr/local GDAL_PREFIX=/usr/local DEMETER_DIR=../../../THIRDPARTYLIBS/demeter # nothing should be edited below this line CSP_BINARY=CSPFlightSim OSG_INCLUDES_PREFIX=$(OSG_PREFIX)/include OSG_LIB_PREFIX=$(OSG_PREFIX)/lib OSG_LIB=-losg -losgGLUT -losgParticle -losgText -losgUtil GDAL_LIB_PREFIX=$(GDAL_PREFIX)/lib GDAL_LIB=-lgdal.1.1 DEMETER_INCLUDES=$(DEMETER_DIR) DEMETER_LIB=-ldemeter_csp # if we want to statically link demeter #DEMETER_OBJ=$(DEMETER_INCLUDES)/demeter_csp.a LDFLAGS=$(shell sdl-config --libs) -lSDL_image -lSDL_console LDFLAGS+=-L$(DEMETER_DIR) $(DEMETER_LIB) LDFLAGS+=-L$(OSG_LIB_PREFIX) $(OSG_LIB) LDFLAGS+=-L$(GDAL_LIB_PREFIX) $(GDAL_LIB) CFLAGS=-Wall -g $(shell sdl-config --cflags) -I../Include/ -I$(DEMETER_INCLUDES) -I$(OSG_INCLUDES_PREFIX) CFLAGS+=-w # get rid of warnings at the moment #CFLAGS+=-funroll-loops # -fomit-frame-pointer # not stable? #CFLAGS+=-march=pentiumpro -mcpu=pentiumpro # not stable? #CFLAGS+=-Wno-missing-braces -Wno-multichar -fsigned-char %.o: %.cpp $(CC) -c -o $@ $< $(CFLAGS) CSP_SOURCES = ./AAAController.cpp \ ./AAAObject.cpp \ ./AeroParam.cpp \ ./AeroParamSymbol.cpp \ ./AIAirplaneController.cpp \ ./AirplaneController.cpp \ ./AirplaneInput.cpp \ ./AirplaneObject.cpp \ ./AirplanePhysics.cpp \ ./BaseController.cpp \ ./base.cpp \ ./BaseObject.cpp \ ./BaseSymbol.cpp \ ./CockpitDrawable.cpp \ ./Config.cpp \ ./ConsoleCommands.cpp \ ./CSPFlightSim.cpp \ ./DirVectorDrawable.cpp \ ./GameScreen.cpp \ ./GlobalCommands.cpp \ ./global.cpp \ ./Hud.cpp \ ./HudElement.cpp \ ./HudGeometricElement.cpp \ ./HudTextElement.cpp \ ./LogoScreen.cpp \ ./logstream.cpp \ ./main.cpp \ ./MenuScreen.cpp \ ./Message.cpp \ ./MessageQueue.cpp \ ./MissileController.cpp \ ./MissileObject.cpp \ ./mmgr.cpp \ ./ObjectFactory.cpp \ ./ObjectRangeInfo.cpp \ ./ObjectSymbol.cpp \ ./ObjectTypeSymbol.cpp \ ./ParticleObject.cpp \ ./Platform.cpp \ ./ProjectileController.cpp \ ./ProjectileObject.cpp \ ./SimTime.cpp \ ./sky.cpp \ ./StaticObject.cpp \ ./stdinc.cpp \ ./SymbolTable.cpp \ ./TankController.cpp \ ./TankObject.cpp \ ./TerrainObject.cpp \ ./TerrainSymbol.cpp \ ./Tools.cpp \ ./trees.cpp \ ./TypesMath.cpp \ ./TypesMatrix3.cpp \ ./TypesMatrix4.cpp \ ./TypesQuaternion.cpp \ ./TypesVector3.cpp \ ./TypesVector4.cpp \ ./VirtualBattlefield.cpp \ ./VirtualBattlefieldScene.cpp \ CSP_OBJECTS=$(CSP_SOURCES:.cpp=.o) all: $(CSP_BINARY) $(CSP_BINARY): $(CSP_OBJECTS) rm -rf $(CSP_BINARY) $(CC) -o $(CSP_BINARY) $(CSP_OBJECTS) $(LDFLAGS) clean: rm -rf $(CSP_BINARY) $(CSP_OBJECTS) install: # soon. Index: BaseObject.cpp =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/CSPFlightSim/Source/BaseObject.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** BaseObject.cpp 14 Dec 2002 18:54:13 -0000 1.5 --- BaseObject.cpp 15 Dec 2002 00:48:45 -0000 1.6 *************** *** 182,187 **** m_GlobalPosition.y = y; ! m_XLatticePos = x / g_LatticeXDist; ! m_YLatticePos = y / g_LatticeYDist; m_LocalPosition.x = m_GlobalPosition.x - g_LatticeXDist*m_XLatticePos; --- 182,187 ---- m_GlobalPosition.y = y; ! m_XLatticePos = (int) (x / g_LatticeXDist); ! m_YLatticePos = (int) (y / g_LatticeYDist); m_LocalPosition.x = m_GlobalPosition.x - g_LatticeXDist*m_XLatticePos; *************** *** 358,365 **** float r = s.radius(); osg::Vec3 c = s.center(); osg::Vec3Array* pl = osgNew osg::Vec3Array; ! for (unsigned short i = 0; i<10; ++i) pl->push_back(osg::Vec3(0.0,-(0.8+i/20.0) * r,0.0)); --- 358,366 ---- float r = s.radius(); osg::Vec3 c = s.center(); + unsigned short i; osg::Vec3Array* pl = osgNew osg::Vec3Array; ! for (i = 0; i<10; ++i) pl->push_back(osg::Vec3(0.0,-(0.8+i/20.0) * r,0.0)); Index: Platform.cpp =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/CSPFlightSim/Source/Platform.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Platform.cpp 14 Dec 2002 18:51:30 -0000 1.2 --- Platform.cpp 15 Dec 2002 00:48:45 -0000 1.3 *************** *** 142,146 **** char *idx = str; for (; *idx; idx++) { ! if (*idx == '/') *idx = '\\'; } result = str; --- 142,146 ---- char *idx = str; for (; *idx; idx++) { ! if (*idx == search) *idx = replace; } result = str; Index: VirtualBattlefield.cpp =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/CSPFlightSim/Source/VirtualBattlefield.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** VirtualBattlefield.cpp 14 Dec 2002 18:58:21 -0000 1.5 --- VirtualBattlefield.cpp 15 Dec 2002 00:48:45 -0000 1.6 *************** *** 154,158 **** osg::ClearNode* earthSky = osgNew osg::ClearNode; ! earthSky->setRequiresClear(false); // we've got base and sky to do it. // use a transform to make the sky and base around with the eye point. --- 154,159 ---- osg::ClearNode* earthSky = osgNew osg::ClearNode; ! earthSky->setRequiresClear(false); // we've got base and sky to do it. ! //earthSky->setRequiresClear(true); // we've got base and sky to do it. // use a transform to make the sky and base around with the eye point. Index: sky.cpp =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/CSPFlightSim/Source/sky.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** sky.cpp 12 Dec 2002 21:13:45 -0000 1.3 --- sky.cpp 15 Dec 2002 00:48:45 -0000 1.4 *************** *** 190,194 **** pLight->setDirection( osg::Vec3(0,0,-1) ); ! pLight->setAmbient( osg::Vec4(0.2f,0.2f,0.2f,1.0f) ); pLight->setDiffuse( osg::Vec4(0.8f,0.8f,0.8f,1.0f) ); pLight->setSpecular( osg::Vec4(0.75f,0.75f,0.75f,1.0f) ); --- 190,195 ---- pLight->setDirection( osg::Vec3(0,0,-1) ); ! //pLight->setAmbient( osg::Vec4(0.2f,0.2f,0.2f,1.0f) ); ! pLight->setAmbient( osg::Vec4(0.4f,0.4f,0.4f,1.0f) ); pLight->setDiffuse( osg::Vec4(0.8f,0.8f,0.8f,1.0f) ); pLight->setSpecular( osg::Vec4(0.75f,0.75f,0.75f,1.0f) ); --- Makefile DELETED --- |