|
@@ -8,6 +8,7 @@ import { OptionsLineComponent } from "../../lines/optionsLineComponent";
|
|
import { MessageLineComponent } from "../../lines/messageLineComponent";
|
|
import { MessageLineComponent } from "../../lines/messageLineComponent";
|
|
import { faCheck, faTimesCircle } from "@fortawesome/free-solid-svg-icons";
|
|
import { faCheck, faTimesCircle } from "@fortawesome/free-solid-svg-icons";
|
|
import { TextLineComponent } from "../../lines/textLineComponent";
|
|
import { TextLineComponent } from "../../lines/textLineComponent";
|
|
|
|
+import { GLTFLoaderCoordinateSystemMode, GLTFLoaderAnimationStartMode } from "babylonjs-loaders/glTF/index";
|
|
|
|
|
|
interface IGLTFComponentProps {
|
|
interface IGLTFComponentProps {
|
|
scene: Scene,
|
|
scene: Scene,
|
|
@@ -34,12 +35,12 @@ export class GLTFComponent extends React.Component<IGLTFComponentProps> {
|
|
const loaderState = this.props.globalState.glTFLoaderDefaults;
|
|
const loaderState = this.props.globalState.glTFLoaderDefaults;
|
|
|
|
|
|
if (loaderState["animationStartMode"] === undefined) {
|
|
if (loaderState["animationStartMode"] === undefined) {
|
|
- loaderState["animationStartMode"] = BABYLON.GLTFLoaderAnimationStartMode.FIRST;
|
|
|
|
|
|
+ loaderState["animationStartMode"] = GLTFLoaderAnimationStartMode.FIRST;
|
|
}
|
|
}
|
|
loaderState["capturePerformanceCounters"] = loaderState["capturePerformanceCounters"] || false;
|
|
loaderState["capturePerformanceCounters"] = loaderState["capturePerformanceCounters"] || false;
|
|
loaderState["compileMaterials"] = loaderState["compileMaterials"] || false;
|
|
loaderState["compileMaterials"] = loaderState["compileMaterials"] || false;
|
|
loaderState["compileShadowGenerators"] = loaderState["compileShadowGenerators"] || false;
|
|
loaderState["compileShadowGenerators"] = loaderState["compileShadowGenerators"] || false;
|
|
- loaderState["coordinateSystemMode"] = loaderState["coordinateSystemMode"] || BABYLON.GLTFLoaderCoordinateSystemMode.AUTO;
|
|
|
|
|
|
+ loaderState["coordinateSystemMode"] = loaderState["coordinateSystemMode"] || GLTFLoaderCoordinateSystemMode.AUTO;
|
|
loaderState["loggingEnabled"] = loaderState["loggingEnabled"] || false;
|
|
loaderState["loggingEnabled"] = loaderState["loggingEnabled"] || false;
|
|
loaderState["transparencyAsCoverage"] = loaderState["transparencyAsCoverage"] || false;
|
|
loaderState["transparencyAsCoverage"] = loaderState["transparencyAsCoverage"] || false;
|
|
loaderState["useClipPlane"] = loaderState["useClipPlane"] || false;
|
|
loaderState["useClipPlane"] = loaderState["useClipPlane"] || false;
|
|
@@ -96,14 +97,14 @@ export class GLTFComponent extends React.Component<IGLTFComponentProps> {
|
|
const loaderState = this.props.globalState.glTFLoaderDefaults;
|
|
const loaderState = this.props.globalState.glTFLoaderDefaults;
|
|
|
|
|
|
var animationStartMode = [
|
|
var animationStartMode = [
|
|
- { label: "None", value: BABYLON.GLTFLoaderAnimationStartMode.NONE },
|
|
|
|
- { label: "First", value: BABYLON.GLTFLoaderAnimationStartMode.FIRST },
|
|
|
|
- { label: "ALL", value: BABYLON.GLTFLoaderAnimationStartMode.ALL }
|
|
|
|
|
|
+ { label: "None", value: GLTFLoaderAnimationStartMode.NONE },
|
|
|
|
+ { label: "First", value: GLTFLoaderAnimationStartMode.FIRST },
|
|
|
|
+ { label: "ALL", value: GLTFLoaderAnimationStartMode.ALL }
|
|
];
|
|
];
|
|
|
|
|
|
var coordinateSystemMode = [
|
|
var coordinateSystemMode = [
|
|
- { label: "Auto", value: BABYLON.GLTFLoaderCoordinateSystemMode.AUTO },
|
|
|
|
- { label: "Right handed", value: BABYLON.GLTFLoaderCoordinateSystemMode.FORCE_RIGHT_HANDED }
|
|
|
|
|
|
+ { label: "Auto", value: GLTFLoaderCoordinateSystemMode.AUTO },
|
|
|
|
+ { label: "Right handed", value: GLTFLoaderCoordinateSystemMode.FORCE_RIGHT_HANDED }
|
|
];
|
|
];
|
|
|
|
|
|
return (
|
|
return (
|