Commit ed315528 authored by Matthias Möller's avatar Matthias Möller

- move iostream from header to source files.

- replace some iostreams to o/istreams only
- some minor include fixes

closes #2489

git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@1278 fdac6126-5c0c-442c-9429-916003d36597
parent 23fb3781
......@@ -53,6 +53,7 @@
#endif
#include <iomanip>
#include <iostream>
#include <sstream>
#include <algorithm>
// --------------------
......@@ -62,12 +63,11 @@
# include <GL/glut.h>
#endif
// --------------------
#include <qnamespace.h>
#include <qapplication.h>
#include <qmenu.h>
#include <qcursor.h>
#include <qimage.h>
#include <qdatetime.h>
#include <QApplication>
#include <QMenu>
#include <QCursor>
#include <QImage>
#include <QDateTime>
#include <QMouseEvent>
// --------------------
#include <OpenMesh/Apps/QtViewer/QGLViewerWidget.hh>
......
......@@ -69,7 +69,7 @@
#include <OpenMesh/Core/System/config.h>
#include <iostream>
#include <ostream>
#include <cmath>
#include <cassert>
#include <cstring>
......
......@@ -60,6 +60,7 @@
#include <OpenMesh/Core/System/config.h>
// -------------------- STL
#include <algorithm>
#include <iostream>
// -------------------- OpenMesh
#include <OpenMesh/Core/IO/BinaryHelper.hh>
......
......@@ -66,7 +66,7 @@
#else
# include <cstdio>
#endif
#include <iostream>
#include <iosfwd>
// -------------------- OpenMesh
......
......@@ -60,6 +60,8 @@
#include <OpenMesh/Core/System/config.h>
#include <OpenMesh/Core/IO/IOManager.hh>
#include <iostream>
//== NAMESPACES ===============================================================
......
......@@ -60,7 +60,7 @@
// STL
#include <iostream>
#include <iosfwd>
#include <sstream>
#include <string>
#include <set>
......
......@@ -53,7 +53,6 @@
#include <OpenMesh/Core/IO/reader/BaseReader.hh>
#include <algorithm>
#include <string>
#include <iterator>
#if defined(OM_CC_MIPS)
# include <ctype.h>
#else
......
......@@ -62,10 +62,11 @@
// STD C++
#include <iostream>
#include <iosfwd>
#include <string>
#include <cctype>
#include <functional>
#include <algorithm>
// OpenMesh
#include <OpenMesh/Core/System/config.h>
......
......@@ -71,7 +71,9 @@ using std::isspace;
#include <string.h>
#endif
#include <set>
#include <istream>
#include <fstream>
#include <vector>
#include <algorithm>
#include <functional>
......
......@@ -61,11 +61,9 @@
//=== INCLUDES ================================================================
#include <iostream>
#include <iosfwd>
#include <string>
#include <vector>
#include <map>
#include <fstream>
#include <OpenMesh/Core/System/config.h>
#include <OpenMesh/Core/Utils/SingletonT.hh>
......
......@@ -65,7 +65,6 @@
//STL
#include <iostream>
#include <ios>
#include <fstream>
#include <memory>
......
......@@ -61,10 +61,9 @@
//=== INCLUDES ================================================================
#include <iostream>
#include <iosfwd>
#include <string>
#include <stdio.h>
#include <fstream>
#include <cstdio>
#include <OpenMesh/Core/System/config.h>
#include <OpenMesh/Core/Utils/SingletonT.hh>
......
......@@ -51,6 +51,8 @@
//STL
#include <vector>
#include <istream>
#include <fstream>
// OpenMesh
......
......@@ -69,7 +69,7 @@
#include <OpenMesh/Core/IO/reader/BaseReader.hh>
// STD C++
#include <iostream>
#include <iosfwd>
#include <string>
......
......@@ -61,6 +61,7 @@
//STL
#include <fstream>
#include <iostream>
#include <memory>
#ifndef WIN32
......
......@@ -61,10 +61,10 @@
//=== INCLUDES ================================================================
#include <iostream>
#include <iosfwd>
#include <string>
#include <stdio.h>
#include <fstream>
#include <cstdio>
#include <vector>
#include <OpenMesh/Core/System/config.h>
......
......@@ -54,7 +54,6 @@
#include <OpenMesh/Core/IO/writer/BaseWriter.hh>
#include <algorithm>
#include <string>
#include <iterator>
#if defined(OM_CC_MIPS)
# include <ctype.h>
#else
......
......@@ -62,7 +62,7 @@
// STD C++
#include <iostream>
#include <iosfwd>
#include <string>
// OpenMesh
......
......@@ -60,6 +60,9 @@
#endif
#include <fstream>
#include <ostream>
#include <vector>
// -------------------- OpenMesh
#include <OpenMesh/Core/IO/OMFormat.hh>
#include <OpenMesh/Core/System/omstream.hh>
......
......@@ -62,7 +62,7 @@
// STD C++
#include <iostream>
#include <iosfwd>
#include <string>
// OpenMesh
......
......@@ -59,6 +59,8 @@
#include <OpenMesh/Core/IO/SR_store.hh>
#include <iostream>
//=== NAMESPACES ==============================================================
......
......@@ -47,9 +47,15 @@
\*===========================================================================*/
#include <OpenMesh/Core/Mesh/BaseKernel.hh>
#include <iostream>
namespace OpenMesh
{
void BaseKernel::property_stats() const
{
property_stats(std::clog);
}
void BaseKernel::property_stats(std::ostream& _ostr) const
{
const PropertyContainer::Properties& vps = vprops_.properties();
......@@ -168,6 +174,10 @@ void BaseKernel::mprop_stats( std::string& _string ) const
}
void BaseKernel::vprop_stats() const
{
vprop_stats(std::clog);
}
void BaseKernel::vprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
......@@ -176,7 +186,10 @@ void BaseKernel::vprop_stats(std::ostream& _ostr ) const
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::hprop_stats() const
{
hprop_stats(std::clog);
}
void BaseKernel::hprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
......@@ -185,6 +198,10 @@ void BaseKernel::hprop_stats(std::ostream& _ostr ) const
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::eprop_stats() const
{
eprop_stats(std::clog);
}
void BaseKernel::eprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
......@@ -193,6 +210,10 @@ void BaseKernel::eprop_stats(std::ostream& _ostr ) const
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::fprop_stats() const
{
fprop_stats(std::clog);
}
void BaseKernel::fprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
......@@ -201,6 +222,10 @@ void BaseKernel::fprop_stats(std::ostream& _ostr ) const
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::mprop_stats() const
{
mprop_stats(std::clog);
}
void BaseKernel::mprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
......
......@@ -66,6 +66,7 @@
#include <vector>
#include <string>
#include <algorithm>
#include <iosfwd>
// --------------------
#include <OpenMesh/Core/Utils/PropertyContainer.hh>
......@@ -688,7 +689,9 @@ protected: //------------------------------------------- synchronize properties
public:
void property_stats(std::ostream& _ostr = std::clog) const;
// uses std::clog as output stream
void property_stats() const;
void property_stats(std::ostream& _ostr) const;
void vprop_stats( std::string& _string ) const;
void hprop_stats( std::string& _string ) const;
......@@ -696,11 +699,18 @@ public:
void fprop_stats( std::string& _string ) const;
void mprop_stats( std::string& _string ) const;
void vprop_stats(std::ostream& _ostr = std::clog) const;
void hprop_stats(std::ostream& _ostr = std::clog) const;
void eprop_stats(std::ostream& _ostr = std::clog) const;
void fprop_stats(std::ostream& _ostr = std::clog) const;
void mprop_stats(std::ostream& _ostr = std::clog) const;
// uses std::clog as output stream
void vprop_stats() const;
void hprop_stats() const;
void eprop_stats() const;
void fprop_stats() const;
void mprop_stats() const;
void vprop_stats(std::ostream& _ostr) const;
void hprop_stats(std::ostream& _ostr) const;
void eprop_stats(std::ostream& _ostr) const;
void fprop_stats(std::ostream& _ostr) const;
void mprop_stats(std::ostream& _ostr) const;
public:
......
......@@ -53,7 +53,7 @@
//== INCLUDES =================================================================
#include <OpenMesh/Core/System/config.h>
#include <iostream>
#include <ostream>
//== NAMESPACES ===============================================================
......
......@@ -59,7 +59,7 @@
//== INCLUDES =================================================================
#include <OpenMesh/Core/System/config.h>
#include <iostream>
#include <ostream>
#if defined( OM_CC_GCC ) && OM_CC_VERSION < 30000
# include <streambuf.h>
#else
......
......@@ -56,6 +56,7 @@
//== INCLUDES =================================================================
#include <OpenMesh/Core/System/omstream.hh>
#include <iostream>
//== IMPLEMENTATION ==========================================================
......
......@@ -47,7 +47,7 @@
\*===========================================================================*/
#include <OpenMesh/Core/Utils/BaseProperty.hh>
#include <iostream>
#include <ostream>
namespace OpenMesh
{
......
......@@ -57,8 +57,6 @@
//== INCLUDES =================================================================
#include <iostream>
#include <algorithm>
#include <OpenMesh/Core/Utils/Endian.hh>
......
......@@ -62,7 +62,6 @@
#include <OpenMesh/Core/System/config.h>
#include <iostream>
//== NAMESPACES ===============================================================
......
......@@ -299,8 +299,6 @@ public:
++bytes;
}
std::cout << std::endl;
assert( bytes == size_of() );
return bytes;
......@@ -339,8 +337,6 @@ public:
++bytes;
}
std::cout << std::endl;
return bytes;
}
......
......@@ -65,7 +65,6 @@
// STL
#include <stdexcept>
#include <iostream>
//== NAMESPACES ===============================================================
......
......@@ -64,8 +64,6 @@
#include <OpenMesh/Core/System/config.h>
#include <OpenMesh/Core/Utils/vector_traits.hh>
#include <OpenMesh/Core/Utils/GenProg.hh>
#include <iostream>
#include <algorithm>
#include <OpenMesh/Core/Geometry/VectorT.hh>
......
......@@ -63,6 +63,7 @@
#include <OpenMesh/Core/System/config.hh>
#include <OpenMesh/Core/System/omstream.hh>
#include <ostream>
#include <OpenMesh/Tools/Subdivider/Adaptive/Composite/CompositeT.hh>
#include <OpenMesh/Tools/Subdivider/Adaptive/Composite/RuleInterfaceT.hh>
......@@ -135,7 +136,7 @@ initialize( void )
if (n_subdiv_rules_ != 1)
{
std::cerr << "Error! More than one subdivision rules not allowed!\n";
::omerr() << "Error! More than one subdivision rules not allowed!\n";
return false;
}
......
......@@ -58,7 +58,7 @@
#include <OpenMesh/Core/System/omstream.hh>
#include <OpenMesh/Core/Utils/GenProg.hh>
#include <OpenMesh/Core/Mesh/Attributes.hh>
#include <iostream>
#include <ostream>
//== NAMESPACES ===============================================================
......
......@@ -59,7 +59,7 @@
#include <OpenMesh/Core/System/config.hh>
//
#include <iostream>
#include <ostream>
#include <string>
#if defined(OM_CC_MIPS)
# include <assert.h>
......
......@@ -56,6 +56,7 @@
//== INCLUDES =================================================================
#include <OpenMesh/Tools/VDPM/ViewingParameters.hh>
#include <iostream>
//== NAMESPACES ===============================================================
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment