Skip to content
This repository has been archived by the owner on Sep 16, 2023. It is now read-only.

Commit

Permalink
Keeps dynamic option after remesh
Browse files Browse the repository at this point in the history
  • Loading branch information
stephomi committed Apr 15, 2017
1 parent b756720 commit 4b7d272
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/gui/GuiTopology.js
Expand Up @@ -72,6 +72,8 @@ class GuiMultiresolution {
if (!mesh)
return;

var wasDynamic = mesh.isDynamic;

var meshes = main.getMeshes();
var selMeshes = main.getSelectedMeshes().slice();
for (var i = 0, l = selMeshes.length; i < l; ++i) {
Expand All @@ -81,7 +83,9 @@ class GuiMultiresolution {
if (sel === mesh)
mesh = selMeshes[i];
}

var newMesh = Remesh.remesh(selMeshes, mesh);
if (wasDynamic) newMesh = new MeshDynamic(newMesh);
main.getStateManager().pushStateAddRemove(newMesh, main.getSelectedMeshes().slice());
main.getMeshes().push(newMesh);
main.setMesh(newMesh);
Expand Down

0 comments on commit 4b7d272

Please sign in to comment.