Commit Graph
292 Commits
Author SHA1 Message Date
James Turner 04a47dfb8d Use mkdtemp where available, avoiding linker warnings about dangerous tempnam 2011-10-15 02:06:35 +01:00
James Turner 086a30e61a Add default constructor to simgear::Dir 2011-10-14 19:28:21 +01:00
James Turner 3397066343 One more Linux compile fix. 2011-08-31 07:26:11 -07:00
James Turner d1d8c68bf1 Missing include on Linux 2011-10-14 12:05:31 +01:00
James Turner d37bf8a4ae SGPath/Dir extensions to ease file handling in TerraGear. Also a unit-test, shocking. 2011-10-14 11:37:36 +01:00
ThorstenB ee06c12374 Fix sg_dir dot-file handling
File dialogs never showed ".." directories for navigation, since these were
filtered by the "INCLUDE_HIDDEN" option. Only the "NO_DOT_OR_DOTDOT"
option should be used for filtering - otherwise it's impossible to show
the "."/".." directories while all other files are still hidden.
2011-08-21 14:31:08 +02:00
James Turner 115531e944 Further HTTP improvements, correct proxy support, spec compliance, support for chunked encoding. 2011-08-04 18:03:56 +01:00
James Turner f06f25532c Tiny HTTP client layer on top of NetChat - and CTest support for some SimGear tests. 2011-07-19 12:55:55 +01:00
Torsten Dreyer d36170879c Terrasync: make whitespace in pathnames work under windows 2011-06-25 00:04:44 +02:00
Torsten Dreyer a079870bca Add strutils::starts_with and strutils::ends_with 2011-02-20 15:29:06 +01:00
James Turner b9a34b1b05 Initial work on CMake support for SimGear. 2010-12-19 14:16:39 +00:00
James Turner 56c520f455 Tighten up name filters on Unix. Fixes bug 168. 2010-11-15 23:23:40 +00:00
ThorstenB 9f88b077ee remove old .cvsignore files
Hello GIT!
2010-11-14 15:09:36 +01:00
James Turner fe628e44e1 Add platform defines to SimGear, and a replacement for ulSleep functions. 2010-10-30 19:18:57 +01:00
Frederic Bouvier d314b6a552 Fix line endings 2010-10-29 19:47:44 +02:00
Frederic Bouvier 02462d1752 Quick hack to remote trailing / on Windows. Feel free to replace by something more elegant 2010-10-29 09:30:59 +02:00
Torsten Dreyer 0994ffc195 Don't crash in strutils::trim() with empty strings 2010-10-05 22:39:41 +02:00
James Turner 289e768ca5 Add ResourceManager, and use to find sound and model paths. 2010-09-06 09:09:58 +01:00
Frederic Bouvier 510543e14b Add a convenience constructeur to SGPath 2010-08-22 09:33:56 +02:00
Frederic Bouvier c3133f020d std::string::c_str() is const 2010-08-21 09:02:12 +02:00
James Turner d7bea0c4c6 Add isAbsolute/isRelative predicates to SGPath. 2010-08-14 22:51:01 +01:00
Torsten Dreyer c0e20ad56b add padding function lpad and rpad to strutils 2010-08-12 13:02:16 +02:00
James Turner cc435ba817 Fix Win32 build of SGPath. 2010-08-09 09:13:28 +01:00
James Turner c4b4c0ce59 Make SGPath cache stat() information, cheers Fred
* cache exists/isDir/isFile in SGPath, to avoid
  repeated calls.
