X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FExchangePlugin%2FExchangePlugin_ExportFeature.cpp;h=f4ff3d3ad9fa976278264117b9b8005ad04e6db5;hb=676ee79de539b14b242a561857c1505cce13d951;hp=a399b646ee9ac6108fad65f45bfc9896a973ec7e;hpb=cbde248859fb0072f6012907391ea90cfc254574;p=modules%2Fshaper.git diff --git a/src/ExchangePlugin/ExchangePlugin_ExportFeature.cpp b/src/ExchangePlugin/ExchangePlugin_ExportFeature.cpp index a399b646e..f4ff3d3ad 100644 --- a/src/ExchangePlugin/ExchangePlugin_ExportFeature.cpp +++ b/src/ExchangePlugin/ExchangePlugin_ExportFeature.cpp @@ -90,8 +90,14 @@ void ExchangePlugin_ExportFeature::execute() if (aCurShape.get() != NULL) aShapes.push_back(aCurShape); } - std::shared_ptr aShape = - GeomAlgoAPI_CompoundBuilder::compound(aShapes); + + // Store compound if we have more than one shape. + std::shared_ptr aShape; + if(aShapes.size() == 1) { + aShape = aShapes.front(); + } else { + aShape = GeomAlgoAPI_CompoundBuilder::compound(aShapes); + } exportFile(aFilePath, aFormat, aShape); }