From: Bertrand <bco...@us...> - 2017-02-25 14:23:22
|
Update of /cvsroot/jsbsim/JSBSim/src In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv24758/src Modified Files: CMakeLists.txt FGFDMExec.cpp FGFDMExec.h JSBSim.cpp Log Message: JSBSim now uses SGPath to manage file names. It allows to use absolute paths, to use Unicode file names and to benefit from SimGear maintenance for the corresponding code. Index: CMakeLists.txt =================================================================== RCS file: /cvsroot/jsbsim/JSBSim/src/CMakeLists.txt,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -r1.11 -r1.12 *** CMakeLists.txt 22 Mar 2015 12:24:48 -0000 1.11 --- CMakeLists.txt 25 Feb 2017 14:23:18 -0000 1.12 *************** *** 6,10 **** if(MSVC) ! add_definitions("/D _USE_MATH_DEFINES") endif() --- 6,10 ---- if(MSVC) ! add_definitions("/D _USE_MATH_DEFINES /D NOMINMAX") endif() *************** *** 82,85 **** --- 82,87 ---- ${JSBSIM_SIMGEAR_XML_HDR} ${JSBSIM_SIMGEAR_XML_SRC} ${JSBSIM_SIMGEAR_MAGVAR_HDR} ${JSBSIM_SIMGEAR_MAGVAR_SRC} + ${JSBSIM_SIMGEAR_MISC_HDR} ${JSBSIM_SIMGEAR_MISC_SRC} + ${JSBSIM_SIMGEAR_IOSTREAMS_HDR} ${JSBSIM_SIMGEAR_IOSTREAMS_SRC} ) Index: FGFDMExec.cpp =================================================================== RCS file: /cvsroot/jsbsim/JSBSim/src/FGFDMExec.cpp,v retrieving revision 1.192 retrieving revision 1.193 diff -C2 -r1.192 -r1.193 *** FGFDMExec.cpp 22 Jan 2017 09:46:48 -0000 1.192 --- FGFDMExec.cpp 25 Feb 2017 14:23:18 -0000 1.193 *************** *** 651,660 **** //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ! bool FGFDMExec::LoadScript(const string& script, double deltaT, const string& initfile) { bool result; Script = new FGScript(this); ! result = Script->LoadScript(RootDir + script, deltaT, initfile); return result; --- 651,661 ---- //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ! bool FGFDMExec::LoadScript(const SGPath& script, double deltaT, ! const SGPath& initfile) { bool result; Script = new FGScript(this); ! result = Script->LoadScript(GetFullPath(script), deltaT, initfile); return result; *************** *** 663,672 **** //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ! bool FGFDMExec::LoadModel(const string& AircraftPath, const string& EnginePath, const string& SystemsPath, ! const string& model, bool addModelToPath) ! { ! FGFDMExec::AircraftPath = RootDir + AircraftPath; ! FGFDMExec::EnginePath = RootDir + EnginePath; ! FGFDMExec::SystemsPath = RootDir + SystemsPath; return LoadModel(model, addModelToPath); --- 664,674 ---- //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ! bool FGFDMExec::LoadModel(const SGPath& AircraftPath, const SGPath& EnginePath, ! const SGPath& SystemsPath, const string& model, ! bool addModelToPath) ! { ! FGFDMExec::AircraftPath = GetFullPath(AircraftPath); ! FGFDMExec::EnginePath = GetFullPath(EnginePath); ! FGFDMExec::SystemsPath = GetFullPath(SystemsPath); return LoadModel(model, addModelToPath); *************** *** 677,686 **** bool FGFDMExec::LoadModel(const string& model, bool addModelToPath) { ! string aircraftCfgFileName; bool result = false; // initialize result to false, indicating input file not yet read modelName = model; // Set the class modelName attribute ! if( AircraftPath.empty() || EnginePath.empty() || SystemsPath.empty()) { cerr << "Error: attempted to load aircraft with undefined "; cerr << "aircraft, engine, and system paths" << endl; --- 679,688 ---- bool FGFDMExec::LoadModel(const string& model, bool addModelToPath) { ! SGPath aircraftCfgFil |