2010-08-09 08:19:14 +01:00
James Turner aa859c488f Remove deprecated vector classes - finally! 2010-07-30 00:46:30 +01:00
James Turner 959f44502b Fix simgear::Dir::children on Linux where dirent->d_type might be 0; always use stat() to determine file type. Thanks to Alex Romonsan for helping debugging this! 2010-07-24 10:27:50 +01:00
James Turner bbd61977f1 Change SGPath::exists to use stat(), fix '.' and '..' handling on Windows, add simgear::Dir version of exists(). 2010-07-23 07:54:10 +01:00
James Turner 63cbd4deb0 On Unix, check for symlinks from readdir(), and look through them (using stat()) to discern target type. 2010-07-21 22:08:06 +01:00
James Turner 3117ec5a7d Fix simgear::Dir compilation on some Unix setups, thanks Anders. 2010-07-16 08:40:07 +01:00
James Turner cb4716f403 Initial work on simgear::Dir, replacement for PLIB ulDir functions. 2010-07-15 09:40:46 +01:00
fredb 3dcffc7df8 MINGW patch from Benoît Laniel 2010-01-25 14:35:45 +01:00
Tim Moore b1c49045a8 forward declare Point3D in sg_types.hxx
This avoids sucking in SGMath.hxx -- and therefore a bunch of OSG headers --
into many compilation units.
2009-10-18 12:11:13 +02:00
Tim Moore 64756d14d0 Back out convertToLowerCase function
It brought in an OSG dependency; we'll just use boost::to_lower_copy instead.
2009-10-01 00:31:36 +02:00
jmt dfe41ad984 Extend simgear::strutils with convertToLowerCase helper - currently a proxy for osgDB helper of the same name. 2009-09-28 23:50:08 +02:00
torsten 6aa459073e don't build tabbed_value_test, swap_test, openal_test1 and openal_test2 by default. 2009-08-23 21:37:03 +02:00
fredb 7e7d877874 Fix case typo 2009-07-27 23:47:15 +02:00
fredb efa2876e29 Compile latest SimGear under MSVC9 2009-07-27 23:47:15 +02:00
mfranz f91d96b51a - fix one broken #include path (in a not usually compiled test app)
- turn four #include paths from the "foo" form to <foo>

The quotes form is normally only used for headers with path relative
to the including file's path, though the standard doesn't strictly
mandate this. This is consistent with the rest of sg, it makes the
code's intent clearer and helps to find headers. (And it's a few
milliseconds faster, too.)
2009-05-16 16:18:37 +02:00
ehofman d4c7e95092 Replace SG_USE_STD() by using std:: 2008-07-28 07:52:13 +00:00
fredb 433be0e46b Maybe a more portable way to do it 2008-07-25 21:33:54 +00:00
fredb 900607034e Compile again with MSVC 2008-07-25 21:27:46 +00:00
ehofman 733e6fa14f Reduce compiler.h to almost nothing (but it's worth keeping around I think, for
the MSVC and MipsPro warning stuff).

As a result of this patch, simgear/sg_traits.h can be deleted. So can SGCMath.h,
but I'll do that separately.

There is one more 'mechanical' change to come - getting rid of SG_USING_STD(X),
but I want to keep that separate from everything else. (There's another mechnica
l change, replacing <math.h> with <cmath> and so on *everywhere*, but one step a
t a time)
2008-07-25 18:35:40 +00:00
ehofman cd72eb20c6 Attached patches remove BORLANDC, and hence SG_MATH_EXCEPTION_CLASH and SG_INCOM
PLETE_FUNCTIONAL from SimGear and FlightGear.

As a result, SG_HAVE_STD_INCLUDES is now *always* set, so I will get the boring
fixes for that done, but separately. I'm still auditing the other things in comp
ilers.h - there's a lot that can die now BORLAND is gone.
2008-07-25 10:39:20 +00:00
ehofman d613e0a488 Patch to remove macintosh and MWERKS from Simgear. 2008-07-24 19:16:50 +00:00
timoore d219c5c4c6 Don't include <iostream> and "using" declarations in header files
<iostream> sucks in expensive initialization of the standard streams
and isn't appropriate in a header file. Use <istream> and <ostream>
instead.

using declarations should never appear at global scope in a header
file; source files get to decide what they want to use in their
namespace.
2008-06-02 20:21:27 +00:00
mfranz 9deb40216e Nicolas: let SGPath::create_dir() return success/failure (for screenshot) 2008-04-26 15:25:29 +00:00
timoore 9861d74221 Fixes for compiling with gcc 4.3
Include standard header files and qualify with std:: where needed.

Add "const" to various char parameters and variables.
2008-04-13 21:11:44 +00:00
timoore 1159784538 minor fix to ModelRegistry and syntax changes for Windows
Create the local path in the right order in OptionsPusher. When
OptionsPusher is used, put it inside a new code block so the order of
destruction with respect to the mutex on reader functions id clear.

Add #include <algorithm> to top of ModelRegistry.cxx.

Change include syntax in PathOptions.cxx
2007-12-11 11:07:21 +00:00
timoore 4efa087cd1 Don't modify OSG Registry with file path
To set a path when loading model files, use an osg ReaderWriter::Options object.

Put locks in ModelRegistry::readNode and ModelRegistry::readImage to avoid
conflicts when files are loaded from both the pager and the main thread.
2007-12-04 22:38:40 +00:00
timoore 6c30f62693 Add curvature to ocean tiles.
An apron around the tile hides cracks with coastal tiles.

The VectorArrayAdapter, which lives in the simgear namespace, is a useful
utility class for treating vectors as 2D arrays.
2007-08-12 21:03:43 +00:00