From 64a0195c8740ed60895677b2b3cb4ea4d68127ba Mon Sep 17 00:00:00 2001 From: Eskimue Date: Tue, 14 Apr 2026 17:31:16 +0200 Subject: [PATCH] Ekliptikebene jetzt rund --- public/solarsystem.php | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/public/solarsystem.php b/public/solarsystem.php index 51cbf62..6e72b22 100644 --- a/public/solarsystem.php +++ b/public/solarsystem.php @@ -2701,11 +2701,35 @@ function createPlanetMesh(planet) { function createEclipticPlane() { eclipticGroup = new THREE.Group(); - const grid = new THREE.GridHelper(680, 68, 0x5aa8d8, 0x2c4d66); - grid.material.transparent = true; - grid.material.opacity = 0.28; - eclipticGroup.add(grid); + // Konzentrische Kreise bei astronomisch sinnvollen AU-Abständen + const auRings = [1, 2, 3, 4, 5, 10, 15, 20, 30, 40, 50, 60, 70, 80, 90, 100]; + const segments = 128; + for (const au of auRings) { + const r = Math.pow(au, 0.56) * DISPLAY_SCALE; + const pts = []; + for (let i = 0; i <= segments; i++) { + const a = (i / segments) * Math.PI * 2; + pts.push(new THREE.Vector3(Math.cos(a) * r, 0, Math.sin(a) * r)); + } + const ringGeo = new THREE.BufferGeometry().setFromPoints(pts); + const ringMat = new THREE.LineBasicMaterial({ color: 0x2c4d66, transparent: true, opacity: 0.45 }); + eclipticGroup.add(new THREE.Line(ringGeo, ringMat)); + } + // Radiale Speichen alle 30° + const maxR = Math.pow(100, 0.56) * DISPLAY_SCALE; + for (let i = 0; i < 12; i++) { + const a = (i / 12) * Math.PI * 2; + const spokePts = [ + new THREE.Vector3(0, 0, 0), + new THREE.Vector3(Math.cos(a) * maxR, 0, Math.sin(a) * maxR) + ]; + const spokeGeo = new THREE.BufferGeometry().setFromPoints(spokePts); + const spokeMat = new THREE.LineBasicMaterial({ color: 0x2c4d66, transparent: true, opacity: 0.25 }); + eclipticGroup.add(new THREE.Line(spokeGeo, spokeMat)); + } + + // Vertikale Achse (Nordpol der Ekliptik) const axisGeometry = new THREE.BufferGeometry().setFromPoints([ new THREE.Vector3(0, -340, 0), new THREE.Vector3(0, 340, 0)