Find the right marker position for a .glb file


I have been trying to place a marker on glb scene.

After much googling I managed to place the marker. But it is completely out of place.

If you rotate the model you will find a smile floating around. The point is to put it, let’s say, in one of the eyes of the model.

But I just can’t find the coordinates. How can I calculate them.

I made a codepen so you can see what I mean.


        loader.load( '', function ( gltf ) {
        gltf.scene.scale.set(0.03,0.03,0.03) // scale here


        const model = gltf.scene.children[0];
        model.position.y = - 1.6;

        scene.add(model); // actually a light ?

      scene.add( new THREE.BoxHelper( gltf.scene, 0xff0000 ) );
      const box = new THREE.Box3;

        createMarker(scene, box.min);


    } );

however, there is something invisible in your gltf that doubles the bounding box:

Screen Shot 2020-02-21 at 18.09.43

Thanks alot makc3d.

The model thing was actually a light and made no sense.

I have experimented so much that part of the code stayed there after my clean up.

I will try to find my way from your help.

Again thanks alot.