Read diffuse colors from vertices in ply

git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@345 fdac6126-5c0c-442c-9429-916003d36597
This commit is contained in:
Jan Möbius
2010-11-18 07:20:06 +00:00
parent aebb76edbe
commit 154d1b31ba

View File

@@ -956,6 +956,18 @@ bool _PLYReader_::can_u_read(std::istream& _is) const {
std::pair<VertexProperty, ValueType> entry(COLORBLUE, valueType); std::pair<VertexProperty, ValueType> entry(COLORBLUE, valueType);
vertexPropertyMap_[vertexPropertyCount_] = entry; vertexPropertyMap_[vertexPropertyCount_] = entry;
options_ += Options::VertexColor; options_ += Options::VertexColor;
} else if (propertyName == "diffuse_red") {
std::pair<VertexProperty, ValueType> entry(COLORRED, valueType);
vertexPropertyMap_[vertexPropertyCount_] = entry;
options_ += Options::VertexColor;
} else if (propertyName == "diffuse_green") {
std::pair<VertexProperty, ValueType> entry(COLORGREEN, valueType);
vertexPropertyMap_[vertexPropertyCount_] = entry;
options_ += Options::VertexColor;
} else if (propertyName == "diffuse_blue") {
std::pair<VertexProperty, ValueType> entry(COLORBLUE, valueType);
vertexPropertyMap_[vertexPropertyCount_] = entry;
options_ += Options::VertexColor;
} else if (propertyName == "alpha") { } else if (propertyName == "alpha") {
std::pair<VertexProperty, ValueType> entry(COLORALPHA, valueType); std::pair<VertexProperty, ValueType> entry(COLORALPHA, valueType);
vertexPropertyMap_[vertexPropertyCount_] = entry; vertexPropertyMap_[vertexPropertyCount_] = entry;