← Back to Projects

Software Project

Curve Plotter

A C++ application built with SDL3 that plots curves, tracks the nearest point to the cursor in real time, and renders the corresponding tangent line, compiled to WebAssembly and embedded below.

C++ SDL3 WebAssembly Emscripten Interactive Math

Overview

Given a function of x and y, the application plots the resulting curve and continuously calculates the nearest point to the cursor position, then draws the tangent line at that point.

The result is a compact tool that combines graphics programming, numerical methods, and responsive input handling, all running natively in the browser via WebAssembly.

Highlights

  • Plots a curve from a user-defined function of x and y.
  • Finds the point on the curve nearest the cursor in real time.
  • Draws the tangent line at the selected point.
  • Compiled with Emscripten to run in the browser with no install.
Live Demo Move your cursor over the canvas to explore the curve.