ZhangXianQiang
2024-04-19 cc6994a5858cd662f5904005bbbd9d34b712f76c
src/views/screen/components/screen-map-three/experience/index.js
@@ -4,6 +4,7 @@
import World from "./world/world";
import Camera from "./camera";
import Renderer from "./renderer";
import CSSRenderer from './cssRenderer';
// 工具类
import Sizes from "./utils/sizes";
@@ -12,11 +13,13 @@
export default class Experience {
  constructor(canvas) {
    this.canvas = canvas;
    this.container = canvas.parentElement;
    this.sizes = new Sizes(this.canvas);
    this.time = new Time();
    this.scene = new Scene();
    this.camera = new Camera(this);
    this.renderer = new Renderer(this);
    this.cssRenderer = new CSSRenderer(this);
    this.world = new World(this);
    // const size = 100;
@@ -40,6 +43,7 @@
    this.camera.update();
    this.world.update();
    this.renderer.update();
    this.cssRenderer.update();
    this.stats.update();
  }
}