HTML canvas JavaScript 库和框架的最新技术是什么?

2022-01-16 00:00:00 canvas frameworks javascript html

我目前正在研究在新的 HTML 5 应用程序中使用画布的选项,并且想知道 HTML 画布 JavaScript 库和框架的当前最新状态是什么?

I am currently investigating options for working with the canvas in a new HTML 5 application, and was wondering what is the current state of the art in HTML canvas JavaScript libraries and frameworks?

具体来说,是否有框架支持游戏开发所需的东西——复杂动画、管理场景图、处理事件和用户交互?

In particular, are there frameworks that support the kind of things needed for game development - complex animation, managing scene graphs, handling events and user interactions?

也愿意同时考虑商业和开源产品.

Also willing to consider both commercial and open source products.

推荐答案

我一直在研究 fabric.js - 一个画布库来帮助解决这个问题 - 通过处理事件和用户交互来操作画布上的对象.它还没有发布,但是看一个简单的预览演示.

I've been working on fabric.js — a canvas library to help with exactly that — manipulating objects on canvas, by handling events and user interactions. It's not released yet, but take a look at a simple preview demo.

您还可以在 这个设计编辑器中看到它的实际效果,它最初是为它创建的.

You can also see it in action in this design editor, which it was originally created for.

该项目现在在 github 上可用(打开-根据 MIT 许可证获取)

The project is now available on github (open-sourced under MIT License)

要开始使用,请查看:

  • 演示(简单和复杂,用代码展示它们是如何完成的)
  • Fabric.js 在 FalsyValues 上的演示(和 另一位在 BK.js)
  • github上的Wiki(包括常见问题解答)
  • 文档
  • Google 群组(在此提问)
  • Twitter 上的Fabric.js(或通过 twitter 提出简短问题)
  • Fabric.js 简介:第 1 部分(关于 ScriptJunkie 的文章)
  • Fabric.js 简介:第 2 部分(关于 ScriptJunkie 的文章)
  • Demos (simple & complex, with code to show how they're done)
  • Fabric.js presentation at FalsyValues (and another one at BK.js)
  • Wiki on github (including FAQ)
  • Documentation
  • Google Group (ask any question there)
  • Fabric.js on twitter (or short questions via twitter)
  • Introduction to Fabric.js: Part 1 (article on ScriptJunkie)
  • Introduction to Fabric.js: Part 2 (article on ScriptJunkie)

Fabric 与其他 Javascript 画布库相比如何?这是比较表.

How does Fabric compare to other Javascript canvas libraries? Here's a comparison table.

相关文章