This p5.js sketch turns live earthquake data into an audio-visual replay. It pulls recent earthquake events from the USGS feed, filters them to a chosen geographic region, and compresses that activity into a short looping timeline on screen. As each quake appears in the replay, it is drawn as a pulsing visual marker and also triggers a bell-like tone, creating a shifting map of seismic activity that can be both seen and heard. The code was created with help of AI. The following is an AI generated description of the code functionality: Main functions fetchQuakes() This is the data-loading function. It connects to the selected USGS GeoJSON feed, reads the earthquake records, and converts them into a simpler internal format containing magnitude, place name,
You are here
Home > Posts tagged "teach"