a b
t
c d
就是两次线性插值,先在x方向插出t上下方的_t1、_t2,然后再用它们插出t来
float test(float x,float y)
{
float _t1,_t2,t;
_t1 = a+(b-a)*(x-ax)/(bx-ax);
_t2 = c+(d-c)*(x-cx)/(dx-cx);
t = _t1 +(_t2-_t1)*(y - ay);
return t;
}
猜你喜欢
- 1you have the ——of working hard and being sucessful or of not working hard and being unsuccessful
- 2已知f(x)=3^2x-(k+1)*3^x+2,当X属于R时,f(x)恒为正,则K的范围
- 3英语.完成句子.求速度回答.
- 4若实数a、b满足根号a+根号b=3,根号a-根号b=3k,则k的取值范围是多少?
- 5帮忙写一篇关于艾薇儿的英语短文:The Person I admire
- 6这里有三种父母的行为是小孩讨厌的 There are 3 parents' actions that children hate.请问错在哪里
- 7帮我看看这句话朗读的时候应该怎么停顿和重音
- 8英语翻译
- 9英语翻译
- 10已知反比例函数y=-x分之15.当x大于等于-5时,y的取值范围是;当x