Apple λάͷ༷Λ
ඪ४ԽஂମʢW3CʣʹఏҊத
ඇରԠϒϥβͰ
දࣔ͢Δը૾
ࠨӈͷճస͕
ՄೳʹͳΔ
·ͣλοϓδΣενϟʔΛՃͯ͠ɺ
ΠϕϯτΛݕͨ͠Β֯Λܭࢉͯ͠…
ͱ͍࣮͕ͬͨෆཁʂ
const model = document.getElementById('3d-model');
function turnRight() {
const matrix = model.entityTransform;
const newMatrix = matrix.rotateAxisAngle(0, 1, 0, 90);
model.entityTransform = newMatrix;
}
ศརͳ໘ɺҰఆͷ੍͕͋Δ
ΞχϝʔγϣϯʹରԠ
Website EnvironmentsʢBETAʣ
const model = document.getElementById('3d-model');
if (window.HTMLModelElement) {
model.ready.then(() => {
// ಡΈࠐΈྃ
}).catch(() => {
// ಡΈࠐΈࣦഊ
});
} else {
// ඇରԠϒϥβ
}
αϙʔτͷ༗ແΛ֬ೝ
const model = document.getElementById('3d-model');
if (window.HTMLModelElement) {
model.ready.then(() => {
// ಡΈࠐΈྃ
}).catch(() => {
// ಡΈࠐΈࣦഊ
});
} else {
// ඇରԠϒϥβ
}
ಡΈࠐΈεςʔλε
औಘՄೳ
Loading 3D model...
const model = document.getElementById('3d-model');
const loading = document.getElementById('loading');
if (window.HTMLModelElement) {
model.ready.then(() => {
loading.style.display = 'none';
}).catch(() => {
loading.innerText = "Failed to load model.";
});
} else {
loading.style.display = 'none';
}