• Advertisement
Sign in to follow this  

no idea about matrix interpolation

This topic is 4295 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Can anyone help me? Now I have a 64*64 matrix, I want to let it become a 1024*1024 matrix by linear interpolation through c++. I am trying to find the solution. Big problem for me now.

Share this post


Link to post
Share on other sites
Advertisement
Linear interpolation is quite easy. For any location on your new 1024 matrix, you are in a 'minisquare' defined by four corners (points in the 64 matrix), and your location within this square can be thought of as (x, y) where 0<(x,y)<1. A simple interpolation would then be
value = vtlxy + vtr(1-x)y + vblx(1-y) + vbr(1-x)(1-y)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement