Compare commits
No commits in common. "ff58cc16ffec7ed494553d963666317f10dc59b6" and "38999932616fa5b1d02ec71832e1869608652868" have entirely different histories.
ff58cc16ff
...
3899993261
|
@ -60,10 +60,12 @@ function Model({ gltfModel, ...props }) {
|
||||||
const maxSize = Math.max(sizeModel.x, sizeModel.y, sizeModel.z);
|
const maxSize = Math.max(sizeModel.x, sizeModel.y, sizeModel.z);
|
||||||
const scale = Math.min(size.width, size.height) / maxSize;
|
const scale = Math.min(size.width, size.height) / maxSize;
|
||||||
|
|
||||||
|
|
||||||
console.log("scaling factor is ", scale)
|
console.log("scaling factor is ", scale)
|
||||||
// Apply the scaling factor to the model
|
// Apply the scaling factor to the model
|
||||||
modelRef.current.scale.set(scale, scale, scale);
|
modelRef.current.scale.set(scale, scale, scale);
|
||||||
|
|
||||||
|
|
||||||
const boxAfterScaling = new Box3().setFromObject(modelRef.current);
|
const boxAfterScaling = new Box3().setFromObject(modelRef.current);
|
||||||
const sizeModelAfterScaling = new Vector3();
|
const sizeModelAfterScaling = new Vector3();
|
||||||
boxAfterScaling.getSize(sizeModelAfterScaling);
|
boxAfterScaling.getSize(sizeModelAfterScaling);
|
||||||
|
|
|
@ -10,11 +10,6 @@ module.exports = {
|
||||||
protocol: "https",
|
protocol: "https",
|
||||||
hostname: "pbxt.replicate.delivery",
|
hostname: "pbxt.replicate.delivery",
|
||||||
},
|
},
|
||||||
{
|
|
||||||
protocol: "https",
|
|
||||||
hostname: "replicate.delivery",
|
|
||||||
pathname: '/pbxt/**',
|
|
||||||
},
|
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
// async headers() {
|
// async headers() {
|
||||||
|
@ -26,6 +21,7 @@ module.exports = {
|
||||||
// key: 'Content-Security-Policy',
|
// key: 'Content-Security-Policy',
|
||||||
// value: "default-src 'self'; img-src 'self' blob: https://replicate.com https://pbxt.replicate.delivery; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; worker-src 'self' blob:; connect-src 'self' blob:;"
|
// value: "default-src 'self'; img-src 'self' blob: https://replicate.com https://pbxt.replicate.delivery; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; worker-src 'self' blob:; connect-src 'self' blob:;"
|
||||||
// }
|
// }
|
||||||
|
|
||||||
// ],
|
// ],
|
||||||
// },
|
// },
|
||||||
// ];
|
// ];
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue