stub in menu for normals inversion
This commit is contained in:
parent
c3049ba546
commit
7d80ed2904
3 changed files with 19 additions and 0 deletions
|
|
@ -313,6 +313,12 @@ let tool = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
invert() {
|
||||||
|
for (let m of selection.models(true)) {
|
||||||
|
m.invert(api.mode.get());
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
analyze(models) {
|
analyze(models) {
|
||||||
models = fallback(models);
|
models = fallback(models);
|
||||||
api.log.emit('analyzing mesh(es)...').pin();
|
api.log.emit('analyzing mesh(es)...').pin();
|
||||||
|
|
|
||||||
|
|
@ -242,6 +242,7 @@ function ui_build() {
|
||||||
h.div({ class: "vsep" }),
|
h.div({ class: "vsep" }),
|
||||||
h.button({ _: 'duplicate', onclick: tool.duplicate }),
|
h.button({ _: 'duplicate', onclick: tool.duplicate }),
|
||||||
h.button({ _: 'merge', onclick: tool.merge }),
|
h.button({ _: 'merge', onclick: tool.merge }),
|
||||||
|
h.button({ _: 'invert', onclick: tool.invert }),
|
||||||
h.div({ class: "vsep" }),
|
h.div({ class: "vsep" }),
|
||||||
h.button({ _: 'analyze', onclick: tool.analyze }),
|
h.button({ _: 'analyze', onclick: tool.analyze }),
|
||||||
h.button({ _: 'repair', onclick: tool.repair }),
|
h.button({ _: 'repair', onclick: tool.repair }),
|
||||||
|
|
|
||||||
|
|
@ -303,6 +303,18 @@ mesh.model = class MeshModel extends mesh.object {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// invert normals for entire mesh or selected faces depending on mod
|
||||||
|
invert(mode) {
|
||||||
|
let { modes } = mesh.api;
|
||||||
|
switch (mode) {
|
||||||
|
case modes.object:
|
||||||
|
break;
|
||||||
|
case modes.face:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// remove model from group and space
|
||||||
remove() {
|
remove() {
|
||||||
if (arguments.length === 0) {
|
if (arguments.length === 0) {
|
||||||
// direct call requires pass through group
|
// direct call requires pass through group
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue