Fixed IRIX build. Required some namespace fixes and include and link

directives in the Makefiles
This commit is contained in:
Don BURNS
2001-12-17 16:21:33 +00:00
parent bc49a83c51
commit b35b5f3c3c
8 changed files with 70 additions and 62 deletions

View File

@@ -111,7 +111,7 @@ class MySceneView : public osgUtil::SceneView {
_bc.setBuffer(&cp, sizeof( CameraPacket ));
_bc.sync();
cout << "broadcasting death"<<endl;
std::cout << "broadcasting death"<<std::endl;
}
}
@@ -144,7 +144,7 @@ class MySceneView : public osgUtil::SceneView {
if (cp.getMasterKilled())
{
cout << "recieved master killed"<<endl;
std::cout << "recieved master killed"<<std::endl;
_viewerMode = STAND_ALONE;
}
}
@@ -250,14 +250,14 @@ osg::Node* getNodeFromFiles(int argc,char **argv,
if (nodeList.size()==0)
{
osg::notify(osg::WARN) << "No data loaded."<<endl;
osg::notify(osg::WARN) << "No data loaded."<<std::endl;
exit(0);
}
/*
if (master) osg::notify(osg::NOTICE)<<"set to MASTER, broadcasting on socketNumber "<<socketNumber<<endl;
else osg::notify(osg::NOTICE)<<"set to SLAVE, reciving on socketNumber "<<socketNumber<<endl;
if (master) osg::notify(osg::NOTICE)<<"set to MASTER, broadcasting on socketNumber "<<socketNumber<<std::endl;
else osg::notify(osg::NOTICE)<<"set to SLAVE, reciving on socketNumber "<<socketNumber<<std::endl;
*/
@@ -295,30 +295,30 @@ int main( int argc, char **argv )
if (argc<2)
{
osg::notify(osg::NOTICE)<<"usage:"<<endl;
osg::notify(osg::NOTICE)<<" osgcluster [options] infile1 [infile2 ...]"<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<"options:"<<endl;
osg::notify(osg::NOTICE)<<" -m - set this viewer to be master"<<endl;
osg::notify(osg::NOTICE)<<" -s - set this viewer to be a slave"<<endl;
osg::notify(osg::NOTICE)<<" -o - offset the slave camera from the master position"<<endl;
osg::notify(osg::NOTICE)<<" by specified number of degress. A positive offset "<<endl;
osg::notify(osg::NOTICE)<<" turns camera towards right."<<endl;
osg::notify(osg::NOTICE)<<" -f - set the horizontal field of view of the camera."<<endl;
osg::notify(osg::NOTICE)<<" -n SocketNumber - set the socket number, defaults to 8100."<<endl;
osg::notify(osg::NOTICE)<<" to broadcast on if a master"<<endl;
osg::notify(osg::NOTICE)<<" to reciever on if a slave"<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<" -l libraryName - load plugin of name libraryName"<<endl;
osg::notify(osg::NOTICE)<<" i.e. -l osgdb_pfb"<<endl;
osg::notify(osg::NOTICE)<<" Useful for loading reader/writers which can load"<<endl;
osg::notify(osg::NOTICE)<<" other file formats in addition to its extension."<<endl;
osg::notify(osg::NOTICE)<<" -e extensionName - load reader/wrter plugin for file extension"<<endl;
osg::notify(osg::NOTICE)<<" i.e. -e pfb"<<endl;
osg::notify(osg::NOTICE)<<" Useful short hand for specifying full library name as"<<endl;
osg::notify(osg::NOTICE)<<" done with -l above, as it automatically expands to the"<<endl;
osg::notify(osg::NOTICE)<<" full library name appropriate for each platform."<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<"usage:"<<std::endl;
osg::notify(osg::NOTICE)<<" osgcluster [options] infile1 [infile2 ...]"<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
osg::notify(osg::NOTICE)<<"options:"<<std::endl;
osg::notify(osg::NOTICE)<<" -m - set this viewer to be master"<<std::endl;
osg::notify(osg::NOTICE)<<" -s - set this viewer to be a slave"<<std::endl;
osg::notify(osg::NOTICE)<<" -o - offset the slave camera from the master position"<<std::endl;
osg::notify(osg::NOTICE)<<" by specified number of degress. A positive offset "<<std::endl;
osg::notify(osg::NOTICE)<<" turns camera towards right."<<std::endl;
osg::notify(osg::NOTICE)<<" -f - set the horizontal field of view of the camera."<<std::endl;
osg::notify(osg::NOTICE)<<" -n SocketNumber - set the socket number, defaults to 8100."<<std::endl;
osg::notify(osg::NOTICE)<<" to broadcast on if a master"<<std::endl;
osg::notify(osg::NOTICE)<<" to reciever on if a slave"<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
osg::notify(osg::NOTICE)<<" -l libraryName - load plugin of name libraryName"<<std::endl;
osg::notify(osg::NOTICE)<<" i.e. -l osgdb_pfb"<<std::endl;
osg::notify(osg::NOTICE)<<" Useful for loading reader/writers which can load"<<std::endl;
osg::notify(osg::NOTICE)<<" other file formats in addition to its extension."<<std::endl;
osg::notify(osg::NOTICE)<<" -e extensionName - load reader/wrter plugin for file extension"<<std::endl;
osg::notify(osg::NOTICE)<<" i.e. -e pfb"<<std::endl;
osg::notify(osg::NOTICE)<<" Useful short hand for specifying full library name as"<<std::endl;
osg::notify(osg::NOTICE)<<" done with -l above, as it automatically expands to the"<<std::endl;
osg::notify(osg::NOTICE)<<" full library name appropriate for each platform."<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
return 0;
}
@@ -334,7 +334,7 @@ int main( int argc, char **argv )
osg::Node* rootnode = getNodeFromFiles( argc, argv, viewerMode, socketNumber,camera_fov,camera_offset);
osg::Timer_t after_load = timer.tick();
cout << "Time for load = "<<timer.delta_s(before_load,after_load)<<" seconds"<<endl;
std::cout << "Time for load = "<<timer.delta_s(before_load,after_load)<<" seconds"<<std::endl;
osg::ref_ptr<MySceneView> mySceneView = new MySceneView(viewerMode,socketNumber,camera_fov,osg::inDegrees(camera_offset));
mySceneView->setSceneData(rootnode);

View File

@@ -15,7 +15,7 @@ TARGET_BIN_FILES = osgtext
LIBS = -losgGLUT -losgText -losgUtil -losgDB -losg $(GLUTLIB) -lGLU -lGL -lm -lXmu -lX11 -lXi
C++FLAGS += -I../../../include -g
LDFLAGS += -L../../../lib
LDFLAGS += -L../../../lib -L/usr/freeware/lib32
include ../../../Make/makerules

View File

@@ -14,6 +14,7 @@
#include <GL/glut.h>
#include <osgGLUT/Viewer>
//
// A simple demo demonstrating different texturing modes,
// including using of texture extensions.
@@ -71,7 +72,7 @@ ImageList getImagesFromFiles(int argc,char **argv)
if (imageList.size()==0)
{
osg::notify(osg::WARN) << "No image data loaded."<<endl;
osg::notify(osg::WARN) << "No image data loaded."<<std::endl;
}
return imageList;
@@ -350,24 +351,24 @@ osg::Node* createModelFromImages(ImageList& imageList)
void write_usage()
{
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<"usage:"<<endl;
osg::notify(osg::NOTICE)<<" osgtexture [options] image_file1 [image_infile2 ...]"<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<"options:"<<endl;
osg::notify(osg::NOTICE)<<" -l libraryName - load plugin of name libraryName"<<endl;
osg::notify(osg::NOTICE)<<" i.e. -l osgdb_pfb"<<endl;
osg::notify(osg::NOTICE)<<" Useful for loading reader/writers which can load"<<endl;
osg::notify(osg::NOTICE)<<" other file formats in addition to its extension."<<endl;
osg::notify(osg::NOTICE)<<" -e extensionName - load reader/wrter plugin for file extension"<<endl;
osg::notify(osg::NOTICE)<<" i.e. -e pfb"<<endl;
osg::notify(osg::NOTICE)<<" Useful short hand for specifying full library name as"<<endl;
osg::notify(osg::NOTICE)<<" done with -l above, as it automatically expands to the"<<endl;
osg::notify(osg::NOTICE)<<" full library name appropriate for each platform."<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<"example:"<<endl;
osg::notify(osg::NOTICE)<<" osgtexture lz.rgb"<<endl;
osg::notify(osg::NOTICE)<<endl;
osg::notify(osg::NOTICE)<<std::endl;
osg::notify(osg::NOTICE)<<"usage:"<<std::endl;
osg::notify(osg::NOTICE)<<" osgtexture [options] image_file1 [image_infile2 ...]"<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
osg::notify(osg::NOTICE)<<"options:"<<std::endl;
osg::notify(osg::NOTICE)<<" -l libraryName - load plugin of name libraryName"<<std::endl;
osg::notify(osg::NOTICE)<<" i.e. -l osgdb_pfb"<<std::endl;
osg::notify(osg::NOTICE)<<" Useful for loading reader/writers which can load"<<std::endl;
osg::notify(osg::NOTICE)<<" other file formats in addition to its extension."<<std::endl;
osg::notify(osg::NOTICE)<<" -e extensionName - load reader/wrter plugin for file extension"<<std::endl;
osg::notify(osg::NOTICE)<<" i.e. -e pfb"<<std::endl;
osg::notify(osg::NOTICE)<<" Useful short hand for specifying full library name as"<<std::endl;
osg::notify(osg::NOTICE)<<" done with -l above, as it automatically expands to the"<<std::endl;
osg::notify(osg::NOTICE)<<" full library name appropriate for each platform."<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
osg::notify(osg::NOTICE)<<"example:"<<std::endl;
osg::notify(osg::NOTICE)<<" osgtexture lz.rgb"<<std::endl;
osg::notify(osg::NOTICE)<<std::endl;
}
int main( int argc, char **argv )

View File

@@ -2,7 +2,8 @@
SHELL=/bin/sh
#DIRS = osg rgb lib3ds flt pfb obj lwo dw bmp pic png jpeg tga tiff gif osgtgz tgz zip
DIRS = osg rgb lib3ds flt obj lwo dw bmp pic png jpeg tga tiff gif osgtgz tgz zip
#DIRS = osg rgb lib3ds flt obj lwo dw bmp pic png jpeg tga tiff gif osgtgz tgz zip
DIRS = osg rgb lib3ds obj lwo dw bmp pic png jpeg tga tiff gif osgtgz tgz zip
all :
for f in $(DIRS) ; do cd $$f; $(MAKE) || exit 1; cd ..; done

View File

@@ -97,20 +97,20 @@ bool DynGeoSet::setLists()
{
if ((_primLenList.size() > 0) && (_coordList.size() > 0))
{
GeoSet::setPrimLengths(_primLenList.begin());
GeoSet::setCoords(_coordList.begin());
osg::GeoSet::setPrimLengths(_primLenList.begin());
osg::GeoSet::setCoords(_coordList.begin());
if ((_normalList.size() > 0)
&& (getNormalBinding() != osg::GeoSet::BIND_OFF))
GeoSet::setNormals(_normalList.begin());
osg::GeoSet::setNormals(_normalList.begin());
if ((_colorList.size() > 0)
&& (getColorBinding() != osg::GeoSet::BIND_OFF))
GeoSet::setColors(_colorList.begin());
osg::GeoSet::setColors(_colorList.begin());
if ((_tcoordList.size() > 0)
&& (getTextureBinding() != osg::GeoSet::BIND_OFF))
GeoSet::setTextureCoords(_tcoordList.begin());
osg::GeoSet::setTextureCoords(_tcoordList.begin());
return true;
}

View File

@@ -10,8 +10,8 @@ TARGET_LOADER_FILES = osgPlugins/osgdb_gif.so
LIBS = -lungif
C++FLAGS += -I. -I../../../include
LDFLAGS += -L../../../lib $(FREEBSD_LOCALLIBS)
C++FLAGS += -I. -I../../../include -I/usr/freeware/include
LDFLAGS += -L../../../lib $(FREEBSD_LOCALLIBS) -L/usr/freeware/lib32
include ../../../Make/makerules

View File

@@ -9,8 +9,8 @@ LIB = ../../../lib/osgPlugins/osgdb_png.so
TARGET_LOADER_FILES = osgPlugins/osgdb_png.so
LIBS = -lpng
C++FLAGS += -I../../../include -I/usr/local/include
LDFLAGS += -L../../../lib -L/usr/local/lib
C++FLAGS += -I../../../include -I/usr/local/include -I/usr/freeware/include
LDFLAGS += -L../../../lib -L/usr/local/lib -L/usr/freeware/lib32
include ../../../Make/makerules

View File

@@ -42,8 +42,14 @@ TARGET_INCLUDE_FILES = \
osgText/Text\
osgText/Version
C++FLAGS += -I../../include -I/usr/include/freetype2 -I/usr/local/include -I/usr/local/include/freetype2
LDFLAGS += -L/usr/local/lib
C++FLAGS += -I../../include \
-I/usr/include/freetype2 \
-I/usr/local/include \
-I/usr/local/include/freetype2 \
-I/usr/freeware/include\
-I/usr/freeware/include/freetype2
LDFLAGS += -L/usr/local/lib -L/usr/freeware/lib32
include ../../Make/makerules