1. 06 Oct, 2026 1 commit
    • Matthias Betz's avatar
      fix drag handling, missing WebGL 2, normal fallback and HiDPI canvas · 6360fdfb
      Matthias Betz authored
      
      
      - pointer events with pointer capture: a drag only starts on the canvas,
        continues outside it and ends on release; deltas from clientX/Y instead
        of the non-standard layerX (a drag entering from outside made the
        camera NaN)
      - without WebGL 2 show a message in the page instead of an alert with raw
        HTML, and refuse to load files
      - normal fallback for zero-area polygons used vec3.create(args), which
        ignores its arguments and returned a zero normal
      - canvas resolution in device pixels (CSS size * devicePixelRatio), mouse
        movement stays in CSS pixels
      - index.html: charset, viewport and lang
      
      Co-Authored-By: default avatarClaude Opus 5.5 (1M context) <noreply@anthropic.com>
      6360fdfb
  2. 05 Oct, 2026 1 commit
    • Matthias Betz's avatar
      stream large CityGML and zip files, fix geometry and view bugs · d7e5ee79
      Matthias Betz authored
      
      
      Loading
      - parse into fixed-size per-LOD blocks and upload them to the GPU while
        reading, so memory stays flat for multi-GB files (3.4 GB 3D-DLM loads
        with a JS heap below 90 MB) and the model is shown during loading
      - load the single .gml (or .xml) inside a zip archive, decompressed as a
        stream, including ZIP64
      - reject 7z/RAR/gzip and other non-XML input at once with a clear message,
        and enable the sax buffer limit that unterminated "<!" in binary data
        used to bypass until the tab ran out of memory
      - decode UTF-8 across chunk borders, cancel a running load when a new
        file is chosen, report load errors
      
      Geometry
      - split coordinates on any whitespace (indented posList, one pos per line)
      - subtract the origin in double precision before float32 conversion
      - handle PolygonPatch, Rectangle and Triangle
      - tag geometry with its LOD; setLodVisible() prepares LOD switches
      - light brown for land use and relief, nested colours restore the parent
      
      View
      - bind shader attribute locations, check compile/link errors, free GPU
        buffers of the previous file
      - infinite far plane with a near plane following the camera distance,
        starting distance fitted to the model without a 10 km cap
      - minimum zoom step and distance, pan speed proportional to the distance
      
      Tests: npm test (Node 22+), 73 tests
      
      Co-Authored-By: default avatarClaude Opus 5.5 (1M context) <noreply@anthropic.com>
      d7e5ee79
  3. 20 Jun, 2024 2 commits
  4. 11 Jun, 2024 1 commit
  5. 29 May, 2024 2 commits
  6. 09 Jul, 2020 1 commit
  7. 06 Mar, 2019 1 commit