HEIC decoder

IF Drama uses Hopper Gee’s heic-to 1.6.7 under the GNU Lesser General Public License v3. The browser downloads this library when it needs help opening a HEIC image. It includes libheif 1.23.7 and libde265 1.1.3.

Licenses

Download the source

IF Drama rebuilt the decoder on November 22, 2026 with libde265 1.1.3 and limits on worker lifetime, codec memory and output pixels. Each source archive retains its upstream notices. Download the distributed decoder module, wrapper changes and build script.

Replace the decoder

You may modify the library and reverse engineer the application to debug those modifications. Download the three source archives, patch and build script into one directory. In that directory run docker run --rm -v "$PWD:/release" emscripten/emsdk:4.0.20 bash /release/build-decoder.sh. The script writes the compatible module to heic-to.js.

Replace /licenses/heic-to-1.6.7/heic-to.js in a copy of the deployed site with your built module. Keep the named heicTo export compatible with heicTo({ blob, type: "bitmap" }). Reload and attach a HEIC file in a browser without native HEIC decoding. The application loads the replacement directly.

On the hosted site you can also use Chrome DevTools Local Overrides. Override the decoder response with your module, reload with DevTools open and attach the file again.