HTML5 Canvas滚动,缩放,淡出效果 [英] Html5 canvas scrolling, zooming, fade out effect

查看:178
本文介绍了HTML5 Canvas滚动,缩放,淡出效果的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的最终目标是实现类似 http://www.crystal.ch/abb/power_systems_landscape/ [ ^ ]使用html5.

如您所见,我们可能需要一块大尺寸(2000 * 600)的画布,但不确定.

任何人都可以给我一个想法,只是上述链接的以下行为吗?
1.使用mousemove和mousedown操作左右滚动
2.根据电源系统选择,左右平滑滚动
3.放大缩小
4.淡出效果,加上标志性圆圈

My final is goal to implement a app like http://www.crystal.ch/abb/power_systems_landscape/[^] using html5.

As you see, we may need a large(2000*600) canvas, but im not sure.

Can anyone give me idea just for following behavior of above link ?

1. Scrolling left-right smoothly using mousemove and mousedown operation
2. Scrolling left-right smoothly according to power system selection
3. Zoom in zoom out
4. Fade out effect like plus iconic circles

Any kind of idea would be appreciated.

推荐答案

首先查看一些HTML5/CSS3,然后看看如何使用溢出,位置,顶部,左侧,宽度和高度样式使画布移动只显示一部分.按比例增加宽度/高度将为您提供缩放功能.最后,看看jQuery-将其输入Google.了解如何使用它来处理JavaScript中的上述样式以及处理事件.这些都是您所需要的.我建议您查找W3Schools网站以学习HTML5/CSS3.

希望这会有所帮助,
Ed
Start by looking some HTML5/CSS3 and look at how to use overflow, position, top, left, width and height styles to get the canvas to move show only one portion. Increasing width/height proportionally will get you zoom functionality. Finally, look at jQuery - type it into Google. Learn how to use it for manipulating the above styles in JavaScript and for handling events. These few things are all that you need. I suggest you look up the W3Schools website for learning HTML5/CSS3.

Hope this helps,
Ed


这篇关于HTML5 Canvas滚动,缩放,淡出效果的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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