Jump to content

Graph interpolation

Recommended Posts


This is a general question about graph interpolation that doesn't concern with the current features of uGFX (i hope these features will be added a day)

Does anyone know some interpolation routine or library for graph that can be used in uGFX?

I already know that uGFX connect points. I mean something  like the figure.




Share this post

Link to post
Share on other sites


This is basically simple math. The most commonly used interpolation algorithms are usually the extremely simple linear, quadratic or cubic ones. However, what algorithm you choose depends almost only on your application (on what kind of data you're plotting). Sometimes you might want to resort to splines instead.
Regarding libraries: Usually this stuff is extremely simple (it's basic math). I am sure that there are tons of great libraries for generic data interpolation and so on, but on an µGFX application you're usually dealing with quite a static environment where your data is always very similar. Therefore, I'd recommend to just figure out what matches your data the best and then implement that function in your application.

TL;DR: What algorithm to use really just depends on the data you're plotting.

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...