dev_close_window ()
dev_open_window (0, 0, 512, 512, 'white', WindowID)
dev_set_color ('black')
* Draw with the mouse an arbitrary region into the window
draw_region (Region, WindowID)#手动绘制,右键确定
hom_mat2d_identity (HomMat2DIdentity)#3维单位矩阵
hom_mat2d_rotate (HomMat2DIdentity, -0.3, 256, 256, HomMat2DRotate)#旋转矩阵,顺时针为负;绕(256,256)坐标顺时针旋转0.3弧度。
hom_mat2d_scale (HomMat2DRotate, 1.5, 1.5, 256, 256, HomMat2DScale)#缩放矩阵,绕(256,256)坐标,x方向和y方向都缩放1.5倍
affine_trans_region (Region, RegionAffineTrans, HomMat2DScale, 'nearest_neighbor')#执行邻近插值的仿射变换
dev_clear_window ()
dev_set_draw ('margin')
dev_set_color ('red')
dev_display (Region)#原始图
dev_set_color ('green')
dev_display (RegionAffineTrans)#仿射图
原始图
仿射图
原始VS仿射轮廓图