Skip to content

Commit

Permalink
Merge pull request #586 from antoine-galataud/fix_585
Browse files Browse the repository at this point in the history
render scene when camera option changes
  • Loading branch information
macumber authored Dec 30, 2022
2 parents 60d4e56 + f7f420d commit 8444dd5
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions src/openstudio_lib/library/geometry_preview.html
Original file line number Diff line number Diff line change
Expand Up @@ -3199,13 +3199,19 @@
f2.open();

var f3 = gui.addFolder('Camera');
f3.add(settings, 'orthographic').name('Orthographic').onChange(function (value) {
setLocalStorage('orthographic', value);
[
["orthographic", "Orthographic"],
["xView", "X View"],
["yView", "Y View"],
["zView", "Z View"],
["reset", "Reset"]
].forEach(opt => {
f3.add(settings, opt[0]).name(opt[1]).onChange(function (value) {
if (opt[0] === "orthographic")
setLocalStorage(opt[0], value);
update(value);
});
});
f3.add(settings, 'xView').name('X View');
f3.add(settings, 'yView').name('Y View');
f3.add(settings, 'zView').name('Z View');
f3.add(settings, 'reset').name('Reset');
f3.open();

/*var f2 = gui.addFolder('Section Cut');
Expand Down

0 comments on commit 8444dd5

Please sign in to comment.