|
@@ -73071,6 +73071,8 @@ var AbstractViewer = (function () {
|
|
|
window.addEventListener('resize', function () {
|
|
|
_this.engine.resize();
|
|
|
});
|
|
|
+ var scale = Math.max(0.5, 1 / (window.devicePixelRatio || 2));
|
|
|
+ this.engine.setHardwareScalingLevel(scale);
|
|
|
return Promise.resolve(this.engine);
|
|
|
};
|
|
|
AbstractViewer.prototype.initScene = function () {
|
|
@@ -75866,7 +75868,11 @@ var DefaultViewer = (function (_super) {
|
|
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
|
}
|
|
|
DefaultViewer.prototype.initScene = function () {
|
|
|
- return _super.prototype.initScene.call(this);
|
|
|
+ var _this = this;
|
|
|
+ return _super.prototype.initScene.call(this).then(function () {
|
|
|
+ _this.scene.createDefaultCameraOrLight(true, true, true);
|
|
|
+ return _this.scene;
|
|
|
+ });
|
|
|
};
|
|
|
DefaultViewer.prototype.onTemplatesLoaded = function () {
|
|
|
this.showLoadingScreen();
|
|
@@ -75884,16 +75890,12 @@ var DefaultViewer = (function (_super) {
|
|
|
this.containerElement.style.display = 'flex';
|
|
|
};
|
|
|
DefaultViewer.prototype.initCameras = function () {
|
|
|
- var camera = new BABYLON.ArcRotateCamera("camera", 4.712, 1.571, 0.05, BABYLON.Vector3.Zero(), this.scene);
|
|
|
- camera.attachControl(this.engine.getRenderingCanvas(), true);
|
|
|
- camera.wheelPrecision = 100.0;
|
|
|
- camera.minZ = 0.01;
|
|
|
- camera.maxZ = 1000;
|
|
|
- camera.useFramingBehavior = true;
|
|
|
+ this.scene.imageProcessingConfiguration.exposure = 1.4;
|
|
|
+ this.scene.imageProcessingConfiguration.contrast = 1.66;
|
|
|
+ this.scene.imageProcessingConfiguration.toneMappingEnabled = true;
|
|
|
return Promise.resolve(this.scene);
|
|
|
};
|
|
|
DefaultViewer.prototype.initLights = function () {
|
|
|
- var light = new babylonjs_1.HemisphericLight("light1", new babylonjs_1.Vector3(0, 1, 0), this.scene);
|
|
|
return Promise.resolve(this.scene);
|
|
|
};
|
|
|
DefaultViewer.prototype.loadModel = function (model) {
|