I’m using TSPS + ofxOSC to read in contours from my webcam. I’m creating a polyline from the osc messages and displaying it on my screen.
There’s a bit of noise and flickering, depending on the TSPS inputs. I wanted to smooth this out by implementing some kind of persistence layer that compares the new polyline with the current one, and either ignores the new one, or updates them smoothly with some kind of lerp.
Are there any pointers as to how to:
(i) Compare polylines?
(ii) Interpolate between them?
My naive solutions consist mostly of pair-wise comparison of the nodes to match them, and then doing interpolations between them. I also looked at Frechet distance, but it seems overly complicated.