Skip to content
Snippets Groups Projects
Commit ee81c49b authored by Rainer Kartmann's avatar Rainer Kartmann
Browse files

Fix NDArray dimensions in Pose, Orientation and Position

parent db8b3f72
No related branches found
No related tags found
2 merge requests!140armem/dev -> master,!133Add Object Memory with Class and Instance Segments
......@@ -81,7 +81,7 @@ namespace armarx::aron::cppcodegenerator::serializer
CppBlockPtr OrientationSerializer::getWriteBlock(const std::string& accessor) const
{
CppBlockPtr b = CppBlockPtr(new CppBlock());
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + "}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".coeffs().data()));");
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + ", 4}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".coeffs().data()));");
return b;
}
......
......@@ -81,7 +81,7 @@ namespace armarx::aron::cppcodegenerator::serializer
CppBlockPtr PoseSerializer::getWriteBlock(const std::string& accessor) const
{
CppBlockPtr b = CppBlockPtr(new CppBlock());
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + "}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".data()));");
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + ", 4}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".data()));");
return b;
}
......
......@@ -81,7 +81,7 @@ namespace armarx::aron::cppcodegenerator::serializer
CppBlockPtr PositionSerializer::getWriteBlock(const std::string& accessor) const
{
CppBlockPtr b = CppBlockPtr(new CppBlock());
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + "}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".data()));");
b->addLine("w.writeNDArray({" + simox::alg::to_string(typenavigator->getDimensions(), ", ") + ", 4}, \"" + typenavigator->getTypename() + "\", reinterpret_cast<const unsigned char*>(" + accessor + ".data()));");
return b;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment