摘要
在工程实践中,往往需要对纹理图像进行某种形变,因此文章提出两种纹理形变控制方法,网格插值法与矩阵映射法。使用者只需拉伸纹理外形边缘,即可实现纹理的形状控制,算法会根据使用者设定的纹理边缘自动的插入内部点,使得纹理最终显示正确的效果。每种方法后面都附带了工程实现,从而验证算法的可行性。网格插值法计算简单,可以完成凸多边形形变与部分非凸多边形形变,矩阵映射法计算复杂,可以实现纹理的凸多边形形变与大部分非凸多边形形变。
In engineering practice,it is often necessary to deform texture images.This article proposes two texture deformation control methods,grid interpolation method and matrix mapping method.Users only need to stretch the outer edges of the texture to achieve shape control.The algorithm automatically inserts internal points based on the texture edges set by the user,making the final display effect of the texture correct.Each method is accompanied by an engineering implementation to verify the feasibility of the algorithm.The grid interpolation method is simple in calculation and can complete the deformation of convex polygons and some non-convex polygons.The matrix mapping method is complex in calculation,but it can achieve the deformation of convex polygons and most non-convex polygons.
作者
付振宇
FU Zhenyu(HASCO Vision Techonology Co.,Ltd.,Shanghai 200000,China)
出处
《信息与电脑》
2024年第5期1-5,共5页
Information & Computer