123456789101112131415161718192021222324 |
- <template>
- <mesh name="Cube" :position="position">
- <geometry type="Box" :args="[size.x, size.y, size.z]" />
- <material type="MeshBasic" :color="color" :options="opts" />
- </mesh>
- </template>
- <script>
- import * as THREE from 'three'
- export default {
- name: 'Cube',
- // mixins: [Object3D],
- props: { size: Object, texture: String, position: Object, color: Number },
- data: () => ({
- opts: {
- side: THREE.DoubleSide,
- wireframe: false,
- transparent: false,
- opacity: 0.6
- }
- })
- }
- </script>
|