This commit is contained in:
Eskimue
2026-04-05 14:01:17 +02:00
parent 2689a32ed6
commit 24096a49a1
5 changed files with 153 additions and 27 deletions
-21
View File
@@ -717,27 +717,6 @@ function drawArc(){
ctx.clip();
if(!sd.polarNight){
// Unter-Horizont gestrichelt (normal day) - nur Punkte wo alt<0
if(!sd.polarDay){
const sub=[];
for(let i=0;i<=80;i++){
const h=sd.riseUTC-3+i*6/80;
const{altitude,azimuth}=sunAltAz(loc.lat,loc.lon,hourToDate(currentDate,h));
if(altitude<0) sub.push(proj(altitude,azimuth));
else if(sub.length>0) { sub.push(null); } // Unterbrecher
}
// Zeichne mit Unterbrechungen
ctx.beginPath();
let inPath=false;
sub.forEach(p=>{
if(!p){inPath=false;return;}
if(!inPath){ctx.moveTo(p.x,p.y);inPath=true;}
else ctx.lineTo(p.x,p.y);
});
ctx.strokeStyle='rgba(200,168,75,.15)';ctx.lineWidth=1.5*dpr;
ctx.setLineDash([4*dpr,8*dpr]);ctx.stroke();ctx.setLineDash([]);
}
// Äußerer Gluehschein
ctx.beginPath();
drawWrappedPath(ctx,pts,W,sd.polarDay);