Use settings for global brush parmeters.

This commit is contained in:
brunoherbelin
2021-01-24 19:23:51 +01:00
parent 2dda3da8b1
commit 83e5c37b60
3 changed files with 29 additions and 9 deletions

View File

@@ -110,6 +110,11 @@ void Settings::Save()
SourceConfNode->SetAttribute("res", application.source.res);
pRoot->InsertEndChild(SourceConfNode);
// Brush
XMLElement *BrushNode = xmlDoc.NewElement( "Brush" );
BrushNode->InsertEndChild( XMLElementFromGLM(&xmlDoc, application.brush) );
pRoot->InsertEndChild(BrushNode);
// bloc connections
{
XMLElement *connectionsNode = xmlDoc.NewElement( "Connections" );
@@ -326,6 +331,12 @@ void Settings::Load()
}
}
// Brush
XMLElement * brushnode = pRoot->FirstChildElement("Brush");
if (brushnode != nullptr) {
tinyxml2::XMLElementToGLM( brushnode->FirstChildElement("vec3"), application.brush);
}
// bloc views
{
application.views.clear(); // trash existing list