This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for /f "delims=" %i in ('pip freeze') do pip uninstall -y %i |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fitCameraToCenteredObject = function (camera, object, offset, orbitControls ) { | |
const boundingBox = new THREE.Box3(); | |
boundingBox.setFromObject( object ); | |
var middle = new THREE.Vector3(); | |
var size = new THREE.Vector3(); | |
boundingBox.getSize(size); | |
// figure out how to fit the box in the view: | |
// 1. figure out horizontal FOV (on non-1.0 aspects) |