1const BAYER_MATRIX=[0,8,2,10,12,4,14,6,3,11,1,9,15,7,13,5];export function ditherPixels(t,o,r,{levels:n,strength:e,offsetX:a,offsetY:s,bias:f}){const h=255/(Math.max(2,Math.round(n))-1),l=Array.from({length:16},(t,o)=>{const r=(o%4+a)%4,n=(Math.floor(o/4)+s)%4,l=(BAYER_MATRIX[4*n+r]/15-.5)*e+f;return Uint8ClampedArray.from({length:256},(t,o)=>Math.max(0,Math.min(255,Math.round((o+l)/h)*h)))});for(let n=0;n<r;n+=1){const r=n%4*4;for(let e=0;e<o;e+=1){const a=4*(n*o+e),s=l[r+e%4];t[a]=s[t[a]],t[a+1]=s[t[a+1]],t[a+2]=s[t[a+2]]}}}
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.