-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathintroduction.html
More file actions
134 lines (119 loc) · 6.96 KB
/
introduction.html
File metadata and controls
134 lines (119 loc) · 6.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
<!DOCTYPE html>
<html class="writer-html5" lang="zh-CN" >
<head>
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>1. Cocoa 项目简介 — Cocoa 文档</title>
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/graphviz.css" type="text/css" />
<link rel="stylesheet" href="_static/styles.css" type="text/css" />
<!--[if lt IE 9]>
<script src="_static/js/html5shiv.min.js"></script>
<![endif]-->
<script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script>
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script>
<script src="_static/doctools.js"></script>
<script src="_static/sphinx_highlight.js"></script>
<script src="_static/translations.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="索引" href="genindex.html" />
<link rel="search" title="搜索" href="search.html" />
<link rel="next" title="1. JavaScript Runtime Environment" href="jsrt_es_module.html" />
<link rel="prev" title="Cocoa 用户文档" href="index.html" />
</head>
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> Cocoa
</a>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="在文档中搜索" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<p class="caption" role="heading"><span class="caption-text">Introduction</span></p>
<ul class="current">
<li class="toctree-l1 current"><a class="current reference internal" href="#">1. Cocoa 项目简介</a></li>
</ul>
<p class="caption" role="heading"><span class="caption-text">JavaScript Runtime</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="jsrt_es_module.html">1. JavaScript Runtime Environment</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">Cocoa</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html" class="icon icon-home"></a> »</li>
<li><span class="section-number">1. </span>Cocoa 项目简介</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/introduction.rst.txt" rel="nofollow"> 查看页面源码</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<section id="cocoa">
<h1><span class="section-number">1. </span>Cocoa 项目简介<a class="headerlink" href="#cocoa" title="此标题的永久链接"></a></h1>
<p>Cocoa 是一个 Linux 平台通用的 2D 渲染和视觉小说框架,
其灵感来自于视觉小说 <a class="reference external" href="https://atri-mdm.com">ATRI -My Dear Moments-</a> 。
最初 Cocoa 的目标是改善 Linux 平台上的视觉小说体验和探索视觉小说的制作,然而随着开发的进程,
Cocoa 已经逐渐转变为一个十分通用的、类似 Flutter 的 2D 渲染引擎。</p>
<p>总所周知,Cocoa(可可)是一种可用于制作巧克力的植物,但是该项目的名称并不取这个意味。
实际上,Cocoa 来自动漫 <a class="reference external" href="https://www.gochiusa.com">ご注文わうさぎですか?</a>
中的角色之一的名字,因此,Cocoa 的发音遵循日语假名「ココア」的发音 kokoa,
但无论如何,将其读作英语中的 Cocoa 也无妨。</p>
<p>Cocoa 本身是一个使用 C++ 编写的 JavaScript 引擎,并内置了图形渲染所需要原生代码,
用户编写的 JavaScript 可以直接在 Cocoa 上运行并调用其图形渲染功能。
这也意味着,Cocoa 本身并不提供任何视觉小说相关的功能,
而是通过一系列由 TypeScript 编写的库来提供编写视觉小说的能力,这些库构建于 Cocoa
原生代码之上,并实现更进一步的特化抽象,提供视觉小说引擎所具备的功能(如剧本解析、场景管理、
存档管理等)。</p>
<p>Cocoa 使用 <a class="reference external" href="https://v8.dev">V8</a> 作为 JavaScript 引擎,<a class="reference external" href="https://skia.org">Skia</a> 作为绘图后端,
通过把 Skia API 暴露给 JavaScript,来实现 2D 绘制。在此之上,Cocoa 还包含了基于图层树的渲染架构,
以及 Wayland 显示后端、Vulkan 硬件加速等诸多功能。而与 Python turtle 一类的绘图库不同,
Cocoa 是真正面向 <em>连续刷新的 2D 动画绘制场景</em> 设计的,更加注重性能。下图展示了整个 Cocoa 的核心架构:</p>
<img alt="_images/core_architecture.png" src="_images/core_architecture.png" />
<p>目前,Cocoa 仍然是仅凭兴趣支撑的项目,且仍处于开发之中。
我们欢迎任何 Issue 和 Pull request:<a class="reference external" href="https://github.com/OpenACG-Group/Cocoa">GitHub</a></p>
</section>
</div>
</div>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="index.html" class="btn btn-neutral float-left" title="Cocoa 用户文档" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> 上一页</a>
<a href="jsrt_es_module.html" class="btn btn-neutral float-right" title="1. JavaScript Runtime Environment" accesskey="n" rel="next">下一页 <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>© 版权所有 2022, OpenACG Group.</p>
</div>
利用 <a href="https://www.sphinx-doc.org/">Sphinx</a> 构建,使用了
<a href="https://github.com/readthedocs/sphinx_rtd_theme">主题</a>
由 <a href="https://readthedocs.org">Read the Docs</a>开发.
</footer>
</div>
</div>
</section>
</div>
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});
</script>
</body>
</html>