惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Webroot Blog
Webroot Blog
T
Troy Hunt's Blog
S
Security Affairs
Hacker News: Ask HN
Hacker News: Ask HN
Attack and Defense Labs
Attack and Defense Labs
P
Proofpoint News Feed
大猫的无限游戏
大猫的无限游戏
G
Google Developers Blog
WordPress大学
WordPress大学
T
The Blog of Author Tim Ferriss
N
Netflix TechBlog - Medium
博客园_首页
Recorded Future
Recorded Future
罗磊的独立博客
I
InfoQ
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
雷峰网
雷峰网
博客园 - Franky
Project Zero
Project Zero
T
Tailwind CSS Blog
Microsoft Azure Blog
Microsoft Azure Blog
V2EX - 技术
V2EX - 技术
MyScale Blog
MyScale Blog
C
Check Point Blog
博客园 - 【当耐特】
D
Docker
aimingoo的专栏
aimingoo的专栏
宝玉的分享
宝玉的分享
小众软件
小众软件
Microsoft Security Blog
Microsoft Security Blog
P
Privacy & Cybersecurity Law Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
C
Cyber Attacks, Cyber Crime and Cyber Security
C
CXSECURITY Database RSS Feed - CXSecurity.com
Jina AI
Jina AI
N
News | PayPal Newsroom
Cisco Talos Blog
Cisco Talos Blog
L
Lohrmann on Cybersecurity
T
Tenable Blog
Forbes - Security
Forbes - Security
V
Vulnerabilities – Threatpost
阮一峰的网络日志
阮一峰的网络日志
H
Heimdal Security Blog
Google Online Security Blog
Google Online Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
量子位
I
Intezer
H
Hacker News: Front Page
博客园 - 司徒正美
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org

Brian Birtles’ Blog

Lessons learned switching to Rspack Weird things engineers believe about Web development Sharding Playwright tests by browser In praise of WordPress RSS the hard way: Adventures with Astro Assets Sponsoring Open Source as a Japanese Company Web animation in 2017 MozAnime in 2016 Gecko insiders Mozilla Japan engineering is quite hot right now What do we do with SMIL? After 10 years Animations on Fire @ Graphical Web 2014 Web Animations @ html5j 2013 Players wanted: the pause and seek game Group and conquer: timing groups for your synchronization woes Introducing Web Animations Help with math(s) Web Animations It’s about time… Synchronising SMIL Beached as bro Wet blanket ただ今! Farvel SMIL SMIL compiles again SMIL Animation in Mozilla report SMIL Animation patch SMIL work: performance and integration Fill modes (nearly) there Additive animation Additive animation nearly done Compositing underway Repeating Intervals New patch Iteration one Draft design Basic prototype
Parapara Animation
Brian Birtles · 2012-01-27 · via Brian Birtles’ Blog

Archive Mozilla

About a week ago Mozilla Japan put on a two-day event in Tokyo called Mozilla Vision 2012. It was a great weekend with several hundred people coming to talk about what it means to be Open, and, in very Japanese-style, see some cool robots (courtesy of Takahashi Tomotaka-san).

Takahashi Tomotaka-san with his robot

Personally, I was involved in running the Parapara Animation Workshop* where kids enjoyed drawing simple frame-based animation on a tablet which was then added to a much bigger animation projected on the walls. The purpose of the project was to teach kids the basics of animation as well as to encourage them to be not just web spectators but web makers.

Parapara animation icon

It’s a workshop that was originally done by a group of Keio University Students and they helped run it again this time. The main difference is that last time it was mostly iOS-based, this time it was all Web.

Christian Heilmann has written up a great summary of this part of the program including a quick interview where you can see how it worked.

Screencap from video demonstration

Japanese kids are really creative so it was a really fun time. But not only was the event fun, the technology side was really fun too.

Some of the technology used

What went well

  • SVG’s native motion on a path (<animateMotion>) saved us so much time. The auto-rotate feature (rotate="auto"), path APIs (getPointAtLength), and ability to calibrate the path length (pathLength="1") also made it easy to position animations at just the right place so they would appear on the screen as soon as the user pressed “send”.

  • Using SVG made it really easy to do the drop shadows. Just a transform and a blur filter and we were done.

    Character with SVG drop shadow

  • SVG animation was surprisingly fast. I expected it to be really slow but it was the fastest of the alternatives we tried. That said there’s still a lot more work to be done (see below).

  • Overall SVG just proved really versatile. Being able to show a faint greyed outline of previous frames just by setting an attribute was great. Likewise being able to do all the animation work on the client-side and then just serialise the subtree and send it to the server was so much simpler than the previous version.

  • Deployment over the Web was great. Just refresh the page to pick up the bug fixes! Likewise when we ran out of tablets at one point we could just load up the editor URL on a laptop and keep drawing.

What didn’t go so well

  • The app marketplace. We badly wanted to package it all up as a Web app using the framework developed by the Mozilla Labs Apps project. We hoped that would give us full-screen display and stop the user from accidentally navigating to other pages. We had high hopes but were shattered to find the Android runtime launched the app in a Webkit runtime which didn’t even support SVG.
  • Going full-screen. Due to some technical reasons we were stuck with an old version of Fennec and old UI which took some coaxing to go full-screen and stop the chrome from flying in when the user was drawing. Fortunately the bugs that stopped us from using a more recent version of Fennec appear to have been fixed so next time we can hopefully use the Fullscreen API and multi-touch for drawing with all your fingers at once (something the really young kids really wanted to do!)
  • CSS and UI layout. Countless hours were sunk into trying to convince CSS to layout widgets on the screen. In the end I gave up and did half of it in script. I’m told CSS flexbox can help a lot here but I spoke to one implementer of flexbox who said that some of the things we were trying to do weren’t possible even with flexbox.
  • Graphics performance. For the combined animation we badly need a boost to our SVG rendering performance. On Windows the performance was generally ok (if you don’t have a loud fan!) but occasionally got jittery. On Mac it looked terrible. We still have a way to go here. Apart from the graphics performance there’s still lots of room to optimize SVG animation itself too. For the editor running on the tablets, I have one patch awaiting review which I hope will make using SVG’s path APIs faster and speed up the drawing and erasing operations.

The result

The wall gallery

The gallery of animations

Animation editor

The editor

And, of course, the code is waiting for your help at github!

Feedback

“That’s a web page?!?” I’m certain that most people who used the demo were oblivious to the fact they were using the Web and that’s probably the greatest success of this demo. Without exception, everyone who asked about the technology was surprised it was Web-based. Everyone assumed it was a native Android app or otherwise Flash.

“That’s SVG?!?” The web developers who came were also surprised at the use of SVG. Most had never really thought of making use of it. They assumed we were using canvas.

“I want to cry, this is the first time I’ve seen Fennec used for something other than reading the news”

Although a lot of the features we used are still in development it was very rewarding to see how much is already possible with Open Web technologies. We’ve had many requests to run this workshop elsewhere and, with your help, it will hopefully get better each time. Thanks very much to the Parapara Animation team and to everyone who contributed to Fennec, Gecko and the Web standards that this is built on.

* For anyone wondering what “parapara” means, it’s the sound of flipping paper and its use here comes from “parapara manga” which means “flipbook comic”. It’s also the name of a kind of hand dancing so we might have to reconsider the name so as not to disappoint the kids.