Android图形在不同的api上得出错误的观点

问题描述

制作一个应用程序,我需要画一个透视图。在api> 27上一切正常,但在27及以下级别上却很奇怪!下两点错误的构建视角

    float[] srcT = {
            0,// Coordinate of top left point
            0,height,// Coordinate of bottom left point
            wight,// Coordinate of bottom right point
            wight,0  // Coordinate of top right point
    };

    float[] dstT = {
            top_left_x,top_left_y,// Coordinate of top left point
            bottom_left_x,bottom_left_y,// Coordinate of bottom left point
            bottom_right_x,bottom_right_y,// Coordinate of bottom right point
            top_right_x,top_right_y  // Coordinate of top right point
    };

    Shader shader = new BitmapShader(bitmap,Shader.TileMode.REPEAT,Shader.TileMode.REPEAT);
    matrix.setPolyToPoly(srcT,dstT,4);
    shader.setLocalMatrix(matrix);
    paint.setShader(shader);

它在28个api上:

this post

这是22个api:

image1

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...