mirror of https://github.com/CGAL/cgal
verbose in readers.
This commit is contained in:
parent
9d237393da
commit
7c8dcbfd47
|
|
@ -45,17 +45,18 @@ class GOCAD_builder
|
|||
typedef typename Base::Face_container Face_container;
|
||||
|
||||
public:
|
||||
GOCAD_builder(std::istream& is_) : Base(is_) { }
|
||||
GOCAD_builder(std::istream& is_, bool verbose) : Base(is_, verbose) { }
|
||||
|
||||
// @check ascii
|
||||
template <typename NamedParameters>
|
||||
bool read(std::istream& input,
|
||||
Point_container& points,
|
||||
Face_container& faces,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose)
|
||||
{
|
||||
std::pair<std::string, std::string> name_and_color;
|
||||
bool res = read_GOCAD(input, name_and_color, points, faces, np);
|
||||
bool res = read_GOCAD(input, name_and_color, points, faces, np, verbose);
|
||||
if(res)
|
||||
{
|
||||
name = name_and_color.first;
|
||||
|
|
@ -77,12 +78,13 @@ template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
|||
bool read_GOCAD(std::istream& in,
|
||||
std::pair<std::string, std::string>& name_and_color,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename CGAL::GetVertexPointMap<FaceGraph, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
typedef typename boost::property_traits<VPM>::value_type Point;
|
||||
|
||||
IO::internal::GOCAD_builder<FaceGraph, Point> builder(in);
|
||||
IO::internal::GOCAD_builder<FaceGraph, Point> builder(in, verbose);
|
||||
if(!builder(g, np))
|
||||
return false;
|
||||
|
||||
|
|
@ -113,10 +115,11 @@ bool read_GOCAD(std::istream& in,
|
|||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_GOCAD(std::istream& in,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::pair<std::string, std::string> dummy;
|
||||
return read_GOCAD(in, dummy,g, np);
|
||||
return read_GOCAD(in, dummy,g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph>
|
||||
|
|
@ -147,13 +150,13 @@ bool read_GOCAD(std::istream& in,
|
|||
\see \ref IOStreamGOCAD
|
||||
*/
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_GOCAD(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_GOCAD(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np, bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
std::string unused_name;
|
||||
std::string unused_color;
|
||||
|
||||
return read_GOCAD(in, unused_name, unused_color, g, np);
|
||||
return read_GOCAD(in, unused_name, unused_color, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ protected:
|
|||
typedef typename boost::graph_traits<FaceGraph>::face_descriptor face_descriptor;
|
||||
|
||||
public:
|
||||
Generic_facegraph_builder(std::istream& in_) : m_in(in_) { }
|
||||
Generic_facegraph_builder(std::istream& in_, bool verbose) : m_in(in_), m_verbose(verbose) { }
|
||||
|
||||
template <typename NamedParameters>
|
||||
bool operator()(FaceGraph& g, const NamedParameters& np)
|
||||
|
|
@ -81,11 +81,13 @@ public:
|
|||
std::vector<Vertex_texture> vertex_textures;
|
||||
std::vector<Face_color> face_colors;
|
||||
|
||||
bool ok = static_cast<Derived*>(this)->read(m_in, m_points, m_faces,
|
||||
parameters::vertex_normal_output_iterator(std::back_inserter(vertex_normals))
|
||||
.vertex_color_output_iterator(std::back_inserter(vertex_colors))
|
||||
.vertex_texture_output_iterator(std::back_inserter(vertex_textures))
|
||||
.face_color_output_iterator(std::back_inserter(face_colors)));
|
||||
bool ok =
|
||||
static_cast<Derived*>(this)->read(m_in, m_points, m_faces,
|
||||
parameters::vertex_normal_output_iterator(std::back_inserter(vertex_normals))
|
||||
.vertex_color_output_iterator(std::back_inserter(vertex_colors))
|
||||
.vertex_texture_output_iterator(std::back_inserter(vertex_textures))
|
||||
.face_color_output_iterator(std::back_inserter(face_colors)),
|
||||
m_verbose);
|
||||
if(!ok)
|
||||
return false;
|
||||
|
||||
|
|
@ -140,6 +142,7 @@ protected:
|
|||
|
||||
Point_container m_points;
|
||||
Face_container m_faces;
|
||||
bool m_verbose;
|
||||
};
|
||||
|
||||
} // end internal
|
||||
|
|
|
|||
|
|
@ -50,15 +50,16 @@ class OBJ_builder
|
|||
typedef typename Base::Face_container Face_container;
|
||||
|
||||
public:
|
||||
OBJ_builder(std::istream& is_) : Base(is_) { }
|
||||
OBJ_builder(std::istream& is_, bool verbose) : Base(is_, verbose) { }
|
||||
|
||||
template <typename NamedParameters>
|
||||
bool read(std::istream& input,
|
||||
Point_container& points,
|
||||
Face_container& faces,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose)
|
||||
{
|
||||
return read_OBJ(input, points, faces, np);
|
||||
return read_OBJ(input, points, faces, np, verbose);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -88,12 +89,13 @@ public:
|
|||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OBJ(std::istream& in,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename CGAL::GetVertexPointMap<FaceGraph, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
typedef typename boost::property_traits<VPM>::value_type Point;
|
||||
|
||||
IO::internal::OBJ_builder<FaceGraph, Point> builder(in);
|
||||
IO::internal::OBJ_builder<FaceGraph, Point> builder(in, verbose);
|
||||
return builder(g, np);
|
||||
}
|
||||
|
||||
|
|
@ -121,18 +123,20 @@ bool read_OBJ(std::istream& in,
|
|||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OBJ(const char* fname,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_OBJ(in, g, np);
|
||||
return read_OBJ(in, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OBJ(const std::string& fname,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_OBJ(fname.c_str(), g, np);
|
||||
return read_OBJ(fname.c_str(), g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph>
|
||||
|
|
|
|||
|
|
@ -48,15 +48,16 @@ class OFF_builder
|
|||
typedef typename Base::Face_container Face_container;
|
||||
|
||||
public:
|
||||
OFF_builder(std::istream& is_) : Base(is_) { }
|
||||
OFF_builder(std::istream& is_, bool verbose) : Base(is_, verbose) { }
|
||||
|
||||
template <typename NamedParameters>
|
||||
bool read(std::istream& input,
|
||||
Point_container& points,
|
||||
Face_container& faces,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose)
|
||||
{
|
||||
return read_OFF(input, points, faces, np);
|
||||
return read_OFF(input, points, faces, np, verbose);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -65,12 +66,13 @@ public:
|
|||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF_BGL(std::istream& in,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename CGAL::GetVertexPointMap<FaceGraph, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
typedef typename boost::property_traits<VPM>::value_type Point;
|
||||
|
||||
IO::internal::OFF_builder<FaceGraph, Point> builder(in);
|
||||
IO::internal::OFF_builder<FaceGraph, Point> builder(in, verbose);
|
||||
return builder(g, np);
|
||||
}
|
||||
|
||||
|
|
@ -104,9 +106,9 @@ bool read_OFF_BGL(std::istream& in,
|
|||
\see \ref IOStreamOFF
|
||||
*/
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_OFF(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np, bool verbose = true)
|
||||
{
|
||||
return IO::internal::read_OFF_BGL(in, g, np);
|
||||
return IO::internal::read_OFF_BGL(in, g, np, verbose);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
|
@ -136,16 +138,18 @@ bool read_OFF(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
|||
\see \ref IOStreamOFF
|
||||
*/
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_OFF(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_OFF(in, g, np);
|
||||
return read_OFF(in, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_OFF(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_OFF(fname.c_str(), g, np);
|
||||
return read_OFF(fname.c_str(), g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph>
|
||||
|
|
|
|||
|
|
@ -43,42 +43,46 @@ class PLY_builder
|
|||
typedef typename Base::Face_container Face_container;
|
||||
|
||||
public:
|
||||
PLY_builder(std::istream& is_) : Base(is_) { }
|
||||
PLY_builder(std::istream& is_, bool verbose) : Base(is_, verbose) { }
|
||||
//! TODO: use vertex_point_map
|
||||
template <typename NamedParameters>
|
||||
bool read(std::istream& input,
|
||||
Point_container& points,
|
||||
Face_container& faces,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose)
|
||||
{
|
||||
return read_PLY(input, points, faces, np);
|
||||
return read_PLY(input, points, faces, np, verbose);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY_BGL(std::istream& in,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename CGAL::GetVertexPointMap<FaceGraph, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
typedef typename boost::property_traits<VPM>::value_type Point;
|
||||
|
||||
IO::internal::PLY_builder<FaceGraph, Point> builder(in);
|
||||
IO::internal::PLY_builder<FaceGraph, Point> builder(in, verbose);
|
||||
return builder(g, np);
|
||||
}
|
||||
|
||||
// document that too
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_PLY(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_PLY(in, g, np);
|
||||
return read_PLY(in, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_PLY(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_PLY(fname.c_str(), g, np);
|
||||
return read_PLY(fname.c_str(), g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph>
|
||||
|
|
@ -118,9 +122,9 @@ bool read_PLY(const std::string& fname, FaceGraph& g) { return read_PLY(fname, g
|
|||
\see \ref IOStreamPLY
|
||||
*/
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_PLY(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np, bool verbose = true)
|
||||
{
|
||||
return IO::internal::read_PLY_BGL(in, g, np);
|
||||
return IO::internal::read_PLY_BGL(in, g, np, verbose);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
|
@ -148,16 +152,18 @@ bool read_PLY(std::istream& in, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
|||
\see \ref IOStreamPLY
|
||||
*/
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_PLY(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream is(fname);
|
||||
return IO::internal::read_PLY_BGL(is, g, np);
|
||||
return IO::internal::read_PLY_BGL(is, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_PLY(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return IO::internal::read_PLY_BGL(fname.c_str(), g, np);
|
||||
return IO::internal::read_PLY_BGL(fname.c_str(), g, np, verbose);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -45,15 +45,16 @@ class STL_builder
|
|||
typedef typename Base::Face_container Face_container;
|
||||
|
||||
public:
|
||||
STL_builder(std::istream& is_) : Base(is_) { }
|
||||
STL_builder(std::istream& is_, bool verbose) : Base(is_, verbose) { }
|
||||
|
||||
template <typename NamedParameters>
|
||||
bool read(std::istream& input,
|
||||
Point_container& points,
|
||||
Face_container& faces,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose)
|
||||
{
|
||||
return read_STL(input, points, faces, np);
|
||||
return read_STL(input, points, faces, np, verbose);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -63,26 +64,29 @@ public:
|
|||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_STL(std::istream& in,
|
||||
FaceGraph& g,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename CGAL::GetVertexPointMap<FaceGraph, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
typedef typename boost::property_traits<VPM>::value_type Point;
|
||||
|
||||
IO::internal::STL_builder<FaceGraph, Point> builder(in);
|
||||
IO::internal::STL_builder<FaceGraph, Point> builder(in, verbose);
|
||||
return builder(g, np);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_STL(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_STL(const char* fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_STL(in, g, np);
|
||||
return read_STL(in, g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_STL(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_STL(const std::string& fname, FaceGraph& g, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_STL(fname.c_str(), g, np);
|
||||
return read_STL(fname.c_str(), g, np, verbose);
|
||||
}
|
||||
|
||||
template <typename FaceGraph>
|
||||
|
|
|
|||
|
|
@ -22,44 +22,111 @@
|
|||
#include <CGAL/boost/graph/IO/WRL.h>
|
||||
|
||||
namespace CGAL{
|
||||
|
||||
/*!
|
||||
*
|
||||
*/
|
||||
template <class FaceGraph, typename NamedParameters>
|
||||
bool read_polygon_mesh(std::istream& is,
|
||||
FaceGraph& g,
|
||||
const NamedParameters& np)
|
||||
{
|
||||
bool ok = false;
|
||||
ok = read_OFF(is, g, np);
|
||||
ok = read_OFF(is, g, np, false);
|
||||
if(ok)
|
||||
return true;
|
||||
g.clear();
|
||||
is.clear();//reset the error state
|
||||
is.seekg (0, is.beg);
|
||||
ok = read_OBJ(is, g, np);
|
||||
ok = read_OBJ(is, g, np, false);
|
||||
if(ok)
|
||||
return true;
|
||||
g.clear();
|
||||
is.clear();
|
||||
is.seekg (0, is.beg);
|
||||
ok = read_PLY(is, g, np);
|
||||
ok = read_PLY(is, g, np, false);
|
||||
if(ok)
|
||||
return true;
|
||||
g.clear();
|
||||
is.clear();
|
||||
is.seekg (0, is.beg);
|
||||
ok = read_STL(is, g, np);
|
||||
ok = read_STL(is, g, np, false);
|
||||
if(ok)
|
||||
return true;
|
||||
g.clear();
|
||||
is.clear();
|
||||
is.seekg (0, is.beg);
|
||||
ok = read_GOCAD(is, g, np);
|
||||
ok = read_GOCAD(is, g, np, false);
|
||||
return ok;
|
||||
}
|
||||
|
||||
template <class FaceGraph>
|
||||
bool read_polygon_mesh(std::istream& is,
|
||||
FaceGraph& g)
|
||||
{
|
||||
return read_polygon_mesh(is, g, parameters::all_default());
|
||||
}
|
||||
|
||||
/*!
|
||||
*
|
||||
*/
|
||||
template <class FaceGraph, typename NamedParameters>
|
||||
bool read_polygon_mesh(const std::string& fname,
|
||||
FaceGraph& g,
|
||||
const NamedParameters& np)
|
||||
{
|
||||
if (fname.find(".TS") != std::string::npos) {
|
||||
return read_GOCAD(fname, g, np);
|
||||
}
|
||||
|
||||
if (fname.find(".obj") != std::string::npos) {
|
||||
return read_OBJ(fname, g, np);
|
||||
}
|
||||
|
||||
if (fname.find(".off") != std::string::npos) {
|
||||
return read_OFF(fname, g, np);
|
||||
}
|
||||
|
||||
if (fname.find(".ply") != std::string::npos) {
|
||||
return read_PLY(fname, g, np);
|
||||
}
|
||||
|
||||
if (fname.find(".stl") != std::string::npos) {
|
||||
return read_STL(fname, g, np);
|
||||
}
|
||||
|
||||
if (fname.find(".vtp") != std::string::npos) {
|
||||
return read_VTP(fname, g, np);
|
||||
}
|
||||
|
||||
std::istream is(fname.c_str());
|
||||
return read_polygon_mesh(is, g, np, false);
|
||||
}
|
||||
|
||||
template <class FaceGraph>
|
||||
bool read_polygon_mesh(const std::string& fname,
|
||||
FaceGraph& g)
|
||||
{
|
||||
return read_polygon_mesh(fname, g, parameters::all_default());
|
||||
}
|
||||
|
||||
|
||||
|
||||
template <class FaceGraph, typename NamedParameters>
|
||||
bool read_polygon_mesh(const char* fname,
|
||||
FaceGraph& g,
|
||||
const NamedParameters& np)
|
||||
{
|
||||
return read_polygon_mesh(std::string(fname), g, np);
|
||||
}
|
||||
|
||||
template <class FaceGraph>
|
||||
bool read_polygon_mesh(const char* fname,
|
||||
FaceGraph& g)
|
||||
{
|
||||
return read_polygon_mesh(fname, g, parameters::all_default());
|
||||
}
|
||||
|
||||
|
||||
}//end CGAL
|
||||
#endif // CGAL_BOOST_GRAPH_IO_H
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ void test_bgl_OFF(const char* filename)
|
|||
Mesh sm;
|
||||
std::ifstream in(filename);
|
||||
CGAL::read_polygon_mesh(in,sm);
|
||||
|
||||
CGAL::write_OFF(std::cout, sm);
|
||||
}
|
||||
|
||||
|
|
@ -564,7 +565,7 @@ int main(int argc, char** argv)
|
|||
{
|
||||
const char* filename=(argc>1) ? argv[1] : "data/prim.off";
|
||||
// OFF
|
||||
/*test_bgl_OFF<Polyhedron>(filename);
|
||||
test_bgl_OFF<Polyhedron>(filename);
|
||||
test_bgl_OFF<SM>(filename);
|
||||
test_bgl_OFF<LCC>(filename);
|
||||
#ifdef CGAL_USE_OPENMESH
|
||||
|
|
@ -594,7 +595,7 @@ int main(int argc, char** argv)
|
|||
#ifdef CGAL_USE_OPENMESH
|
||||
test_bgl_OBJ_with_np<OMesh>();
|
||||
#endif
|
||||
*/
|
||||
|
||||
|
||||
//PLY
|
||||
if(!test_bgl_PLY<Polyhedron>())
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
// $URL$
|
||||
// $Id$
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-Commercial
|
||||
//
|
||||
//
|
||||
//
|
||||
// Author(s) : Lutz Kettner <kettner@mpi-sb.mpg.de>
|
||||
|
||||
|
|
@ -62,7 +62,7 @@ template <class Traits,
|
|||
class Alloc, class CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(std::istream& in,
|
||||
Polyhedron_3<Traits, Items, HDS, Alloc>& P,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np, bool verbose = true)
|
||||
{
|
||||
// reads a polyhedron from `in' and appends it to P.
|
||||
typedef typename CGAL::GetVertexPointMap<Polyhedron_3<Traits, Items, HDS, Alloc>, CGAL_BGL_NP_CLASS>::type VPM;
|
||||
|
|
@ -70,7 +70,7 @@ bool read_OFF(std::istream& in,
|
|||
using parameters::choose_parameter;
|
||||
using parameters::get_parameter;
|
||||
|
||||
CGAL::scan_OFF(in, P);
|
||||
CGAL::scan_OFF(in, P, verbose);
|
||||
|
||||
if(!parameters::is_default_parameter(get_parameter(np, internal_np::vertex_point)))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ template <class Traits,
|
|||
class HDS, class Alloc>
|
||||
void scan_OFF(std::istream& in,
|
||||
Polyhedron_3<Traits, Items, HDS, Alloc>& P,
|
||||
bool verbose = false)
|
||||
bool verbose = true)
|
||||
{
|
||||
// reads a polyhedron from `in' and appends it to P.
|
||||
typedef Polyhedron_3<Traits, Items, HDS, Alloc> Polyhedron;
|
||||
|
|
|
|||
|
|
@ -39,8 +39,10 @@ bool read_GOCAD(std::istream& input,
|
|||
std::pair<std::string, std::string>& name_and_color,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const NamedParameters&)
|
||||
const NamedParameters&,
|
||||
bool verbose = true)
|
||||
{
|
||||
CGAL_USE(verbose);
|
||||
typedef typename boost::range_value<PointRange>::type Point;
|
||||
typedef typename boost::range_value<PolygonRange>::type CGAL_Polygon;
|
||||
int offset = 0;
|
||||
|
|
|
|||
|
|
@ -37,7 +37,8 @@ template <typename PointRange, typename PolygonRange, typename VertexNormalOutpu
|
|||
bool read_OBJ(std::istream& is,
|
||||
PointRange& points,
|
||||
PolygonRange& faces,
|
||||
VertexNormalOutputIterator vn_out)
|
||||
VertexNormalOutputIterator vn_out,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename boost::range_value<PointRange>::type Point;
|
||||
typedef typename CGAL::Kernel_traits<Point>::Kernel Kernel;
|
||||
|
|
@ -103,12 +104,14 @@ bool read_OBJ(std::istream& is,
|
|||
}
|
||||
if(maxi<0)
|
||||
{
|
||||
//not a OBJ file
|
||||
if(verbose)
|
||||
std::cerr<<"No face detected."<<std::endl;
|
||||
return false;
|
||||
}
|
||||
if(maxi > static_cast<int>(points.size()) || mini < -static_cast<int>(points.size()))
|
||||
{
|
||||
std::cerr << "a face index is invalid " << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "a face index is invalid " << std::endl;
|
||||
return false;
|
||||
}
|
||||
bool res = is.bad();
|
||||
|
|
@ -123,30 +126,34 @@ template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPL
|
|||
bool read_OBJ(std::istream& is,
|
||||
PointRange& points,
|
||||
PolygonRange& faces,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
using parameters::choose_parameter;
|
||||
using parameters::get_parameter;
|
||||
|
||||
return IO::internal::read_OBJ(is, points, faces,
|
||||
choose_parameter(get_parameter(np, internal_np::vertex_normal_output_iterator),
|
||||
CGAL::Emptyset_iterator()));
|
||||
CGAL::Emptyset_iterator()),
|
||||
verbose);
|
||||
}
|
||||
|
||||
template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OBJ(const char* fname,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_OBJ(in, points, polygons, np);
|
||||
return read_OBJ(in, points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OBJ(const std::string& fname, PointRange& points, PolygonRange& polygons, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_OBJ(const std::string& fname, PointRange& points, PolygonRange& polygons, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_OBJ(fname.c_str(), points, polygons, np);
|
||||
return read_OBJ(fname.c_str(), points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
//! \ingroup IOstreamFunctions
|
||||
|
|
|
|||
|
|
@ -49,8 +49,10 @@ bool read_OFF(std::istream& is,
|
|||
VertexNormalOutputIterator vn_out,
|
||||
VertexColorOutputIterator vc_out,
|
||||
VertexTextureOutputIterator vt_out,
|
||||
FaceColorOutputIterator fc_out)
|
||||
FaceColorOutputIterator fc_out,
|
||||
bool verbose = true)
|
||||
{
|
||||
CGAL_USE(verbose);
|
||||
typedef typename boost::range_value<PointRange>::type Point;
|
||||
typedef typename CGAL::Kernel_traits<Point>::Kernel Kernel;
|
||||
typedef typename Kernel::Point_2 Texture;
|
||||
|
|
@ -154,7 +156,8 @@ template <typename PointRange, typename PolygonRange, typename NamedParameters>
|
|||
bool read_OFF(std::istream& is,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const NamedParameters& np)
|
||||
const NamedParameters& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
using parameters::choose_parameter;
|
||||
using parameters::get_parameter;
|
||||
|
|
@ -167,23 +170,26 @@ bool read_OFF(std::istream& is,
|
|||
choose_parameter(get_parameter(np, internal_np::vertex_texture_output_iterator),
|
||||
CGAL::Emptyset_iterator()),
|
||||
choose_parameter(get_parameter(np, internal_np::face_color_output_iterator),
|
||||
CGAL::Emptyset_iterator()));
|
||||
CGAL::Emptyset_iterator()),
|
||||
verbose);
|
||||
}
|
||||
|
||||
template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(const char* fname,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ifstream in(fname);
|
||||
return read_OFF(in, points, polygons, np);
|
||||
return read_OFF(in, points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_OFF(const std::string& fname, PointRange& points, PolygonRange& polygons, const CGAL_BGL_NP_CLASS& np)
|
||||
bool read_OFF(const std::string& fname, PointRange& points, PolygonRange& polygons, const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_OFF(fname.c_str(), points, polygons, np);
|
||||
return read_OFF(fname.c_str(), points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
|
|
|||
|
|
@ -241,11 +241,6 @@ std::istream& operator>>( std::istream& in, File_header_OFF& h) {
|
|||
}
|
||||
if ( ! in )
|
||||
return in;
|
||||
if( ! h.off_header())
|
||||
{
|
||||
in.clear( std::ios::badbit);
|
||||
return in;
|
||||
}
|
||||
h.set_skel(false);
|
||||
h.set_binary(false);
|
||||
h.set_index_offset(1);
|
||||
|
|
@ -265,7 +260,14 @@ std::istream& operator>>( std::istream& in, File_header_OFF& h) {
|
|||
keyword[i] = '\0';
|
||||
if ( i < 2 || (std::isdigit(keyword[0]) && keyword[0] != '4')
|
||||
|| std::isdigit(keyword[1])) {
|
||||
h.set_vertices( std::atoi( keyword));
|
||||
in.clear( std::ios::badbit);
|
||||
if ( h.verbose()) {
|
||||
std::cerr << " " << std::endl;
|
||||
std::cerr << "error: File_header_OFF: "
|
||||
"Missing header."
|
||||
<< std::endl;
|
||||
}
|
||||
return in;
|
||||
} else {
|
||||
h.set_index_offset( 0);
|
||||
int j = 0;
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ bool read_PLY(std::istream& is,
|
|||
ColorOutputIterator fc_out,
|
||||
ColorOutputIterator vc_out,
|
||||
HUVOutputIterator huvs_out,
|
||||
bool /* verbose */ = false,
|
||||
bool verbose = true,
|
||||
typename std::enable_if<
|
||||
CGAL::is_iterator<ColorOutputIterator>::value
|
||||
>::type* =0)
|
||||
|
|
@ -48,11 +48,12 @@ bool read_PLY(std::istream& is,
|
|||
typedef CGAL::Color Color_rgb;
|
||||
if(!is.good())
|
||||
{
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
IO::internal::PLY_reader reader;
|
||||
IO::internal::PLY_reader reader(verbose);
|
||||
|
||||
if(!(reader.init(is)))
|
||||
{
|
||||
|
|
@ -124,7 +125,8 @@ bool read_PLY(std::istream& is,
|
|||
IO::internal::read_PLY_faces<boost::uint32_t>(is, element, polygons, fc_out, "vertex_index");
|
||||
else
|
||||
{
|
||||
std::cerr << "Error: can't find vertex indices in PLY input" << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "Error: can't find vertex indices in PLY input" << std::endl;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -203,12 +205,12 @@ bool read_PLY(std::istream& is,
|
|||
ColorRange& fcolors,
|
||||
ColorRange& vcolors,
|
||||
HUVRange& huvs,
|
||||
bool /* verbose */ = false,
|
||||
bool verbose =true,
|
||||
typename std::enable_if<
|
||||
!CGAL::is_iterator<ColorRange>::value
|
||||
>::type* =0)
|
||||
{
|
||||
return IO::internal::read_PLY(is, points, polygons, std::back_inserter(hedges), std::back_inserter(fcolors), std::back_inserter(vcolors), std::back_inserter(huvs));
|
||||
return IO::internal::read_PLY(is, points, polygons, std::back_inserter(hedges), std::back_inserter(fcolors), std::back_inserter(vcolors), std::back_inserter(huvs), verbose);
|
||||
}
|
||||
template <class PointRange, class PolygonRange, class ColorRange>
|
||||
bool read_PLY(std::istream& is,
|
||||
|
|
@ -216,19 +218,20 @@ bool read_PLY(std::istream& is,
|
|||
PolygonRange& polygons,
|
||||
ColorRange& fcolors,
|
||||
ColorRange& vcolors,
|
||||
bool /* verbose */ = false)
|
||||
bool verbose = true)
|
||||
{
|
||||
std::vector<std::pair<unsigned int, unsigned int> > dummy_pui;
|
||||
std::vector<std::pair<float, float> > dummy_pf;
|
||||
return IO::internal::read_PLY(is, points, polygons, dummy_pui, std::back_inserter(fcolors), std::back_inserter(vcolors), dummy_pf);
|
||||
return IO::internal::read_PLY(is, points, polygons, dummy_pui, std::back_inserter(fcolors), std::back_inserter(vcolors), dummy_pf, verbose);
|
||||
}
|
||||
|
||||
|
||||
template <typename PointRange, typename PolygonRange, typename NamedParameters>
|
||||
template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPLATE_PARAMETERS>
|
||||
bool read_PLY(std::istream& is,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const NamedParameters& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
|
||||
using parameters::choose_parameter;
|
||||
|
|
@ -241,7 +244,7 @@ bool read_PLY(std::istream& is,
|
|||
CGAL::Emptyset_iterator()),
|
||||
choose_parameter(get_parameter(np, internal_np::vertex_color_output_iterator),
|
||||
CGAL::Emptyset_iterator()),
|
||||
std::back_inserter(dummy_pf));
|
||||
std::back_inserter(dummy_pf), verbose);
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -263,7 +266,8 @@ template <class PointRange, class PolygonRange>
|
|||
bool
|
||||
read_PLY(std::istream& is,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons
|
||||
PolygonRange& polygons,
|
||||
bool verbose = true
|
||||
#ifndef DOXYGEN_RUNNING
|
||||
,typename std::enable_if<
|
||||
boost::has_value_type<PointRange>::value
|
||||
|
|
@ -274,11 +278,12 @@ read_PLY(std::istream& is,
|
|||
typedef typename PointRange::value_type Point_3;
|
||||
if(!is.good())
|
||||
{
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
IO::internal::PLY_reader reader;
|
||||
IO::internal::PLY_reader reader(verbose);
|
||||
|
||||
if(!(reader.init(is)))
|
||||
{
|
||||
|
|
@ -325,7 +330,8 @@ read_PLY(std::istream& is,
|
|||
IO::internal::read_PLY_faces<boost::uint32_t>(is, element, polygons, dummy, "vertex_index");
|
||||
else
|
||||
{
|
||||
std::cerr << "Error: can't find vertex indices in PLY input" << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "Error: can't find vertex indices in PLY input" << std::endl;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -352,10 +358,11 @@ template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPL
|
|||
bool read_PLY(const char* fname,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
std::ofstream os(fname);
|
||||
return read_PLY(os, points, polygons, np);
|
||||
return read_PLY(os, points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
|
@ -383,9 +390,10 @@ template <typename PointRange, typename PolygonRange, typename CGAL_BGL_NP_TEMPL
|
|||
bool read_PLY(const std::string& fname,
|
||||
PointRange& points,
|
||||
PolygonRange& polygons,
|
||||
const CGAL_BGL_NP_CLASS& np)
|
||||
const CGAL_BGL_NP_CLASS& np,
|
||||
bool verbose = true)
|
||||
{
|
||||
return read_PLY(fname.c_str(), points, polygons, np);
|
||||
return read_PLY(fname.c_str(), points, polygons, np, verbose);
|
||||
}
|
||||
|
||||
template <typename PointRange, typename PolygonRange>
|
||||
|
|
|
|||
|
|
@ -414,9 +414,10 @@ class PLY_reader
|
|||
{
|
||||
std::vector<PLY_element> m_elements;
|
||||
std::string m_comments;
|
||||
bool m_verbose;
|
||||
|
||||
public:
|
||||
PLY_reader() { }
|
||||
PLY_reader(bool verbose) : m_verbose(verbose) { }
|
||||
|
||||
std::size_t number_of_elements() const { return m_elements.size(); }
|
||||
PLY_element& element(std::size_t idx)
|
||||
|
|
@ -449,7 +450,8 @@ public:
|
|||
if(!(iss >> signature) || (signature != "ply"))
|
||||
{
|
||||
// if wrong file format
|
||||
std::cerr << "Error: incorrect file format line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error: incorrect file format line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -460,7 +462,8 @@ public:
|
|||
std::string tag, format_string, version;
|
||||
if( !(iss >> tag >> format_string >> version) )
|
||||
{
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
if(format_string == "ascii") format = ASCII;
|
||||
|
|
@ -468,7 +471,8 @@ public:
|
|||
else if(format_string == "binary_big_endian") format = BINARY_BIG_ENDIAN;
|
||||
else
|
||||
{
|
||||
std::cerr << "Error: unknown file format \"" << format_string << "\" line " << lineNumber << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error: unknown file format \"" << format_string << "\" line " << lineNumber << std::endl;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -479,7 +483,8 @@ public:
|
|||
std::string keyword;
|
||||
if(!(iss >> keyword))
|
||||
{
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -488,7 +493,8 @@ public:
|
|||
std::string type, name;
|
||||
if(!(iss >> type >> name))
|
||||
{
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -500,7 +506,8 @@ public:
|
|||
name.clear();
|
||||
if(!(iss >> index_type >> name))
|
||||
{
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -542,7 +549,8 @@ public:
|
|||
std::size_t number;
|
||||
if(!(iss >> type >> number))
|
||||
{
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
if(m_verbose)
|
||||
std::cerr << "Error line " << lineNumber << " of file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -34,9 +34,9 @@ template <typename PointRange, typename TriangleRange, typename CGAL_BGL_NP_TEMP
|
|||
bool read_STL(std::istream& is,
|
||||
PointRange& points,
|
||||
TriangleRange& facets,
|
||||
const CGAL_BGL_NP_CLASS& /*np*/) // might become useful one day for face normals
|
||||
const CGAL_BGL_NP_CLASS& /*np*/,
|
||||
bool verbose = true) // might become useful one day for face normals
|
||||
{
|
||||
const bool verbose = false;
|
||||
int pos = 0;
|
||||
|
||||
// Ignore all initial whitespace
|
||||
|
|
|
|||
|
|
@ -59,8 +59,7 @@ bool read_OFF(std::istream& is,
|
|||
#else
|
||||
const NamedParameters& np
|
||||
#endif
|
||||
|
||||
)
|
||||
, bool verbose = true)
|
||||
{
|
||||
typedef Surface_mesh<Point> Mesh;
|
||||
typedef typename Mesh::Vertex_index Vertex_index;
|
||||
|
|
@ -97,7 +96,8 @@ bool read_OFF(std::istream& is,
|
|||
.vertex_normal_map(vnormals)
|
||||
.vertex_color_map(vcolors)
|
||||
.vertex_texture_map(vtextures)
|
||||
.face_color_map(fcolors));
|
||||
.face_color_map(fcolors),
|
||||
verbose);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
|
|||
|
|
@ -932,13 +932,15 @@ bool write_PLY(std::ostream& os,
|
|||
template <typename P>
|
||||
bool read_PLY(std::istream& is,
|
||||
Surface_mesh<P>& sm,
|
||||
std::string& comments)
|
||||
std::string& comments,
|
||||
bool verbose = true)
|
||||
{
|
||||
typedef typename Surface_mesh<P>::size_type size_type;
|
||||
|
||||
if(!is.good())
|
||||
{
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
if(verbose)
|
||||
std::cerr << "Error: cannot open file" << std::endl;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue