/*
Auto-generated by: https://github.com/pmndrs/gltfjsx
*/

import * as THREE from 'three'
import React, { useRef } from 'react'
import { useGLTF } from '@react-three/drei/useGLTF'

import { GLTF } from 'three/examples/jsm/loaders/GLTFLoader'

type GLTFResult = GLTF & {
  nodes: {
    museum_building015: THREE.Mesh
  }
  materials: {
    lucia: THREE.MeshStandardMaterial
  }
}

export default function Model(props: JSX.IntrinsicElements['group']) {
  const group = useRef<THREE.Group>()
  const { nodes, materials } = useGLTF('/model/obras/cordoba.glb') as GLTFResult
  return (
    <group ref={group} {...props} dispose={null} position={[1, 0, 0]}>
      <mesh material={materials.lucia} geometry={nodes.museum_building015.geometry} />
    </group>
  )
}

useGLTF.preload('/model/obras/cordoba.glb')
