diff --git a/Make/dependencies b/Make/dependencies index 772634a8e..64fdaaf50 100644 --- a/Make/dependencies +++ b/Make/dependencies @@ -1,7 +1,7 @@ ################################################################ # Dependency library which have been installed on this system -GDAL_INSTALLED = no +GDAL_INSTALLED = yes JASPER_INSTALLED = no FREETYPE_INSTALLED = yes diff --git a/Make/makedefs b/Make/makedefs index b291d569b..dbcbf8a37 100644 --- a/Make/makedefs +++ b/Make/makedefs @@ -197,17 +197,24 @@ ifeq ($(OS),SunOS) PNG_LIBS = /usr/local/lib/libpng.a /usr/local/lib/libz.a FREETYPE_LIB = /usr/local/lib/libfreetype.a endif - DYNAMICLIBRARYLIB = -ldl - OSG_LIBS = -losgGA -losgDB -losgUtil -losg - GL_LIBS = -lGLU -lGL - X_INC = -I/usr/X11R6/include - X_LIBS = -lXext -lXmu -lXi -lX11 - SOCKET_LIBS = -lsocket -lnsl - INSTBINCMD = cp - INSTDEVCMD = cp - INST_LOCATION = /opt/OpenSceneGraph - MAKEDIST = $(TOPDIR)/Make/makepkg - OTHER_LIBS = -lOpenThreads + + DYNAMICLIBRARYLIB = -ldl + OSG_LIBS = -losgGA -losgDB -losgUtil -losg + GL_LIBS = -lGLU -lGL + X_INC = -I/usr/X11R6/include + X_LIBS = -lXext -lXmu -lXi -lX11 + SOCKET_LIBS = -lsocket -lnsl + INSTBINCMD = cp + INSTDEVCMD = cp + INST_LOCATION = /opt/OpenSceneGraph + MAKEDIST = $(TOPDIR)/Make/makepkg + OTHER_LIBS = -lOpenThreads + + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + + endif #### IRIX Specific definitions @@ -290,6 +297,11 @@ ifeq ($(OS),IRIX) GIF_LIBS = -lungif MAKEDIST = $(TOPDIR)/Make/makeirixdist + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + + endif #### Linux specific definitions @@ -368,6 +380,10 @@ ifeq ($(OS),Linux) OTHER_LIBS += -lfnccheck endif + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + endif #### FreeBSD specific definitions @@ -395,6 +411,11 @@ ifeq ($(OS),FreeBSD) JPEG_LIBS = -ljpeg TIFF_LIB = -ltiff GIF_LIBS = -lungif + + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + endif #### MacOS X specific definitions @@ -441,6 +462,10 @@ ifeq ($(OS),Darwin) GIF_LIBS = -lungif TIFF_LIBS = -ltiff -lz -ljpeg + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + endif #### Cygwin specific definitions @@ -451,9 +476,9 @@ ifeq ($(OS),CYGWIN) DEF += -DWIN32 -W -Wall -DNOMINMAX OPTF = -O2 DBGF = -g -DOSG_COMPILE_UNIT_TESTS - SHARED = -shared\ - -Wl,--out-implib,$(TOPDIR)/lib/$(OS)/lib$(TARGET_BASENAME).dll.a - -Wl,--export-all-symbols + SHARED = -shared \ + -Wl,--out-implib,$(TOPDIR)/lib/$(OS)/lib$(TARGET_BASENAME).dll.a \ + -Wl,--export-all-symbols EXE_EXT =.exe ARCH = @@ -471,7 +496,11 @@ ifeq ($(OS),CYGWIN) JPEG_LIBS = -ljpeg GIF_LIBS = -lungif TIFF_LIB = -ltiff -lz -ljpeg - FREETYPE_LIB = -lfreetype + FREETYPE_LIB = `freetype-config --libs` + + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` LIBINST = bin PLUGININST = bin/$(OS)$(ARCH) @@ -495,12 +524,13 @@ endif #### Mingw specific definitions ifeq ($(OS),MINGW) - C++ = c++ -mthreads + C++ = c++ -mthreads +# -fomit-frame-pointer -march=pentium3 -msse -mmmx -mfpmath=sse DEPARG = -M INC += DEF += -DWIN32 -Wall # -W - OPTF = -O2 + OPTF = -O2 DBGF = -g -DOSG_COMPILE_UNIT_TESTS SHARED = -shared -mthreads \ -Wl,--out-implib,$(TOPDIR)/lib/$(OS)/lib$(TARGET_BASENAME).dll.a \ @@ -523,6 +553,7 @@ ifeq ($(OS),MINGW) GIF_LIBS = -lungif TIFF_LIB = -ltiff -lz -ljpeg FREETYPE_LIB = -lfreetype + GDAL_LIB = -lgdal -ljpeg -lgeotiff -ltiff -lpng -lz LIBXML2_INCLUDE = -I/usr/mingw/include/libxml2 @@ -592,6 +623,10 @@ endif GIF_INCLUDE = -I/opt/libungif/include GIF_LIBS = -L/opt/libungif/lib -lungif + GDAL_INCLUDES = -I`gdal-config --prefix`/include + GDAL_LIBS = `gdal-config --dep-libs` + GDAL_LIBS += `gdal-config --libs` + endif VPATH=.. diff --git a/NEWS.txt b/NEWS.txt index 1e1812df4..2b8de0831 100644 --- a/NEWS.txt +++ b/NEWS.txt @@ -11,6 +11,8 @@ OSG News (most significant items from ChangeLog) DatabasePager + Double Vec & Matrix classes + osgUtil - tristipper, simplifier, GLObjectVisitor. Examples - osgdem, osgphotoalbum, osgbluemarble, osgtesselate, osgsimulation diff --git a/examples/osgcluster/broadcaster.cpp b/examples/osgcluster/broadcaster.cpp index f26287de0..ce345d2c0 100644 --- a/examples/osgcluster/broadcaster.cpp +++ b/examples/osgcluster/broadcaster.cpp @@ -2,7 +2,7 @@ #include #include -#if !defined (WIN32) +#if !defined (WIN32) || defined(__CYGWIN__) #include #include #include @@ -26,7 +26,7 @@ #include #include #elif defined(__CYGWIN__) - // nothing needed + #include #elif defined(__sun) #include #include @@ -56,7 +56,7 @@ Broadcaster::Broadcaster( void ) Broadcaster::~Broadcaster( void ) { -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) closesocket( _so); #else close( _so ); @@ -65,7 +65,7 @@ Broadcaster::~Broadcaster( void ) bool Broadcaster::init( void ) { -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) WORD version = MAKEWORD(1,1); WSADATA wsaData; // First, we start up Winsock @@ -83,13 +83,13 @@ bool Broadcaster::init( void ) perror( "Socket" ); return false; } -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) const BOOL on = TRUE; #else int on = 1; #endif -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) setsockopt( _so, SOL_SOCKET, SO_REUSEADDR, (const char *) &on, sizeof(int)); #else setsockopt( _so, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)); @@ -99,16 +99,16 @@ bool Broadcaster::init( void ) saddr.sin_port = htons( _port ); if( _address == 0 ) { -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) setsockopt( _so, SOL_SOCKET, SO_BROADCAST, (const char *) &on, sizeof(int)); #else setsockopt( _so, SOL_SOCKET, SO_BROADCAST, &on, sizeof(on)); #endif -#if !defined (WIN32) +#if !defined (WIN32) || defined(__CYGWIN__) struct ifreq ifr; #endif -#if defined (__linux) +#if defined (__linux) || defined(__CYGWIN__) strcpy( ifr.ifr_name, "eth0" ); #elif defined(__sun) strcpy( ifr.ifr_name, "hme0" ); @@ -174,7 +174,7 @@ void Broadcaster::sync( void ) return; } -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) unsigned int size = sizeof( SOCKADDR_IN ); sendto( _so, (const char *)_buffer, _buffer_size, 0, (struct sockaddr *)&saddr, size ); int err = WSAGetLastError (); diff --git a/examples/osgcluster/broadcaster.h b/examples/osgcluster/broadcaster.h index 32d84892d..44148fdb5 100644 --- a/examples/osgcluster/broadcaster.h +++ b/examples/osgcluster/broadcaster.h @@ -7,7 +7,7 @@ // Class definition for broadcasting a buffer to a LAN // -#ifndef WIN32 +#if !defined(WIN32) || defined(__CYGWIN__) #include #endif @@ -36,7 +36,7 @@ class Broadcaster bool init( void ); private : -#if defined (WIN32) +#if defined(WIN32) && !defined(__CYGWIN__) SOCKET _so; #else int _so; @@ -45,7 +45,7 @@ class Broadcaster short _port; void *_buffer; unsigned int _buffer_size; -#if defined (WIN32) +#if defined(WIN32) && !defined(__CYGWIN__) SOCKADDR_IN saddr; #else struct sockaddr_in saddr; diff --git a/examples/osgcluster/osgcluster.cpp b/examples/osgcluster/osgcluster.cpp index 2f74a654f..7942202d2 100644 --- a/examples/osgcluster/osgcluster.cpp +++ b/examples/osgcluster/osgcluster.cpp @@ -12,7 +12,7 @@ #include -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) #include #endif diff --git a/examples/osgcluster/receiver.cpp b/examples/osgcluster/receiver.cpp index c50481388..7ea7c8ad6 100644 --- a/examples/osgcluster/receiver.cpp +++ b/examples/osgcluster/receiver.cpp @@ -1,7 +1,7 @@ #include #include #include -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) #include #else #include @@ -26,7 +26,7 @@ Receiver::Receiver( void ) Receiver::~Receiver( void ) { -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) closesocket( _so); #else close( _so ); @@ -35,7 +35,7 @@ Receiver::~Receiver( void ) bool Receiver::init( void ) { -#ifdef WIN32 +#if defined(WIN32) && !defined(__CYGWIN__) WORD version = MAKEWORD(1,1); WSADATA wsaData; // First, we start up Winsock @@ -53,7 +53,7 @@ bool Receiver::init( void ) perror( "Socket" ); return false; } -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) // const BOOL on = TRUE; // setsockopt( _so, SOL_SOCKET, SO_REUSEADDR, (const char*) &on, sizeof(int)); #else @@ -64,7 +64,7 @@ bool Receiver::init( void ) // struct sockaddr_in saddr; saddr.sin_family = AF_INET; saddr.sin_port = htons( _port ); -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) saddr.sin_addr.s_addr = htonl(INADDR_ANY); #else saddr.sin_addr.s_addr = 0; @@ -117,7 +117,7 @@ void Receiver::sync( void ) tv.tv_sec = 0; tv.tv_usec = 0; -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) // saddr.sin_port = htons( _port ); recvfrom( _so, (char *)_buffer, _buffer_size, 0, (sockaddr*)&saddr, &size ); // recvfrom(sock_Receive, szMessage, 256, 0, (sockaddr*)&addr_Cli, &clilen) diff --git a/examples/osgcluster/receiver.h b/examples/osgcluster/receiver.h index f9043d106..4a72a2a32 100644 --- a/examples/osgcluster/receiver.h +++ b/examples/osgcluster/receiver.h @@ -8,7 +8,7 @@ // Class definition for the recipient of a broadcasted message // -#ifndef WIN32 +#if !defined(WIN32) || defined(__CYGWIN__) #include #endif @@ -33,14 +33,11 @@ class Receiver bool init( void ); private : -#if defined (WIN32) +#if defined (WIN32) && !defined(__CYGWIN__) SOCKET _so; -#else - int _so; -#endif -#if defined (WIN32) SOCKADDR_IN saddr; #else + int _so; struct sockaddr_in saddr; #endif bool _initialized; diff --git a/examples/osgdem/GNUmakefile b/examples/osgdem/GNUmakefile index e500dc058..551fb7aa2 100644 --- a/examples/osgdem/GNUmakefile +++ b/examples/osgdem/GNUmakefile @@ -4,15 +4,13 @@ include $(TOPDIR)/Make/makedefs CXXFILES =\ osgdem.cpp\ -ifneq ("$(GDAL_INCLUDES)","") INC += $(GDAL_INCLUDES) -endif -ifneq ("$(GDAL_LIB_DIR)","") -LDFLAGS += -L$(GDAL_LIB_DIR) -endif +LIBS += -losgProducer -lProducer -losgTerrain -losgFX -losgGL2 -losgText -losgGA -losgDB -losgUtil -losg $(GDAL_LIBS) $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS) -LIBS += -losgProducer -lProducer -losgTerrain -losgFX -losgGL2 -losgText -losgGA -losgDB -losgUtil -losg -lgdal $(GL_LIBS) $(X_LIBS) $(OTHER_LIBS) +ifeq ($(OS),MINGW) +LIBS += -ljpeg -lpng -lgeotiff -ltiff -lz -L/usr/mingw/lib/malloc.o +endif INSTFILES = \ $(CXXFILES)\ diff --git a/include/osg/AnimationPath b/include/osg/AnimationPath index 348d62246..91ce0622c 100644 --- a/include/osg/AnimationPath +++ b/include/osg/AnimationPath @@ -14,15 +14,15 @@ #ifndef OSG_ANIMATIONPATH #define OSG_ANIMATIONPATH 1 +#include +#include +#include + #include #include #include #include -#include -#include -#include - namespace osg { /** AnimationPath for specify the time varying transformation pathway to use when update camera and model objects. diff --git a/include/osg/Array b/include/osg/Array index 66f713b25..b96295e8d 100644 --- a/include/osg/Array +++ b/include/osg/Array @@ -14,14 +14,15 @@ #ifndef OSG_ARRAY #define OSG_ARRAY 1 -#include -#include +#include + #include #include #include #include -#include +#include +#include namespace osg { diff --git a/include/osg/AutoTransform b/include/osg/AutoTransform index da29f53ef..954eee3fa 100644 --- a/include/osg/AutoTransform +++ b/include/osg/AutoTransform @@ -14,9 +14,9 @@ #ifndef OSG_AUTOTRANSFORM #define OSG_AUTOTRANSFORM 1 +#include #include #include -#include #include namespace osg { diff --git a/include/osg/CoordinateSystemNode b/include/osg/CoordinateSystemNode index e6ed8b0ea..811ea105f 100644 --- a/include/osg/CoordinateSystemNode +++ b/include/osg/CoordinateSystemNode @@ -147,7 +147,7 @@ inline void EllipsoidModel::convertLatLongHeightToXYZ(double latitude, double lo double N = _radiusEquator / sqrt( 1.0 - _eccentricitySquared*sin_latitude*sin_latitude); X = (N+height)*cos_latitude*cos(longitude); Y = (N+height)*cos_latitude*sin(longitude); - Z = (N*(1-_eccentricitySquared)+height)*sin(latitude); + Z = (N*(1-_eccentricitySquared)+height)*sin_latitude; } diff --git a/include/osg/Vec2d b/include/osg/Vec2d index 121180019..f72c3da19 100644 --- a/include/osg/Vec2d +++ b/include/osg/Vec2d @@ -16,8 +16,6 @@ #include -#include - namespace osg { /** General purpose double pair, uses include representation of diff --git a/include/osg/Vec2f b/include/osg/Vec2f index fb35d7689..901d939bc 100644 --- a/include/osg/Vec2f +++ b/include/osg/Vec2f @@ -14,10 +14,10 @@ #ifndef OSG_VEC2F #define OSG_VEC2F 1 -#include - #include +#include + namespace osg { /** General purpose float pair, uses include representation of diff --git a/include/osg/Vec3d b/include/osg/Vec3d index 135f81911..c71bfb001 100644 --- a/include/osg/Vec3d +++ b/include/osg/Vec3d @@ -16,8 +16,6 @@ #include -#include - namespace osg { /** General purpose double triple for use as vertices, vectors and normals. diff --git a/include/osg/Vec3f b/include/osg/Vec3f index 91a9affdd..267504347 100644 --- a/include/osg/Vec3f +++ b/include/osg/Vec3f @@ -14,10 +14,10 @@ #ifndef OSG_VEC3F #define OSG_VEC3F 1 -#include - #include +#include + namespace osg { /** General purpose float triple for use as vertices, vectors and normals. diff --git a/include/osg/Vec4f b/include/osg/Vec4f index 45aac196a..4cad8dd6f 100644 --- a/include/osg/Vec4f +++ b/include/osg/Vec4f @@ -16,8 +16,6 @@ #include -#include - namespace osg { /** General purpose float quad, uses include representation diff --git a/include/osgDB/ReadFile b/include/osgDB/ReadFile index da782da0d..a061ea2ee 100644 --- a/include/osgDB/ReadFile +++ b/include/osgDB/ReadFile @@ -14,6 +14,8 @@ #ifndef OSGDB_READFILE #define OSGDB_READFILE 1 +#include + #include #include #include @@ -21,8 +23,6 @@ #include #include -#include - namespace osgDB { diff --git a/include/osgText/Font b/include/osgText/Font index 921771574..e06c2def2 100644 --- a/include/osgText/Font +++ b/include/osgText/Font @@ -14,6 +14,8 @@ #ifndef OSGTEXT_FONT #define OSGTEXT_FONT 1 +#include + #include #include #include @@ -23,8 +25,6 @@ #include -#include - namespace osgText { class Font; diff --git a/include/osgText/String b/include/osgText/String index 2cee89a82..33f668d8b 100644 --- a/include/osgText/String +++ b/include/osgText/String @@ -14,13 +14,13 @@ #ifndef OSGTEXT_STRING #define OSGTEXT_STRING 1 -#include -#include - #include #include #include +#include +#include + namespace osgText { class Text; diff --git a/include/osgUtil/CullVisitor b/include/osgUtil/CullVisitor index 2f45ad0f8..944747ad8 100644 --- a/include/osgUtil/CullVisitor +++ b/include/osgUtil/CullVisitor @@ -14,6 +14,9 @@ #ifndef OSGUTIL_CULLVISITOR #define OSGUTIL_CULLVISITOR 1 +#include +#include + #include #include #include @@ -24,16 +27,12 @@ #include #include #include -#include #include #include #include -#include -#include - #include namespace osgUtil { diff --git a/include/osgUtil/SmoothingVisitor b/include/osgUtil/SmoothingVisitor index b181f9b80..b8b3fc95c 100644 --- a/include/osgUtil/SmoothingVisitor +++ b/include/osgUtil/SmoothingVisitor @@ -30,11 +30,9 @@ class OSGUTIL_EXPORT SmoothingVisitor : public osg::NodeVisitor public: /// default to traversing all children. - SmoothingVisitor() - { - setTraversalMode(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN); - } - + SmoothingVisitor(); + virtual ~SmoothingVisitor(); + /// smooth geoset by creating per vertex normals. static void smooth(osg::Geometry& geoset); diff --git a/src/osgPlugins/directx/directx.h b/src/osgPlugins/directx/directx.h index 1f06c29a4..c4fdeff37 100644 --- a/src/osgPlugins/directx/directx.h +++ b/src/osgPlugins/directx/directx.h @@ -24,12 +24,12 @@ #ifndef _DIRECTX_H_ #define _DIRECTX_H_ -#include - #include #include #include +#include + namespace DX { /* diff --git a/src/osgPlugins/gdal/GNUmakefile b/src/osgPlugins/gdal/GNUmakefile index f4ebec271..9e942814e 100644 --- a/src/osgPlugins/gdal/GNUmakefile +++ b/src/osgPlugins/gdal/GNUmakefile @@ -4,15 +4,10 @@ include $(TOPDIR)/Make/makedefs CXXFILES =\ ReaderWriterGDAL.cpp\ -ifneq ("$(GDAL_INCLUDES)","") + INC += $(GDAL_INCLUDES) -endif -ifneq ("$(GDAL_LIB_DIR)","") -LDFLAGS += -L$(GDAL_LIB_DIR) -endif - -LIBS += $(OSG_LIBS) -lgdal $(OTHER_LIBS) +LIBS += $(OSG_LIBS) $(GDAL_LIBS) $(OTHER_LIBS) TARGET_BASENAME = gdal diff --git a/src/osgPlugins/obj/glm.cpp b/src/osgPlugins/obj/glm.cpp index ad7c58ce1..808bf0056 100644 --- a/src/osgPlugins/obj/glm.cpp +++ b/src/osgPlugins/obj/glm.cpp @@ -8,13 +8,13 @@ /* includes */ +#include "glm.h" #include #include #include #include #include #include -#include "glm.h" #include diff --git a/src/osgPlugins/txp/trpage_sys.h b/src/osgPlugins/txp/trpage_sys.h index 24715cdcc..1879c7340 100644 --- a/src/osgPlugins/txp/trpage_sys.h +++ b/src/osgPlugins/txp/trpage_sys.h @@ -37,10 +37,12 @@ #include +#ifdef __MSC_VER // Microsoft Developer warnings that annoy me #pragma warning ( disable : 4251) #pragma warning ( disable : 4275) #pragma warning ( disable : 4786) +#endif // Somewhat system independent file deletion macro #define TRPGDELETEFILE(file) DeleteFile((file)) diff --git a/src/osgProducer/KeyboardMouseCallback.cpp b/src/osgProducer/KeyboardMouseCallback.cpp index 2ba23e8ff..913f0abc0 100644 --- a/src/osgProducer/KeyboardMouseCallback.cpp +++ b/src/osgProducer/KeyboardMouseCallback.cpp @@ -1,8 +1,8 @@ +#include + #include #include -#include - #include using namespace osgProducer; diff --git a/src/osgTerrain/GNUmakefile b/src/osgTerrain/GNUmakefile index d70e63c94..b4845105e 100644 --- a/src/osgTerrain/GNUmakefile +++ b/src/osgTerrain/GNUmakefile @@ -8,17 +8,11 @@ CXXFILES = \ HeightFieldRenderer.cpp\ Version.cpp\ -ifneq ("$(GDAL_INCLUDES)","") -INC += $(GDAL_INCLUDES) -endif - -ifneq ("$(GDAL_LIB_DIR)","") -LDFLAGS += -L$(GDAL_LIB_DIR) -endif - DEF += -DOSGTERRAIN_LIBRARY -LIBS += -losgDB -losgUtil -losg -lgdal $(GL_LIBS) $(OTHER_LIBS) +INC += $(GDAL_INCLUDES) + +LIBS += -losgDB -losgUtil -losg $(GDAL_LIBS) $(GL_LIBS) $(OTHER_LIBS) TARGET_BASENAME = osgTerrain LIB = $(LIB_PREFIX)$(TARGET_BASENAME).$(LIB_EXT) diff --git a/src/osgText/DefaultFont.h b/src/osgText/DefaultFont.h index 6616e12d2..efc02c216 100644 --- a/src/osgText/DefaultFont.h +++ b/src/osgText/DefaultFont.h @@ -14,12 +14,12 @@ #ifndef NEWTEXT_DEFAULTFONT_H #define NEWTEXT_DEFAULTFONT_H 1 +#include + #include #include -#include - namespace osgText { class DefaultFont : public Font diff --git a/src/osgText/String.cpp b/src/osgText/String.cpp index 5eb32d755..2fe9d43fa 100644 --- a/src/osgText/String.cpp +++ b/src/osgText/String.cpp @@ -1,7 +1,7 @@ #include -#include #include +#include using namespace osgText; diff --git a/src/osgText/Text.cpp b/src/osgText/Text.cpp index 2166970ea..60a032f85 100644 --- a/src/osgText/Text.cpp +++ b/src/osgText/Text.cpp @@ -12,11 +12,13 @@ */ -#include +#include +#include + #include +#include #include #include -#include #include "DefaultFont.h" diff --git a/src/osgUtil/SmoothingVisitor.cpp b/src/osgUtil/SmoothingVisitor.cpp index 70146ae8c..b9d92173d 100644 --- a/src/osgUtil/SmoothingVisitor.cpp +++ b/src/osgUtil/SmoothingVisitor.cpp @@ -86,6 +86,15 @@ struct SmoothTriangleFunctor } }; +SmoothingVisitor::SmoothingVisitor() +{ + setTraversalMode(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN); +} + +SmoothingVisitor::~SmoothingVisitor() +{ +} + void SmoothingVisitor::smooth(osg::Geometry& geom) { Geometry::PrimitiveSetList& primitives = geom.getPrimitiveSetList();