PageSourceSearch

https://how-radar-sees.pages.dev/assets/materialExplorer-CUelFH3W.js

js how-radar-sees.pages.dev collected 2026-10-03 05:52:35 UTC 2,081 bytes, 1 lines download raw bytes

1import{C}from"./Canvas2DFigure-CTHNVuxJ.js";import{a as S,r as X,F as u}from"./draw-C9i6pDRq.js";import"./Figure-jqdbFS1A.js";import"./index-5oHlzLJt.js";const k={water:{X:-20,C:-22,L:-25},forest:{X:-8,C:-12,L:-17},field:{X:-11,C:-12,L:-13},road:{X:-16,C:-17,L:-18},urban:{X:0,C:-2,L:-4},vehicle:{X:5,C:4,L:2}},$=r=>{const t=Math.sin(r*127.1+311.7)*43758.5453;return t-Math.floor(t)};function A(r,t){return r<.3&&t>.12&&t<.9?"water":t>.47&&t<.53?[.4,.52,.64,.75].some(o=>Math.abs(r-o)<.012)?"vehicle":"road":r>.6&&t<.42?"forest":r>.62&&t>.6?Math.floor(r*40)%3===0&&Math.floor(t*40)%3===0?"vehicle":"urban":"field"}const T=[{u:.15,v:.5,t:"water"},{u:.44,v:.28,t:"field"},{u:.8,v:.24,t:"forest"},{u:.8,v:.78,t:"urban"},{u:.5,v:.44,t:"road"}];class H extends C{controlsSchema=[{type:"segmented",name:"band",label:"Band",options:[["X 10GHz","X"],["C 5GHz","C"],["L 1.3GHz","L"]],value:"X"}];draw(){const t=this.g,l=this.w,o=this.h,s=this.palette;if(!t)return;S(t,l,o,s);const i=this.params.band,n=14,f=34,c=l-n*2,h=o-f-40,d=190,x=Math.round(d*h/c),p=c/d,b=h/x;for(let e=0;e<x;e++)for(let a=0;a<d;a++){const g=(a+.5)/d,M=(e+.5)/x,y=k[A(g,M)][i],L=Math.max(.02,Math.min(1,(y+30)/35)),v=.45+.85*-Math.log(Math.max(.001,$(a*3+e*7))),w=Math.max(0,Math.min(1,L*v)),m=Math.round(w*235);t.fillStyle=`rgb(${m},${m},${m})`,t.fillRect(n+a*p,f+e*b,p+.7,b+.7)}t.strokeStyle=X(s.ink,.2),t.strokeRect(n,f,c,h),t.font=`600 12px ${u}`,t.textAlign="center";for(const e of T){const a=n+e.u*c,g=f+e.v*h;t.fillStyle="rgba(0,0,0,0.55)",t.fillText(e.t,a+1,g+1),t.fillStyle="rgba(255,255,255,0.95)",t.fillText(e.t,a,g)}t.textAlign="left",t.fillStyle=s.ink,t.font=`700 14px ${u}`,t.fillText(`Radar image at ${i}-band`,n,24),t.fillStyle=s.muted,t.font=`12px ${u}`,t.textAlign="right",t.fillText(i==="L"?"long waves penetrate the canopy — forest darkens":i==="X"?"short waves scatter off leaves — forest is bright":"water dark · metal bright",l-n,24),t.textAlign="left",t.fillStyle=s.muted,t.font=`11px ${u}`,t.fillText("bright = strong return · speckle is real radar grain",n,o-10)}}export{H as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.