Compare commits
2 Commits
50d755793d
...
cf3b915666
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cf3b915666 | ||
|
|
8a008e4b99 |
@ -93,7 +93,7 @@ export function createTvSet(x, z, rotY) {
|
|||||||
tvGroup.add(createLeg(offset, -depthOffset));
|
tvGroup.add(createLeg(offset, -depthOffset));
|
||||||
|
|
||||||
// --- 2. The TV box ---
|
// --- 2. The TV box ---
|
||||||
const cabinetGeometry = new THREE.BoxGeometry(1.75, 1.5, 1.0);
|
const cabinetGeometry = new THREE.BoxGeometry(1.9, 1.5, 1.0);
|
||||||
const cabinet = new THREE.Mesh(cabinetGeometry, tvPlastic);
|
const cabinet = new THREE.Mesh(cabinetGeometry, tvPlastic);
|
||||||
cabinet.position.y = 1.51;
|
cabinet.position.y = 1.51;
|
||||||
cabinet.castShadow = true;
|
cabinet.castShadow = true;
|
||||||
@ -101,7 +101,7 @@ export function createTvSet(x, z, rotY) {
|
|||||||
tvGroup.add(cabinet);
|
tvGroup.add(cabinet);
|
||||||
|
|
||||||
// --- 3. Screen Frame ---
|
// --- 3. Screen Frame ---
|
||||||
const frameGeometry = new THREE.BoxGeometry(1.5, 1.3, 0.1);
|
const frameGeometry = new THREE.BoxGeometry(1.7, 1.3, 0.1);
|
||||||
const frameMaterial = new THREE.MeshPhongMaterial({ color: 0x111111, shininess: 20 });
|
const frameMaterial = new THREE.MeshPhongMaterial({ color: 0x111111, shininess: 20 });
|
||||||
const frame = new THREE.Mesh(frameGeometry, frameMaterial);
|
const frame = new THREE.Mesh(frameGeometry, frameMaterial);
|
||||||
frame.position.set(0, 1.5, 0.68);
|
frame.position.set(0, 1.5, 0.68);
|
||||||
@ -111,7 +111,7 @@ export function createTvSet(x, z, rotY) {
|
|||||||
|
|
||||||
// --- 4. Curved Screen (CRT Effect) ---
|
// --- 4. Curved Screen (CRT Effect) ---
|
||||||
const screenRadius = 3.0; // Radius for the subtle curve
|
const screenRadius = 3.0; // Radius for the subtle curve
|
||||||
const screenWidth = 1.4;
|
const screenWidth = 1.6;
|
||||||
const screenHeight = 1.2;
|
const screenHeight = 1.2;
|
||||||
const thetaLength = screenWidth / screenRadius; // Calculate angle needed for the arc
|
const thetaLength = screenWidth / screenRadius; // Calculate angle needed for the arc
|
||||||
|
|
||||||
|
|||||||
@ -182,21 +182,17 @@ export function createVcrDisplay() {
|
|||||||
canvas.height = 32;
|
canvas.height = 32;
|
||||||
const ctx = canvas.getContext('2d');
|
const ctx = canvas.getContext('2d');
|
||||||
|
|
||||||
ctx.fillStyle = '#0a0a0a';
|
ctx.fillStyle = '#030303';
|
||||||
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
||||||
|
|
||||||
state.vcrDisplayTexture = new THREE.CanvasTexture(canvas);
|
state.vcrDisplayTexture = new THREE.CanvasTexture(canvas);
|
||||||
state.vcrDisplayTexture.needsUpdate = true;
|
state.vcrDisplayTexture.needsUpdate = true;
|
||||||
|
|
||||||
const displayGeometry = new THREE.PlaneGeometry(0.45, 0.1); // Adjust geometry width for new canvas size
|
const displayGeometry = new THREE.PlaneGeometry(0.45, 0.1); // Adjust geometry width for new canvas size
|
||||||
const displayMaterial = new THREE.MeshPhongMaterial({
|
const displayMaterial = new THREE.MeshBasicMaterial({
|
||||||
map: state.vcrDisplayTexture,
|
map: state.vcrDisplayTexture,
|
||||||
side: THREE.FrontSide,
|
side: THREE.FrontSide,
|
||||||
color: 0xffffff,
|
color: 0x105a10,
|
||||||
transparent: true,
|
|
||||||
emissive: 0x00ff44,
|
|
||||||
emissiveIntensity: 0.05,
|
|
||||||
shininess: 0
|
|
||||||
});
|
});
|
||||||
|
|
||||||
const displayMesh = new THREE.Mesh(displayGeometry, displayMaterial);
|
const displayMesh = new THREE.Mesh(displayGeometry, displayMaterial);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user