Cleanup blobs

This commit is contained in:
luboslenco
2019-03-04 13:21:14 +01:00
parent cf44396d3d
commit b9560f27fc
3 changed files with 9 additions and 0 deletions
+4
View File
@@ -397,6 +397,7 @@ class Importer {
obj = new iron.format.obj.ObjParser(b, obj.pos);
addMesh(obj);
}
iron.data.Data.deleteBlob(path);
});
}
@@ -404,6 +405,7 @@ class Importer {
iron.data.Data.getBlob(path, function(b:kha.Blob) {
var obj = new iron.format.gltf.GltfParser(b);
makeMesh(obj, path);
iron.data.Data.deleteBlob(path);
});
}
@@ -414,6 +416,7 @@ class Importer {
while (obj.next()) {
addMesh(obj);
}
iron.data.Data.deleteBlob(path);
});
}
@@ -564,6 +567,7 @@ class Importer {
name = name.substring(2, name.length);
var obj = {posa: posa, nora: nora, texa: texa, inda: inda, name: name, scalePos: scalePos, scaleTes: 1.0};
makeMesh(obj, path);
iron.data.Data.deleteBlob(path);
});
}
+2
View File
@@ -259,6 +259,8 @@ class Project {
UITrait.inst.ddirty = 4;
UITrait.inst.hwnd.redraws = 2;
iron.data.Data.deleteBlob(path);
});
}
}
+3
View File
@@ -1750,6 +1750,9 @@ class UITrait extends iron.Trait {
ui.row([1/2, 1/2]);
drawWireframe = ui.check(wireframeHandle, "Wireframe");
if (wireframeHandle.changed) {
ui.g.end();
UIView2D.inst.cacheUVMap();
ui.g.begin(false);
UINodes.inst.parseMeshMaterial();
ddirty = 2;
}