From 154d1b31ba9b42668bf56199ed3c03d75cfbde7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20M=C3=B6bius?= Date: Thu, 18 Nov 2010 07:20:06 +0000 Subject: [PATCH] Read diffuse colors from vertices in ply git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@345 fdac6126-5c0c-442c-9429-916003d36597 --- src/OpenMesh/Core/IO/reader/PLYReader.cc | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/OpenMesh/Core/IO/reader/PLYReader.cc b/src/OpenMesh/Core/IO/reader/PLYReader.cc index d7a1aff4..4ea06503 100644 --- a/src/OpenMesh/Core/IO/reader/PLYReader.cc +++ b/src/OpenMesh/Core/IO/reader/PLYReader.cc @@ -956,6 +956,18 @@ bool _PLYReader_::can_u_read(std::istream& _is) const { std::pair entry(COLORBLUE, valueType); vertexPropertyMap_[vertexPropertyCount_] = entry; options_ += Options::VertexColor; + } else if (propertyName == "diffuse_red") { + std::pair entry(COLORRED, valueType); + vertexPropertyMap_[vertexPropertyCount_] = entry; + options_ += Options::VertexColor; + } else if (propertyName == "diffuse_green") { + std::pair entry(COLORGREEN, valueType); + vertexPropertyMap_[vertexPropertyCount_] = entry; + options_ += Options::VertexColor; + } else if (propertyName == "diffuse_blue") { + std::pair entry(COLORBLUE, valueType); + vertexPropertyMap_[vertexPropertyCount_] = entry; + options_ += Options::VertexColor; } else if (propertyName == "alpha") { std::pair entry(COLORALPHA, valueType); vertexPropertyMap_[vertexPropertyCount_] = entry;