mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0033751: Shape Healing - Use static values in case of an absent Resource file
If a Resource file with parameters for ShapeFix is absent, use static parameters instead if possible.
This commit is contained in:
@@ -104,17 +104,12 @@ TopoDS_Shape XSAlgo_AlgoContainer::ProcessShape(const TopoDS_Shape& theShape,
|
||||
if (aContext.IsNull())
|
||||
{
|
||||
Standard_CString aRscfile = Interface_Static::CVal(thePrscfile);
|
||||
if (aRscfile != nullptr && strlen(aRscfile) == 0)
|
||||
aContext = new ShapeProcess_ShapeContext(theShape, aRscfile);
|
||||
if (!aContext->ResourceManager()->IsInitialized())
|
||||
{
|
||||
aContext = new ShapeProcess_ShapeContext(theShape, nullptr);
|
||||
// If resource file wasn't found, use static values instead
|
||||
Interface_Static::FillMap(aContext->ResourceManager()->GetMap());
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!aRscfile)
|
||||
aRscfile = thePrscfile;
|
||||
aContext = new ShapeProcess_ShapeContext(theShape, aRscfile);
|
||||
}
|
||||
aContext->SetDetalisation(theDetalisationLevel);
|
||||
}
|
||||
aContext->SetNonManifold(theNonManifold);
|
||||
|
Reference in New Issue
Block a user