EaselJS透视图像转换 [英] EaselJS perspective image transformation

查看:175
本文介绍了EaselJS透视图像转换的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在html5画布中进行透视图像转换?我现在正在使用EaselJS,无法找到满足我需求的解决方案。

Is it possible to make perspective image transformation in html5 canvas? I am using EaselJS right now and can't find a solution for my need.

推荐答案

我没有尝试过画架。但是,但每个图像转换都是通过矩阵运算完成的:平移,旋转,倾斜等。查看画架上的源代码,有一个 Matrix2D 类和文档它: http://www.createjs.com/Docs/EaselJS/Matrix2D.html 。对于透视转换,您需要使用 rotation 缩放倾斜。您只需要玩最适合您需求的值和测试。

I don't tried the easel.js yet, but every image transformation is done with matrix operations: translate, rotate, skew etc. Looking on the easel.js source code there is a Matrix2D class, and the documentation to it: http://www.createjs.com/Docs/EaselJS/Matrix2D.html. For a perspective transformation you need to use rotation, scaling and skewing. You need to only play with values and test which is best suited for your needs.

这篇关于EaselJS透视图像转换的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