From 4751f401d7eea6e2132ac8c7051ac154780549de Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Sat, 6 Mar 2004 14:13:53 +0000 Subject: [PATCH] Changed cout/cerr to osg::notify(). --- src/osgPlugins/gdal/ReaderWriterGDAL.cpp | 2 +- src/osgPlugins/iv/normals.cpp | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/osgPlugins/gdal/ReaderWriterGDAL.cpp b/src/osgPlugins/gdal/ReaderWriterGDAL.cpp index e68d67c11..b63febea8 100644 --- a/src/osgPlugins/gdal/ReaderWriterGDAL.cpp +++ b/src/osgPlugins/gdal/ReaderWriterGDAL.cpp @@ -28,7 +28,7 @@ class ReaderWriterGDAL : public osgDB::ReaderWriter //if (!acceptsExtension(ext)) return ReadResult::FILE_NOT_HANDLED; - std::cout << "GDAL : " << file << std::endl; + osg::notify(osg::INFO) << "GDAL : " << file << std::endl; std::string fileName = osgDB::findDataFile( file ); if (fileName.empty()) return ReadResult::FILE_NOT_FOUND; diff --git a/src/osgPlugins/iv/normals.cpp b/src/osgPlugins/iv/normals.cpp index 9e118d159..34fd61358 100644 --- a/src/osgPlugins/iv/normals.cpp +++ b/src/osgPlugins/iv/normals.cpp @@ -19,6 +19,8 @@ #include +#include + #include "normals.h" #define CREASE_ANGLE 3.14159265356 * 45 / 180 @@ -65,13 +67,13 @@ osg::Vec3 *calcNormals(VertexList &vertices, PolygonList &polygons, unsigned nve int v0,v1,v2; get3v(vertices,vindex,v0,v1,v2); if (v0 == v1 || v0 == v2) { - std::cerr << "ERROR: Vertices alineados: nv=" << vindex.size() << std::endl; + osg::notify(osg::WARN) << "ERROR: Vertices alineados: nv=" << vindex.size() << std::endl; } normales_polys[poly] = calcNormal(vertices[v0], vertices[v1], vertices[v2]); if (normales_polys[poly] == osg::Vec3(0,0,0) && vindex.size() > 2) { - std::cerr << "##***" << "Normal nula VERTICES=" << vindex.size() << " " << vertices[v0] << " " << vertices[v1] << " " << vertices[v2] << std::endl; + osg::notify(osg::WARN) << "##***" << "Normal nula VERTICES=" << vindex.size() << " " << vertices[v0] << " " << vertices[v1] << " " << vertices[v2] << std::endl; } } }