This commit is contained in:
Wes Kocher 2014-09-18 15:26:44 -07:00
Родитель 033860a079 ccb7a1ab98
Коммит 45f4500903
217 изменённых файлов: 5610 добавлений и 2763 удалений

Просмотреть файл

@ -234,19 +234,18 @@ Accessible::Description(nsString& aDescription)
}
}
}
}
}
if (!aDescription.IsEmpty()) {
aDescription.CompressWhitespace();
nsAutoString name;
ENameValueFlag nameFlag = Name(name);
// Don't use tooltip for a description if it was used for a name.
if (nameFlag == eNameFromTooltip)
// Don't expose a description if it is the same as the name.
if (aDescription.Equals(name))
aDescription.Truncate();
}
}
}
aDescription.CompressWhitespace();
}
KeyBinding
Accessible::AccessKey() const

Просмотреть файл

@ -25,6 +25,14 @@
// attribute.
testDescr("img3", "description");
// No description from aria-describedby since it is the same as the
// @alt attribute which is used as the name
testDescr("img4", "");
// No description from @title attribute since it is the same as the
// @alt attribute which is used as the name
testDescr("img5", "");
// Description from content of h2.
testDescr("p", "heading");
@ -37,6 +45,10 @@
// From title (summary is used as a name)
testDescr("table3", "title");
// No description from <desc> element since it is the same as the
// <title> element.
testDescr("svg", "");
SimpleTest.finish();
}
@ -58,6 +70,12 @@
title="summary attribute content mapped to accessible name in MSAA">
Mozilla Bug 666212
</a>
<a target="_blank"
href="https://bugzilla.mozilla.org/show_bug.cgi/id=1031188"
title="Ensure that accDescription never duplicates AccessibleName">
Mozilla Bug 1031188
</a>
<p id="display"></p>
<div id="content" style="display: none"></div>
<pre id="test">
@ -67,6 +85,8 @@
<img id="img1" aria-describedby="description" />
<img id="img2" title="title" />
<img id="img3" alt="name" title="description" />
<img id="img4" alt="aria description" aria-describedby="description">
<img id="img5" alt="image" title="image">
<h2 id="heading">heading</h2>
<p id="p" aria-describedby="heading" role="button">click me</p>
@ -83,5 +103,19 @@
<table id="table3" summary="summary" title="title">
<tr><td>cell</td></tr>
</table>
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"
viewBox="0 0 100 100" preserveAspectRatio="xMidYMid slice"
id="svg"
style="width:100px; height:100px;">
<title>SVG Image</title>
<desc>SVG Image</desc>
<linearGradient id="gradient">
<stop class="begin" offset="0%"/>
<stop class="end" offset="100%"/>
</linearGradient>
<rect x="0" y="0" width="100" height="100" style="fill:url(#gradient)" />
<circle cx="50" cy="50" r="30" style="fill:url(#gradient)" />
</svg>
</body>
</html>

Просмотреть файл

@ -30,6 +30,12 @@ function log(msg) {
//dump('ProcessGlobal: ' + msg + '\n');
}
function formatStackFrame(aFrame) {
let functionName = aFrame.functionName || '<anonymous>';
return ' at ' + functionName +
' (' + aFrame.filename + ':' + aFrame.lineNumber + ')';
}
const gFactoryResetFile = "/persist/__post_reset_cmd__";
function ProcessGlobal() {}
@ -112,11 +118,21 @@ ProcessGlobal.prototype = {
// Pipe `console` log messages to the nsIConsoleService which
// writes them to logcat on Gonk.
let message = subject.wrappedJSObject;
let prefix = ('Content JS ' + message.level.toUpperCase() +
' at ' + message.filename + ':' + message.lineNumber +
' in ' + (message.functionName || 'anonymous') + ': ');
Services.console.logStringMessage(prefix + Array.join(message.arguments,
' '));
let args = message.arguments;
let stackTrace = '';
if (message.level == 'assert' || message.level == 'error' || message.level == 'trace') {
stackTrace = Array.map(message.stacktrace, formatStackFrame).join('\n');
} else {
stackTrace = formatStackFrame(message);
}
if (stackTrace) {
args.push('\n' + stackTrace);
}
let prefix = 'Content JS ' + message.level.toUpperCase() + ': ';
Services.console.logStringMessage(prefix + Array.join(args, ' '));
break;
}
}

Просмотреть файл

@ -2287,6 +2287,7 @@ let E10SUINotification = {
if (!Services.appinfo.inSafeMode &&
!Services.appinfo.accessibilityEnabled &&
!Services.appinfo.keyboardMayHaveIME &&
e10sPromptShownCount < 5) {
Services.tm.mainThread.dispatch(() => {
try {

Просмотреть файл

@ -29,7 +29,7 @@ function test() {
name: "Amazon.com",
alias: null,
description: "Amazon.com Search",
searchForm: "http://www.amazon.com/",
searchForm: "http://www.amazon.com/exec/obidos/external-search/?field-keywords=&mode=blended&tag=mozilla-20&sourceid=Mozilla-search",
type: Ci.nsISearchEngine.TYPE_MOZSEARCH,
hidden: false,
wrappedJSObject: {

Просмотреть файл

@ -39,7 +39,7 @@ function test() {
name: "Bing",
alias: null,
description: "Bing. Search by Microsoft.",
searchForm: "http://www.bing.com/search",
searchForm: "http://www.bing.com/search?q=&pc=MOZI",
type: Ci.nsISearchEngine.TYPE_MOZSEARCH,
hidden: false,
wrappedJSObject: {

Просмотреть файл

@ -86,7 +86,8 @@ function test() {
name: "Google",
alias: null,
description: "Google Search",
searchForm: "https://www.google.com/",
searchForm: "https://www.google.com/search?q=&ie=utf-8&oe=utf-8&aq=t&rls=" +
distributionID + ":" + getLocale() + ":" + MOZ_OFFICIAL + "&client=" + GOOGLE_CLIENT,
type: Ci.nsISearchEngine.TYPE_MOZSEARCH,
hidden: false,
wrappedJSObject: {
@ -175,11 +176,6 @@ function test() {
},
},
},
{
type: "text/html",
method: "GET",
template: "https://www.google.com/",
},
],
},
};

Просмотреть файл

@ -29,7 +29,7 @@ function test() {
name: "Yahoo",
alias: null,
description: "Yahoo Search",
searchForm: "https://search.yahoo.com/",
searchForm: "https://search.yahoo.com/search?p=&ei=UTF-8&fr=moz35",
type: Ci.nsISearchEngine.TYPE_MOZSEARCH,
hidden: false,
wrappedJSObject: {

Различия файлов скрыты, потому что одна или несколько строк слишком длинны

Просмотреть файл

@ -14,7 +14,7 @@
<Param name="form" value="OSDJAS"/>
<Param name="language" value="{moz:locale}"/>
</Url>
<Url type="text/html" method="GET" template="http://www.bing.com/search">
<Url type="text/html" method="GET" template="http://www.bing.com/search" rel="searchform">
<Param name="q" value="{searchTerms}"/>
<Param name="pc" value="MOZI"/>
<MozParam name="form" condition="purpose" purpose="contextmenu" value="MOZCON"/>
@ -23,5 +23,4 @@
<MozParam name="form" condition="purpose" purpose="keyword" value="MOZLBR"/>
<MozParam name="form" condition="purpose" purpose="newtab" value="MOZTSB"/>
</Url>
<SearchForm>http://www.bing.com/search</SearchForm>
</SearchPlugin>

Различия файлов скрыты, потому что одна или несколько строк слишком длинны

Просмотреть файл

@ -9,8 +9,7 @@
<Image width="16" height="16">data:image/x-icon;base64,AAABAAIAEBAAAAAAAAALAgAAJgAAACAgAAAAAAAAQQQAADECAACJUE5HDQoaCgAAAA1JSERSAAAAEAAAABAIBgAAAB/z/2EAAAHSSURBVDjLfVO/axRREP6SS0ihlv4FQpoYWxHyHxgCsUxhmToBS4tF7NLZWaiIEHLv7d5dJNEQ0tgYEAmIjeAfYC57++7MGbzLjxu/Nxt27zZrBoadnZnvm3kz7wEqMpZqmdAfBBMIZBzGVGCkorbXq4kFp/yPtBgPZCJzZvYQuNZ+jKhVo75G2LyHVz9uoeFmc6bILaHaepv9v/w6iRcypXbonmNPBB9OBbv82tYfmPgn7NHTnKAaP8E+g8Ztot68k/nXDm8ooNEVhHEP1vXROBbUf/M/Wc0Jwl8zsEkHOxcMtE6Y+A42nodpLtLfR9QWRMmA9jm2eh78aXQY4eF9VvjCgKDWEewM2PIZQc4nD9Sf6hk+sohNqorzW0kN91BBdYKtO9dE/00JZITA50XxsxTHlWarqMYBh/O3UPGqrednx7ox3o+UhbIRT7O1BO9PfIsXI5V9J34WvrqN94buwFi+b3N0k0nrCjAFAp1+Nz1Czd3N2y8Tm6ywYk9JTHKqk/cD9cM17YW89WExbo6Ja1zhvgK3+4Itql+rt8PkO1f6oBysBN3brLrMVhs84wHJvpHoMwnf8CI9ygZd3nbJgymrMvxeSoLjmlCsIJf+a17lP6juZmUWkMzvAAAAAElFTkSuQmCCiVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAECElEQVRYw+1XS2gTURS9ia0/EMSCCC4siCIKrly4UVwIrgRR3KgbXQmCCiIiCha7EQRR6cIupHShSeZjf6lttdWFgqBRBPGDKIqF1mQ+1Wp/SZvnvXfmTWfMpJ3U0pUPHplJ3rv33HO/Afi/5nPViTjuKm8rYlFlAoSI8a500R1SGLYUZRH+Hvee6+qqygvxW1KJ1XLd+74aUuY+0OzjoHw/BElj4zQQHxv0HDBUvjR9WQlNYmnJhSjK9dxFUC0LOsYE3M8LSI8LUKw8AmoG5ecqPtP8vgZ04zKeO+jqjUtBDi2qWY+71xPaKKpnpF0uzUpCnxDQOixQ+BSo9iR/3vsh4CF+r5of8D3F75r9udQAKUwx++AJXkhZCe9QBkGEuUSC1swTjhK0VrUmEYzw7SKCyUPrLwEP8IxufQN9aCfKPwCJwdq/lCPluvUG2n4jhQW8bD6Hu+amABvSd/LOTbEENOMjdIyicLuA1om/ADhbMqIZn/DMOMq+7iqPBanUzWfQOUGUjUFnnj5H0WdnQOlfFoxssdix3tjGgnWbrCuGKvdA4LmuSQJ6s9SN0zFwg6lS7Qmms+WngK4pEvAVg+w83MltCAAhAHSGFMwEgGQRq2quwZe2cShJkaYvtey39hEHMfsQL7cjxd1F4dBnPWUKVeMwaLmTkRggGd1oiJI9GxLcLg2NA8s5DTXzCKePbjtBJAVoVoGjmFxEwsgiCi5tFuoDDFinHcb9xWg6CBcjpS9ReReCeF9GOL5TsCEYhRkSs26HmSLXh2R2f8DlJS7Q7BZOwyhWzeZ3P2hijtJRG9wSXuQkIj27m1OKKKPUiQIiCv1ptF4x33rUh/Yb+aVqN8BjIf07HwDy0EPFzU2/ck0rgCpln8MgtOcBgOOiFizRSWt7aQCWA0GHdesSBuOAm+fFOQIoOFXVeBRqaGnvlsGIed5LwWiO/LP11KASg7tmt97fnRoz1Xj5NXc4WQP0Sliw6d4EN6mUdStyew8cbB6uQWGdXL+pPHMrjQLCVe40tHdo1NJoQ47X5XBnfKUykduBQ0U9+jEbKR5IOTc0IwfJb+tnjvwoq+3DCmxEV1iwvzyHtlzbSTnVHMRKuTm6crK8AcelDrGc/a/0r4WUsRcF3ebWzC4YCqt8Rbdo5XmO4IZj9IGSW+PFUuSVyu7BeeABIrdZMNFIfiSrCQQFouwDNHxQLyBQdK6nSPOfgftUSXWtaOlD67BkXkCLXrFV1IYJBAUifcpnspQHFjyjmi+4y8nBs6KIL1cJuRZkt6K1xzCYrvFAqdtptDCNz3dxX8V91Gsufqvn8r/CByJemd/kvJiprui/RAQkMaZR/r1i4W6a0rP/N/gXi6OvmDvBLoiyBV1/AN29Cs9hVFoUAAAAAElFTkSuQmCC</Image>
<Image width="65" height="26">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEEAAAAaCAYAAADovjFxAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyNpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NDkxMSwgMjAxMy8xMC8yOS0xMTo0NzoxNiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChNYWNpbnRvc2gpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjQ0MDYxRTY0QjUyNTExRTNCNzdEOTU4N0NCMjI3MEFDIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOjQ0MDYxRTY1QjUyNTExRTNCNzdEOTU4N0NCMjI3MEFDIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6MDcyQzJENkJCNTI1MTFFM0I3N0Q5NTg3Q0IyMjcwQUMiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6MDcyQzJENkNCNTI1MTFFM0I3N0Q5NTg3Q0IyMjcwQUMiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4/Os9TAAADvUlEQVR42uyYWWxNURSGz723OiotMbU1N25jKNImIhENfSAh8SDxQgQP7QPxQhAVU1DihYjxwRBCCAktaohZE6EkNIqUmtJWq0LV2On6V/OfZNnO6RXJfXJW8uXuffc9Z5/9r7XX2uf6QqGQ9b+bzxPBE8ETwRPBE+F3i8q+bwXxuRhcAmciJTbYBmaDXWA16AMKwGOw1+GaANgAosEK0BKxSMgqC73G5wD200B1BOYZCcqNBR4Ds9ifAEqNa5aBLWyvA2sjJYJfCSA2MELz1IPPbIsYsgcz1Phwh2v0dxmR3A4iQpPql0dQhCSQCzIpQkCNP3W45rtqv4poTjD6a8Bb7mGhDZSASi5gDjgMrqprZoJp3Otl6vuFIIv7ugqMAWPBG/Cc97Ytj2MBjp8yRJjIvCXjX8Ah0MyxrmAuyGb+qAHF4JbDehPAFNCf95J7nJScIGGa2IlQX8EwcIVh2Qh6chF9QS1/9wKksx1U3j0OFvA+Yh9AbwqZ4zLndD7obpfx62ASf3OXz2HaAc5r21RwkAlZW7X/L6IlgaHcyn40sbgY2+JUu59qy297qb54LsbwtGmDwoyn8LNECVABzoF37M8HK1VOKXEQQCzV3A5lzBE+9kNUVCbooSLDPlw0GxFj20/V/qEEtBjOZk6o4MP7uR33cGvaJiH+jOPfQD631wiO17H8vuTWPMI1SEXZBJYb67zJSG6XuaKMvJCrsrhleDOG7TYuzFxsi4sIfiWqLazPEEEWddvF2xbDuMAYX6TaySyx8RTZnq8LGKWqizhtslmO/cqrYuNcwq+dN7Q4kVMG7+YiQpQxh5+CaWEyHebU0TPapbLpw1i82m62Sb5oUFum1uE80vGAD8F49o+CreCTqhAVDJ8aLlSS6D6wHyxR90pjCF8G69X3ku3fq34sF1jB5Ca2mXmjjp6UcL7ICLEY4jLnA14rz3kBLFUleAZ4Qof5+Gk7IynciVEuPh0mOQ7l4aX4H8pwOhfXpLaTbK3BLL1OJiVwHj3nlPmreN9HPI2K3WNOa2GUtPI4XkknJPM0nOYkgsVElN/JQlaBjSxNOS7bxanS7GB9DxoHokR6XB+Nnd43gi4HKV2Z6jt5bkmUQyhIgJER+8dLSkpex5H8LPjIZBRHNZtJJcO7gQmqO70jW0neOwopYAyv9/EwVKgyfCM9IKVvJzjP70vp1RSW4lZGjIh+h2cKealLZUiHuJAicIL3LWJJtsft5/5O596g6JIct4Nr3qu093+CJ4IngieCJ0J4+yXAANopCw9hh0hVAAAAAElFTkSuQmCC</Image>
<Image width="130" height="52">data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIIAAAA0CAYAAABGkOCVAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyNpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NDkxMSwgMjAxMy8xMC8yOS0xMTo0NzoxNiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChNYWNpbnRvc2gpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjg5QzlEREI0QjUyNjExRTNCNzdEOTU4N0NCMjI3MEFDIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOjg5QzlEREI1QjUyNjExRTNCNzdEOTU4N0NCMjI3MEFDIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6ODlDOUREQjJCNTI2MTFFM0I3N0Q5NTg3Q0IyMjcwQUMiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6ODlDOUREQjNCNTI2MTFFM0I3N0Q5NTg3Q0IyMjcwQUMiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5Ln/UEAAAHKElEQVR42uxca2wVRRTe2wdULUVARDQIkqCmARGKhQBqeBsCKkiImmiML0xUFEs0BImIaDQSH2gQlB9iQlQQUAHFF5QWQbDiI4oIiBCgIE9BaAv03us59rsyjjOzO7s3mC3zJV/a7szszsx+c+acswOJdDrtOTjkuClwcEJwcEJwcEJwcEJwcEJwcEJwcEJwcEJwcEJwcEJwcEJwiIC8Ht/883tXYhFxPfFYzMc1jXgXsY44g/iUok47YgfiVuKukM8pJeYS1zQWi7CI+B2xAhNzTYzHNI9YRjyXeAFxikIIz2GcPN7fiJMtn3EhcS24mriZ2CnOQkiUVKV5kh6Xrh/HYA/GbDy9iV8qrqdh7Y4SRxPfVdQZRlwa8DlfE3tI17YRLyWejKtFeERxvSlxUAzHc5lO8BAC43ZNnTsDPqOjQgQetpnucd4a8jVlBTEcT6Xm+l7iHvye0tTJD/iMFoayc+IshDpNWRxN3BbiWMX1ewQB6MZVH/AZpnon4yqEvEYYCb1C3EQcSkwS5wf06s/oM3smIeyL8bg+AW1Qk4Xn7mmMQigh7kacrHPAThA3aNpmnK85xHU+/RhCHEE8QJyNkM4EzhH0JP5MfFFR3o84Cqb6LeRG/NCW2FkaL4+xlvhLwPnsC0c7V2ifgkD2+rRl/+Jq9KE98Ty04WjkJ+KqCGLlCLAl3nda6FsNrOff4eMR+tksgpi24sWUCy91mUVoxnH+JCl0LcHgVVgKsy+GcgOJR/D3/cRXpTbDiUvw+wLiSMsxcr7gerwY7luVZftaCHaioqw15mAUXr7JQi8kPk3cEeCZFxPHEQcjrNUteg63R2RDCB4sQ3M4nvwCi6XyzeiMjPZQvIz3YSFkDCB+rrg+gfgs8RIIUxU1tMXqDCOEjOBKEaJuDDlPY4ivC39fjgXUxuIeRyHsckOdkbCEQaOYZdn61tAEpprRSlHeSrPFFBvUrEIXn/xBqab8fJ/VFgRXeQ3Zyh0R7iHmKgohrjaW9+B2K4h9NOUTIXabUPa6bH50+lMwgzLqLEOxGsvw7Dh+Jg0RQW4WxlgP0YfFMcnqFUa41xfY90X0J04Nca9UtoSwUXDI0hahWcoylEv5XE8aylMRx/gmzHK7CPd4RnAqB2jq8NZ3I7bSbsSHsfXKYKf0SenaeyH7Nd0UNfC+etjgZCSwQtejs3HHMURJORhbZoxszT4lPoRrpgxkNaxZriRqjhqexypm6NLcy73/pvb5Y+BK4reK+nyf8bCIN3vmrOdOjCVXiog+JpaZhMADf+cMyqksg+fuh6ShbLSn/uglo6fmOvtSr3mnvotknqfbEovgN1Xh2brt9DYk1lKmPELC4J02RiR8/Aw/5ATwk0xoanCGu4I2aI2fnTXlg2BRfAeVb+hwGORonKykxeSfsHxZORH751k4kyZf46yAQmiSRWFvF6yDjF+DiCAzKbqM161ZXHGtNNfzDOGejThTFv2q1ZT3Cji+Q4ayawP6Itmytuw3bDBsWYeC3ohfxDqNJ8xJiXulBEgQ7FOYvkI4S+Ol62WGfEE/xMsi7tPU3+1j9sUVr0sGcXJruqf+eik7XXs1YuUMKZ9YWuXjY+zUtGdnkjOgzX3GwthGfFsYmyrSyrcRAocrN2nKZ6FsJQaQUEzufoQtBwSVlijuVYY9dC5MIx+IGWbo22dew+fjSkwaHy+7QlN3taVTOFlT9qDXkJKdj1WbiSC2o98Z61OpmbNClC2EA5fCHNfheuabC5d111i2l/4Xx6mkKl2EMDEKDsIT3gLzWH4ax8AvqSMmka3YAs0q5BWfOaTKH7U6WD7ne6/hm8Z+WKvlIfo6FVajm6f/ELYJQvwR7yUhLcAErO5aaUHyPFyk6POVQX0E/tbwRMSXwRmumfidrccPp1EID4RIFt0d4jnszU/D7ys0gvMDnw0thtVcpKnDiaSJMPsfeQ0f2ZYIXEz8Cu3PztYkZjzoKV6wT7Um9BX24RGnSQSLvVNfFRkFBv8gT9qLJ4V43kDhd845/B7iHjcIPlh1hLFz9nGCjz/QxFYIjP4BkyE6HBFW5lZ0tN6ive1BmDUKwe2y8PbZTM+wfOYf0t99QrzMaqn9zghz3kPY+vKjhNVixcNY1bNCduplyXP9AE7jlgBtK7DPDw8Y8vBhl96KkKnCUx9Lm+2dOq8ggs8uPOoFP/DxgiJOZwc26Gmoo3AkRc+/i2d/mioDsd08RflcG2dRdb0UeYReeEEFPpaAH/iYQWzs/Q/FPttSCPnWIuL4UKjfQqjP/2ikGSzLdtSf45nPIBagzhC044kf45nPJPI/hLkDbTopkjN7IIKZPtvGLRB/O2mF1iOyGW8IX/thzkvR3pT+r4EPMU6KAN+AlUzinYwNLAT3/yw6WO0hDk4IDk4IDk4IDk4IDk4IDk4IDk4IDk4IbgocnBAcnBAc/o2/BBgAWu+TFRGzndoAAAAASUVORK5CYII=</Image>
<SearchForm>https://twitter.com/search/</SearchForm>
<Url type="text/html" method="GET" template="https://twitter.com/search">
<Url type="text/html" method="GET" template="https://twitter.com/search" rel="searchform">
<Param name="q" value="{searchTerms}"/>
<Param name="partner" value="Firefox"/>
<Param name="source" value="desktop-search"/>

Просмотреть файл

@ -13,9 +13,9 @@
<Param name="action" value="opensearch"/>
<Param name="search" value="{searchTerms}"/>
</Url>
<Url type="text/html" method="GET" template="https://en.wikipedia.org/wiki/Special:Search" resultdomain="wikipedia.org">
<Url type="text/html" method="GET" template="https://en.wikipedia.org/wiki/Special:Search"
resultdomain="wikipedia.org" rel="searchform">
<Param name="search" value="{searchTerms}"/>
<Param name="sourceid" value="Mozilla-search"/>
</Url>
<SearchForm>https://en.wikipedia.org/wiki/Special:Search</SearchForm>
</SearchPlugin>

Просмотреть файл

@ -15,10 +15,10 @@
<Param name="appid" value="ffd" />
<Param name="command" value="{searchTerms}" />
</Url>
<Url type="text/html" method="GET" template="https://search.yahoo.com/search" resultdomain="yahoo.com">
<Url type="text/html" method="GET" template="https://search.yahoo.com/search"
resultdomain="yahoo.com" rel="searchform">
<Param name="p" value="{searchTerms}"/>
<Param name="ei" value="UTF-8"/>
<MozParam name="fr" condition="pref" pref="yahoo-fr" />
</Url>
<SearchForm>https://search.yahoo.com/</SearchForm>
</SearchPlugin>

Просмотреть файл

@ -252,7 +252,7 @@ this.ContentSearch = {
controller.maxLocalResults = ok ? 2 : 6;
controller.maxRemoteResults = ok ? 6 : 0;
controller.remoteTimeout = data.remoteTimeout || undefined;
let priv = PrivateBrowsingUtils.isWindowPrivate(msg.target.contentWindow);
let priv = PrivateBrowsingUtils.isBrowserPrivate(msg.target);
// fetch() rejects its promise if there's a pending request, but since we
// process our event queue serially, there's never a pending request.
let suggestions = yield controller.fetch(data.searchString, priv, engine);

Просмотреть файл

@ -45,6 +45,10 @@
/** Begin titlebar **/
#titlebar {
-moz-window-dragging: drag;
}
#titlebar-buttonbox > .titlebar-button {
display: none;
}

Просмотреть файл

@ -237,6 +237,7 @@ def check_style():
#
# Examples (filename -> inclname)
# - "mfbt/Attributes.h" -> "mozilla/Attributes.h"
# - "mfbt/decimal/Decimal.h -> "mozilla/Decimal.h"
# - "js/public/Vector.h" -> "js/Vector.h"
# - "js/src/vm/String.h" -> "vm/String.h"
@ -246,7 +247,7 @@ def check_style():
# Select the appropriate files.
for filename in get_all_filenames():
if filename.startswith('mfbt/') and filename.endswith('.h'):
inclname = 'mozilla/' + filename[len('mfbt/'):]
inclname = 'mozilla/' + filename.split('/')[-1]
mfbt_inclnames.add(inclname)
if filename.startswith('js/public/') and filename.endswith('.h'):
@ -454,7 +455,7 @@ def do_file(filename, inclname, file_kind, f, all_inclnames, included_h_inclname
# Check the #include path has the correct form.
if include.inclname not in all_inclnames:
error(filename, include.linenum,
include.quote() + ' is included ' + 'using the wrong path;',
include.quote() + ' is included using the wrong path;',
'did you forget a prefix, or is the file not yet committed?')
# Record inclusions of .h files for cycle detection later.

Просмотреть файл

@ -7,7 +7,9 @@
#include <stdint.h>
#include <algorithm>
#include "mozilla/Preferences.h"
#include "mozilla/StaticMutex.h"
#include "CubebUtils.h"
#include "nsAutoRef.h"
#include "prdtoa.h"
#define PREF_VOLUME_SCALE "media.volume_scale"
@ -15,18 +17,36 @@
namespace mozilla {
namespace {
// This mutex protects the variables below.
StaticMutex sMutex;
cubeb* sCubebContext;
double sVolumeScale;
uint32_t sCubebLatency;
bool sCubebLatencyPrefSet;
// Prefered samplerate, in Hz (characteristic of the hardware, mixer, platform,
// and API used).
//
// sMutex protects *initialization* of this, which must be performed from each
// thread before fetching, after which it is safe to fetch without holding the
// mutex because it is only written once per process execution (by the first
// initialization to complete). Since the init must have been called on a
// given thread before fetching the value, it's guaranteed (via the mutex) that
// sufficient memory barriers have occurred to ensure the correct value is
// visible on the querying thread/CPU.
uint32_t sPreferredSampleRate;
} // anonymous namespace
extern PRLogModuleInfo* gAudioStreamLog;
static const uint32_t CUBEB_NORMAL_LATENCY_MS = 100;
StaticMutex CubebUtils::sMutex;
cubeb* CubebUtils::sCubebContext;
uint32_t CubebUtils::sPreferredSampleRate;
double CubebUtils::sVolumeScale;
uint32_t CubebUtils::sCubebLatency;
bool CubebUtils::sCubebLatencyPrefSet;
namespace CubebUtils {
/*static*/ void CubebUtils::PrefChanged(const char* aPref, void* aClosure)
void PrefChanged(const char* aPref, void* aClosure)
{
if (strcmp(aPref, PREF_VOLUME_SCALE) == 0) {
nsAdoptingString value = Preferences::GetString(aPref);
@ -48,7 +68,7 @@ bool CubebUtils::sCubebLatencyPrefSet;
}
}
/*static*/ bool CubebUtils::GetFirstStream()
bool GetFirstStream()
{
static bool sFirstStream = true;
@ -58,29 +78,30 @@ bool CubebUtils::sCubebLatencyPrefSet;
return result;
}
/*static*/ double CubebUtils::GetVolumeScale()
double GetVolumeScale()
{
StaticMutexAutoLock lock(sMutex);
return sVolumeScale;
}
/*static*/ cubeb* CubebUtils::GetCubebContext()
cubeb* GetCubebContext()
{
StaticMutexAutoLock lock(sMutex);
return GetCubebContextUnlocked();
}
/*static*/ void CubebUtils::InitPreferredSampleRate()
void InitPreferredSampleRate()
{
StaticMutexAutoLock lock(sMutex);
if (sPreferredSampleRate == 0 &&
cubeb_get_preferred_sample_rate(GetCubebContextUnlocked(),
&sPreferredSampleRate) != CUBEB_OK) {
// Query failed, use a sensible default.
sPreferredSampleRate = 44100;
}
}
/*static*/ cubeb* CubebUtils::GetCubebContextUnlocked()
cubeb* GetCubebContextUnlocked()
{
sMutex.AssertCurrentThreadOwns();
if (sCubebContext ||
@ -91,19 +112,19 @@ bool CubebUtils::sCubebLatencyPrefSet;
return nullptr;
}
/*static*/ uint32_t CubebUtils::GetCubebLatency()
uint32_t GetCubebLatency()
{
StaticMutexAutoLock lock(sMutex);
return sCubebLatency;
}
/*static*/ bool CubebUtils::CubebLatencyPrefSet()
bool CubebLatencyPrefSet()
{
StaticMutexAutoLock lock(sMutex);
return sCubebLatencyPrefSet;
}
/*static*/ void CubebUtils::InitLibrary()
void InitLibrary()
{
#ifdef PR_LOGGING
gAudioStreamLog = PR_NewLogModule("AudioStream");
@ -114,7 +135,7 @@ bool CubebUtils::sCubebLatencyPrefSet;
Preferences::RegisterCallback(PrefChanged, PREF_CUBEB_LATENCY);
}
/*static*/ void CubebUtils::ShutdownLibrary()
void ShutdownLibrary()
{
Preferences::UnregisterCallback(PrefChanged, PREF_VOLUME_SCALE);
Preferences::UnregisterCallback(PrefChanged, PREF_CUBEB_LATENCY);
@ -126,20 +147,20 @@ bool CubebUtils::sCubebLatencyPrefSet;
}
}
/*static*/ int CubebUtils::MaxNumberOfChannels()
uint32_t MaxNumberOfChannels()
{
cubeb* cubebContext = CubebUtils::GetCubebContext();
cubeb* cubebContext = GetCubebContext();
uint32_t maxNumberOfChannels;
if (cubebContext &&
cubeb_get_max_channel_count(cubebContext,
&maxNumberOfChannels) == CUBEB_OK) {
return static_cast<int>(maxNumberOfChannels);
return maxNumberOfChannels;
}
return 0;
}
/*static*/ int CubebUtils::PreferredSampleRate()
uint32_t PreferredSampleRate()
{
MOZ_ASSERT(sPreferredSampleRate,
"sPreferredSampleRate has not been initialized!");
@ -147,7 +168,7 @@ bool CubebUtils::sCubebLatencyPrefSet;
}
#if defined(__ANDROID__) && defined(MOZ_B2G)
/*static*/ cubeb_stream_type CubebUtils::ConvertChannelToCubebType(dom::AudioChannel aChannel)
cubeb_stream_type ConvertChannelToCubebType(dom::AudioChannel aChannel)
{
switch(aChannel) {
case dom::AudioChannel::Normal:
@ -171,4 +192,5 @@ bool CubebUtils::sCubebLatencyPrefSet;
}
#endif
}
} // namespace CubebUtils
} // namespace mozilla

Просмотреть файл

@ -8,65 +8,42 @@
#define CubebUtils_h_
#include "cubeb/cubeb.h"
#include "nsAutoRef.h"
#include "mozilla/StaticMutex.h"
#include "mozilla/dom/AudioChannelBinding.h"
template <>
class nsAutoRefTraits<cubeb_stream> : public nsPointerRefTraits<cubeb_stream>
{
public:
static void Release(cubeb_stream* aStream) { cubeb_stream_destroy(aStream); }
};
namespace mozilla {
namespace CubebUtils {
class CubebUtils {
public:
// Initialize Audio Library. Some Audio backends require initializing the
// library before using it.
static void InitLibrary();
void InitLibrary();
// Shutdown Audio Library. Some Audio backends require shutting down the
// library after using it.
static void ShutdownLibrary();
void ShutdownLibrary();
// Returns the maximum number of channels supported by the audio hardware.
static int MaxNumberOfChannels();
uint32_t MaxNumberOfChannels();
// Queries the samplerate the hardware/mixer runs at, and stores it.
// Can be called on any thread. When this returns, it is safe to call
// PreferredSampleRate without locking.
static void InitPreferredSampleRate();
// Get the aformentionned sample rate. Does not lock.
static int PreferredSampleRate();
// PreferredSampleRate.
void InitPreferredSampleRate();
static void PrefChanged(const char* aPref, void* aClosure);
static double GetVolumeScale();
static bool GetFirstStream();
static cubeb* GetCubebContext();
static cubeb* GetCubebContextUnlocked();
static uint32_t GetCubebLatency();
static bool CubebLatencyPrefSet();
// Get the aforementioned sample rate. Thread safe.
uint32_t PreferredSampleRate();
void PrefChanged(const char* aPref, void* aClosure);
double GetVolumeScale();
bool GetFirstStream();
cubeb* GetCubebContext();
cubeb* GetCubebContextUnlocked();
uint32_t GetCubebLatency();
bool CubebLatencyPrefSet();
#if defined(__ANDROID__) && defined(MOZ_B2G)
static cubeb_stream_type ConvertChannelToCubebType(dom::AudioChannel aChannel);
cubeb_stream_type ConvertChannelToCubebType(dom::AudioChannel aChannel);
#endif
private:
// This mutex protects the static members below.
static StaticMutex sMutex;
static cubeb* sCubebContext;
// Prefered samplerate, in Hz (characteristic of the
// hardware/mixer/platform/API used).
static uint32_t sPreferredSampleRate;
static double sVolumeScale;
static uint32_t sCubebLatency;
static bool sCubebLatencyPrefSet;
};
}
} // namespace CubebUtils
} // namespace mozilla
#endif // CubebUtils_h_

Просмотреть файл

@ -14,8 +14,14 @@
struct cubeb_stream;
namespace mozilla {
template <>
class nsAutoRefTraits<cubeb_stream> : public nsPointerRefTraits<cubeb_stream>
{
public:
static void Release(cubeb_stream* aStream) { cubeb_stream_destroy(aStream); }
};
namespace mozilla {
/**
* Assume we can run an iteration of the MediaStreamGraph loop in this much time

Просмотреть файл

@ -1438,10 +1438,6 @@ bool MediaDecoder::OnStateMachineThread() const
void MediaDecoder::SetPlaybackRate(double aPlaybackRate)
{
if (aPlaybackRate == mInitialPlaybackRate) {
return;
}
if (aPlaybackRate == 0.0) {
mPausedForPlaybackRateNull = true;
mInitialPlaybackRate = aPlaybackRate;

Просмотреть файл

@ -21,8 +21,7 @@
#include "FFmpegRuntimeLinker.h"
#endif
#ifdef MOZ_APPLEMEDIA
#include "apple/AppleCMLinker.h"
#include "apple/AppleVTLinker.h"
#include "apple/AppleDecoderModule.h"
#endif
namespace mozilla {
@ -151,17 +150,7 @@ IsAppleAvailable()
// Disabled by preference.
return false;
}
// Attempt to load the required frameworks.
bool haveCoreMedia = AppleCMLinker::Link();
if (!haveCoreMedia) {
return false;
}
bool haveVideoToolbox = AppleVTLinker::Link();
if (!haveVideoToolbox) {
return false;
}
// All hurdles cleared!
return true;
return NS_SUCCEEDED(AppleDecoderModule::CanDecode());
#endif
}

Просмотреть файл

@ -6,7 +6,7 @@
// Construct references to each of the CoreMedia symbols we use.
LINK_FUNC(CMVideoFormatDescriptionCreate)
LINK_FUNC(CMBlockBufferCreateWithMemoryBlock)
LINK_FUNC(CMSampleBufferCreate)
LINK_FUNC(CMTimeMake)
LINK_FUNC(VideoFormatDescriptionCreate)
LINK_FUNC(BlockBufferCreateWithMemoryBlock)
LINK_FUNC(SampleBufferCreate)
LINK_FUNC(TimeMake)

Просмотреть файл

@ -8,6 +8,8 @@
#include "AppleCMLinker.h"
#include "MainThreadUtils.h"
#include "mozilla/ArrayUtils.h"
#include "nsCocoaFeatures.h"
#include "nsDebug.h"
#ifdef PR_LOGGING
@ -24,8 +26,10 @@ AppleCMLinker::sLinkStatus = LinkStatus_INIT;
void* AppleCMLinker::sLink = nullptr;
nsrefcnt AppleCMLinker::sRefCount = 0;
CFStringRef AppleCMLinker::skPropExtensionAtoms = nullptr;
CFStringRef AppleCMLinker::skPropFullRangeVideo = nullptr;
#define LINK_FUNC(func) typeof(func) func;
#define LINK_FUNC(func) typeof(CM ## func) CM ## func;
#include "AppleCMFunctions.h"
#undef LINK_FUNC
@ -42,21 +46,58 @@ AppleCMLinker::Link()
return sLinkStatus == LinkStatus_SUCCEEDED;
}
const char* dlname =
"/System/Library/Frameworks/CoreMedia.framework/CoreMedia";
if (!(sLink = dlopen(dlname, RTLD_NOW | RTLD_LOCAL))) {
const char* dlnames[] =
{ "/System/Library/Frameworks/CoreMedia.framework/CoreMedia",
"/System/Library/PrivateFrameworks/CoreMedia.framework/CoreMedia" };
bool dlfound = false;
for (size_t i = 0; i < ArrayLength(dlnames); i++) {
if ((sLink = dlopen(dlnames[i], RTLD_NOW | RTLD_LOCAL))) {
dlfound = true;
break;
}
}
if (!dlfound) {
NS_WARNING("Couldn't load CoreMedia framework");
goto fail;
}
#define LINK_FUNC(func) \
if (nsCocoaFeatures::OnLionOrLater()) {
#define LINK_FUNC2(func) \
func = (typeof(func))dlsym(sLink, #func); \
if (!func) { \
NS_WARNING("Couldn't load CoreMedia function " #func ); \
goto fail; \
}
#define LINK_FUNC(func) LINK_FUNC2(CM ## func)
#include "AppleCMFunctions.h"
#undef LINK_FUNC
#undef LINK_FUNC2
skPropExtensionAtoms =
GetIOConst("kCMFormatDescriptionExtension_SampleDescriptionExtensionAtoms");
skPropFullRangeVideo =
GetIOConst("kCMFormatDescriptionExtension_FullRangeVideo");
} else {
#define LINK_FUNC2(cm, fig) \
cm = (typeof(cm))dlsym(sLink, #fig); \
if (!cm) { \
NS_WARNING("Couldn't load CoreMedia function " #fig ); \
goto fail; \
}
#define LINK_FUNC(func) LINK_FUNC2(CM ## func, Fig ## func)
#include "AppleCMFunctions.h"
#undef LINK_FUNC
#undef LINK_FUNC2
skPropExtensionAtoms =
GetIOConst("kFigFormatDescriptionExtension_SampleDescriptionExtensionAtoms");
}
if (!skPropExtensionAtoms) {
goto fail;
}
LOG("Loaded CoreMedia framework.");
sLinkStatus = LinkStatus_SUCCEEDED;
@ -79,7 +120,19 @@ AppleCMLinker::Unlink()
LOG("Unlinking CoreMedia framework.");
dlclose(sLink);
sLink = nullptr;
sLinkStatus = LinkStatus_INIT;
}
}
/* static */ CFStringRef
AppleCMLinker::GetIOConst(const char* symbol)
{
CFStringRef* address = (CFStringRef*)dlsym(sLink, symbol);
if (!address) {
return nullptr;
}
return *address;
}
} // namespace mozilla

Просмотреть файл

@ -22,6 +22,8 @@ class AppleCMLinker
public:
static bool Link();
static void Unlink();
static CFStringRef skPropExtensionAtoms;
static CFStringRef skPropFullRangeVideo;
private:
static void* sLink;
@ -32,9 +34,11 @@ private:
LinkStatus_FAILED,
LinkStatus_SUCCEEDED
} sLinkStatus;
static CFStringRef GetIOConst(const char* symbol);
};
#define LINK_FUNC(func) extern typeof(func)* func;
#define LINK_FUNC(func) extern typeof(CM ## func)* CM ## func;
#include "AppleCMFunctions.h"
#undef LINK_FUNC

Просмотреть файл

@ -7,6 +7,8 @@
#include "AppleATDecoder.h"
#include "AppleCMLinker.h"
#include "AppleDecoderModule.h"
#include "AppleVDADecoder.h"
#include "AppleVDALinker.h"
#include "AppleVTDecoder.h"
#include "AppleVTLinker.h"
#include "mozilla/Preferences.h"
@ -14,7 +16,11 @@
namespace mozilla {
bool AppleDecoderModule::sIsEnabled = false;
bool AppleDecoderModule::sInitialized = false;
bool AppleDecoderModule::sIsVTAvailable = false;
bool AppleDecoderModule::sIsVTHWAvailable = false;
bool AppleDecoderModule::sIsVDAAvailable = false;
bool AppleDecoderModule::sForceVDA = false;
AppleDecoderModule::AppleDecoderModule()
{
@ -29,30 +35,87 @@ void
AppleDecoderModule::Init()
{
MOZ_ASSERT(NS_IsMainThread(), "Must be on main thread.");
sIsEnabled = Preferences::GetBool("media.apple.mp4.enabled", false);
if (!sIsEnabled) {
sForceVDA = Preferences::GetBool("media.apple.forcevda", false);
if (sInitialized) {
return;
}
// dlopen VideoDecodeAcceleration.framework if it's available.
sIsVDAAvailable = AppleVDALinker::Link();
// dlopen CoreMedia.framework if it's available.
sIsEnabled = AppleCMLinker::Link();
if (!sIsEnabled) {
return;
bool haveCoreMedia = AppleCMLinker::Link();
// dlopen VideoToolbox.framework if it's available.
// We must link both CM and VideoToolbox framework to allow for proper
// paired Link/Unlink calls
bool haveVideoToolbox = AppleVTLinker::Link();
sIsVTAvailable = haveCoreMedia && haveVideoToolbox;
sIsVTHWAvailable = AppleVTLinker::skPropHWAccel != nullptr;
if (sIsVDAAvailable) {
AppleVDALinker::Unlink();
}
if (sIsVTAvailable) {
AppleVTLinker::Unlink();
AppleCMLinker::Unlink();
}
sInitialized = true;
}
// dlopen VideoToolbox.framework if it's available.
sIsEnabled = AppleVTLinker::Link();
class InitTask : public nsRunnable {
public:
NS_IMETHOD Run() MOZ_OVERRIDE {
MOZ_ASSERT(NS_IsMainThread(), "Must be on main thread.");
AppleDecoderModule::Init();
return NS_OK;
}
};
/* static */
nsresult
AppleDecoderModule::CanDecode()
{
if (!sInitialized) {
if (NS_IsMainThread()) {
Init();
} else {
nsRefPtr<nsIRunnable> task(new InitTask());
NS_DispatchToMainThread(task, NS_DISPATCH_SYNC);
}
}
return (sIsVDAAvailable || sIsVTAvailable) ? NS_OK : NS_ERROR_NO_INTERFACE;
}
class LinkTask : public nsRunnable {
public:
NS_IMETHOD Run() MOZ_OVERRIDE {
MOZ_ASSERT(NS_IsMainThread(), "Must be on main thread.");
MOZ_ASSERT(AppleDecoderModule::sInitialized);
if (AppleDecoderModule::sIsVDAAvailable) {
AppleVDALinker::Link();
}
if (AppleDecoderModule::sIsVTAvailable) {
AppleVTLinker::Link();
AppleCMLinker::Link();
}
return NS_OK;
}
};
nsresult
AppleDecoderModule::Startup()
{
// We don't have any per-instance initialization to do.
// Check whether ::Init() above succeeded to know if
// we're functional.
if (!sIsEnabled) {
if (!sIsVDAAvailable && !sIsVTAvailable) {
return NS_ERROR_FAILURE;
}
nsRefPtr<nsIRunnable> task(new LinkTask());
NS_DispatchToMainThread(task, NS_DISPATCH_SYNC);
return NS_OK;
}
@ -60,8 +123,14 @@ class UnlinkTask : public nsRunnable {
public:
NS_IMETHOD Run() MOZ_OVERRIDE {
MOZ_ASSERT(NS_IsMainThread(), "Must be on main thread.");
MOZ_ASSERT(AppleDecoderModule::sInitialized);
if (AppleDecoderModule::sIsVDAAvailable) {
AppleVDALinker::Unlink();
}
if (AppleDecoderModule::sIsVTAvailable) {
AppleVTLinker::Unlink();
AppleCMLinker::Unlink();
}
return NS_OK;
}
};
@ -81,8 +150,24 @@ AppleDecoderModule::CreateH264Decoder(const mp4_demuxer::VideoDecoderConfig& aCo
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback)
{
nsRefPtr<MediaDataDecoder> decoder =
nsRefPtr<MediaDataDecoder> decoder;
if (sIsVDAAvailable && (!sIsVTHWAvailable || sForceVDA)) {
decoder =
AppleVDADecoder::CreateVDADecoder(aConfig,
aVideoTaskQueue,
aCallback,
aImageContainer);
if (decoder) {
return decoder.forget();
}
}
// We fallback here if VDA isn't available, or is available but isn't
// supported by the current platform.
if (sIsVTAvailable) {
decoder =
new AppleVTDecoder(aConfig, aVideoTaskQueue, aCallback, aImageContainer);
}
return decoder.forget();
}

Просмотреть файл

@ -41,8 +41,18 @@ public:
virtual bool SupportsAudioMimeType(const char* aMimeType) MOZ_OVERRIDE;
static void Init();
static nsresult CanDecode();
private:
static bool sIsEnabled;
friend class InitTask;
friend class LinkTask;
friend class UnlinkTask;
static bool sInitialized;
static bool sIsVTAvailable;
static bool sIsVTHWAvailable;
static bool sIsVDAAvailable;
static bool sForceVDA;
};
} // namespace mozilla

Просмотреть файл

@ -0,0 +1,505 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include <CoreFoundation/CFString.h>
#include "AppleUtils.h"
#include "AppleVDADecoder.h"
#include "AppleVDALinker.h"
#include "mp4_demuxer/DecoderData.h"
#include "MP4Decoder.h"
#include "MediaData.h"
#include "MacIOSurfaceImage.h"
#include "mozilla/ArrayUtils.h"
#include "nsAutoPtr.h"
#include "nsCocoaFeatures.h"
#include "nsThreadUtils.h"
#include "prlog.h"
#include "VideoUtils.h"
#ifdef PR_LOGGING
PRLogModuleInfo* GetAppleMediaLog();
#define LOG(...) PR_LOG(GetAppleMediaLog(), PR_LOG_DEBUG, (__VA_ARGS__))
//#define LOG_MEDIA_SHA1
#else
#define LOG(...)
#endif
namespace mozilla {
AppleVDADecoder::AppleVDADecoder(const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback,
layers::ImageContainer* aImageContainer)
: mConfig(aConfig)
, mTaskQueue(aVideoTaskQueue)
, mCallback(aCallback)
, mImageContainer(aImageContainer)
, mDecoder(nullptr)
, mIs106(!nsCocoaFeatures::OnLionOrLater())
{
MOZ_COUNT_CTOR(AppleVDADecoder);
// TODO: Verify aConfig.mime_type.
LOG("Creating AppleVDADecoder for %dx%d h.264 video",
mConfig.display_width,
mConfig.display_height
);
}
AppleVDADecoder::~AppleVDADecoder()
{
MOZ_COUNT_DTOR(AppleVDADecoder);
}
nsresult
AppleVDADecoder::Init()
{
if (mDecoder) {
return NS_OK;
}
nsresult rv = InitializeSession();
return rv;
}
nsresult
AppleVDADecoder::Shutdown()
{
if (mDecoder) {
LOG("%s: cleaning up decoder %p", __func__, mDecoder);
VDADecoderDestroy(mDecoder);
mDecoder = nullptr;
}
return NS_OK;
}
nsresult
AppleVDADecoder::Input(mp4_demuxer::MP4Sample* aSample)
{
LOG("mp4 input sample %p pts %lld duration %lld us%s %d bytes",
aSample,
aSample->composition_timestamp,
aSample->duration,
aSample->is_sync_point ? " keyframe" : "",
aSample->size);
mTaskQueue->Dispatch(
NS_NewRunnableMethodWithArg<nsAutoPtr<mp4_demuxer::MP4Sample>>(
this,
&AppleVDADecoder::SubmitFrame,
nsAutoPtr<mp4_demuxer::MP4Sample>(aSample)));
return NS_OK;
}
nsresult
AppleVDADecoder::Flush()
{
mTaskQueue->Flush();
OSStatus rv = VDADecoderFlush(mDecoder, 0 /*dont emit*/);
if (rv != noErr) {
LOG("AppleVDADecoder::Flush failed waiting for platform decoder "
"with error:%d.", rv);
}
ClearReorderedFrames();
return NS_OK;
}
nsresult
AppleVDADecoder::Drain()
{
mTaskQueue->AwaitIdle();
OSStatus rv = VDADecoderFlush(mDecoder, kVDADecoderFlush_EmitFrames);
if (rv != noErr) {
LOG("AppleVDADecoder::Drain failed waiting for platform decoder "
"with error:%d.", rv);
}
DrainReorderedFrames();
mCallback->DrainComplete();
return NS_OK;
}
//
// Implementation details.
//
// Callback passed to the VideoToolbox decoder for returning data.
// This needs to be static because the API takes a C-style pair of
// function and userdata pointers. This validates parameters and
// forwards the decoded image back to an object method.
static void
PlatformCallback(void* decompressionOutputRefCon,
CFDictionaryRef frameInfo,
OSStatus status,
VDADecodeInfoFlags infoFlags,
CVImageBufferRef image)
{
LOG("AppleVDADecoder[%s] status %d flags %d retainCount %ld",
__func__, status, infoFlags, CFGetRetainCount(frameInfo));
// Validate our arguments.
// According to Apple's TN2267
// The output callback is still called for all flushed frames,
// but no image buffers will be returned.
// FIXME: Distinguish between errors and empty flushed frames.
if (status != noErr || !image) {
NS_WARNING("AppleVDADecoder decoder returned no data");
return;
}
MOZ_ASSERT(CFGetTypeID(image) == CVPixelBufferGetTypeID(),
"AppleVDADecoder returned an unexpected image type");
if (infoFlags & kVDADecodeInfo_FrameDropped)
{
NS_WARNING(" ...frame dropped...");
return;
}
AppleVDADecoder* decoder =
static_cast<AppleVDADecoder*>(decompressionOutputRefCon);
AutoCFRelease<CFNumberRef> ptsref =
(CFNumberRef)CFDictionaryGetValue(frameInfo, CFSTR("FRAME_PTS"));
AutoCFRelease<CFNumberRef> dtsref =
(CFNumberRef)CFDictionaryGetValue(frameInfo, CFSTR("FRAME_DTS"));
AutoCFRelease<CFNumberRef> durref =
(CFNumberRef)CFDictionaryGetValue(frameInfo, CFSTR("FRAME_DURATION"));
AutoCFRelease<CFNumberRef> boref =
(CFNumberRef)CFDictionaryGetValue(frameInfo, CFSTR("FRAME_OFFSET"));
AutoCFRelease<CFNumberRef> kfref =
(CFNumberRef)CFDictionaryGetValue(frameInfo, CFSTR("FRAME_KEYFRAME"));
Microseconds dts;
Microseconds pts;
Microseconds duration;
int64_t byte_offset;
char is_sync_point;
CFNumberGetValue(ptsref, kCFNumberSInt64Type, &pts);
CFNumberGetValue(dtsref, kCFNumberSInt64Type, &dts);
CFNumberGetValue(durref, kCFNumberSInt64Type, &duration);
CFNumberGetValue(boref, kCFNumberSInt64Type, &byte_offset);
CFNumberGetValue(kfref, kCFNumberSInt8Type, &is_sync_point);
nsAutoPtr<AppleVDADecoder::AppleFrameRef> frameRef(
new AppleVDADecoder::AppleFrameRef(dts,
pts,
duration,
byte_offset,
is_sync_point == 1));
// Forward the data back to an object method which can access
// the correct MP4Reader callback.
decoder->OutputFrame(image, frameRef);
}
AppleVDADecoder::AppleFrameRef*
AppleVDADecoder::CreateAppleFrameRef(const mp4_demuxer::MP4Sample* aSample)
{
MOZ_ASSERT(aSample);
return new AppleFrameRef(*aSample);
}
void
AppleVDADecoder::DrainReorderedFrames()
{
while (!mReorderQueue.IsEmpty()) {
mCallback->Output(mReorderQueue.Pop());
}
}
void
AppleVDADecoder::ClearReorderedFrames()
{
while (!mReorderQueue.IsEmpty()) {
delete mReorderQueue.Pop();
}
}
// Copy and return a decoded frame.
nsresult
AppleVDADecoder::OutputFrame(CVPixelBufferRef aImage,
nsAutoPtr<AppleVDADecoder::AppleFrameRef> aFrameRef)
{
IOSurfacePtr surface = MacIOSurfaceLib::CVPixelBufferGetIOSurface(aImage);
MOZ_ASSERT(surface, "Decoder didn't return an IOSurface backed buffer");
LOG("mp4 output frame %lld dts %lld pts %lld duration %lld us%s",
aFrameRef->byte_offset,
aFrameRef->decode_timestamp,
aFrameRef->composition_timestamp,
aFrameRef->duration,
aFrameRef->is_sync_point ? " keyframe" : ""
);
nsRefPtr<MacIOSurface> macSurface = new MacIOSurface(surface);
// Bounds.
VideoInfo info;
info.mDisplay = nsIntSize(macSurface->GetWidth(), macSurface->GetHeight());
info.mHasVideo = true;
gfx::IntRect visible = gfx::IntRect(0,
0,
mConfig.display_width,
mConfig.display_height);
nsRefPtr<layers::Image> image =
mImageContainer->CreateImage(ImageFormat::MAC_IOSURFACE);
layers::MacIOSurfaceImage* videoImage =
static_cast<layers::MacIOSurfaceImage*>(image.get());
videoImage->SetSurface(macSurface);
nsAutoPtr<VideoData> data;
data = VideoData::CreateFromImage(info,
mImageContainer,
aFrameRef->byte_offset,
aFrameRef->composition_timestamp,
aFrameRef->duration, image.forget(),
aFrameRef->is_sync_point,
aFrameRef->decode_timestamp,
visible);
if (!data) {
NS_ERROR("Couldn't create VideoData for frame");
mCallback->Error();
return NS_ERROR_FAILURE;
}
// Frames come out in DTS order but we need to output them
// in composition order.
mReorderQueue.Push(data.forget());
// Assume a frame with a PTS <= current DTS is ready.
while (mReorderQueue.Length() > 0) {
VideoData* readyData = mReorderQueue.Pop();
if (readyData->mTime <= aFrameRef->decode_timestamp) {
LOG("returning queued frame with pts %lld", readyData->mTime);
mCallback->Output(readyData);
} else {
LOG("requeued frame with pts %lld > %lld",
readyData->mTime, aFrameRef->decode_timestamp);
mReorderQueue.Push(readyData);
break;
}
}
LOG("%llu decoded frames queued",
static_cast<unsigned long long>(mReorderQueue.Length()));
return NS_OK;
}
nsresult
AppleVDADecoder::SubmitFrame(mp4_demuxer::MP4Sample* aSample)
{
AutoCFRelease<CFDataRef> block =
CFDataCreate(kCFAllocatorDefault, aSample->data, aSample->size);
if (!block) {
NS_ERROR("Couldn't create CFData");
return NS_ERROR_FAILURE;
}
AutoCFRelease<CFNumberRef> pts =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt64Type,
&aSample->composition_timestamp);
AutoCFRelease<CFNumberRef> dts =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt64Type,
&aSample->decode_timestamp);
AutoCFRelease<CFNumberRef> duration =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt64Type,
&aSample->duration);
AutoCFRelease<CFNumberRef> byte_offset =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt64Type,
&aSample->byte_offset);
char keyframe = aSample->is_sync_point ? 1 : 0;
AutoCFRelease<CFNumberRef> cfkeyframe =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt8Type,
&keyframe);
const void* keys[] = { CFSTR("FRAME_PTS"),
CFSTR("FRAME_DTS"),
CFSTR("FRAME_DURATION"),
CFSTR("FRAME_OFFSET"),
CFSTR("FRAME_KEYFRAME") };
const void* values[] = { pts,
dts,
duration,
byte_offset,
cfkeyframe };
static_assert(ArrayLength(keys) == ArrayLength(values),
"Non matching keys/values array size");
AutoCFRelease<CFDictionaryRef> frameInfo =
CFDictionaryCreate(kCFAllocatorDefault,
keys,
values,
ArrayLength(keys),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
OSStatus rv = VDADecoderDecode(mDecoder,
0,
block,
frameInfo);
LOG("[%s]: FrameInfo retain count = %ld",
__func__, CFGetRetainCount(frameInfo));
MOZ_ASSERT(CFGetRetainCount(frameInfo) >= 2, "Bad retain count");
if (rv != noErr) {
NS_ERROR("AppleVDADecoder: Couldn't pass frame to decoder");
return NS_ERROR_FAILURE;
}
if (mIs106) {
// TN2267:
// frameInfo: A CFDictionaryRef containing information to be returned in
// the output callback for this frame.
// This dictionary can contain client provided information associated with
// the frame being decoded, for example presentation time.
// The CFDictionaryRef will be retained by the framework.
// In 10.6, it is released one too many. So retain it.
CFRetain(frameInfo);
}
// Ask for more data.
if (mTaskQueue->IsEmpty()) {
LOG("AppleVDADecoder task queue empty; requesting more data");
mCallback->InputExhausted();
}
return NS_OK;
}
nsresult
AppleVDADecoder::InitializeSession()
{
OSStatus rv;
AutoCFRelease<CFDictionaryRef> decoderConfig =
CreateDecoderSpecification();
AutoCFRelease<CFDictionaryRef> outputConfiguration =
CreateOutputConfiguration();
rv =
VDADecoderCreate(decoderConfig,
outputConfiguration,
(VDADecoderOutputCallback*)PlatformCallback,
this,
&mDecoder);
if (rv != noErr) {
NS_ERROR("AppleVDADecoder: Couldn't create decoder!");
return NS_ERROR_FAILURE;
}
return NS_OK;
}
CFDictionaryRef
AppleVDADecoder::CreateDecoderSpecification()
{
const uint8_t* extradata = mConfig.extra_data.begin();
int extrasize = mConfig.extra_data.length();
OSType format = 'avc1';
AutoCFRelease<CFNumberRef> avc_width =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt32Type,
&mConfig.display_width);
AutoCFRelease<CFNumberRef> avc_height =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt32Type,
&mConfig.display_height);
AutoCFRelease<CFNumberRef> avc_format =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt32Type,
&format);
AutoCFRelease<CFDataRef> avc_data =
CFDataCreate(kCFAllocatorDefault,
extradata,
extrasize);
const void* decoderKeys[] = { AppleVDALinker::skPropWidth,
AppleVDALinker::skPropHeight,
AppleVDALinker::skPropSourceFormat,
AppleVDALinker::skPropAVCCData };
const void* decoderValue[] = { avc_width,
avc_height,
avc_format,
avc_data };
static_assert(ArrayLength(decoderKeys) == ArrayLength(decoderValue),
"Non matching keys/values array size");
return CFDictionaryCreate(kCFAllocatorDefault,
decoderKeys,
decoderValue,
ArrayLength(decoderKeys),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
}
CFDictionaryRef
AppleVDADecoder::CreateOutputConfiguration()
{
// Construct IOSurface Properties
const void* IOSurfaceKeys[] = { MacIOSurfaceLib::kPropIsGlobal };
const void* IOSurfaceValues[] = { kCFBooleanTrue };
static_assert(ArrayLength(IOSurfaceKeys) == ArrayLength(IOSurfaceValues),
"Non matching keys/values array size");
// Contruct output configuration.
AutoCFRelease<CFDictionaryRef> IOSurfaceProperties =
CFDictionaryCreate(kCFAllocatorDefault,
IOSurfaceKeys,
IOSurfaceValues,
ArrayLength(IOSurfaceKeys),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
SInt32 PixelFormatTypeValue = kCVPixelFormatType_32BGRA;
AutoCFRelease<CFNumberRef> PixelFormatTypeNumber =
CFNumberCreate(kCFAllocatorDefault,
kCFNumberSInt32Type,
&PixelFormatTypeValue);
const void* outputKeys[] = { kCVPixelBufferIOSurfacePropertiesKey,
kCVPixelBufferPixelFormatTypeKey,
kCVPixelBufferOpenGLCompatibilityKey };
const void* outputValues[] = { IOSurfaceProperties,
PixelFormatTypeNumber,
kCFBooleanTrue };
static_assert(ArrayLength(outputKeys) == ArrayLength(outputValues),
"Non matching keys/values array size");
return CFDictionaryCreate(kCFAllocatorDefault,
outputKeys,
outputValues,
ArrayLength(outputKeys),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
}
/* static */
already_AddRefed<AppleVDADecoder>
AppleVDADecoder::CreateVDADecoder(
const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback,
layers::ImageContainer* aImageContainer)
{
nsRefPtr<AppleVDADecoder> decoder =
new AppleVDADecoder(aConfig, aVideoTaskQueue, aCallback, aImageContainer);
if (NS_FAILED(decoder->Init())) {
NS_ERROR("AppleVDADecoder an error occurred");
return nullptr;
}
return decoder.forget();
}
} // namespace mozilla

Просмотреть файл

@ -0,0 +1,108 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef mozilla_AppleVDADecoder_h
#define mozilla_AppleVDADecoder_h
#include "PlatformDecoderModule.h"
#include "mozilla/RefPtr.h"
#include "mozilla/ReentrantMonitor.h"
#include "MP4Reader.h"
#include "MP4Decoder.h"
#include "nsIThread.h"
#include "ReorderQueue.h"
#include "VideoDecodeAcceleration/VDADecoder.h"
namespace mozilla {
class MediaTaskQueue;
class MediaDataDecoderCallback;
namespace layers {
class ImageContainer;
}
class AppleVDADecoder : public MediaDataDecoder {
public:
class AppleFrameRef {
public:
Microseconds decode_timestamp;
Microseconds composition_timestamp;
Microseconds duration;
int64_t byte_offset;
bool is_sync_point;
explicit AppleFrameRef(const mp4_demuxer::MP4Sample& aSample)
: decode_timestamp(aSample.decode_timestamp)
, composition_timestamp(aSample.composition_timestamp)
, duration(aSample.duration)
, byte_offset(aSample.byte_offset)
, is_sync_point(aSample.is_sync_point)
{
}
AppleFrameRef(Microseconds aDts,
Microseconds aPts,
Microseconds aDuration,
int64_t aByte_offset,
bool aIs_sync_point)
: decode_timestamp(aDts)
, composition_timestamp(aPts)
, duration(aDuration)
, byte_offset(aByte_offset)
, is_sync_point(aIs_sync_point)
{
}
};
// Return a new created AppleVDADecoder or nullptr if media or hardware is
// not supported by current configuration.
static already_AddRefed<AppleVDADecoder> CreateVDADecoder(
const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback,
layers::ImageContainer* aImageContainer);
AppleVDADecoder(const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback,
layers::ImageContainer* aImageContainer);
~AppleVDADecoder();
virtual nsresult Init() MOZ_OVERRIDE;
virtual nsresult Input(mp4_demuxer::MP4Sample* aSample) MOZ_OVERRIDE;
virtual nsresult Flush() MOZ_OVERRIDE;
virtual nsresult Drain() MOZ_OVERRIDE;
virtual nsresult Shutdown() MOZ_OVERRIDE;
nsresult OutputFrame(CVPixelBufferRef aImage,
nsAutoPtr<AppleFrameRef> aFrameRef);
protected:
AppleFrameRef* CreateAppleFrameRef(const mp4_demuxer::MP4Sample* aSample);
void DrainReorderedFrames();
void ClearReorderedFrames();
CFDictionaryRef CreateOutputConfiguration();
const mp4_demuxer::VideoDecoderConfig& mConfig;
RefPtr<MediaTaskQueue> mTaskQueue;
MediaDataDecoderCallback* mCallback;
layers::ImageContainer* mImageContainer;
ReorderQueue mReorderQueue;
private:
VDADecoder mDecoder;
bool mIs106;
// Method to pass a frame to VideoToolbox for decoding.
nsresult SubmitFrame(mp4_demuxer::MP4Sample* aSample);
// Method to set up the decompression session.
nsresult InitializeSession();
CFDictionaryRef CreateDecoderSpecification();
};
} // namespace mozilla
#endif // mozilla_AppleVDADecoder_h

Просмотреть файл

@ -0,0 +1,12 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
// Construct references to each of the VDA symbols we use.
LINK_FUNC(VDADecoderCreate)
LINK_FUNC(VDADecoderDecode)
LINK_FUNC(VDADecoderFlush)
LINK_FUNC(VDADecoderDestroy)

Просмотреть файл

@ -0,0 +1,119 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include <dlfcn.h>
#include "AppleVDALinker.h"
#include "MainThreadUtils.h"
#include "nsDebug.h"
#ifdef PR_LOGGING
PRLogModuleInfo* GetAppleMediaLog();
#define LOG(...) PR_LOG(GetAppleMediaLog(), PR_LOG_DEBUG, (__VA_ARGS__))
#else
#define LOG(...)
#endif
namespace mozilla {
AppleVDALinker::LinkStatus
AppleVDALinker::sLinkStatus = LinkStatus_INIT;
void* AppleVDALinker::sLink = nullptr;
nsrefcnt AppleVDALinker::sRefCount = 0;
CFStringRef AppleVDALinker::skPropWidth = nullptr;
CFStringRef AppleVDALinker::skPropHeight = nullptr;
CFStringRef AppleVDALinker::skPropSourceFormat = nullptr;
CFStringRef AppleVDALinker::skPropAVCCData = nullptr;
#define LINK_FUNC(func) typeof(func) func;
#include "AppleVDAFunctions.h"
#undef LINK_FUNC
/* static */ bool
AppleVDALinker::Link()
{
// Bump our reference count every time we're called.
// Add a lock or change the thread assertion if
// you need to call this off the main thread.
MOZ_ASSERT(NS_IsMainThread());
++sRefCount;
if (sLinkStatus) {
return sLinkStatus == LinkStatus_SUCCEEDED;
}
const char* dlname =
"/System/Library/Frameworks/VideoDecodeAcceleration.framework/VideoDecodeAcceleration";
if (!(sLink = dlopen(dlname, RTLD_NOW | RTLD_LOCAL))) {
NS_WARNING("Couldn't load VideoDecodeAcceleration framework");
goto fail;
}
#define LINK_FUNC(func) \
func = (typeof(func))dlsym(sLink, #func); \
if (!func) { \
NS_WARNING("Couldn't load VideoDecodeAcceleration function " #func ); \
goto fail; \
}
#include "AppleVDAFunctions.h"
#undef LINK_FUNC
skPropWidth = GetIOConst("kVDADecoderConfiguration_Width");
skPropHeight = GetIOConst("kVDADecoderConfiguration_Height");
skPropSourceFormat = GetIOConst("kVDADecoderConfiguration_SourceFormat");
skPropAVCCData = GetIOConst("kVDADecoderConfiguration_avcCData");
if (!skPropWidth || !skPropHeight || !skPropSourceFormat || !skPropAVCCData) {
goto fail;
}
LOG("Loaded VideoDecodeAcceleration framework.");
sLinkStatus = LinkStatus_SUCCEEDED;
return true;
fail:
Unlink();
sLinkStatus = LinkStatus_FAILED;
return false;
}
/* static */ void
AppleVDALinker::Unlink()
{
// We'll be called by multiple Decoders, one intantiated for
// each media element. Therefore we receive must maintain a
// reference count to avoidunloading our symbols when other
// instances still need them.
MOZ_ASSERT(NS_IsMainThread());
MOZ_ASSERT(sRefCount > 0, "Unbalanced Unlink()");
--sRefCount;
if (sLink && sRefCount < 1) {
LOG("Unlinking VideoToolbox framework.");
dlclose(sLink);
sLink = nullptr;
skPropWidth = nullptr;
skPropHeight = nullptr;
skPropSourceFormat = nullptr;
skPropAVCCData = nullptr;
sLinkStatus = LinkStatus_INIT;
}
}
/* static */ CFStringRef
AppleVDALinker::GetIOConst(const char* symbol)
{
CFStringRef* address = (CFStringRef*)dlsym(sLink, symbol);
if (!address) {
return nullptr;
}
return *address;
}
} // namespace mozilla

Просмотреть файл

@ -0,0 +1,49 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef AppleVDALinker_h
#define AppleVDALinker_h
extern "C" {
#pragma GCC visibility push(default)
#include "VideoDecodeAcceleration/VDADecoder.h"
#pragma GCC visibility pop
}
#include "nscore.h"
namespace mozilla {
class AppleVDALinker
{
public:
static bool Link();
static void Unlink();
static CFStringRef skPropWidth;
static CFStringRef skPropHeight;
static CFStringRef skPropSourceFormat;
static CFStringRef skPropAVCCData;
private:
static void* sLink;
static nsrefcnt sRefCount;
static enum LinkStatus {
LinkStatus_INIT = 0,
LinkStatus_FAILED,
LinkStatus_SUCCEEDED
} sLinkStatus;
static CFStringRef GetIOConst(const char* symbol);
};
#define LINK_FUNC(func) extern typeof(func)* func;
#include "AppleVDAFunctions.h"
#undef LINK_FUNC
} // namespace mozilla
#endif // AppleVDALinker_h

Просмотреть файл

@ -11,8 +11,6 @@
#include "AppleVTDecoder.h"
#include "AppleVTLinker.h"
#include "mp4_demuxer/DecoderData.h"
#include "MP4Reader.h"
#include "MP4Decoder.h"
#include "MediaData.h"
#include "MacIOSurfaceImage.h"
#include "mozilla/ArrayUtils.h"
@ -39,10 +37,7 @@ AppleVTDecoder::AppleVTDecoder(const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
MediaDataDecoderCallback* aCallback,
layers::ImageContainer* aImageContainer)
: mConfig(aConfig)
, mTaskQueue(aVideoTaskQueue)
, mCallback(aCallback)
, mImageContainer(aImageContainer)
: AppleVDADecoder(aConfig, aVideoTaskQueue, aCallback, aImageContainer)
, mFormat(nullptr)
, mSession(nullptr)
{
@ -119,7 +114,8 @@ AppleVTDecoder::Flush()
mTaskQueue->Flush();
nsresult rv = WaitForAsynchronousFrames();
if (NS_FAILED(rv)) {
LOG("AppleVTDecoder::Drain failed waiting for platform decoder.");
LOG("AppleVTDecoder::Flush failed waiting for platform decoder "
"with error:%d.", rv);
}
ClearReorderedFrames();
@ -132,8 +128,8 @@ AppleVTDecoder::Drain()
mTaskQueue->AwaitIdle();
nsresult rv = WaitForAsynchronousFrames();
if (NS_FAILED(rv)) {
LOG("AppleVTDecoder::Drain failed waiting for platform decoder.");
return rv;
LOG("AppleVTDecoder::Drain failed waiting for platform decoder "
"with error:%d.", rv);
}
DrainReorderedFrames();
mCallback->DrainComplete();
@ -144,26 +140,6 @@ AppleVTDecoder::Drain()
// Implementation details.
//
// Context object to hold a copy of sample metadata.
class FrameRef {
public:
Microseconds decode_timestamp;
Microseconds composition_timestamp;
Microseconds duration;
int64_t byte_offset;
bool is_sync_point;
explicit FrameRef(mp4_demuxer::MP4Sample* aSample)
{
MOZ_ASSERT(aSample);
decode_timestamp = aSample->decode_timestamp;
composition_timestamp = aSample->composition_timestamp;
duration = aSample->duration;
byte_offset = aSample->byte_offset;
is_sync_point = aSample->is_sync_point;
}
};
// Callback passed to the VideoToolbox decoder for returning data.
// This needs to be static because the API takes a C-style pair of
// function and userdata pointers. This validates parameters and
@ -181,16 +157,8 @@ PlatformCallback(void* decompressionOutputRefCon,
AppleVTDecoder* decoder =
static_cast<AppleVTDecoder*>(decompressionOutputRefCon);
nsAutoPtr<FrameRef> frameRef =
nsAutoPtr<FrameRef>(static_cast<FrameRef*>(sourceFrameRefCon));
LOG("mp4 output frame %lld dts %lld pts %lld duration %lld us%s",
frameRef->byte_offset,
frameRef->decode_timestamp,
frameRef->composition_timestamp,
frameRef->duration,
frameRef->is_sync_point ? " keyframe" : ""
);
nsAutoPtr<AppleVTDecoder::AppleFrameRef> frameRef(
static_cast<AppleVTDecoder::AppleFrameRef*>(sourceFrameRefCon));
// Validate our arguments.
if (status != noErr || !image) {
@ -219,84 +187,6 @@ AppleVTDecoder::WaitForAsynchronousFrames()
return NS_OK;
}
void
AppleVTDecoder::DrainReorderedFrames()
{
while (!mReorderQueue.IsEmpty()) {
mCallback->Output(mReorderQueue.Pop());
}
}
void
AppleVTDecoder::ClearReorderedFrames()
{
while (!mReorderQueue.IsEmpty()) {
delete mReorderQueue.Pop();
}
}
// Copy and return a decoded frame.
nsresult
AppleVTDecoder::OutputFrame(CVPixelBufferRef aImage,
nsAutoPtr<FrameRef> aFrameRef)
{
IOSurfacePtr surface = MacIOSurfaceLib::CVPixelBufferGetIOSurface(aImage);
MOZ_ASSERT(surface, "VideoToolbox didn't return an IOSurface backed buffer");
nsRefPtr<MacIOSurface> macSurface = new MacIOSurface(surface);
// Bounds.
VideoInfo info;
info.mDisplay = nsIntSize(macSurface->GetWidth(), macSurface->GetHeight());
info.mHasVideo = true;
gfx::IntRect visible = gfx::IntRect(0,
0,
mConfig.display_width,
mConfig.display_height);
nsRefPtr<layers::Image> image =
mImageContainer->CreateImage(ImageFormat::MAC_IOSURFACE);
layers::MacIOSurfaceImage* videoImage =
static_cast<layers::MacIOSurfaceImage*>(image.get());
videoImage->SetSurface(macSurface);
nsAutoPtr<VideoData> data;
data = VideoData::CreateFromImage(info,
mImageContainer,
aFrameRef->byte_offset,
aFrameRef->composition_timestamp,
aFrameRef->duration, image.forget(),
aFrameRef->is_sync_point,
aFrameRef->decode_timestamp,
visible);
if (!data) {
NS_ERROR("Couldn't create VideoData for frame");
mCallback->Error();
return NS_ERROR_FAILURE;
}
// Frames come out in DTS order but we need to output them
// in composition order.
mReorderQueue.Push(data.forget());
// Assume a frame with a PTS <= current DTS is ready.
while (mReorderQueue.Length() > 0) {
VideoData* readyData = mReorderQueue.Pop();
if (readyData->mTime <= aFrameRef->decode_timestamp) {
LOG("returning queued frame with pts %lld", readyData->mTime);
mCallback->Output(readyData);
} else {
LOG("requeued frame with pts %lld > %lld",
readyData->mTime, aFrameRef->decode_timestamp);
mReorderQueue.Push(readyData);
break;
}
}
LOG("%llu decoded frames queued",
static_cast<unsigned long long>(mReorderQueue.Length()));
return NS_OK;
}
// Helper to fill in a timestamp structure.
static CMSampleTimingInfo
TimingInfoFromSample(mp4_demuxer::MP4Sample* aSample)
@ -325,7 +215,7 @@ AppleVTDecoder::SubmitFrame(mp4_demuxer::MP4Sample* aSample)
// a custom block source which reuses the aSample buffer.
// But note that there may be a problem keeping the samples
// alive over multiple frames.
rv = CMBlockBufferCreateWithMemoryBlock(NULL // Struct allocator.
rv = CMBlockBufferCreateWithMemoryBlock(kCFAllocatorDefault // Struct allocator.
,aSample->data
,aSample->size
,kCFAllocatorNull // Block allocator.
@ -334,16 +224,25 @@ AppleVTDecoder::SubmitFrame(mp4_demuxer::MP4Sample* aSample)
,aSample->size
,false
,block.receive());
NS_ASSERTION(rv == noErr, "Couldn't create CMBlockBuffer");
if (rv != noErr) {
NS_ERROR("Couldn't create CMBlockBuffer");
return NS_ERROR_FAILURE;
}
CMSampleTimingInfo timestamp = TimingInfoFromSample(aSample);
rv = CMSampleBufferCreate(NULL, block, true, 0, 0, mFormat, 1, 1, &timestamp, 0, NULL, sample.receive());
NS_ASSERTION(rv == noErr, "Couldn't create CMSampleBuffer");
rv = CMSampleBufferCreate(kCFAllocatorDefault, block, true, 0, 0, mFormat, 1, 1, &timestamp, 0, NULL, sample.receive());
if (rv != noErr) {
NS_ERROR("Couldn't create CMSampleBuffer");
return NS_ERROR_FAILURE;
}
rv = VTDecompressionSessionDecodeFrame(mSession,
sample,
0,
new FrameRef(aSample),
CreateAppleFrameRef(aSample),
&flags);
NS_ASSERTION(rv == noErr, "Couldn't pass frame to decoder");
if (rv != noErr) {
NS_ERROR("Couldn't pass frame to decoder");
return NS_ERROR_FAILURE;
}
// Ask for more data.
if (mTaskQueue->IsEmpty()) {
@ -358,20 +257,6 @@ nsresult
AppleVTDecoder::InitializeSession()
{
OSStatus rv;
AutoCFRelease<CFMutableDictionaryRef> extensions =
CFDictionaryCreateMutable(NULL, 0,
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
AppleUtils::SetCFDict(extensions, "CVImageBufferChromaLocationBottomField", "left");
AppleUtils::SetCFDict(extensions, "CVImageBufferChromaLocationTopField", "left");
AppleUtils::SetCFDict(extensions, "FullRangeVideo", true);
AutoCFRelease<CFMutableDictionaryRef> atoms =
CFDictionaryCreateMutable(NULL, 0,
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
AutoCFRelease<CFDataRef> avc_data = CFDataCreate(NULL,
mConfig.extra_data.begin(), mConfig.extra_data.length());
#ifdef LOG_MEDIA_SHA1
SHA1Sum avc_hash;
@ -386,9 +271,9 @@ AppleVTDecoder::InitializeSession()
mConfig.extra_data.length(), avc_digest.get());
#endif // LOG_MEDIA_SHA1
CFDictionarySetValue(atoms, CFSTR("avcC"), avc_data);
CFDictionarySetValue(extensions, CFSTR("SampleDescriptionExtensionAtoms"), atoms);
rv = CMVideoFormatDescriptionCreate(NULL, // Use default allocator.
AutoCFRelease<CFDictionaryRef> extensions = CreateDecoderExtensions();
rv = CMVideoFormatDescriptionCreate(kCFAllocatorDefault,
kCMVideoCodecType_H264,
mConfig.display_width,
mConfig.display_height,
@ -403,34 +288,11 @@ AppleVTDecoder::InitializeSession()
AutoCFRelease<CFDictionaryRef> spec = CreateDecoderSpecification();
// Contruct output configuration.
AutoCFRelease<CFDictionaryRef> IOSurfaceProperties =
CFDictionaryCreate(NULL,
NULL,
NULL,
0,
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
SInt32 PixelFormatTypeValue = kCVPixelFormatType_32BGRA;
AutoCFRelease<CFNumberRef> PixelFormatTypeNumber =
CFNumberCreate(NULL, kCFNumberSInt32Type, &PixelFormatTypeValue);
const void* outputKeys[] = { kCVPixelBufferIOSurfacePropertiesKey,
kCVPixelBufferPixelFormatTypeKey,
kCVPixelBufferOpenGLCompatibilityKey };
const void* outputValues[] = { IOSurfaceProperties,
PixelFormatTypeNumber,
kCFBooleanTrue };
AutoCFRelease<CFDictionaryRef> outputConfiguration =
CFDictionaryCreate(NULL,
outputKeys,
outputValues,
ArrayLength(outputKeys),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
CreateOutputConfiguration();
VTDecompressionOutputCallbackRecord cb = { PlatformCallback, this };
rv = VTDecompressionSessionCreate(NULL, // Allocator.
rv = VTDecompressionSessionCreate(kCFAllocatorDefault,
mFormat,
spec, // Video decoder selection.
outputConfiguration, // Output video format.
@ -445,16 +307,64 @@ AppleVTDecoder::InitializeSession()
return NS_OK;
}
CFDictionaryRef
AppleVTDecoder::CreateDecoderExtensions()
{
AutoCFRelease<CFDataRef> avc_data =
CFDataCreate(kCFAllocatorDefault,
mConfig.extra_data.begin(),
mConfig.extra_data.length());
const void* atomsKey[] = { CFSTR("avcC") };
const void* atomsValue[] = { avc_data };
static_assert(ArrayLength(atomsKey) == ArrayLength(atomsValue),
"Non matching keys/values array size");
AutoCFRelease<CFDictionaryRef> atoms =
CFDictionaryCreate(kCFAllocatorDefault,
atomsKey,
atomsValue,
ArrayLength(atomsKey),
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
const void* extensionKeys[] =
{ kCVImageBufferChromaLocationBottomFieldKey,
kCVImageBufferChromaLocationTopFieldKey,
AppleCMLinker::skPropExtensionAtoms,
AppleCMLinker::skPropFullRangeVideo /* Not defined in 10.6 */ };
const void* extensionValues[] =
{ kCVImageBufferChromaLocation_Left,
kCVImageBufferChromaLocation_Left,
atoms,
kCFBooleanTrue };
static_assert(ArrayLength(extensionKeys) == ArrayLength(extensionValues),
"Non matching keys/values array size");
return CFDictionaryCreate(kCFAllocatorDefault,
extensionKeys,
extensionValues,
AppleCMLinker::skPropFullRangeVideo ?
ArrayLength(extensionKeys) :
ArrayLength(extensionKeys) - 1,
&kCFTypeDictionaryKeyCallBacks,
&kCFTypeDictionaryValueCallBacks);
}
CFDictionaryRef
AppleVTDecoder::CreateDecoderSpecification()
{
if (!AppleVTLinker::GetPropHWAccel()) {
if (!AppleVTLinker::skPropHWAccel) {
return nullptr;
}
const void* specKeys[] = { AppleVTLinker::GetPropHWAccel() };
const void* specKeys[] = { AppleVTLinker::skPropHWAccel };
const void* specValues[] = { kCFBooleanTrue };
return CFDictionaryCreate(NULL,
static_assert(ArrayLength(specKeys) == ArrayLength(specValues),
"Non matching keys/values array size");
return CFDictionaryCreate(kCFAllocatorDefault,
specKeys,
specValues,
ArrayLength(specKeys),

Просмотреть файл

@ -7,24 +7,13 @@
#ifndef mozilla_AppleVTDecoder_h
#define mozilla_AppleVTDecoder_h
#include "PlatformDecoderModule.h"
#include "mozilla/RefPtr.h"
#include "mozilla/ReentrantMonitor.h"
#include "nsIThread.h"
#include "ReorderQueue.h"
#include "AppleVDADecoder.h"
#include "VideoToolbox/VideoToolbox.h"
namespace mozilla {
class MediaTaskQueue;
class MediaDataDecoderCallback;
namespace layers {
class ImageContainer;
}
class FrameRef;
class AppleVTDecoder : public MediaDataDecoder {
class AppleVTDecoder : public AppleVDADecoder {
public:
AppleVTDecoder(const mp4_demuxer::VideoDecoderConfig& aConfig,
MediaTaskQueue* aVideoTaskQueue,
@ -36,27 +25,18 @@ public:
virtual nsresult Flush() MOZ_OVERRIDE;
virtual nsresult Drain() MOZ_OVERRIDE;
virtual nsresult Shutdown() MOZ_OVERRIDE;
// Return hook for VideoToolbox callback.
nsresult OutputFrame(CVPixelBufferRef aImage,
nsAutoPtr<FrameRef> frameRef);
private:
const mp4_demuxer::VideoDecoderConfig& mConfig;
RefPtr<MediaTaskQueue> mTaskQueue;
MediaDataDecoderCallback* mCallback;
layers::ImageContainer* mImageContainer;
CMVideoFormatDescriptionRef mFormat;
VTDecompressionSessionRef mSession;
ReorderQueue mReorderQueue;
// Method to pass a frame to VideoToolbox for decoding.
nsresult SubmitFrame(mp4_demuxer::MP4Sample* aSample);
// Method to set up the decompression session.
nsresult InitializeSession();
nsresult WaitForAsynchronousFrames();
void DrainReorderedFrames();
void ClearReorderedFrames();
CFDictionaryRef CreateDecoderSpecification();
CFDictionaryRef CreateDecoderExtensions();
};
} // namespace mozilla

Просмотреть файл

@ -8,6 +8,7 @@
#include "AppleVTLinker.h"
#include "MainThreadUtils.h"
#include "mozilla/ArrayUtils.h"
#include "nsDebug.h"
#ifdef PR_LOGGING
@ -43,9 +44,17 @@ AppleVTLinker::Link()
return sLinkStatus == LinkStatus_SUCCEEDED;
}
const char* dlname =
"/System/Library/Frameworks/VideoToolbox.framework/VideoToolbox";
if (!(sLink = dlopen(dlname, RTLD_NOW | RTLD_LOCAL))) {
const char* dlnames[] =
{ "/System/Library/Frameworks/VideoToolbox.framework/VideoToolbox",
"/System/Library/PrivateFrameworks/VideoToolbox.framework/VideoToolbox" };
bool dlfound = false;
for (size_t i = 0; i < ArrayLength(dlnames); i++) {
if ((sLink = dlopen(dlnames[i], RTLD_NOW | RTLD_LOCAL))) {
dlfound = true;
break;
}
}
if (!dlfound) {
NS_WARNING("Couldn't load VideoToolbox framework");
goto fail;
}
@ -89,6 +98,7 @@ AppleVTLinker::Unlink()
dlclose(sLink);
sLink = nullptr;
skPropHWAccel = nullptr;
sLinkStatus = LinkStatus_INIT;
}
}
@ -103,10 +113,4 @@ AppleVTLinker::GetIOConst(const char* symbol)
return *address;
}
/* static */ CFStringRef
AppleVTLinker::GetPropHWAccel()
{
return skPropHWAccel;
}
} // namespace mozilla

Просмотреть файл

@ -22,12 +22,11 @@ class AppleVTLinker
public:
static bool Link();
static void Unlink();
static CFStringRef GetPropHWAccel();
static CFStringRef skPropHWAccel;
private:
static void* sLink;
static nsrefcnt sRefCount;
static CFStringRef skPropHWAccel;
static enum LinkStatus {
LinkStatus_INIT = 0,

Просмотреть файл

@ -0,0 +1,63 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
// Stub header for VideoDecodeAcceleration framework API.
// This is a private Framework on 10.6 see:
// https://developer.apple.com/library/mac/technotes/tn2267/_index.html
// We include our own copy so we can build on MacOS versions
// where it's not available.
#ifndef mozilla_VideoDecodeAcceleration_VDADecoder_h
#define mozilla_VideoDecodeAcceleration_VDADecoder_h
#include <CoreFoundation/CoreFoundation.h>
#include <CoreVideo/CoreVideo.h>
typedef uint32_t VDADecodeFrameFlags;
typedef uint32_t VDADecodeInfoFlags;
enum {
kVDADecodeInfo_Asynchronous = 1UL << 0,
kVDADecodeInfo_FrameDropped = 1UL << 1
};
enum {
kVDADecoderFlush_EmitFrames = 1 << 0
};
typedef struct OpaqueVDADecoder* VDADecoder;
typedef void (*VDADecoderOutputCallback)
(void* decompressionOutputRefCon,
CFDictionaryRef frameInfo,
OSStatus status,
uint32_t infoFlags,
CVImageBufferRef imageBuffer);
OSStatus
VDADecoderCreate(
CFDictionaryRef decoderConfiguration,
CFDictionaryRef destinationImageBufferAttributes, /* can be NULL */
VDADecoderOutputCallback* outputCallback,
void* decoderOutputCallbackRefcon,
VDADecoder* decoderOut);
OSStatus
VDADecoderDecode(
VDADecoder decoder,
uint32_t decodeFlags,
CFTypeRef compressedBuffer,
CFDictionaryRef frameInfo); /* can be NULL */
OSStatus
VDADecoderFlush(
VDADecoder decoder,
uint32_t flushFlags);
OSStatus
VDADecoderDestroy(VDADecoder decoder);
#endif // mozilla_VideoDecodeAcceleration_VDADecoder_h

Просмотреть файл

@ -15,12 +15,9 @@
// so we need to dlopen it as well to run on 10.6,
// but we can depend on the real framework headers at build time.
#include <CoreMedia/CMBase.h>
#include <CoreFoundation/CoreFoundation.h>
#include <CoreMedia/CoreMedia.h>
#include <CoreVideo/CVPixelBuffer.h>
#include <CoreMedia/CMSampleBuffer.h>
#include <CoreMedia/CMFormatDescription.h>
#include <CoreMedia/CMTime.h>
typedef uint32_t VTDecodeFrameFlags;
typedef uint32_t VTDecodeInfoFlags;

Просмотреть файл

@ -52,6 +52,8 @@ if CONFIG['MOZ_APPLEMEDIA']:
'apple/AppleCMLinker.cpp',
'apple/AppleDecoderModule.cpp',
'apple/AppleUtils.cpp',
'apple/AppleVDADecoder.cpp',
'apple/AppleVDALinker.cpp',
'apple/AppleVTDecoder.cpp',
'apple/AppleVTLinker.cpp',
]

Просмотреть файл

@ -21,7 +21,6 @@
#include "nsContentTypeParser.h"
#include "nsDebug.h"
#include "nsError.h"
#include "nsIEventTarget.h"
#include "nsIRunnable.h"
#include "nsPIDOMWindow.h"
#include "nsString.h"

Просмотреть файл

@ -10,7 +10,6 @@
#include "DecoderTraits.h"
#include "MediaDataDecodedListener.h"
#include "MediaDecoderOwner.h"
#include "MediaSource.h"
#include "MediaSourceDecoder.h"
#include "MediaSourceUtils.h"
#include "SourceBufferDecoder.h"

Просмотреть файл

@ -9,7 +9,6 @@
#include "AsyncEventRunner.h"
#include "MediaSourceUtils.h"
#include "TrackBuffer.h"
#include "VideoUtils.h"
#include "WebMBufferedParser.h"
#include "mozilla/Endian.h"
#include "mozilla/ErrorResult.h"
@ -583,15 +582,9 @@ void
SourceBuffer::AppendData(const uint8_t* aData, uint32_t aLength, ErrorResult& aRv)
{
MSE_DEBUG("SourceBuffer(%p)::AppendData(aLength=%u)", this, aLength);
if (!IsAttached() || mUpdating) {
aRv.Throw(NS_ERROR_DOM_INVALID_STATE_ERR);
if (!PrepareAppend(aRv)) {
return;
}
if (mMediaSource->ReadyState() == MediaSourceReadyState::Ended) {
mMediaSource->SetReadyState(MediaSourceReadyState::Open);
}
// TODO: Run coded frame eviction algorithm.
// TODO: Test buffer full flag.
StartUpdating();
// TODO: Run more of the buffer append algorithm asynchronously.
if (mParser->IsInitSegmentPresent(aData, aLength)) {
@ -647,6 +640,28 @@ SourceBuffer::AppendData(const uint8_t* aData, uint32_t aLength, ErrorResult& aR
return;
}
// Schedule the state machine thread to ensure playback starts
// if required when data is appended.
mMediaSource->GetDecoder()->ScheduleStateMachineThread();
// Run the final step of the buffer append algorithm asynchronously to
// ensure the SourceBuffer's updating flag transition behaves as required
// by the spec.
nsCOMPtr<nsIRunnable> event = NS_NewRunnableMethod(this, &SourceBuffer::StopUpdating);
NS_DispatchToMainThread(event);
}
bool
SourceBuffer::PrepareAppend(ErrorResult& aRv)
{
if (!IsAttached() || mUpdating) {
aRv.Throw(NS_ERROR_DOM_INVALID_STATE_ERR);
return false;
}
if (mMediaSource->ReadyState() == MediaSourceReadyState::Ended) {
mMediaSource->SetReadyState(MediaSourceReadyState::Open);
}
// Eviction uses a byte threshold. If the buffer is greater than the
// number of bytes then data is evicted. The time range for this
// eviction is reported back to the media source. It will then
@ -665,15 +680,8 @@ SourceBuffer::AppendData(const uint8_t* aData, uint32_t aLength, ErrorResult& aR
mMediaSource->NotifyEvicted(0.0, GetBufferedStart());
}
// Run the final step of the buffer append algorithm asynchronously to
// ensure the SourceBuffer's updating flag transition behaves as required
// by the spec.
nsCOMPtr<nsIRunnable> event = NS_NewRunnableMethod(this, &SourceBuffer::StopUpdating);
NS_DispatchToMainThread(event);
// Schedule the state machine thread to ensure playback starts
// if required when data is appended.
mMediaSource->GetDecoder()->ScheduleStateMachineThread();
// TODO: Test buffer full flag.
return true;
}
double

Просмотреть файл

@ -135,6 +135,10 @@ private:
// Shared implementation of AppendBuffer overloads.
void AppendData(const uint8_t* aData, uint32_t aLength, ErrorResult& aRv);
// Implements the "Prepare Append Algorithm". Returns true if the append
// may continue, or false (with aRv set) on error.
bool PrepareAppend(ErrorResult& aRv);
nsRefPtr<MediaSource> mMediaSource;
const nsCString mType;

Просмотреть файл

@ -8,7 +8,6 @@
#include "prlog.h"
#include "AbstractMediaDecoder.h"
#include "MediaDecoderReader.h"
#include "mozilla/dom/TimeRanges.h"
#ifdef PR_LOGGING
extern PRLogModuleInfo* GetMediaSourceLog();

Просмотреть файл

@ -11,7 +11,6 @@
#include "mozilla/dom/SourceBufferListBinding.h"
#include "mozilla/mozalloc.h"
#include "nsCOMPtr.h"
#include "nsIEventTarget.h"
#include "nsIRunnable.h"
#include "nsString.h"
#include "nsThreadUtils.h"

Просмотреть файл

@ -6,11 +6,10 @@
#include "SourceBufferResource.h"
#include <string.h>
#include <algorithm>
#include "nsISeekableStream.h"
#include "nsISupportsImpl.h"
#include "nsISupports.h"
#include "prlog.h"
#ifdef PR_LOGGING
@ -32,12 +31,6 @@ PRLogModuleInfo* GetSourceBufferResourceLog()
namespace mozilla {
namespace dom {
class SourceBuffer;
} // namespace dom
nsresult
SourceBufferResource::Close()
{

Просмотреть файл

@ -13,7 +13,6 @@
#include "SourceBufferResource.h"
#include "VideoUtils.h"
#include "mozilla/FloatingPoint.h"
#include "mozilla/dom/MediaSourceBinding.h"
#include "mozilla/dom/TimeRanges.h"
#include "nsError.h"
#include "nsIRunnable.h"

Просмотреть файл

@ -99,7 +99,7 @@ function IsWindowsVistaOrLater() {
return winver && winver.length == 2 && parseFloat(winver[1]) >= 6.0;
}
function IsMacOSLionOrLater() {
function IsMacOSSnowLeopardOrLater() {
var re = /Mac OS X (\d+)\.(\d+)/;
var ver = navigator.userAgent.match(re);
if (!ver || ver.length != 3) {
@ -107,7 +107,7 @@ function IsMacOSLionOrLater() {
}
var major = ver[1] | 0;
var minor = ver[2] | 0;
return major == 10 && minor >= 7;
return major == 10 && minor >= 6;
}
function getPref(name) {
@ -127,7 +127,7 @@ function IsLinuxGStreamer() {
function IsMP4ReaderAvailable() {
var prefs = getPref("media.fragmented-mp4.enabled") &&
getPref("media.fragmented-mp4.exposed");
return prefs && (IsWindowsVistaOrLater() || IsMacOSLionOrLater());
return prefs && (IsWindowsVistaOrLater() || IsMacOSSnowLeopardOrLater());
}
var haveMp4 = (getPref("media.windows-media-foundation.enabled") && IsWindowsVistaOrLater()) ||

Просмотреть файл

@ -116,7 +116,8 @@ SVGForeignObjectElement::BindToTree(nsIDocument* aDocument,
aCompileEventHandlers);
NS_ENSURE_SUCCESS(rv, rv);
if (aDocument && aDocument->IsSVG()) {
nsIDocument* doc = GetComposedDoc();
if (doc && doc->IsSVG()) {
// We assume that we're going to have HTML content, so we ensure that the
// UA style sheets that nsDocumentViewer::CreateStyleSet skipped when
// it saw the document was an SVG document are loaded.
@ -124,7 +125,7 @@ SVGForeignObjectElement::BindToTree(nsIDocument* aDocument,
// We setup these style sheets during binding, not element construction,
// because elements can be moved from the document that creates them to
// another document.
aDocument->AsSVGDocument()->EnsureNonSVGUserAgentStyleSheetsLoaded();
doc->AsSVGDocument()->EnsureNonSVGUserAgentStyleSheetsLoaded();
}
return rv;

Просмотреть файл

@ -756,12 +756,12 @@ SVGSVGElement::BindToTree(nsIDocument* aDocument,
aCompileEventHandlers);
NS_ENSURE_SUCCESS(rv,rv);
if (aDocument) {
nsIDocument* doc = GetComposedDoc();
if (doc) {
// Setup the style sheet during binding, not element construction,
// because we could move the root SVG element from the document
// that created it to another document.
aDocument->
EnsureOnDemandBuiltInUASheet(nsLayoutStylesheetCache::SVGSheet());
doc->EnsureOnDemandBuiltInUASheet(nsLayoutStylesheetCache::SVGSheet());
}
if (mTimedDocumentRoot && smilController) {

Просмотреть файл

@ -839,9 +839,10 @@ nsXULElement::BindToTree(nsIDocument* aDocument,
aCompileEventHandlers);
NS_ENSURE_SUCCESS(rv, rv);
if (aDocument &&
!aDocument->LoadsFullXULStyleSheetUpFront() &&
!aDocument->IsUnstyledDocument()) {
nsIDocument* doc = GetComposedDoc();
if (doc &&
!doc->LoadsFullXULStyleSheetUpFront() &&
!doc->IsUnstyledDocument()) {
// To save CPU cycles and memory, non-XUL documents only load the user
// agent style sheet rules for a minimal set of XUL elements such as
@ -854,7 +855,7 @@ nsXULElement::BindToTree(nsIDocument* aDocument,
// can be moved from the document that creates them to another document.
if (!XULElementsRulesInMinimalXULSheet(Tag())) {
aDocument->EnsureOnDemandBuiltInUASheet(nsLayoutStylesheetCache::XULSheet());
doc->EnsureOnDemandBuiltInUASheet(nsLayoutStylesheetCache::XULSheet());
// To keep memory usage down it is important that we try and avoid
// pulling xul.css into non-XUL documents. That should be very rare, and
// for HTML we currently should only pull it in if the document contains

Просмотреть файл

@ -1355,11 +1355,16 @@ DOMInterfaces = {
},
'WebGL2RenderingContext': {
'nativeType': 'mozilla::WebGLContext',
'headerFile': 'WebGLContext.h',
'nativeType': 'mozilla::WebGL2Context',
'headerFile': 'WebGL2Context.h',
'implicitJSContext': [ 'getSupportedExtensions' ],
},
'WebGLSampler': {
'nativeType': 'mozilla::WebGLSampler',
'headerFile': 'WebGLSampler.h'
},
'WebGLShader': {
'nativeType': 'mozilla::WebGLShader',
'headerFile': 'WebGLShader.h'
@ -1371,11 +1376,21 @@ DOMInterfaces = {
'wrapperCache': False
},
'WebGLSync': {
'nativeType': 'mozilla::WebGLSync',
'headerFile': 'WebGLSync.h'
},
'WebGLTexture': {
'nativeType': 'mozilla::WebGLTexture',
'headerFile': 'WebGLTexture.h'
},
'WebGLTransformFeedback': {
'nativeType': 'mozilla::WebGLTransformFeedback',
'headerFile': 'WebGLTransformFeedback.h'
},
'WebGLUniformLocation': {
'nativeType': 'mozilla::WebGLUniformLocation',
'headerFile': 'WebGLUniformLocation.h',

Просмотреть файл

@ -10,52 +10,233 @@
namespace mozilla {
class WebGLSampler;
class WebGLSync;
class WebGLTransformFeedback;
class WebGLVertexArrayObject;
class WebGL2Context
: public WebGLContext
{
// -----------------------------------------------------------------------------
// PUBLIC
public:
// -------------------------------------------------------------------------
// DESTRUCTOR
virtual ~WebGL2Context();
// -------------------------------------------------------------------------
// STATIC FUNCTIONS
static bool IsSupported();
static WebGL2Context* Create();
// -------------------------------------------------------------------------
// IMPLEMENT WebGLContext
virtual bool IsWebGL2() const MOZ_OVERRIDE
{
return true;
}
// -------------------------------------------------------------------------
// IMPLEMENT nsWrapperCache
virtual JSObject* WrapObject(JSContext *cx) MOZ_OVERRIDE;
// -----------------------------------------------------------------------------
// PRIVATE
private:
// -------------------------------------------------------------------------
// Buffer objects - WebGL2ContextBuffers.cpp
void CopyBufferSubData(GLenum readTarget, GLenum writeTarget,
GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
void GetBufferSubData(GLenum target, GLintptr offset, const dom::ArrayBuffer& returnedData);
void GetBufferSubData(GLenum target, GLintptr offset, const dom::ArrayBufferView& returnedData);
// -------------------------------------------------------------------------
// CONSTRUCTOR
// Framebuffer objects - WebGL2ContextFramebuffers.cpp
void BlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
GLbitfield mask, GLenum filter);
void FramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
void GetInternalformatParameter(JSContext*, GLenum target, GLenum internalformat, GLenum pname, JS::MutableHandleValue retval);
void InvalidateFramebuffer(GLenum target, const dom::Sequence<GLenum>& attachments);
void InvalidateSubFramebuffer (GLenum target, const dom::Sequence<GLenum>& attachments, GLint x, GLint y,
GLsizei width, GLsizei height);
void ReadBuffer(GLenum mode);
void RenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat,
GLsizei width, GLsizei height);
// -------------------------------------------------------------------------
// Texture objects - WebGL2ContextTextures.cpp
void TexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
void TexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height,
GLsizei depth);
void TexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth,
GLenum format, GLenum type, const Nullable<dom::ArrayBufferView>& pixels,
ErrorResult& rv);
void TexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, dom::ImageData* data,
ErrorResult& rv);
template<class ElementType>
void TexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, ElementType& elt, ErrorResult& rv)
{}
void CopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLint x, GLint y, GLsizei width, GLsizei height);
void CompressedTexImage3D(GLenum target, GLint level, GLenum internalformat,
GLsizei width, GLsizei height, GLsizei depth,
GLint border, GLsizei imageSize, const dom::ArrayBufferView& data);
void CompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth,
GLenum format, GLsizei imageSize, const dom::ArrayBufferView& data);
// -------------------------------------------------------------------------
// Programs and shaders - WebGL2ContextPrograms.cpp
GLint GetFragDataLocation(WebGLProgram* program, const nsAString& name);
// -------------------------------------------------------------------------
// Uniforms and attributes - WebGL2ContextUniforms.cpp
void VertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset);
void Uniform1ui(WebGLUniformLocation* location, GLuint v0);
void Uniform2ui(WebGLUniformLocation* location, GLuint v0, GLuint v1);
void Uniform3ui(WebGLUniformLocation* location, GLuint v0, GLuint v1, GLuint v2);
void Uniform4ui(WebGLUniformLocation* location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
void Uniform1uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value);
void Uniform2uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value);
void Uniform3uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value);
void Uniform4uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value);
void UniformMatrix2x3fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix2x3fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void UniformMatrix3x2fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix3x2fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void UniformMatrix2x4fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix2x4fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void UniformMatrix4x2fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix4x2fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void UniformMatrix3x4fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix3x4fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void UniformMatrix4x3fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value);
void UniformMatrix4x3fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value);
void VertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
void VertexAttribI4iv(GLuint index, const dom::Sequence<GLint>& v);
void VertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
void VertexAttribI4uiv(GLuint index, const dom::Sequence<GLuint>& v);
// -------------------------------------------------------------------------
// Writing to the drawing buffer
// TODO(djg): Implemented in WebGLContext
/*
void VertexAttribDivisor(GLuint index, GLuint divisor);
void DrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instanceCount);
void DrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, GLintptr offset, GLsizei instanceCount);
*/
void DrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, GLintptr offset);
// ------------------------------------------------------------------------
// Multiple Render Targets - WebGL2ContextMRTs.cpp
// TODO(djg): Implemented in WebGLContext
/*
void DrawBuffers(const dom::Sequence<GLenum>& buffers);
*/
void ClearBufferiv(GLenum buffer, GLint drawbuffer, const dom::Int32Array& value);
void ClearBufferiv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLint>& value);
void ClearBufferuiv(GLenum buffer, GLint drawbuffer, const dom::Uint32Array& value);
void ClearBufferuiv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLuint>& value);
void ClearBufferfv(GLenum buffer, GLint drawbuffer, const dom::Float32Array& value);
void ClearBufferfv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLfloat>& value);
void ClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
// -------------------------------------------------------------------------
// Query Objects - WebGL2ContextQueries.cpp
// TODO(djg): Implemented in WebGLContext
/* already_AddRefed<WebGLQuery> CreateQuery();
void DeleteQuery(WebGLQuery* query);
bool IsQuery(WebGLQuery* query);
void BeginQuery(GLenum target, WebGLQuery* query);
void EndQuery(GLenum target);
JS::Value GetQuery(JSContext*, GLenum target, GLenum pname); */
void GetQueryParameter(JSContext*, WebGLQuery* query, GLenum pname, JS::MutableHandleValue retval);
// -------------------------------------------------------------------------
// Sampler Objects - WebGL2ContextSamplers.cpp
already_AddRefed<WebGLSampler> CreateSampler();
void DeleteSampler(WebGLSampler* sampler);
bool IsSampler(WebGLSampler* sampler);
void BindSampler(GLuint unit, WebGLSampler* sampler);
void SamplerParameteri(WebGLSampler* sampler, GLenum pname, GLint param);
void SamplerParameteriv(WebGLSampler* sampler, GLenum pname, const dom::Int32Array& param);
void SamplerParameteriv(WebGLSampler* sampler, GLenum pname, const dom::Sequence<GLint>& param);
void SamplerParameterf(WebGLSampler* sampler, GLenum pname, GLfloat param);
void SamplerParameterfv(WebGLSampler* sampler, GLenum pname, const dom::Float32Array& param);
void SamplerParameterfv(WebGLSampler* sampler, GLenum pname, const dom::Sequence<GLfloat>& param);
void GetSamplerParameter(JSContext*, WebGLSampler* sampler, GLenum pname, JS::MutableHandleValue retval);
// -------------------------------------------------------------------------
// Sync objects - WebGL2ContextSync.cpp
already_AddRefed<WebGLSync> FenceSync(GLenum condition, GLbitfield flags);
bool IsSync(WebGLSync* sync);
void DeleteSync(WebGLSync* sync);
GLenum ClientWaitSync(WebGLSync* sync, GLbitfield flags, GLuint64 timeout);
void WaitSync(WebGLSync* sync, GLbitfield flags, GLuint64 timeout);
void GetSyncParameter(JSContext*, WebGLSync* sync, GLenum pname, JS::MutableHandleValue retval);
// -------------------------------------------------------------------------
// Transform Feedback - WebGL2ContextTransformFeedback.cpp
already_AddRefed<WebGLTransformFeedback> CreateTransformFeedback();
void DeleteTransformFeedback(WebGLTransformFeedback* tf);
bool IsTransformFeedback(WebGLTransformFeedback* tf);
void BindTransformFeedback(GLenum target, GLuint id);
void BeginTransformFeedback(GLenum primitiveMode);
void EndTransformFeedback();
void TransformFeedbackVaryings(WebGLProgram* program, GLsizei count,
const dom::Sequence<nsString>& varyings, GLenum bufferMode);
already_AddRefed<WebGLActiveInfo> GetTransformFeedbackVarying(WebGLProgram* program, GLuint index);
void PauseTransformFeedback();
void ResumeTransformFeedback();
// -------------------------------------------------------------------------
// Uniform Buffer Objects and Transform Feedback Buffers - WebGL2ContextUniforms.cpp
// TODO(djg): Implemented in WebGLContext
/*
void BindBufferBase(GLenum target, GLuint index, WebGLBuffer* buffer);
void BindBufferRange(GLenum target, GLuint index, WebGLBuffer* buffer, GLintptr offset, GLsizeiptr size);
*/
void GetIndexedParameter(JSContext*, GLenum target, GLuint index, JS::MutableHandleValue retval);
void GetUniformIndices(WebGLProgram* program, const dom::Sequence<nsString>& uniformNames, dom::Nullable< nsTArray<GLuint> >& retval);
void GetActiveUniforms(WebGLProgram* program, const dom::Sequence<GLuint>& uniformIndices, GLenum pname,
dom::Nullable< nsTArray<GLint> >& retval);
GLuint GetUniformBlockIndex(WebGLProgram* program, const nsAString& uniformBlockName);
void GetActiveUniformBlockParameter(JSContext*, WebGLProgram* program, GLuint uniformBlockIndex, GLenum pname, JS::MutableHandleValue retval);
void GetActiveUniformBlockName(WebGLProgram* program, GLuint uniformBlockIndex, dom::DOMString& retval);
void UniformBlockBinding(WebGLProgram* program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
// -------------------------------------------------------------------------
// Vertex Array Object - WebGL2ContextVAOs.cpp
// TODO(djg): Implemented in WebGLContext
/*
already_AddRefed<WebGLVertexArrayObject> CreateVertexArray();
void DeleteVertexArray(WebGLVertexArrayObject* vertexArray);
bool IsVertexArray(WebGLVertexArrayObject* vertexArray);
void BindVertexArray(WebGLVertexArrayObject* vertexArray);
*/
private:
WebGL2Context();
};
} // namespace mozilla

Просмотреть файл

@ -0,0 +1,32 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Buffer objects
void
WebGL2Context::CopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset,
GLintptr writeOffset, GLsizeiptr size)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetBufferSubData(GLenum target, GLintptr offset, const dom::ArrayBuffer& returnedData)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetBufferSubData(GLenum target, GLintptr offset, const dom::ArrayBufferView& returnedData)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,19 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Writing to the drawing buffer
void
WebGL2Context::DrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, GLintptr offset)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,59 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Framebuffer objects
void
WebGL2Context::BlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
GLbitfield mask, GLenum filter)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::FramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetInternalformatParameter(JSContext*, GLenum target, GLenum internalformat, GLenum pname, JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::InvalidateFramebuffer(GLenum target, const dom::Sequence<GLenum>& attachments)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::InvalidateSubFramebuffer (GLenum target, const dom::Sequence<GLenum>& attachments,
GLint x, GLint y, GLsizei width, GLsizei height)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ReadBuffer(GLenum mode)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::RenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat,
GLsizei width, GLsizei height)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,52 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
void
WebGL2Context::ClearBufferiv(GLenum buffer, GLint drawbuffer, const dom::Int32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferiv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferuiv(GLenum buffer, GLint drawbuffer, const dom::Uint32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferuiv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLuint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferfv(GLenum buffer, GLint drawbuffer, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferfv(GLenum buffer, GLint drawbuffer, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,19 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Programs and shaders
GLint
WebGL2Context::GetFragDataLocation(WebGLProgram* program, const nsAString& name)
{
MOZ_CRASH("Not Implemented.");
return 0;
}

Просмотреть файл

@ -0,0 +1,28 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Query Objects
// TODO(djg): Implemented in WebGLContext
/*
already_AddRefed<WebGLQuery> CreateQuery();
void DeleteQuery(WebGLQuery* query);
bool IsQuery(WebGLQuery* query);
void BeginQuery(GLenum target, WebGLQuery* query);
void EndQuery(GLenum target);
JS::Value GetQuery(JSContext*, GLenum target, GLenum pname);
*/
void
WebGL2Context::GetQueryParameter(JSContext*, WebGLQuery* query, GLenum pname, JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented");
}

Просмотреть файл

@ -0,0 +1,78 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
already_AddRefed<WebGLSampler>
WebGL2Context::CreateSampler()
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
void
WebGL2Context::DeleteSampler(WebGLSampler* sampler)
{
MOZ_CRASH("Not Implemented.");
}
bool
WebGL2Context::IsSampler(WebGLSampler* sampler)
{
MOZ_CRASH("Not Implemented.");
return false;
}
void
WebGL2Context::BindSampler(GLuint unit, WebGLSampler* sampler)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameteri(WebGLSampler* sampler, GLenum pname, GLint param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameteriv(WebGLSampler* sampler, GLenum pname, const dom::Int32Array& param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameteriv(WebGLSampler* sampler, GLenum pname, const dom::Sequence<GLint>& param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameterf(WebGLSampler* sampler, GLenum pname, GLfloat param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameterfv(WebGLSampler* sampler, GLenum pname, const dom::Float32Array& param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::SamplerParameterfv(WebGLSampler* sampler, GLenum pname, const dom::Sequence<GLfloat>& param)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetSamplerParameter(JSContext*, WebGLSampler* sampler, GLenum pname, JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,52 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Sync objects
already_AddRefed<WebGLSync>
WebGL2Context::FenceSync(GLenum condition, GLbitfield flags)
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
bool
WebGL2Context::IsSync(WebGLSync* sync)
{
MOZ_CRASH("Not Implemented.");
return false;
}
void
WebGL2Context::DeleteSync(WebGLSync* sync)
{
MOZ_CRASH("Not Implemented.");
}
GLenum
WebGL2Context::ClientWaitSync(WebGLSync* sync, GLbitfield flags, GLuint64 timeout)
{
MOZ_CRASH("Not Implemented.");
return LOCAL_GL_FALSE;
}
void
WebGL2Context::WaitSync(WebGLSync* sync, GLbitfield flags, GLuint64 timeout)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetSyncParameter(JSContext*, WebGLSync* sync, GLenum pname, JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,69 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Texture objects
void
WebGL2Context::TexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::TexStorage3D(GLenum target, GLsizei levels, GLenum internalformat,
GLsizei width, GLsizei height, GLsizei depth)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::TexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth,
GLenum format, GLenum type, const Nullable<dom::ArrayBufferView>& pixels,
ErrorResult& rv)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::TexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, dom::ImageData* data,
ErrorResult& rv)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::CopyTexSubImage3D(GLenum target, GLint level,
GLint xoffset, GLint yoffset, GLint zoffset,
GLint x, GLint y, GLsizei width, GLsizei height)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::CompressedTexImage3D(GLenum target, GLint level, GLenum internalformat,
GLsizei width, GLsizei height, GLsizei depth,
GLint border, GLsizei imageSize, const dom::ArrayBufferView& data)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::CompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth,
GLenum format, GLsizei imageSize, const dom::ArrayBufferView& data)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,78 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Transform Feedback
already_AddRefed<WebGLTransformFeedback>
WebGL2Context::CreateTransformFeedback()
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
void
WebGL2Context::DeleteTransformFeedback(WebGLTransformFeedback* tf)
{
MOZ_CRASH("Not Implemented.");
}
bool
WebGL2Context::IsTransformFeedback(WebGLTransformFeedback* tf)
{
MOZ_CRASH("Not Implemented.");
return false;
}
void
WebGL2Context::BindTransformFeedback(GLenum target, GLuint id)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::BeginTransformFeedback(GLenum primitiveMode)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::EndTransformFeedback()
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::TransformFeedbackVaryings(WebGLProgram* program, GLsizei count,
const dom::Sequence<nsString>& varyings, GLenum bufferMode)
{
MOZ_CRASH("Not Implemented.");
}
already_AddRefed<WebGLActiveInfo>
WebGL2Context::GetTransformFeedbackVarying(WebGLProgram* program, GLuint index)
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
void
WebGL2Context::PauseTransformFeedback()
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::ResumeTransformFeedback()
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,221 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Uniforms and attributes
void
WebGL2Context::VertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform1ui(WebGLUniformLocation* location, GLuint v0)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform2ui(WebGLUniformLocation* location, GLuint v0, GLuint v1)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform3ui(WebGLUniformLocation* location, GLuint v0, GLuint v1, GLuint v2)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform4ui(WebGLUniformLocation* location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform1uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform2uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform3uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::Uniform4uiv(WebGLUniformLocation* location, const dom::Sequence<GLuint>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix2x3fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix2x3fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix3x2fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix3x2fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix2x4fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix2x4fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix4x2fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix4x2fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix3x4fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix3x4fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix4x3fv(WebGLUniformLocation* location, bool transpose, const dom::Float32Array& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformMatrix4x3fv(WebGLUniformLocation* location, bool transpose, const dom::Sequence<GLfloat>& value)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::VertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::VertexAttribI4iv(GLuint index, const dom::Sequence<GLint>& v)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::VertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::VertexAttribI4uiv(GLuint index, const dom::Sequence<GLuint>& v)
{
MOZ_CRASH("Not Implemented.");
}
// -------------------------------------------------------------------------
// Uniform Buffer Objects and Transform Feedback Buffers
// TODO(djg): Implemented in WebGLContext
/*
void BindBufferBase(GLenum target, GLuint index, WebGLBuffer* buffer);
void BindBufferRange(GLenum target, GLuint index, WebGLBuffer* buffer, GLintptr offset, GLsizeiptr size);
*/
void
WebGL2Context::GetIndexedParameter(JSContext*, GLenum target, GLuint index, JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetUniformIndices(WebGLProgram* program,
const dom::Sequence<nsString>& uniformNames,
dom::Nullable< nsTArray<GLuint> >& retval)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetActiveUniforms(WebGLProgram* program,
const dom::Sequence<GLuint>& uniformIndices,
GLenum pname,
dom::Nullable< nsTArray<GLint> >& retval)
{
MOZ_CRASH("Not Implemented.");
}
GLuint
WebGL2Context::GetUniformBlockIndex(WebGLProgram* program, const nsAString& uniformBlockName)
{
MOZ_CRASH("Not Implemented.");
return 0;
}
void
WebGL2Context::GetActiveUniformBlockParameter(JSContext*, WebGLProgram* program,
GLuint uniformBlockIndex, GLenum pname,
JS::MutableHandleValue retval)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::GetActiveUniformBlockName(WebGLProgram* program, GLuint uniformBlockIndex, dom::DOMString& retval)
{
MOZ_CRASH("Not Implemented.");
}
void
WebGL2Context::UniformBlockBinding(WebGLProgram* program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
{
MOZ_CRASH("Not Implemented.");
}

Просмотреть файл

@ -0,0 +1,20 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "GLContext.h"
using namespace mozilla;
using namespace mozilla::dom;
// -------------------------------------------------------------------------
// Vertex Array Object
// TODO(djg): Implemented in WebGLContext
/*
already_AddRefed<WebGLVertexArrayObject> CreateVertexArray();
void DeleteVertexArray(WebGLVertexArrayObject* vertexArray);
bool IsVertexArray(WebGLVertexArrayObject* vertexArray);
void BindVertexArray(WebGLVertexArrayObject* vertexArray);
*/

Просмотреть файл

@ -0,0 +1,49 @@
/* -*- Mode: C++; tab-width: 20; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGLContext.h"
#include "WebGLSampler.h"
#include "GLContext.h"
#include "mozilla/dom/WebGL2RenderingContextBinding.h"
using namespace mozilla;
WebGLSampler::WebGLSampler(WebGLContext* context)
: WebGLBindableName()
, WebGLContextBoundObject(context)
{
SetIsDOMBinding();
MOZ_CRASH("Not Implemented.");
}
WebGLSampler::~WebGLSampler()
{}
void
WebGLSampler::Delete()
{
MOZ_CRASH("Not Implemented.");
}
WebGLContext*
WebGLSampler::GetParentObject() const
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
JSObject*
WebGLSampler::WrapObject(JSContext* cx)
{
MOZ_CRASH("Not Implemented.");
return dom::WebGLSamplerBinding::Wrap(cx, this);
}
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_0(WebGLSampler)
NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(WebGLSampler, AddRef)
NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(WebGLSampler, Release)

46
dom/canvas/WebGLSampler.h Normal file
Просмотреть файл

@ -0,0 +1,46 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef WEBGL2SAMPLER_H_
#define WEBGL2SAMPLER_H_
#include "WebGLBindableName.h"
#include "WebGLObjectModel.h"
#include "nsWrapperCache.h"
#include "mozilla/LinkedList.h"
namespace mozilla {
class WebGLSampler MOZ_FINAL
: public WebGLBindableName
, public nsWrapperCache
, public WebGLRefCountedObject<WebGLSampler>
, public LinkedListElement<WebGLSampler>
, public WebGLContextBoundObject
{
friend class WebGLContext2;
public:
WebGLSampler(WebGLContext* context);
void Delete();
WebGLContext* GetParentObject() const;
virtual JSObject* WrapObject(JSContext* cx) MOZ_OVERRIDE;
NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(WebGLSampler)
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(WebGLSampler)
private:
~WebGLSampler();
};
} // namespace mozilla
#endif // !WEBGL2SAMPLER_H_

44
dom/canvas/WebGLSync.cpp Normal file
Просмотреть файл

@ -0,0 +1,44 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGLSync.h"
#include "mozilla/dom/WebGL2RenderingContextBinding.h"
using namespace mozilla;
WebGLSync::WebGLSync(WebGLContext* context) :
WebGLContextBoundObject(context)
{
MOZ_CRASH("Not Implemented.");
}
WebGLSync::~WebGLSync()
{}
void
WebGLSync::Delete()
{
MOZ_CRASH("Not Implemented.");
}
WebGLContext*
WebGLSync::GetParentObject() const
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
// -------------------------------------------------------------------------
// IMPLEMENT NS
JSObject*
WebGLSync::WrapObject(JSContext *cx)
{
return dom::WebGLSyncBinding::Wrap(cx, this);
}
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_0(WebGLSync)
NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(WebGLSync, AddRef)
NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(WebGLSync, Release);

46
dom/canvas/WebGLSync.h Normal file
Просмотреть файл

@ -0,0 +1,46 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef WEBGLSYNC_H_
#define WEBGLSYNC_H_
#include "WebGLObjectModel.h"
#include "nsWrapperCache.h"
#include "mozilla/LinkedList.h"
namespace mozilla {
class WebGLSync MOZ_FINAL
: public nsWrapperCache
, public WebGLRefCountedObject<WebGLSync>
, public LinkedListElement<WebGLSync>
, public WebGLContextBoundObject
{
friend class WebGL2Context;
public:
WebGLSync(WebGLContext* context);
void Delete();
WebGLContext* GetParentObject() const;
// -------------------------------------------------------------------------
// IMPLEMENT NS
virtual JSObject* WrapObject(JSContext* cx) MOZ_OVERRIDE;
NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(WebGLSync)
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(WebGLSync)
private:
~WebGLSync();
};
} // namespace mozilla
#endif // !WEBGLSYNC_H_

Просмотреть файл

@ -0,0 +1,48 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "WebGL2Context.h"
#include "WebGLTransformFeedback.h"
#include "GLContext.h"
#include "mozilla/dom/WebGL2RenderingContextBinding.h"
using namespace mozilla;
WebGLTransformFeedback::WebGLTransformFeedback(WebGLContext* context)
: WebGLBindableName()
, WebGLContextBoundObject(context)
{
SetIsDOMBinding();
MOZ_CRASH("Not Implemented.");
}
WebGLTransformFeedback::~WebGLTransformFeedback()
{}
void
WebGLTransformFeedback::Delete()
{
MOZ_CRASH("Not Implemented.");
}
WebGLContext*
WebGLTransformFeedback::GetParentObject() const
{
MOZ_CRASH("Not Implemented.");
return nullptr;
}
JSObject*
WebGLTransformFeedback::WrapObject(JSContext* cx)
{
return dom::WebGLTransformFeedbackBinding::Wrap(cx, this);
}
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_0(WebGLTransformFeedback)
NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(WebGLTransformFeedback, AddRef)
NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(WebGLTransformFeedback, Release)

Просмотреть файл

@ -0,0 +1,48 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef WEBGLTRANSFORMFEEDBACK_H_
#define WEBGLTRANSFORMFEEDBACK_H_
#include "WebGLBindableName.h"
#include "WebGLObjectModel.h"
#include "nsWrapperCache.h"
#include "mozilla/LinkedList.h"
namespace mozilla {
class WebGLTransformFeedback MOZ_FINAL
: public WebGLBindableName
, public nsWrapperCache
, public WebGLRefCountedObject<WebGLTransformFeedback>
, public LinkedListElement<WebGLTransformFeedback>
, public WebGLContextBoundObject
{
friend class WebGLContext;
public:
WebGLTransformFeedback(WebGLContext* context);
void Delete();
WebGLContext* GetParentObject() const;
// -------------------------------------------------------------------------
// IMPLEMENT NS
virtual JSObject* WrapObject(JSContext* cx) MOZ_OVERRIDE;
NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(WebGLTransformFeedback)
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(WebGLTransformFeedback)
private:
~WebGLTransformFeedback();
};
}
#endif // !WEBGLTRANSFORMFEEDBACK_H_

Просмотреть файл

@ -40,6 +40,18 @@ UNIFIED_SOURCES += [
'MurmurHash3.cpp',
'WebGL1Context.cpp',
'WebGL2Context.cpp',
'WebGL2ContextBuffers.cpp',
'WebGL2ContextDraw.cpp',
'WebGL2ContextFramebuffers.cpp',
'WebGL2ContextMRTs.cpp',
'WebGL2ContextPrograms.cpp',
'WebGL2ContextQueries.cpp',
'WebGL2ContextSamplers.cpp',
'WebGL2ContextSync.cpp',
'WebGL2ContextTextures.cpp',
'WebGL2ContextTransformFeedback.cpp',
'WebGL2ContextUniforms.cpp',
'WebGL2ContextVAOs.cpp',
'WebGLActiveInfo.cpp',
'WebGLBindableName.cpp',
'WebGLBuffer.cpp',
@ -89,10 +101,13 @@ UNIFIED_SOURCES += [
'WebGLProgram.cpp',
'WebGLQuery.cpp',
'WebGLRenderbuffer.cpp',
'WebGLSampler.cpp',
'WebGLShader.cpp',
'WebGLShaderPrecisionFormat.cpp',
'WebGLSync.cpp',
'WebGLTexelConversions.cpp',
'WebGLTexture.cpp',
'WebGLTransformFeedback.cpp',
'WebGLUniformLocation.cpp',
'WebGLVertexArray.cpp',
'WebGLVertexArrayFake.cpp',

Просмотреть файл

@ -498,17 +498,15 @@ ContentChild* ContentChild::sSingleton;
// Performs initialization that is not fork-safe, i.e. that must be done after
// forking from the Nuwa process.
static void
InitOnContentProcessCreated(bool aAfterNuwaFork)
InitOnContentProcessCreated()
{
#ifdef MOZ_NUWA_PROCESS
// Wait until we are forked from Nuwa
if (!aAfterNuwaFork &&
Preferences::GetBool("dom.ipc.processPrelaunch.enabled", false)) {
if (IsNuwaProcess()) {
return;
}
#else
unused << aAfterNuwaFork;
#endif
// This will register cross-process observer.
mozilla::dom::time::InitializeDateCacheCleaner();
}
@ -702,7 +700,7 @@ ContentChild::InitXPCOM()
new SystemMessageHandledObserver();
sysMsgObserver->Init();
InitOnContentProcessCreated(/* aAfterNuwaFork = */false);
InitOnContentProcessCreated();
}
PMemoryReportRequestChild*
@ -2058,7 +2056,7 @@ public:
}
// Perform other after-fork initializations.
InitOnContentProcessCreated(/* aAfterNuwaFork = */true);
InitOnContentProcessCreated();
return NS_OK;
}

Просмотреть файл

@ -102,19 +102,22 @@ nsMathMLElement::BindToTree(nsIDocument* aDocument, nsIContent* aParent,
if (aDocument) {
aDocument->RegisterPendingLinkUpdate(this);
}
if (!aDocument->GetMathMLEnabled()) {
nsIDocument* doc = GetComposedDoc();
if (doc) {
if (!doc->GetMathMLEnabled()) {
// Enable MathML and setup the style sheet during binding, not element
// construction, because we could move a MathML element from the document
// that created it to another document.
aDocument->SetMathMLEnabled();
aDocument->
doc->SetMathMLEnabled();
doc->
EnsureOnDemandBuiltInUASheet(nsLayoutStylesheetCache::MathMLSheet());
// Rebuild style data for the presshell, because style system
// optimizations may have taken place assuming MathML was disabled.
// (See nsRuleNode::CheckSpecifiedProperties.)
nsCOMPtr<nsIPresShell> shell = aDocument->GetShell();
nsCOMPtr<nsIPresShell> shell = doc->GetShell();
if (shell) {
shell->GetPresContext()->PostRebuildAllStyleDataEvent(nsChangeHint(0));
}

Просмотреть файл

@ -3,37 +3,81 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/.
*
* The source for this IDL is found at https://www.khronos.org/registry/webgl/specs/latest/2.0
* This IDL depends on WebGLRenderingContext.webidl
*/
typedef long long GLint64; // Should this be int64?
typedef unsigned long long GLuint64; // Should this be uint64?
[Pref="webgl.enable-prototype-webgl2"]
interface WebGLQuery {
};
[Pref="webgl.enable-prototype-webgl2"]
interface WebGL2RenderingContext : WebGLRenderingContext {
interface WebGLSampler {
};
/* depth textures */
const GLenum UNSIGNED_INT_24_8 = 0x84FA;
[Pref="webgl.enable-prototype-webgl2"]
interface WebGLSync {
};
[Pref="webgl.enable-prototype-webgl2"]
interface WebGLTransformFeedback {
};
/* draw buffers */
const GLenum COLOR_ATTACHMENT1 = 0x8CE1;
const GLenum COLOR_ATTACHMENT2 = 0x8CE2;
const GLenum COLOR_ATTACHMENT3 = 0x8CE3;
const GLenum COLOR_ATTACHMENT4 = 0x8CE4;
const GLenum COLOR_ATTACHMENT5 = 0x8CE5;
const GLenum COLOR_ATTACHMENT6 = 0x8CE6;
const GLenum COLOR_ATTACHMENT7 = 0x8CE7;
const GLenum COLOR_ATTACHMENT8 = 0x8CE8;
const GLenum COLOR_ATTACHMENT9 = 0x8CE9;
const GLenum COLOR_ATTACHMENT10 = 0x8CEA;
const GLenum COLOR_ATTACHMENT11 = 0x8CEB;
const GLenum COLOR_ATTACHMENT12 = 0x8CEC;
const GLenum COLOR_ATTACHMENT13 = 0x8CED;
const GLenum COLOR_ATTACHMENT14 = 0x8CEE;
const GLenum COLOR_ATTACHMENT15 = 0x8CEF;
/*
[Pref="webgl.enable-prototype-webgl2"]
interface WebGLVertexArrayObject {
};
*/
[Pref="webgl.enable-prototype-webgl2"]
interface WebGL2RenderingContext : WebGLRenderingContext
{
const GLenum READ_BUFFER = 0x0C02;
const GLenum UNPACK_ROW_LENGTH = 0x0CF2;
const GLenum UNPACK_SKIP_ROWS = 0x0CF3;
const GLenum UNPACK_SKIP_PIXELS = 0x0CF4;
const GLenum PACK_ROW_LENGTH = 0x0D02;
const GLenum PACK_SKIP_ROWS = 0x0D03;
const GLenum PACK_SKIP_PIXELS = 0x0D04;
const GLenum COLOR = 0x1800;
const GLenum DEPTH = 0x1801;
const GLenum STENCIL = 0x1802;
const GLenum RED = 0x1903;
const GLenum RGB8 = 0x8051;
const GLenum RGBA8 = 0x8058;
const GLenum RGB10_A2 = 0x8059;
const GLenum TEXTURE_BINDING_3D = 0x806A;
const GLenum UNPACK_SKIP_IMAGES = 0x806D;
const GLenum UNPACK_IMAGE_HEIGHT = 0x806E;
const GLenum TEXTURE_3D = 0x806F;
const GLenum TEXTURE_WRAP_R = 0x8072;
const GLenum MAX_3D_TEXTURE_SIZE = 0x8073;
const GLenum UNSIGNED_INT_2_10_10_10_REV = 0x8368;
const GLenum MAX_ELEMENTS_VERTICES = 0x80E8;
const GLenum MAX_ELEMENTS_INDICES = 0x80E9;
const GLenum TEXTURE_MIN_LOD = 0x813A;
const GLenum TEXTURE_MAX_LOD = 0x813B;
const GLenum TEXTURE_BASE_LEVEL = 0x813C;
const GLenum TEXTURE_MAX_LEVEL = 0x813D;
const GLenum MIN = 0x8007;
const GLenum MAX = 0x8008;
const GLenum DEPTH_COMPONENT24 = 0x81A6;
const GLenum MAX_TEXTURE_LOD_BIAS = 0x84FD;
const GLenum TEXTURE_COMPARE_MODE = 0x884C;
const GLenum TEXTURE_COMPARE_FUNC = 0x884D;
const GLenum CURRENT_QUERY = 0x8865;
const GLenum QUERY_RESULT = 0x8866;
const GLenum QUERY_RESULT_AVAILABLE = 0x8867;
const GLenum STREAM_READ = 0x88E1;
const GLenum STREAM_COPY = 0x88E2;
const GLenum STATIC_READ = 0x88E5;
const GLenum STATIC_COPY = 0x88E6;
const GLenum DYNAMIC_READ = 0x88E9;
const GLenum DYNAMIC_COPY = 0x88EA;
const GLenum MAX_DRAW_BUFFERS = 0x8824;
const GLenum DRAW_BUFFER0 = 0x8825;
const GLenum DRAW_BUFFER1 = 0x8826;
const GLenum DRAW_BUFFER2 = 0x8827;
@ -50,82 +94,374 @@ interface WebGL2RenderingContext : WebGLRenderingContext {
const GLenum DRAW_BUFFER13 = 0x8832;
const GLenum DRAW_BUFFER14 = 0x8833;
const GLenum DRAW_BUFFER15 = 0x8834;
const GLenum MAX_COLOR_ATTACHMENTS = 0x8CDF;
const GLenum MAX_DRAW_BUFFERS = 0x8824;
void drawBuffers(sequence<GLenum> buffers);
/* draw instanced */
void drawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
void drawElementsInstanced(GLenum mode, GLsizei count, GLenum type, GLintptr offset, GLsizei primcount);
/* instanced array */
const GLenum VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE;
void vertexAttribDivisor(GLuint index, GLuint divisor);
/* blend equations */
const GLenum MIN = 0x8007;
const GLenum MAX = 0x8008;
/* transform feedback */
const GLenum RASTERIZER_DISCARD = 0x8C89;
const GLenum TRANSFORM_FEEDBACK_BUFFER = 0x8C8E;
const GLenum TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F;
const GLenum MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49;
const GLenum MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A;
const GLenum SAMPLER_3D = 0x8B5F;
const GLenum SAMPLER_2D_SHADOW = 0x8B62;
const GLenum FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B;
const GLenum PIXEL_PACK_BUFFER = 0x88EB;
const GLenum PIXEL_UNPACK_BUFFER = 0x88EC;
const GLenum PIXEL_PACK_BUFFER_BINDING = 0x88ED;
const GLenum PIXEL_UNPACK_BUFFER_BINDING = 0x88EF;
const GLenum FLOAT_MAT2x3 = 0x8B65;
const GLenum FLOAT_MAT2x4 = 0x8B66;
const GLenum FLOAT_MAT3x2 = 0x8B67;
const GLenum FLOAT_MAT3x4 = 0x8B68;
const GLenum FLOAT_MAT4x2 = 0x8B69;
const GLenum FLOAT_MAT4x3 = 0x8B6A;
const GLenum SRGB = 0x8C40;
const GLenum SRGB8 = 0x8C41;
const GLenum SRGB8_ALPHA8 = 0x8C43;
const GLenum COMPARE_REF_TO_TEXTURE = 0x884E;
const GLenum RGBA32F = 0x8814;
const GLenum RGB32F = 0x8815;
const GLenum RGBA16F = 0x881A;
const GLenum RGB16F = 0x881B;
const GLenum VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD;
const GLenum MAX_ARRAY_TEXTURE_LAYERS = 0x88FF;
const GLenum MIN_PROGRAM_TEXEL_OFFSET = 0x8904;
const GLenum MAX_PROGRAM_TEXEL_OFFSET = 0x8905;
const GLenum MAX_VARYING_COMPONENTS = 0x8B4B;
const GLenum TEXTURE_2D_ARRAY = 0x8C1A;
const GLenum TEXTURE_BINDING_2D_ARRAY = 0x8C1D;
const GLenum R11F_G11F_B10F = 0x8C3A;
const GLenum UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B;
const GLenum RGB9_E5 = 0x8C3D;
const GLenum UNSIGNED_INT_5_9_9_9_REV = 0x8C3E;
const GLenum TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F;
const GLenum MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80;
const GLenum TRANSFORM_FEEDBACK_VARYINGS = 0x8C83;
const GLenum TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84;
const GLenum TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85;
const GLenum TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88;
const GLenum RASTERIZER_DISCARD = 0x8C89;
const GLenum MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A;
const GLenum MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B;
/* query objects */
const GLenum CURRENT_QUERY = 0x8865;
const GLenum QUERY_RESULT = 0x8866;
const GLenum QUERY_RESULT_AVAILABLE = 0x8867;
void beginQuery(GLenum target, WebGLQuery? queryObject);
WebGLQuery? createQuery();
void deleteQuery(WebGLQuery? queryObject);
void endQuery(GLenum target);
WebGLQuery? getQuery(GLenum target, GLenum pname);
any getQueryObject(WebGLQuery? queryObject, GLenum pname);
[WebGLHandlesContextLoss] GLboolean isQuery(WebGLQuery? queryObject);
/* occlusion queries */
const GLenum INTERLEAVED_ATTRIBS = 0x8C8C;
const GLenum SEPARATE_ATTRIBS = 0x8C8D;
const GLenum TRANSFORM_FEEDBACK_BUFFER = 0x8C8E;
const GLenum TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F;
const GLenum RGBA32UI = 0x8D70;
const GLenum RGB32UI = 0x8D71;
const GLenum RGBA16UI = 0x8D76;
const GLenum RGB16UI = 0x8D77;
const GLenum RGBA8UI = 0x8D7C;
const GLenum RGB8UI = 0x8D7D;
const GLenum RGBA32I = 0x8D82;
const GLenum RGB32I = 0x8D83;
const GLenum RGBA16I = 0x8D88;
const GLenum RGB16I = 0x8D89;
const GLenum RGBA8I = 0x8D8E;
const GLenum RGB8I = 0x8D8F;
const GLenum RED_INTEGER = 0x8D94;
const GLenum RGB_INTEGER = 0x8D98;
const GLenum RGBA_INTEGER = 0x8D99;
const GLenum SAMPLER_2D_ARRAY = 0x8DC1;
const GLenum SAMPLER_2D_ARRAY_SHADOW = 0x8DC4;
const GLenum SAMPLER_CUBE_SHADOW = 0x8DC5;
const GLenum UNSIGNED_INT_VEC2 = 0x8DC6;
const GLenum UNSIGNED_INT_VEC3 = 0x8DC7;
const GLenum UNSIGNED_INT_VEC4 = 0x8DC8;
const GLenum INT_SAMPLER_2D = 0x8DCA;
const GLenum INT_SAMPLER_3D = 0x8DCB;
const GLenum INT_SAMPLER_CUBE = 0x8DCC;
const GLenum INT_SAMPLER_2D_ARRAY = 0x8DCF;
const GLenum UNSIGNED_INT_SAMPLER_2D = 0x8DD2;
const GLenum UNSIGNED_INT_SAMPLER_3D = 0x8DD3;
const GLenum UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4;
const GLenum UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7;
const GLenum DEPTH_COMPONENT32F = 0x8CAC;
const GLenum DEPTH32F_STENCIL8 = 0x8CAD;
const GLenum FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD;
const GLenum FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210;
const GLenum FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211;
const GLenum FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212;
const GLenum FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213;
const GLenum FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214;
const GLenum FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215;
const GLenum FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216;
const GLenum FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217;
const GLenum FRAMEBUFFER_DEFAULT = 0x8218;
const GLenum DEPTH_STENCIL_ATTACHMENT = 0x821A;
const GLenum DEPTH_STENCIL = 0x84F9;
const GLenum UNSIGNED_INT_24_8 = 0x84FA;
const GLenum DEPTH24_STENCIL8 = 0x88F0;
const GLenum UNSIGNED_NORMALIZED = 0x8C17;
const GLenum DRAW_FRAMEBUFFER_BINDING = 0x8CA6; /* Same as FRAMEBUFFER_BINDING */
const GLenum READ_FRAMEBUFFER = 0x8CA8;
const GLenum DRAW_FRAMEBUFFER = 0x8CA9;
const GLenum READ_FRAMEBUFFER_BINDING = 0x8CAA;
const GLenum RENDERBUFFER_SAMPLES = 0x8CAB;
const GLenum FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4;
const GLenum MAX_COLOR_ATTACHMENTS = 0x8CDF;
const GLenum COLOR_ATTACHMENT1 = 0x8CE1;
const GLenum COLOR_ATTACHMENT2 = 0x8CE2;
const GLenum COLOR_ATTACHMENT3 = 0x8CE3;
const GLenum COLOR_ATTACHMENT4 = 0x8CE4;
const GLenum COLOR_ATTACHMENT5 = 0x8CE5;
const GLenum COLOR_ATTACHMENT6 = 0x8CE6;
const GLenum COLOR_ATTACHMENT7 = 0x8CE7;
const GLenum COLOR_ATTACHMENT8 = 0x8CE8;
const GLenum COLOR_ATTACHMENT9 = 0x8CE9;
const GLenum COLOR_ATTACHMENT10 = 0x8CEA;
const GLenum COLOR_ATTACHMENT11 = 0x8CEB;
const GLenum COLOR_ATTACHMENT12 = 0x8CEC;
const GLenum COLOR_ATTACHMENT13 = 0x8CED;
const GLenum COLOR_ATTACHMENT14 = 0x8CEE;
const GLenum COLOR_ATTACHMENT15 = 0x8CEF;
const GLenum FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56;
const GLenum MAX_SAMPLES = 0x8D57;
const GLenum HALF_FLOAT = 0x140B;
const GLenum RG = 0x8227;
const GLenum RG_INTEGER = 0x8228;
const GLenum R8 = 0x8229;
const GLenum RG8 = 0x822B;
const GLenum R16F = 0x822D;
const GLenum R32F = 0x822E;
const GLenum RG16F = 0x822F;
const GLenum RG32F = 0x8230;
const GLenum R8I = 0x8231;
const GLenum R8UI = 0x8232;
const GLenum R16I = 0x8233;
const GLenum R16UI = 0x8234;
const GLenum R32I = 0x8235;
const GLenum R32UI = 0x8236;
const GLenum RG8I = 0x8237;
const GLenum RG8UI = 0x8238;
const GLenum RG16I = 0x8239;
const GLenum RG16UI = 0x823A;
const GLenum RG32I = 0x823B;
const GLenum RG32UI = 0x823C;
const GLenum VERTEX_ARRAY_BINDING = 0x85B5;
const GLenum R8_SNORM = 0x8F94;
const GLenum RG8_SNORM = 0x8F95;
const GLenum RGB8_SNORM = 0x8F96;
const GLenum RGBA8_SNORM = 0x8F97;
const GLenum SIGNED_NORMALIZED = 0x8F9C;
const GLenum PRIMITIVE_RESTART_FIXED_INDEX = 0x8D69;
const GLenum COPY_READ_BUFFER = 0x8F36;
const GLenum COPY_WRITE_BUFFER = 0x8F37;
const GLenum COPY_READ_BUFFER_BINDING = 0x8F36; /* Same as COPY_READ_BUFFER */
const GLenum COPY_WRITE_BUFFER_BINDING = 0x8F37; /* Same as COPY_WRITE_BUFFER */
const GLenum UNIFORM_BUFFER = 0x8A11;
const GLenum UNIFORM_BUFFER_BINDING = 0x8A28;
const GLenum UNIFORM_BUFFER_START = 0x8A29;
const GLenum UNIFORM_BUFFER_SIZE = 0x8A2A;
const GLenum MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B;
const GLenum MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D;
const GLenum MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E;
const GLenum MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F;
const GLenum MAX_UNIFORM_BLOCK_SIZE = 0x8A30;
const GLenum MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31;
const GLenum MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33;
const GLenum UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34;
const GLenum ACTIVE_UNIFORM_BLOCKS = 0x8A36;
const GLenum UNIFORM_TYPE = 0x8A37;
const GLenum UNIFORM_SIZE = 0x8A38;
const GLenum UNIFORM_BLOCK_INDEX = 0x8A3A;
const GLenum UNIFORM_OFFSET = 0x8A3B;
const GLenum UNIFORM_ARRAY_STRIDE = 0x8A3C;
const GLenum UNIFORM_MATRIX_STRIDE = 0x8A3D;
const GLenum UNIFORM_IS_ROW_MAJOR = 0x8A3E;
const GLenum UNIFORM_BLOCK_BINDING = 0x8A3F;
const GLenum UNIFORM_BLOCK_DATA_SIZE = 0x8A40;
const GLenum UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42;
const GLenum UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43;
const GLenum UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44;
const GLenum UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46;
const GLenum INVALID_INDEX = 0xFFFFFFFF;
const GLenum MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122;
const GLenum MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125;
const GLenum MAX_SERVER_WAIT_TIMEOUT = 0x9111;
const GLenum OBJECT_TYPE = 0x9112;
const GLenum SYNC_CONDITION = 0x9113;
const GLenum SYNC_STATUS = 0x9114;
const GLenum SYNC_FLAGS = 0x9115;
const GLenum SYNC_FENCE = 0x9116;
const GLenum SYNC_GPU_COMMANDS_COMPLETE = 0x9117;
const GLenum UNSIGNALED = 0x9118;
const GLenum SIGNALED = 0x9119;
const GLenum ALREADY_SIGNALED = 0x911A;
const GLenum TIMEOUT_EXPIRED = 0x911B;
const GLenum CONDITION_SATISFIED = 0x911C;
const GLenum WAIT_FAILED = 0x911D;
const GLenum SYNC_FLUSH_COMMANDS_BIT = 0x00000001;
const GLenum VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE;
const GLenum ANY_SAMPLES_PASSED = 0x8C2F;
const GLenum ANY_SAMPLES_PASSED_CONSERVATIVE = 0x8D6A;
const GLenum SAMPLER_BINDING = 0x8919;
const GLenum RGB10_A2UI = 0x906F;
const GLenum TEXTURE_SWIZZLE_R = 0x8E42;
const GLenum TEXTURE_SWIZZLE_G = 0x8E43;
const GLenum TEXTURE_SWIZZLE_B = 0x8E44;
const GLenum TEXTURE_SWIZZLE_A = 0x8E45;
const GLenum GREEN = 0x1904;
const GLenum BLUE = 0x1905;
const GLenum INT_2_10_10_10_REV = 0x8D9F;
const GLenum TRANSFORM_FEEDBACK = 0x8E22;
const GLenum TRANSFORM_FEEDBACK_PAUSED = 0x8E23;
const GLenum TRANSFORM_FEEDBACK_ACTIVE = 0x8E24;
const GLenum TRANSFORM_FEEDBACK_BINDING = 0x8E25;
const GLenum COMPRESSED_R11_EAC = 0x9270;
const GLenum COMPRESSED_SIGNED_R11_EAC = 0x9271;
const GLenum COMPRESSED_RG11_EAC = 0x9272;
const GLenum COMPRESSED_SIGNED_RG11_EAC = 0x9273;
const GLenum COMPRESSED_RGB8_ETC2 = 0x9274;
const GLenum COMPRESSED_SRGB8_ETC2 = 0x9275;
const GLenum COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9276;
const GLenum COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9277;
const GLenum COMPRESSED_RGBA8_ETC2_EAC = 0x9278;
const GLenum COMPRESSED_SRGB8_ALPHA8_ETC2_EAC = 0x9279;
const GLenum TEXTURE_IMMUTABLE_FORMAT = 0x912F;
const GLenum MAX_ELEMENT_INDEX = 0x8D6B;
const GLenum NUM_SAMPLE_COUNTS = 0x9380;
const GLenum TEXTURE_IMMUTABLE_LEVELS = 0x82DF;
const GLint64 TIMEOUT_IGNORED = -1;
/* transform feedback queries */
const GLenum TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88;
/* Buffer objects */
void copyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset,
GLintptr writeOffset, GLsizeiptr size);
void getBufferSubData(GLenum target, GLintptr offset, ArrayBuffer returnedData);
void getBufferSubData(GLenum target, GLintptr offset, ArrayBufferView returnedData);
/* Framebuffer objects */
void blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0,
GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
void framebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
any getInternalformatParameter(GLenum target, GLenum internalformat, GLenum pname);
void invalidateFramebuffer(GLenum target, sequence<GLenum> attachments);
void invalidateSubFramebuffer (GLenum target, sequence<GLenum> attachments,
GLint x, GLint y, GLsizei width, GLsizei height);
void readBuffer(GLenum src);
/* buffer objects */
/* Renderbuffer objects */
void renderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
/* Texture objects */
void texStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
void texStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height,
GLsizei depth);
[Throws] void texSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type,
ArrayBufferView? pixels);
[Throws] void texSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, ImageData? data);
[Throws] void texSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, HTMLImageElement image);
[Throws] void texSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, HTMLCanvasElement canvas);
[Throws] void texSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLenum format, GLenum type, HTMLVideoElement video);
void copyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLint x, GLint y, GLsizei width, GLsizei height);
void compressedTexImage3D(GLenum target, GLint level, GLenum internalformat,
GLsizei width, GLsizei height, GLsizei depth,
GLint border, GLsizei imageSize, ArrayBufferView data);
void compressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height, GLsizei depth,
GLenum format, GLsizei imageSize, ArrayBufferView data);
/* Programs and shaders */
[WebGLHandlesContextLoss] GLint getFragDataLocation(WebGLProgram? program, DOMString name);
/* Uniforms and attributes */
void uniform1ui(WebGLUniformLocation? location, GLuint v0);
void uniform2ui(WebGLUniformLocation? location, GLuint v0, GLuint v1);
void uniform3ui(WebGLUniformLocation? location, GLuint v0, GLuint v1, GLuint v2);
void uniform4ui(WebGLUniformLocation? location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
void uniform1uiv(WebGLUniformLocation? location, sequence<GLuint> value);
void uniform2uiv(WebGLUniformLocation? location, sequence<GLuint> value);
void uniform3uiv(WebGLUniformLocation? location, sequence<GLuint> value);
void uniform4uiv(WebGLUniformLocation? location, sequence<GLuint> value);
void uniformMatrix2x3fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix2x3fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void uniformMatrix3x2fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix3x2fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void uniformMatrix2x4fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix2x4fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void uniformMatrix4x2fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix4x2fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void uniformMatrix3x4fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix3x4fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void uniformMatrix4x3fv(WebGLUniformLocation? location, GLboolean transpose, Float32Array value);
void uniformMatrix4x3fv(WebGLUniformLocation? location, GLboolean transpose, sequence<GLfloat> value);
void vertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
void vertexAttribI4iv(GLuint index, sequence<GLint> v);
void vertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
void vertexAttribI4uiv(GLuint index, sequence<GLuint> v);
void vertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset);
/* Writing to the drawing buffer */
void vertexAttribDivisor(GLuint index, GLuint divisor);
void drawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instanceCount);
void drawElementsInstanced(GLenum mode, GLsizei count, GLenum type, GLintptr offset, GLsizei instanceCount);
void drawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, GLintptr offset);
/* Multiple Render Targets */
void drawBuffers(sequence<GLenum> buffers);
void clearBufferiv(GLenum buffer, GLint drawbuffer, Int32Array value);
void clearBufferiv(GLenum buffer, GLint drawbuffer, sequence<GLint> value);
void clearBufferuiv(GLenum buffer, GLint drawbuffer, Uint32Array value);
void clearBufferuiv(GLenum buffer, GLint drawbuffer, sequence<GLuint> value);
void clearBufferfv(GLenum buffer, GLint drawbuffer, Float32Array value);
void clearBufferfv(GLenum buffer, GLint drawbuffer, sequence<GLfloat> value);
void clearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
/* Query Objects */
WebGLQuery? createQuery();
void deleteQuery(WebGLQuery? query);
[WebGLHandlesContextLoss] GLboolean isQuery(WebGLQuery? query);
void beginQuery(GLenum target, WebGLQuery? query);
void endQuery(GLenum target);
WebGLQuery? getQuery(GLenum target, GLenum pname);
any getQueryParameter(WebGLQuery? query, GLenum pname);
/* Sampler Objects */
WebGLSampler? createSampler();
void deleteSampler(WebGLSampler? sampler);
[WebGLHandlesContextLoss] GLboolean isSampler(WebGLSampler? sampler);
void bindSampler(GLuint unit, WebGLSampler? sampler);
void samplerParameteri(WebGLSampler? sampler, GLenum pname, GLint param);
void samplerParameterf(WebGLSampler? sampler, GLenum pname, GLfloat param);
any getSamplerParameter(WebGLSampler? sampler, GLenum pname);
/* Sync objects */
WebGLSync? fenceSync(GLenum condition, GLbitfield flags);
[WebGLHandlesContextLoss] GLboolean isSync(WebGLSync? sync);
void deleteSync(WebGLSync? sync);
GLenum clientWaitSync(WebGLSync? sync, GLbitfield flags, GLint64 timeout);
void waitSync(WebGLSync? sync, GLbitfield flags, GLint64 timeout);
any getSyncParameter(WebGLSync? sync, GLenum pname);
/* Transform Feedback */
WebGLTransformFeedback? createTransformFeedback();
void deleteTransformFeedback(WebGLTransformFeedback? tf);
[WebGLHandlesContextLoss] GLboolean isTransformFeedback(WebGLTransformFeedback? tf);
void bindTransformFeedback(GLenum target, GLuint id);
void beginTransformFeedback(GLenum primitiveMode);
void endTransformFeedback();
void transformFeedbackVaryings(WebGLProgram? program, GLsizei count, sequence<DOMString> varyings, GLenum bufferMode);
[NewObject] WebGLActiveInfo? getTransformFeedbackVarying(WebGLProgram? program, GLuint index);
void pauseTransformFeedback();
void resumeTransformFeedback();
/* Uniform Buffer Objects and Transform Feedback Buffers */
void bindBufferBase(GLenum target, GLuint index, WebGLBuffer? buffer);
void bindBufferRange(GLenum target, GLuint index, WebGLBuffer? buffer,
GLintptr offset, GLsizeiptr size);
/* standart derivatives */
const GLenum FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B;
/* state requests */
any getParameterIndexed(GLenum pname, GLuint index);
/* vertex array objects */
const GLenum VERTEX_ARRAY_BINDING = 0x85B5;
void bindVertexArray(WebGLVertexArray? arrayObject);
WebGLVertexArray? createVertexArray();
void deleteVertexArray(WebGLVertexArray? arrayObject);
[WebGLHandlesContextLoss] GLboolean isVertexArray(WebGLVertexArray? arrayObject);
void bindBufferRange(GLenum target, GLuint index, WebGLBuffer? buffer, GLintptr offset, GLsizeiptr size);
any getIndexedParameter(GLenum target, GLuint index);
sequence<GLuint>? getUniformIndices(WebGLProgram? program, sequence<DOMString> uniformNames);
sequence<GLint>? getActiveUniforms(WebGLProgram? program, sequence<GLuint> uniformIndices, GLenum pname);
GLuint getUniformBlockIndex(WebGLProgram? program, DOMString uniformBlockName);
any getActiveUniformBlockParameter(WebGLProgram? program, GLuint uniformBlockIndex, GLenum pname);
DOMString? getActiveUniformBlockName(WebGLProgram? program, GLuint uniformBlockIndex);
void uniformBlockBinding(WebGLProgram? program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
/* Vertex Array Objects */
/*
WebGLVertexArrayObject? createVertexArray();
void deleteVertexArray(WebGLVertexArrayObject? vertexArray);
[WebGLHandlesContextLoss] GLboolean isVertexArray(WebGLVertexArrayObject? vertexArray);
void bindVertexArray(WebGLVertexArrayObject? array);
*/
};

Просмотреть файл

@ -32,6 +32,7 @@
#include "nsRegion.h" // for nsIntRegion
#include "nsTArray.h" // for nsTArray, nsTArray_Impl, etc
#include "nsTArrayForwardDeclare.h" // for InfallibleTArray
#include "UnitTransforms.h" // for TransformTo
#if defined(MOZ_WIDGET_ANDROID)
# include <android/log.h>
# include "AndroidBridge.h"
@ -136,6 +137,19 @@ GetBaseTransform2D(Layer* aLayer, Matrix* aTransform)
aLayer->GetLocalTransform() : aLayer->GetTransform()).Is2D(aTransform);
}
static void
TransformClipRect(Layer* aLayer,
const Matrix4x4& aTransform)
{
const nsIntRect* clipRect = aLayer->GetClipRect();
if (clipRect) {
LayerIntRect transformed = TransformTo<LayerPixel>(
aTransform, LayerIntRect::FromUntyped(*clipRect));
nsIntRect shadowClip = LayerIntRect::ToUntyped(transformed);
aLayer->AsLayerComposite()->SetShadowClipRect(&shadowClip);
}
}
static void
TranslateShadowLayer2D(Layer* aLayer,
const gfxPoint& aTranslation,
@ -173,11 +187,8 @@ TranslateShadowLayer2D(Layer* aLayer,
layerComposite->SetShadowTransform(layerTransform3D);
layerComposite->SetShadowTransformSetByAnimation(false);
const nsIntRect* clipRect = aLayer->GetClipRect();
if (aAdjustClipRect && clipRect) {
nsIntRect transformedClipRect(*clipRect);
transformedClipRect.MoveBy(aTranslation.x, aTranslation.y);
layerComposite->SetShadowClipRect(&transformedClipRect);
if (aAdjustClipRect) {
TransformClipRect(aLayer, Matrix4x4().Translate(aTranslation.x, aTranslation.y, 0));
}
}
@ -727,6 +738,14 @@ ApplyAsyncTransformToScrollbarForContent(Layer* aScrollbar,
// as the content scrolls.
transientTransform.Invert();
transform = transform * transientTransform;
// We also need to make a corresponding change on the clip rect of all the
// layers on the ancestor chain from the scrollbar layer up to but not
// including the layer with the async transform. Otherwise the scrollbar
// shifts but gets clipped and so appears to flicker.
for (Layer* ancestor = aScrollbar; ancestor != aContent.GetLayer(); ancestor = ancestor->GetParent()) {
TransformClipRect(ancestor, transientTransform);
}
}
// GetTransform already takes the pre- and post-scale into account. Since we

Просмотреть файл

@ -533,7 +533,7 @@ ShadowLayerForwarder::EndTransaction(InfallibleTArray<EditReply>* aReplies,
MOZ_ASSERT(aId);
PROFILER_LABEL("ShadowLayerForwarder", "EndTranscation",
PROFILER_LABEL("ShadowLayerForwarder", "EndTransaction",
js::ProfileEntry::Category::GRAPHICS);
RenderTraceScope rendertrace("Foward Transaction", "000091");

Просмотреть файл

@ -68,6 +68,10 @@ public:
{
return IsEqual(aRgn);
}
bool operator!=(const nsRegion& aRgn) const
{
return !(*this == aRgn);
}
friend std::ostream& operator<<(std::ostream& stream, const nsRegion& m);
@ -464,6 +468,10 @@ public:
{
return IsEqual(aRgn);
}
bool operator!=(const nsIntRegion& aRgn) const
{
return !(*this == aRgn);
}
friend std::ostream& operator<<(std::ostream& stream, const nsIntRegion& m) {
return stream << m.mImpl;

Просмотреть файл

@ -1303,7 +1303,7 @@ gfxFontFamily::ContainsFace(gfxFontEntry* aFontEntry) {
return true;
}
// userfonts contain the actual real font entry
if (mAvailableFonts[i]->mIsUserFontContainer) {
if (mAvailableFonts[i] && mAvailableFonts[i]->mIsUserFontContainer) {
gfxUserFontEntry* ufe =
static_cast<gfxUserFontEntry*>(mAvailableFonts[i].get());
if (ufe->GetPlatformFontEntry() == aFontEntry) {

Просмотреть файл

@ -446,13 +446,14 @@ imgFrame::SurfaceForDrawing(bool aDoPadding,
// Fill 'available' with whatever we've got
if (mSinglePixel) {
target->FillRect(ToRect(aRegion.Rect()), ColorPattern(mSinglePixelColor),
target->FillRect(ToRect(aRegion.Intersect(available).Rect()),
ColorPattern(mSinglePixelColor),
DrawOptions(1.0f, CompositionOp::OP_SOURCE));
} else {
SurfacePattern pattern(aSurface,
ExtendMode::REPEAT,
ToMatrix(aContext->CurrentMatrix()));
target->FillRect(ToRect(aRegion.Rect()), pattern);
target->FillRect(ToRect(aRegion.Intersect(available).Rect()), pattern);
}
RefPtr<SourceSurface> newsurf = target->Snapshot();
@ -503,7 +504,7 @@ bool imgFrame::Draw(gfxContext* aContext, const ImageRegion& aRegion,
mSize.height + aPadding.TopBottom());
RefPtr<SourceSurface> surf = GetSurface();
if (!surf) {
if (!surf && !mSinglePixel) {
return false;
}

Двоичные данные
image/test/reftest/gif/one-color-offset-ref.gif Normal file

Двоичный файл не отображается.

После

Ширина:  |  Высота:  |  Размер: 69 B

Двоичные данные
image/test/reftest/gif/one-color-offset.gif Normal file

Двоичный файл не отображается.

После

Ширина:  |  Высота:  |  Размер: 49 B

Просмотреть файл

@ -19,6 +19,9 @@ random == delaytest.html?transparent-animation.gif transparent-animation-finalfr
# test for bug 641198
skip-if(B2G) random-if(Android) == test_bug641198.html animation2a-finalframe.gif # bug 773482
# Bug 1062886: a gif with a single color and an offset
== one-color-offset.gif one-color-offset-ref.gif
# webcam-simulacrum.mgif is a hand-edited file containing red.gif and blue.gif,
# concatenated together with the relevant headers for
# multipart/x-mixed-replace. Specifically, with the headers in

Просмотреть файл

@ -16,7 +16,7 @@ ucvcn - Simplified Chinese charsets - GB2312, HZ, ISO-2022-CN, GBK, GB18030
ucvja - Japanese charsets - Shift-JIS, ISO-2022-JP, EUC-JP
ucvko - Korean charsets - ISO-2022-KR, EUC-KR, Johab
ucvlatin - Latin charsets and others - ISO-8859-x, CP1250-1258
CP866, 874, ISO-IR-111, KOI8,
CP866, 874, KOI8,
Mac charsets, TIS620, UTF16
ucvtw - Traditional Chinese charsets Set 1 - Big5
ucvtw2 - Traditional Chinese charsets Set 2 - EUC-TW

Просмотреть файл

@ -61,7 +61,6 @@ UNIFIED_SOURCES += [
'ucvja/nsJapaneseToUnicode.cpp',
'ucvja/nsUnicodeToEUCJP.cpp',
'ucvja/nsUnicodeToISO2022JP.cpp',
'ucvja/nsUnicodeToJISx0201.cpp',
'ucvja/nsUnicodeToSJIS.cpp',
]
@ -92,15 +91,11 @@ UNIFIED_SOURCES += [
'ucvlatin/nsISO88593ToUnicode.cpp',
'ucvlatin/nsISO88594ToUnicode.cpp',
'ucvlatin/nsISO88595ToUnicode.cpp',
'ucvlatin/nsISO88596EToUnicode.cpp',
'ucvlatin/nsISO88596IToUnicode.cpp',
'ucvlatin/nsISO88596ToUnicode.cpp',
'ucvlatin/nsISO88597ToUnicode.cpp',
'ucvlatin/nsISO88598EToUnicode.cpp',
'ucvlatin/nsISO88598IToUnicode.cpp',
'ucvlatin/nsISO88598ToUnicode.cpp',
'ucvlatin/nsISO88599ToUnicode.cpp',
'ucvlatin/nsISOIR111ToUnicode.cpp',
'ucvlatin/nsKOI8RToUnicode.cpp',
'ucvlatin/nsKOI8UToUnicode.cpp',
'ucvlatin/nsMacArabicToUnicode.cpp',
@ -139,14 +134,10 @@ UNIFIED_SOURCES += [
'ucvlatin/nsUnicodeToISO88594.cpp',
'ucvlatin/nsUnicodeToISO88595.cpp',
'ucvlatin/nsUnicodeToISO88596.cpp',
'ucvlatin/nsUnicodeToISO88596E.cpp',
'ucvlatin/nsUnicodeToISO88596I.cpp',
'ucvlatin/nsUnicodeToISO88597.cpp',
'ucvlatin/nsUnicodeToISO88598.cpp',
'ucvlatin/nsUnicodeToISO88598E.cpp',
'ucvlatin/nsUnicodeToISO88598I.cpp',
'ucvlatin/nsUnicodeToISO88599.cpp',
'ucvlatin/nsUnicodeToISOIR111.cpp',
'ucvlatin/nsUnicodeToKOI8R.cpp',
'ucvlatin/nsUnicodeToKOI8U.cpp',
'ucvlatin/nsUnicodeToMacCyrillic.cpp',
@ -162,7 +153,6 @@ UNIFIED_SOURCES += [
'ucvtw/nsBIG5ToUnicode.cpp',
'ucvtw/nsUnicodeToBIG5.cpp',
'ucvtw/nsUnicodeToBIG5HKSCS.cpp',
'ucvtw/nsUnicodeToHKSCS.cpp',
]
UNIFIED_SOURCES += [

Просмотреть файл

@ -34,11 +34,8 @@
#include "nsISO88594ToUnicode.h"
#include "nsISO88595ToUnicode.h"
#include "nsISO88596ToUnicode.h"
#include "nsISO88596EToUnicode.h"
#include "nsISO88596IToUnicode.h"
#include "nsISO88597ToUnicode.h"
#include "nsISO88598ToUnicode.h"
#include "nsISO88598EToUnicode.h"
#include "nsISO88598IToUnicode.h"
#include "nsISO88599ToUnicode.h"
#include "nsISO885910ToUnicode.h"
@ -46,7 +43,6 @@
#include "nsISO885914ToUnicode.h"
#include "nsISO885915ToUnicode.h"
#include "nsISO885916ToUnicode.h"
#include "nsISOIR111ToUnicode.h"
#include "nsCP1250ToUnicode.h"
#include "nsCP1251ToUnicode.h"
#include "nsCP1253ToUnicode.h"
@ -76,11 +72,8 @@
#include "nsUnicodeToISO88594.h"
#include "nsUnicodeToISO88595.h"
#include "nsUnicodeToISO88596.h"
#include "nsUnicodeToISO88596E.h"
#include "nsUnicodeToISO88596I.h"
#include "nsUnicodeToISO88597.h"
#include "nsUnicodeToISO88598.h"
#include "nsUnicodeToISO88598E.h"
#include "nsUnicodeToISO88598I.h"
#include "nsUnicodeToISO88599.h"
#include "nsUnicodeToISO885910.h"
@ -88,7 +81,6 @@
#include "nsUnicodeToISO885914.h"
#include "nsUnicodeToISO885915.h"
#include "nsUnicodeToISO885916.h"
#include "nsUnicodeToISOIR111.h"
#include "nsUnicodeToCP1250.h"
#include "nsUnicodeToCP1251.h"
#include "nsUnicodeToCP1253.h"
@ -121,7 +113,6 @@
#include "nsUnicodeToSJIS.h"
#include "nsUnicodeToEUCJP.h"
#include "nsUnicodeToISO2022JP.h"
#include "nsUnicodeToJISx0201.h"
// ucvtw
#include "nsUCvTWCID.h"
@ -130,7 +121,6 @@
#include "nsUnicodeToBIG5.h"
#include "nsBIG5HKSCSToUnicode.h"
#include "nsUnicodeToBIG5HKSCS.h"
#include "nsUnicodeToHKSCS.h"
// ucvko
#include "nsUCvKOCID.h"
@ -162,19 +152,15 @@ NS_UCONV_REG_UNREG("ISO-8859-3", NS_ISO88593TOUNICODE_CID, NS_UNICODETOISO88593_
NS_UCONV_REG_UNREG("ISO-8859-4", NS_ISO88594TOUNICODE_CID, NS_UNICODETOISO88594_CID)
NS_UCONV_REG_UNREG("ISO-8859-5", NS_ISO88595TOUNICODE_CID, NS_UNICODETOISO88595_CID)
NS_UCONV_REG_UNREG("ISO-8859-6", NS_ISO88596TOUNICODE_CID, NS_UNICODETOISO88596_CID)
NS_UCONV_REG_UNREG("ISO-8859-6-I", NS_ISO88596ITOUNICODE_CID, NS_UNICODETOISO88596I_CID)
NS_UCONV_REG_UNREG("ISO-8859-6-E", NS_ISO88596ETOUNICODE_CID, NS_UNICODETOISO88596E_CID)
NS_UCONV_REG_UNREG("ISO-8859-7", NS_ISO88597TOUNICODE_CID, NS_UNICODETOISO88597_CID)
NS_UCONV_REG_UNREG("ISO-8859-8", NS_ISO88598TOUNICODE_CID, NS_UNICODETOISO88598_CID)
NS_UCONV_REG_UNREG("ISO-8859-8-I", NS_ISO88598ITOUNICODE_CID, NS_UNICODETOISO88598I_CID)
NS_UCONV_REG_UNREG("ISO-8859-8-E", NS_ISO88598ETOUNICODE_CID, NS_UNICODETOISO88598E_CID)
NS_UCONV_REG_UNREG("ISO-8859-9", NS_ISO88599TOUNICODE_CID, NS_UNICODETOISO88599_CID)
NS_UCONV_REG_UNREG("ISO-8859-10", NS_ISO885910TOUNICODE_CID, NS_UNICODETOISO885910_CID)
NS_UCONV_REG_UNREG("ISO-8859-13", NS_ISO885913TOUNICODE_CID, NS_UNICODETOISO885913_CID)
NS_UCONV_REG_UNREG("ISO-8859-14", NS_ISO885914TOUNICODE_CID, NS_UNICODETOISO885914_CID)
NS_UCONV_REG_UNREG("ISO-8859-15", NS_ISO885915TOUNICODE_CID, NS_UNICODETOISO885915_CID)
NS_UCONV_REG_UNREG("ISO-8859-16", NS_ISO885916TOUNICODE_CID, NS_UNICODETOISO885916_CID)
NS_UCONV_REG_UNREG("ISO-IR-111", NS_ISOIR111TOUNICODE_CID, NS_UNICODETOISOIR111_CID)
NS_UCONV_REG_UNREG("windows-1250", NS_CP1250TOUNICODE_CID, NS_UNICODETOCP1250_CID)
NS_UCONV_REG_UNREG("windows-1251", NS_CP1251TOUNICODE_CID, NS_UNICODETOCP1251_CID)
NS_UCONV_REG_UNREG("windows-1253", NS_CP1253TOUNICODE_CID, NS_UNICODETOCP1253_CID)
@ -212,14 +198,10 @@ NS_UCONV_REG_UNREG("Shift_JIS", NS_SJISTOUNICODE_CID, NS_UNICODETOSJIS_CID)
NS_UCONV_REG_UNREG("ISO-2022-JP", NS_ISO2022JPTOUNICODE_CID, NS_UNICODETOISO2022JP_CID)
NS_UCONV_REG_UNREG("EUC-JP", NS_EUCJPTOUNICODE_CID, NS_UNICODETOEUCJP_CID)
NS_UCONV_REG_UNREG_ENCODER("jis_0201" , NS_UNICODETOJISX0201_CID)
// ucvtw
NS_UCONV_REG_UNREG("Big5", NS_BIG5TOUNICODE_CID, NS_UNICODETOBIG5_CID)
NS_UCONV_REG_UNREG("Big5-HKSCS", NS_BIG5HKSCSTOUNICODE_CID, NS_UNICODETOBIG5HKSCS_CID)
NS_UCONV_REG_UNREG_ENCODER("hkscs-1" , NS_UNICODETOHKSCS_CID)
// ucvko
NS_UCONV_REG_UNREG("EUC-KR", NS_EUCKRTOUNICODE_CID, NS_UNICODETOEUCKR_CID)
@ -342,19 +324,15 @@ NS_DEFINE_NAMED_CID(NS_ISO88593TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88594TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88595TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88596TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88596ITOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88596ETOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88597TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88598TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88598ITOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88598ETOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO88599TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO885910TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO885913TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO885914TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO885915TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISO885916TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_ISOIR111TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_CP1250TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_CP1251TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_CP1253TOUNICODE_CID);
@ -392,19 +370,15 @@ NS_DEFINE_NAMED_CID(NS_UNICODETOISO88593_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88594_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88595_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88596_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88596I_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88596E_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88597_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88598_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88598I_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88598E_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO88599_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO885910_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO885913_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO885914_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO885915_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO885916_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISOIR111_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOCP1250_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOCP1251_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOCP1253_CID);
@ -430,11 +404,9 @@ NS_DEFINE_NAMED_CID( NS_ISO2022JPTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOSJIS_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOEUCJP_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOISO2022JP_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOJISX0201_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOBIG5_CID);
NS_DEFINE_NAMED_CID(NS_BIG5TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOBIG5HKSCS_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOHKSCS_CID);
NS_DEFINE_NAMED_CID(NS_BIG5HKSCSTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_EUCKRTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOEUCKR_CID);
@ -468,19 +440,15 @@ static const mozilla::Module::CIDEntry kUConvCIDs[] = {
{ &kNS_ISO88594TOUNICODE_CID, false, nullptr, nsISO88594ToUnicodeConstructor },
{ &kNS_ISO88595TOUNICODE_CID, false, nullptr, nsISO88595ToUnicodeConstructor },
{ &kNS_ISO88596TOUNICODE_CID, false, nullptr, nsISO88596ToUnicodeConstructor },
{ &kNS_ISO88596ITOUNICODE_CID, false, nullptr, nsISO88596IToUnicodeConstructor },
{ &kNS_ISO88596ETOUNICODE_CID, false, nullptr, nsISO88596EToUnicodeConstructor },
{ &kNS_ISO88597TOUNICODE_CID, false, nullptr, nsISO88597ToUnicodeConstructor },
{ &kNS_ISO88598TOUNICODE_CID, false, nullptr, nsISO88598ToUnicodeConstructor },
{ &kNS_ISO88598ITOUNICODE_CID, false, nullptr, nsISO88598IToUnicodeConstructor },
{ &kNS_ISO88598ETOUNICODE_CID, false, nullptr, nsISO88598EToUnicodeConstructor },
{ &kNS_ISO88599TOUNICODE_CID, false, nullptr, nsISO88599ToUnicodeConstructor },
{ &kNS_ISO885910TOUNICODE_CID, false, nullptr, nsISO885910ToUnicodeConstructor },
{ &kNS_ISO885913TOUNICODE_CID, false, nullptr, nsISO885913ToUnicodeConstructor },
{ &kNS_ISO885914TOUNICODE_CID, false, nullptr, nsISO885914ToUnicodeConstructor },
{ &kNS_ISO885915TOUNICODE_CID, false, nullptr, nsISO885915ToUnicodeConstructor },
{ &kNS_ISO885916TOUNICODE_CID, false, nullptr, nsISO885916ToUnicodeConstructor },
{ &kNS_ISOIR111TOUNICODE_CID, false, nullptr, nsISOIR111ToUnicodeConstructor },
{ &kNS_CP1250TOUNICODE_CID, false, nullptr, nsCP1250ToUnicodeConstructor },
{ &kNS_CP1251TOUNICODE_CID, false, nullptr, nsCP1251ToUnicodeConstructor },
{ &kNS_CP1253TOUNICODE_CID, false, nullptr, nsCP1253ToUnicodeConstructor },
@ -518,19 +486,15 @@ static const mozilla::Module::CIDEntry kUConvCIDs[] = {
{ &kNS_UNICODETOISO88594_CID, false, nullptr, nsUnicodeToISO88594Constructor },
{ &kNS_UNICODETOISO88595_CID, false, nullptr, nsUnicodeToISO88595Constructor },
{ &kNS_UNICODETOISO88596_CID, false, nullptr, nsUnicodeToISO88596Constructor },
{ &kNS_UNICODETOISO88596I_CID, false, nullptr, nsUnicodeToISO88596IConstructor },
{ &kNS_UNICODETOISO88596E_CID, false, nullptr, nsUnicodeToISO88596EConstructor },
{ &kNS_UNICODETOISO88597_CID, false, nullptr, nsUnicodeToISO88597Constructor },
{ &kNS_UNICODETOISO88598_CID, false, nullptr, nsUnicodeToISO88598Constructor },
{ &kNS_UNICODETOISO88598I_CID, false, nullptr, nsUnicodeToISO88598IConstructor },
{ &kNS_UNICODETOISO88598E_CID, false, nullptr, nsUnicodeToISO88598EConstructor },
{ &kNS_UNICODETOISO88599_CID, false, nullptr, nsUnicodeToISO88599Constructor },
{ &kNS_UNICODETOISO885910_CID, false, nullptr, nsUnicodeToISO885910Constructor },
{ &kNS_UNICODETOISO885913_CID, false, nullptr, nsUnicodeToISO885913Constructor },
{ &kNS_UNICODETOISO885914_CID, false, nullptr, nsUnicodeToISO885914Constructor },
{ &kNS_UNICODETOISO885915_CID, false, nullptr, nsUnicodeToISO885915Constructor },
{ &kNS_UNICODETOISO885916_CID, false, nullptr, nsUnicodeToISO885916Constructor },
{ &kNS_UNICODETOISOIR111_CID, false, nullptr, nsUnicodeToISOIR111Constructor },
{ &kNS_UNICODETOCP1250_CID, false, nullptr, nsUnicodeToCP1250Constructor },
{ &kNS_UNICODETOCP1251_CID, false, nullptr, nsUnicodeToCP1251Constructor },
{ &kNS_UNICODETOCP1253_CID, false, nullptr, nsUnicodeToCP1253Constructor },
@ -556,11 +520,9 @@ static const mozilla::Module::CIDEntry kUConvCIDs[] = {
{ &kNS_UNICODETOSJIS_CID, false, nullptr, nsUnicodeToSJISConstructor },
{ &kNS_UNICODETOEUCJP_CID, false, nullptr, nsUnicodeToEUCJPConstructor },
{ &kNS_UNICODETOISO2022JP_CID, false, nullptr, nsUnicodeToISO2022JPConstructor },
{ &kNS_UNICODETOJISX0201_CID, false, nullptr, nsUnicodeToJISx0201Constructor },
{ &kNS_UNICODETOBIG5_CID, false, nullptr, nsUnicodeToBIG5Constructor },
{ &kNS_BIG5TOUNICODE_CID, false, nullptr, nsBIG5ToUnicodeConstructor },
{ &kNS_UNICODETOBIG5HKSCS_CID, false, nullptr, nsUnicodeToBIG5HKSCSConstructor },
{ &kNS_UNICODETOHKSCS_CID, false, nullptr, nsUnicodeToHKSCSConstructor },
{ &kNS_BIG5HKSCSTOUNICODE_CID, false, nullptr, nsBIG5HKSCSToUnicodeConstructor },
{ &kNS_EUCKRTOUNICODE_CID, false, nullptr, nsCP949ToUnicodeConstructor },
{ &kNS_UNICODETOEUCKR_CID, false, nullptr, nsUnicodeToCP949Constructor },
@ -596,19 +558,15 @@ static const mozilla::Module::ContractIDEntry kUConvContracts[] = {
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-4", &kNS_ISO88594TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-5", &kNS_ISO88595TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-6", &kNS_ISO88596TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-6-I", &kNS_ISO88596ITOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-6-E", &kNS_ISO88596ETOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-7", &kNS_ISO88597TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-8", &kNS_ISO88598TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-8-I", &kNS_ISO88598ITOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-8-E", &kNS_ISO88598ETOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-9", &kNS_ISO88599TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-10", &kNS_ISO885910TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-13", &kNS_ISO885913TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-14", &kNS_ISO885914TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-15", &kNS_ISO885915TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-8859-16", &kNS_ISO885916TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-IR-111", &kNS_ISOIR111TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "windows-1250", &kNS_CP1250TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "windows-1251", &kNS_CP1251TOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "windows-1253", &kNS_CP1253TOUNICODE_CID },
@ -646,19 +604,15 @@ static const mozilla::Module::ContractIDEntry kUConvContracts[] = {
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-4", &kNS_UNICODETOISO88594_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-5", &kNS_UNICODETOISO88595_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-6", &kNS_UNICODETOISO88596_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-6-I", &kNS_UNICODETOISO88596I_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-6-E", &kNS_UNICODETOISO88596E_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-7", &kNS_UNICODETOISO88597_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-8", &kNS_UNICODETOISO88598_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-8-I", &kNS_UNICODETOISO88598I_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-8-E", &kNS_UNICODETOISO88598E_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-9", &kNS_UNICODETOISO88599_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-10", &kNS_UNICODETOISO885910_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-13", &kNS_UNICODETOISO885913_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-14", &kNS_UNICODETOISO885914_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-15", &kNS_UNICODETOISO885915_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-8859-16", &kNS_UNICODETOISO885916_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-IR-111", &kNS_UNICODETOISOIR111_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "windows-1250", &kNS_UNICODETOCP1250_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "windows-1251", &kNS_UNICODETOCP1251_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "windows-1253", &kNS_UNICODETOCP1253_CID },
@ -684,11 +638,9 @@ static const mozilla::Module::ContractIDEntry kUConvContracts[] = {
{ NS_UNICODEENCODER_CONTRACTID_BASE "Shift_JIS", &kNS_UNICODETOSJIS_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "EUC-JP", &kNS_UNICODETOEUCJP_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "ISO-2022-JP", &kNS_UNICODETOISO2022JP_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "jis_0201", &kNS_UNICODETOJISX0201_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "Big5", &kNS_UNICODETOBIG5_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "Big5", &kNS_BIG5TOUNICODE_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "Big5-HKSCS", &kNS_UNICODETOBIG5HKSCS_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "hkscs-1", &kNS_UNICODETOHKSCS_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "Big5-HKSCS", &kNS_BIG5HKSCSTOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "EUC-KR", &kNS_EUCKRTOUNICODE_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "EUC-KR", &kNS_UNICODETOEUCKR_CID },

Просмотреть файл

@ -282,29 +282,24 @@ sub print_table {
my %cp932 = read_sjis_map('CP932.TXT', 0, 1);
my %ibm = read_sjis_map('IBM943.TXT', 0, 1);
my $jis0212 = read_0212_map('JIS0212.TXT', 0, 1);
%printed = ();
write_fromu_map('jis0201-uf-unify', 'jis',
$cp932{jis0201},
$ibm{jis0201}
);
write_fromu_map('jis0208-uf-unify', 'jis',
$cp932{jis0208},
$ibm{jis0208}
);
%printed = ();
write_fromu_map('jis0208ext-uf-unify', 'jis',
$cp932{jis0208undef},
$ibm{jis0208undef}
);
%printed = ();
write_fromu_map('sjis-uf-unify', 'sjis',
@cp932{'jis0201', 'jis0208', 'jis0208undef', 'sjis1undef', 'sjis2undef'},
@ibm{'jis0201', 'jis0208', 'jis0208undef', 'sjis1undef', 'sjis2undef'}
);
open MAP, ">japanese.map" or die $!;
@ -325,7 +320,6 @@ print MAP <<EOM;
EOM
print_table_index('CP932', @cp932{'jis0208', 'jis0208undef', 'sjis2undef'});
print_table_index('IBM943', @ibm{'jis0208', 'jis0208undef', 'sjis2undef'});
print_0212_table_index('JIS0212', $jis0212);
print_table();

Просмотреть файл

@ -3,7 +3,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/* generated by jamap.pl CP932.TXT IBM943.TXT JIS0212.TXT */
/* generated by jamap.pl CP932.TXT JIS0212.TXT */
// IE-compatible handling of undefined codepoints:
// 0x80 --> U+0080
@ -51,61 +51,21 @@ static const uint16_t * const gCP932Index[] = {
gCP932IndexShiftJis, gCP932IndexJis0208
};
static const uint16_t gIBM943IndexShiftJis[] = {
0xFFFD, 8648, 376, 564, 752, 0, 0, 940,
1128, 1316, 1504, 1692, 1880, 2068, 2256, 2444,
2632, 2820, 3008, 3196, 3384, 3572, 3760, 3948,
4136, 4324, 4512, 4700, 4888, 5076, 5264, 5452,
0xF8F0, 0xFF61, 0xFF62, 0xFF63, 0xFF64, 0xFF65, 0xFF66, 0xFF67,
0xFF68, 0xFF69, 0xFF6A, 0xFF6B, 0xFF6C, 0xFF6D, 0xFF6E, 0xFF6F,
0xFF70, 0xFF71, 0xFF72, 0xFF73, 0xFF74, 0xFF75, 0xFF76, 0xFF77,
0xFF78, 0xFF79, 0xFF7A, 0xFF7B, 0xFF7C, 0xFF7D, 0xFF7E, 0xFF7F,
0xFF80, 0xFF81, 0xFF82, 0xFF83, 0xFF84, 0xFF85, 0xFF86, 0xFF87,
0xFF88, 0xFF89, 0xFF8A, 0xFF8B, 0xFF8C, 0xFF8D, 0xFF8E, 0xFF8F,
0xFF90, 0xFF91, 0xFF92, 0xFF93, 0xFF94, 0xFF95, 0xFF96, 0xFF97,
0xFF98, 0xFF99, 0xFF9A, 0xFF9B, 0xFF9C, 0xFF9D, 0xFF9E, 0xFF9F,
5640, 5828, 6016, 6204, 6392, 6580, 6768, 6956,
7144, 7332, 7520, 0, 0, 7708, 8836, 0,
0xE000, 0xE0BC, 0xE178, 0xE234, 0xE2F0, 0xE3AC, 0xE468, 0xE524,
0xE5E0, 0xE69C, 9024, 8272, 8460, 0xF8F1, 0xF8F2, 0xF8F3,
};
static const uint16_t gIBM943IndexJis0208[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 8648, 282, 376, 470, 564, 658, 752,
846, 0, 0, 0, 0, 940, 0, 0,
1222, 1316, 1410, 1504, 1598, 1692, 1786, 1880,
1974, 2068, 2162, 2256, 2350, 2444, 2538, 2632,
2726, 2820, 2914, 3008, 3102, 3196, 3290, 3384,
3478, 3572, 3666, 3760, 3854, 3948, 4042, 4136,
4230, 4324, 4418, 4512, 4606, 4700, 4794, 4888,
4982, 5076, 5170, 5264, 5358, 5452, 5546, 5640,
5734, 5828, 5922, 6016, 6110, 6204, 6298, 6392,
6486, 6580, 6674, 6768, 6862, 6956, 7050, 7144,
7238, 7332, 7426, 7520, 7614, 0, 0, 0,
0, 7708, 7802, 7896, 8930, 0, 0, 0xFFFD,
};
static const uint16_t * const gIBM943Index[] = {
gIBM943IndexShiftJis, gIBM943IndexJis0208
};
static const uint16_t gJIS0212Index[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0, 9212, 0, 0, 0, 9306, 9400,
0, 9494, 9588, 9682, 0, 0, 0, 0,
9776, 9870, 9964, 10058, 10152, 10246, 10340, 10434,
10528, 10622, 10716, 10810, 10904, 10998, 11092, 11186,
11280, 11374, 11468, 11562, 11656, 11750, 11844, 11938,
12032, 12126, 12220, 12314, 12408, 12502, 12596, 12690,
12784, 12878, 12972, 13066, 13160, 13254, 13348, 13442,
13536, 13630, 13724, 13818, 13912, 14006, 14100, 14194,
14288, 14382, 14476, 14570, 14664, 14758, 14852, 14946,
15040, 15134, 15228, 15322, 15416, 15510, 0, 0,
0xFFFD, 0, 8648, 0, 0, 0, 8742, 8836,
0, 8930, 9024, 9118, 0, 0, 0, 0,
9212, 9306, 9400, 9494, 9588, 9682, 9776, 9870,
9964, 10058, 10152, 10246, 10340, 10434, 10528, 10622,
10716, 10810, 10904, 10998, 11092, 11186, 11280, 11374,
11468, 11562, 11656, 11750, 11844, 11938, 12032, 12126,
12220, 12314, 12408, 12502, 12596, 12690, 12784, 12878,
12972, 13066, 13160, 13254, 13348, 13442, 13536, 13630,
13724, 13818, 13912, 14006, 14100, 14194, 14288, 14382,
14476, 14570, 14664, 14758, 14852, 14946, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0xFFFD,
};
@ -1308,84 +1268,6 @@ static const uint16_t gJapaneseMap[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* index 8648 */
0x3000, 0x3001, 0x3002, 0xFF0C, 0xFF0E, 0x30FB, 0xFF1A,
0xFF1B, 0xFF1F, 0xFF01, 0x309B, 0x309C, 0x00B4, 0xFF40, 0x00A8,
0xFF3E, 0xFFE3, 0xFF3F, 0x30FD, 0x30FE, 0x309D, 0x309E, 0x3003,
0x4EDD, 0x3005, 0x3006, 0x3007, 0x30FC, 0x2014, 0x2010, 0xFF0F,
0xFF3C, 0x301C, 0x2016, 0xFF5C, 0x2026, 0x2025, 0x2018, 0x2019,
0x201C, 0x201D, 0xFF08, 0xFF09, 0x3014, 0x3015, 0xFF3B, 0xFF3D,
0xFF5B, 0xFF5D, 0x3008, 0x3009, 0x300A, 0x300B, 0x300C, 0x300D,
0x300E, 0x300F, 0x3010, 0x3011, 0xFF0B, 0x2212, 0x00B1, 0x00D7,
0x00F7, 0xFF1D, 0x2260, 0xFF1C, 0xFF1E, 0x2266, 0x2267, 0x221E,
0x2234, 0x2642, 0x2640, 0x00B0, 0x2032, 0x2033, 0x2103, 0xFFE5,
0xFF04, 0xFFE0, 0xFFE1, 0xFF05, 0xFF03, 0xFF06, 0xFF0A, 0xFF20,
0x00A7, 0x2606, 0x2605, 0x25CB, 0x25CF, 0x25CE, 0x25C7,
/* index 8742 */
0x25C6, 0x25A1, 0x25A0, 0x25B3, 0x25B2, 0x25BD, 0x25BC,
0x203B, 0x3012, 0x2192, 0x2190, 0x2191, 0x2193, 0x3013, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0x2208, 0x220B, 0x2286, 0x2287, 0x2282, 0x2283,
0x222A, 0x2229, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0x2227, 0x2228, 0xFFE2, 0x21D2, 0x21D4, 0x2200,
0x2203, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x2220, 0x22A5, 0x2312, 0x2202,
0x2207, 0x2261, 0x2252, 0x226A, 0x226B, 0x221A, 0x223D, 0x221D,
0x2235, 0x222B, 0x222C, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0x212B, 0x2030, 0x266F, 0x266D, 0x266A, 0x2020,
0x2021, 0x00B6, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x25EF,
/* index 8836 */
0x72BE, 0x7324, 0xFA16, 0x7377, 0x73BD, 0x73C9, 0x73D6,
0x73E3, 0x73D2, 0x7407, 0x73F5, 0x7426, 0x742A, 0x7429, 0x742E,
0x7462, 0x7489, 0x749F, 0x7501, 0x756F, 0x7682, 0x769C, 0x769E,
0x769B, 0x76A6, 0xFA17, 0x7746, 0x52AF, 0x7821, 0x784E, 0x7864,
0x787A, 0x7930, 0xFA18, 0xFA19, 0xFA1A, 0x7994, 0xFA1B, 0x799B,
0x7AD1, 0x7AE7, 0xFA1C, 0x7AEB, 0x7B9E, 0xFA1D, 0x7D48, 0x7D5C,
0x7DB7, 0x7DA0, 0x7DD6, 0x7E52, 0x7F47, 0x7FA1, 0xFA1E, 0x8301,
0x8362, 0x837F, 0x83C7, 0x83F6, 0x8448, 0x84B4, 0x8553, 0x8559,
0x856B, 0xFA1F, 0x85B0, 0xFA20, 0xFA21, 0x8807, 0x88F5, 0x8A12,
0x8A37, 0x8A79, 0x8AA7, 0x8ABE, 0x8ADF, 0xFA22, 0x8AF6, 0x8B53,
0x8B7F, 0x8CF0, 0x8CF4, 0x8D12, 0x8D76, 0xFA23, 0x8ECF, 0xFA24,
0xFA25, 0x9067, 0x90DE, 0xFA26, 0x9115, 0x9127, 0x91DA,
/* index 8930 */
0x91D7, 0x91DE, 0x91ED, 0x91EE, 0x91E4, 0x91E5, 0x9206,
0x9210, 0x920A, 0x923A, 0x9240, 0x923C, 0x924E, 0x9259, 0x9251,
0x9239, 0x9267, 0x92A7, 0x9277, 0x9278, 0x92E7, 0x92D7, 0x92D9,
0x92D0, 0xFA27, 0x92D5, 0x92E0, 0x92D3, 0x9325, 0x9321, 0x92FB,
0xFA28, 0x931E, 0x92FF, 0x931D, 0x9302, 0x9370, 0x9357, 0x93A4,
0x93C6, 0x93DE, 0x93F8, 0x9431, 0x9445, 0x9448, 0x9592, 0xF9DC,
0xFA29, 0x969D, 0x96AF, 0x9733, 0x973B, 0x9743, 0x974D, 0x974F,
0x9751, 0x9755, 0x9857, 0x9865, 0xFA2A, 0xFA2B, 0x9927, 0xFA2C,
0x999E, 0x9A4E, 0x9AD9, 0x9ADC, 0x9B75, 0x9B72, 0x9B8F, 0x9BB1,
0x9BBB, 0x9C00, 0x9D70, 0x9D6B, 0xFA2D, 0x9E19, 0x9ED1, 0xFFFD,
0xFFFD, 0x2170, 0x2171, 0x2172, 0x2173, 0x2174, 0x2175, 0x2176,
0x2177, 0x2178, 0x2179, 0xFFE2, 0x00A6, 0xFF07, 0xFF02,
/* index 9024 */
0x2170, 0x2171, 0x2172, 0x2173, 0x2174, 0x2175, 0x2176,
0x2177, 0x2178, 0x2179, 0x2160, 0x2161, 0x2162, 0x2163, 0x2164,
0x2165, 0x2166, 0x2167, 0x2168, 0x2169, 0xFFE2, 0x00A6, 0xFF07,
0xFF02, 0x3231, 0x2116, 0x2121, 0x2235, 0x7E8A, 0x891C, 0x9348,
0x9288, 0x84DC, 0x4FC9, 0x70BB, 0x6631, 0x68C8, 0x92F9, 0x66FB,
0x5F45, 0x4E28, 0x4EE1, 0x4EFC, 0x4F00, 0x4F03, 0x4F39, 0x4F56,
0x4F92, 0x4F8A, 0x4F9A, 0x4F94, 0x4FCD, 0x5040, 0x5022, 0x4FFF,
0x501E, 0x5046, 0x5070, 0x5042, 0x5094, 0x50F4, 0x50D8, 0x514A,
0x5164, 0x519D, 0x51BE, 0x51EC, 0x5215, 0x529C, 0x52A6, 0x52C0,
0x52DB, 0x5300, 0x5307, 0x5324, 0x5372, 0x5393, 0x53B2, 0x53DD,
0xFA0E, 0x549C, 0x548A, 0x54A9, 0x54FF, 0x5586, 0x5759, 0x5765,
0x57AC, 0x57C8, 0x57C7, 0xFA0F, 0xFA10, 0x589E, 0x58B2,
/* index 9118 */
0x590B, 0x5953, 0x595B, 0x595D, 0x5963, 0x59A4, 0x59BA,
0x5B56, 0x5BC0, 0x752F, 0x5BD8, 0x5BEC, 0x5C1E, 0x5CA6, 0x5CBA,
0x5CF5, 0x5D27, 0x5D53, 0xFA11, 0x5D42, 0x5D6D, 0x5DB8, 0x5DB9,
0x5DD0, 0x5F21, 0x5F34, 0x5F67, 0x5FB7, 0x5FDE, 0x605D, 0x6085,
0x608A, 0x60DE, 0x60D5, 0x6120, 0x60F2, 0x6111, 0x6137, 0x6130,
0x6198, 0x6213, 0x62A6, 0x63F5, 0x6460, 0x649D, 0x64CE, 0x654E,
0x6600, 0x6615, 0x663B, 0x6609, 0x662E, 0x661E, 0x6624, 0x6665,
0x6657, 0x6659, 0xFA12, 0x6673, 0x6699, 0x66A0, 0x66B2, 0x66BF,
0x66FA, 0x670E, 0xF929, 0x6766, 0x67BB, 0x6852, 0x67C0, 0x6801,
0x6844, 0x68CF, 0xFA13, 0x6968, 0xFA14, 0x6998, 0x69E2, 0x6A30,
0x6A6B, 0x6A46, 0x6A73, 0x6A7E, 0x6AE2, 0x6AE4, 0x6BD6, 0x6C3F,
0x6C5C, 0x6C86, 0x6C6F, 0x6CDA, 0x6D04, 0x6D87, 0x6D6F,
/* index 9212 */
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x02D8,
0x02C7, 0x00B8, 0x02D9, 0x02DD, 0x00AF, 0x02DB, 0x02DA, 0xFF5E,
@ -1398,7 +1280,7 @@ static const uint16_t gJapaneseMap[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0x00BA, 0x00AA, 0x00A9, 0x00AE, 0x2122,
0x00A4, 0x2116, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* index 9306 */
/* index 8742 */
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
@ -1411,7 +1293,7 @@ static const uint16_t gJapaneseMap[] = {
0xFFFD, 0x038E, 0x03AB, 0xFFFD, 0x038F, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0x03AC, 0x03AD, 0x03AE, 0x03AF, 0x03CA, 0x0390, 0x03CC,
0x03C2, 0x03CD, 0x03CB, 0x03B0, 0x03CE, 0xFFFD, 0xFFFD,
/* index 9400 */
/* index 8836 */
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
@ -1424,7 +1306,7 @@ static const uint16_t gJapaneseMap[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0x0452, 0x0453, 0x0454, 0x0455, 0x0456, 0x0457,
0x0458, 0x0459, 0x045A, 0x045B, 0x045C, 0x045E, 0x045F,
/* index 9494 */
/* index 8930 */
0x00C6, 0x0110, 0xFFFD, 0x0126, 0xFFFD, 0x0132, 0xFFFD,
0x0141, 0x013F, 0xFFFD, 0x014A, 0x00D8, 0x0152, 0xFFFD, 0x0166,
0x00DE, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
@ -1437,7 +1319,7 @@ static const uint16_t gJapaneseMap[] = {
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* index 9588 */
/* index 9024 */
0x00C1, 0x00C0, 0x00C4, 0x00C2, 0x0102, 0x01CD, 0x0100,
0x0104, 0x00C5, 0x00C3, 0x0106, 0x0108, 0x010C, 0x00C7, 0x010A,
0x010E, 0x00C9, 0x00C8, 0x00CB, 0x00CA, 0x011A, 0x0116, 0x0112,
@ -1450,7 +1332,7 @@ static const uint16_t gJapaneseMap[] = {
0x0170, 0x016A, 0x0172, 0x016E, 0x0168, 0x01D7, 0x01DB, 0x01D9,
0x01D5, 0x0174, 0x00DD, 0x0178, 0x0176, 0x0179, 0x017D, 0x017B,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* index 9682 */
/* index 9118 */
0x00E1, 0x00E0, 0x00E4, 0x00E2, 0x0103, 0x01CE, 0x0101,
0x0105, 0x00E5, 0x00E3, 0x0107, 0x0109, 0x010D, 0x00E7, 0x010B,
0x010F, 0x00E9, 0x00E8, 0x00EB, 0x00EA, 0x011B, 0x0117, 0x0113,
@ -1463,7 +1345,7 @@ static const uint16_t gJapaneseMap[] = {
0x0171, 0x016B, 0x0173, 0x016F, 0x0169, 0x01D8, 0x01DC, 0x01DA,
0x01D6, 0x0175, 0x00FD, 0x00FF, 0x0177, 0x017A, 0x017E, 0x017C,
0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* index 9776 */
/* index 9212 */
0x4E02, 0x4E04, 0x4E05, 0x4E0C, 0x4E12, 0x4E1F, 0x4E23,
0x4E24, 0x4E28, 0x4E2B, 0x4E2E, 0x4E2F, 0x4E30, 0x4E35, 0x4E40,
0x4E41, 0x4E44, 0x4E47, 0x4E51, 0x4E5A, 0x4E5C, 0x4E63, 0x4E68,
@ -1476,7 +1358,7 @@ static const uint16_t gJapaneseMap[] = {
0x4F48, 0x4F49, 0x4F4B, 0x4F4C, 0x4F52, 0x4F54, 0x4F56, 0x4F58,
0x4F5F, 0x4F63, 0x4F6A, 0x4F6C, 0x4F6E, 0x4F71, 0x4F77, 0x4F78,
0x4F79, 0x4F7A, 0x4F7D, 0x4F7E, 0x4F81, 0x4F82, 0x4F84,
/* index 9870 */
/* index 9306 */
0x4F85, 0x4F89, 0x4F8A, 0x4F8C, 0x4F8E, 0x4F90, 0x4F92,
0x4F93, 0x4F94, 0x4F97, 0x4F99, 0x4F9A, 0x4F9E, 0x4F9F, 0x4FB2,
0x4FB7, 0x4FB9, 0x4FBB, 0x4FBC, 0x4FBD, 0x4FBE, 0x4FC0, 0x4FC1,
@ -1489,7 +1371,7 @@ static const uint16_t gJapaneseMap[] = {
0x5052, 0x5053, 0x5057, 0x5059, 0x505F, 0x5060, 0x5062, 0x5063,
0x5066, 0x5067, 0x506A, 0x506D, 0x5070, 0x5071, 0x503B, 0x5081,
0x5083, 0x5084, 0x5086, 0x508A, 0x508E, 0x508F, 0x5090,
/* index 9964 */
/* index 9400 */
0x5092, 0x5093, 0x5094, 0x5096, 0x509B, 0x509C, 0x509E,
0x509F, 0x50A0, 0x50A1, 0x50A2, 0x50AA, 0x50AF, 0x50B0, 0x50B9,
0x50BA, 0x50BD, 0x50C0, 0x50C3, 0x50C4, 0x50C7, 0x50CC, 0x50CE,
@ -1502,7 +1384,7 @@ static const uint16_t gJapaneseMap[] = {
0x5153, 0x5155, 0x5157, 0x5158, 0x515F, 0x5164, 0x5166, 0x517E,
0x5183, 0x5184, 0x518B, 0x518E, 0x5198, 0x519D, 0x51A1, 0x51A3,
0x51AD, 0x51B8, 0x51BA, 0x51BC, 0x51BE, 0x51BF, 0x51C2,
/* index 10058 */
/* index 9494 */
0x51C8, 0x51CF, 0x51D1, 0x51D2, 0x51D3, 0x51D5, 0x51D8,
0x51DE, 0x51E2, 0x51E5, 0x51EE, 0x51F2, 0x51F3, 0x51F4, 0x51F7,
0x5201, 0x5202, 0x5205, 0x5212, 0x5213, 0x5215, 0x5216, 0x5218,
@ -1515,7 +1397,7 @@ static const uint16_t gJapaneseMap[] = {
0x52C8, 0x52CC, 0x52CF, 0x52D1, 0x52D4, 0x52D6, 0x52DB, 0x52DC,
0x52E1, 0x52E5, 0x52E8, 0x52E9, 0x52EA, 0x52EC, 0x52F0, 0x52F1,
0x52F4, 0x52F6, 0x52F7, 0x5300, 0x5303, 0x530A, 0x530B,
/* index 10152 */
/* index 9588 */
0x530C, 0x5311, 0x5313, 0x5318, 0x531B, 0x531C, 0x531E,
0x531F, 0x5325, 0x5327, 0x5328, 0x5329, 0x532B, 0x532C, 0x532D,
0x5330, 0x5332, 0x5335, 0x533C, 0x533D, 0x533E, 0x5342, 0x534C,
@ -1528,7 +1410,7 @@ static const uint16_t gJapaneseMap[] = {
0x5427, 0x5428, 0x542A, 0x542F, 0x5431, 0x5434, 0x5435, 0x5443,
0x5444, 0x5447, 0x544D, 0x544F, 0x545E, 0x5462, 0x5464, 0x5466,
0x5467, 0x5469, 0x546B, 0x546D, 0x546E, 0x5474, 0x547F,
/* index 10246 */
/* index 9682 */
0x5481, 0x5483, 0x5485, 0x5488, 0x5489, 0x548D, 0x5491,
0x5495, 0x5496, 0x549C, 0x549F, 0x54A1, 0x54A6, 0x54A7, 0x54A9,
0x54AA, 0x54AD, 0x54AE, 0x54B1, 0x54B7, 0x54B9, 0x54BA, 0x54BB,
@ -1541,7 +1423,7 @@ static const uint16_t gJapaneseMap[] = {
0x5586, 0x5588, 0x558E, 0x558F, 0x5591, 0x5592, 0x5593, 0x5594,
0x5597, 0x55A3, 0x55A4, 0x55AD, 0x55B2, 0x55BF, 0x55C1, 0x55C3,
0x55C6, 0x55C9, 0x55CB, 0x55CC, 0x55CE, 0x55D1, 0x55D2,
/* index 10340 */
/* index 9776 */
0x55D3, 0x55D7, 0x55D8, 0x55DB, 0x55DE, 0x55E2, 0x55E9,
0x55F6, 0x55FF, 0x5605, 0x5608, 0x560A, 0x560D, 0x560E, 0x560F,
0x5610, 0x5611, 0x5612, 0x5619, 0x562C, 0x5630, 0x5633, 0x5635,
@ -1554,7 +1436,7 @@ static const uint16_t gJapaneseMap[] = {
0x56B7, 0x56BE, 0x56C5, 0x56C9, 0x56CA, 0x56CB, 0x56CF, 0x56D0,
0x56CC, 0x56CD, 0x56D9, 0x56DC, 0x56DD, 0x56DF, 0x56E1, 0x56E4,
0x56E5, 0x56E6, 0x56E7, 0x56E8, 0x56F1, 0x56EB, 0x56ED,
/* index 10434 */
/* index 9870 */
0x56F6, 0x56F7, 0x5701, 0x5702, 0x5707, 0x570A, 0x570C,
0x5711, 0x5715, 0x571A, 0x571B, 0x571D, 0x5720, 0x5722, 0x5723,
0x5724, 0x5725, 0x5729, 0x572A, 0x572C, 0x572E, 0x572F, 0x5733,
@ -1567,7 +1449,7 @@ static const uint16_t gJapaneseMap[] = {
0x57C8, 0x57CC, 0x57CF, 0x57D5, 0x57DD, 0x57DE, 0x57E4, 0x57E6,
0x57E7, 0x57E9, 0x57ED, 0x57F0, 0x57F5, 0x57F6, 0x57F8, 0x57FD,
0x57FE, 0x57FF, 0x5803, 0x5804, 0x5808, 0x5809, 0x57E1,
/* index 10528 */
/* index 9964 */
0x580C, 0x580D, 0x581B, 0x581E, 0x581F, 0x5820, 0x5826,
0x5827, 0x582D, 0x5832, 0x5839, 0x583F, 0x5849, 0x584C, 0x584D,
0x584F, 0x5850, 0x5855, 0x585F, 0x5861, 0x5864, 0x5867, 0x5868,
@ -1580,7 +1462,7 @@ static const uint16_t gJapaneseMap[] = {
0x5921, 0x5923, 0x5924, 0x5928, 0x592F, 0x5930, 0x5933, 0x5935,
0x5936, 0x593F, 0x5943, 0x5946, 0x5952, 0x5953, 0x5959, 0x595B,
0x595D, 0x595E, 0x595F, 0x5961, 0x5963, 0x596B, 0x596D,
/* index 10622 */
/* index 10058 */
0x596F, 0x5972, 0x5975, 0x5976, 0x5979, 0x597B, 0x597C,
0x598B, 0x598C, 0x598E, 0x5992, 0x5995, 0x5997, 0x599F, 0x59A4,
0x59A7, 0x59AD, 0x59AE, 0x59AF, 0x59B0, 0x59B3, 0x59B7, 0x59BA,
@ -1593,7 +1475,7 @@ static const uint16_t gJapaneseMap[] = {
0x5A7A, 0x5A7B, 0x5A7E, 0x5A8B, 0x5A90, 0x5A93, 0x5A96, 0x5A99,
0x5A9C, 0x5A9E, 0x5A9F, 0x5AA0, 0x5AA2, 0x5AA7, 0x5AAC, 0x5AB1,
0x5AB2, 0x5AB3, 0x5AB5, 0x5AB8, 0x5ABA, 0x5ABB, 0x5ABF,
/* index 10716 */
/* index 10152 */
0x5AC4, 0x5AC6, 0x5AC8, 0x5ACF, 0x5ADA, 0x5ADC, 0x5AE0,
0x5AE5, 0x5AEA, 0x5AEE, 0x5AF5, 0x5AF6, 0x5AFD, 0x5B00, 0x5B01,
0x5B08, 0x5B17, 0x5B34, 0x5B19, 0x5B1B, 0x5B1D, 0x5B21, 0x5B25,
@ -1606,7 +1488,7 @@ static const uint16_t gJapaneseMap[] = {
0x5BFD, 0x5C0C, 0x5C17, 0x5C1E, 0x5C1F, 0x5C23, 0x5C26, 0x5C29,
0x5C2B, 0x5C2C, 0x5C2E, 0x5C30, 0x5C32, 0x5C35, 0x5C36, 0x5C59,
0x5C5A, 0x5C5C, 0x5C62, 0x5C63, 0x5C67, 0x5C68, 0x5C69,
/* index 10810 */
/* index 10246 */
0x5C6D, 0x5C70, 0x5C74, 0x5C75, 0x5C7A, 0x5C7B, 0x5C7C,
0x5C7D, 0x5C87, 0x5C88, 0x5C8A, 0x5C8F, 0x5C92, 0x5C9D, 0x5C9F,
0x5CA0, 0x5CA2, 0x5CA3, 0x5CA6, 0x5CAA, 0x5CB2, 0x5CB4, 0x5CB5,
@ -1619,7 +1501,7 @@ static const uint16_t gJapaneseMap[] = {
0x5D92, 0x5D93, 0x5D94, 0x5D95, 0x5D99, 0x5D9B, 0x5D9F, 0x5DA0,
0x5DA7, 0x5DAB, 0x5DB0, 0x5DB4, 0x5DB8, 0x5DB9, 0x5DC3, 0x5DC7,
0x5DCB, 0x5DD0, 0x5DCE, 0x5DD8, 0x5DD9, 0x5DE0, 0x5DE4,
/* index 10904 */
/* index 10340 */
0x5DE9, 0x5DF8, 0x5DF9, 0x5E00, 0x5E07, 0x5E0D, 0x5E12,
0x5E14, 0x5E15, 0x5E18, 0x5E1F, 0x5E20, 0x5E2E, 0x5E28, 0x5E32,
0x5E35, 0x5E3E, 0x5E4B, 0x5E50, 0x5E49, 0x5E51, 0x5E56, 0x5E58,
@ -1632,7 +1514,7 @@ static const uint16_t gJapaneseMap[] = {
0x5F28, 0x5F2B, 0x5F2C, 0x5F2E, 0x5F30, 0x5F34, 0x5F36, 0x5F3B,
0x5F3D, 0x5F3F, 0x5F40, 0x5F44, 0x5F45, 0x5F47, 0x5F4D, 0x5F50,
0x5F54, 0x5F58, 0x5F5B, 0x5F60, 0x5F63, 0x5F64, 0x5F67,
/* index 10998 */
/* index 10434 */
0x5F6F, 0x5F72, 0x5F74, 0x5F75, 0x5F78, 0x5F7A, 0x5F7D,
0x5F7E, 0x5F89, 0x5F8D, 0x5F8F, 0x5F96, 0x5F9C, 0x5F9D, 0x5FA2,
0x5FA7, 0x5FAB, 0x5FA4, 0x5FAC, 0x5FAF, 0x5FB0, 0x5FB1, 0x5FB8,
@ -1645,7 +1527,7 @@ static const uint16_t gJapaneseMap[] = {
0x6061, 0x6067, 0x6071, 0x607E, 0x607F, 0x6082, 0x6086, 0x6088,
0x608A, 0x608E, 0x6091, 0x6093, 0x6095, 0x6098, 0x609D, 0x609E,
0x60A2, 0x60A4, 0x60A5, 0x60A8, 0x60B0, 0x60B1, 0x60B7,
/* index 11092 */
/* index 10528 */
0x60BB, 0x60BE, 0x60C2, 0x60C4, 0x60C8, 0x60C9, 0x60CA,
0x60CB, 0x60CE, 0x60CF, 0x60D4, 0x60D5, 0x60D9, 0x60DB, 0x60DD,
0x60DE, 0x60E2, 0x60E5, 0x60F2, 0x60F5, 0x60F8, 0x60FC, 0x60FD,
@ -1658,7 +1540,7 @@ static const uint16_t gJapaneseMap[] = {
0x61A0, 0x61A5, 0x61A8, 0x61AA, 0x61AD, 0x61B8, 0x61B9, 0x61BC,
0x61C0, 0x61C1, 0x61C2, 0x61CE, 0x61CF, 0x61D5, 0x61DC, 0x61DD,
0x61DE, 0x61DF, 0x61E1, 0x61E2, 0x61E7, 0x61E9, 0x61E5,
/* index 11186 */
/* index 10622 */
0x61EC, 0x61ED, 0x61EF, 0x6201, 0x6203, 0x6204, 0x6207,
0x6213, 0x6215, 0x621C, 0x6220, 0x6222, 0x6223, 0x6227, 0x6229,
0x622B, 0x6239, 0x623D, 0x6242, 0x6243, 0x6244, 0x6246, 0x624C,
@ -1671,7 +1553,7 @@ static const uint16_t gJapaneseMap[] = {
0x6336, 0x6339, 0x633C, 0x6341, 0x6342, 0x6343, 0x6344, 0x6346,
0x634A, 0x634B, 0x634E, 0x6352, 0x6353, 0x6354, 0x6358, 0x635B,
0x6365, 0x6366, 0x636C, 0x636D, 0x6371, 0x6374, 0x6375,
/* index 11280 */
/* index 10716 */
0x6378, 0x637C, 0x637D, 0x637F, 0x6382, 0x6384, 0x6387,
0x638A, 0x6390, 0x6394, 0x6395, 0x6399, 0x639A, 0x639E, 0x63A4,
0x63A6, 0x63AD, 0x63AE, 0x63AF, 0x63BD, 0x63C1, 0x63C5, 0x63C8,
@ -1684,7 +1566,7 @@ static const uint16_t gJapaneseMap[] = {
0x6473, 0x6474, 0x647B, 0x647D, 0x6485, 0x6487, 0x648F, 0x6490,
0x6491, 0x6498, 0x6499, 0x649B, 0x649D, 0x649F, 0x64A1, 0x64A3,
0x64A6, 0x64A8, 0x64AC, 0x64B3, 0x64BD, 0x64BE, 0x64BF,
/* index 11374 */
/* index 10810 */
0x64C4, 0x64C9, 0x64CA, 0x64CB, 0x64CC, 0x64CE, 0x64D0,
0x64D1, 0x64D5, 0x64D7, 0x64E4, 0x64E5, 0x64E9, 0x64EA, 0x64ED,
0x64F0, 0x64F5, 0x64F7, 0x64FB, 0x64FF, 0x6501, 0x6504, 0x6508,
@ -1697,7 +1579,7 @@ static const uint16_t gJapaneseMap[] = {
0x65CE, 0x65D0, 0x65D4, 0x65D6, 0x65D8, 0x65DF, 0x65F0, 0x65F2,
0x65F4, 0x65F5, 0x65F9, 0x65FE, 0x65FF, 0x6600, 0x6604, 0x6608,
0x6609, 0x660D, 0x6611, 0x6612, 0x6615, 0x6616, 0x661D,
/* index 11468 */
/* index 10904 */
0x661E, 0x6621, 0x6622, 0x6623, 0x6624, 0x6626, 0x6629,
0x662A, 0x662B, 0x662C, 0x662E, 0x6630, 0x6631, 0x6633, 0x6639,
0x6637, 0x6640, 0x6645, 0x6646, 0x664A, 0x664C, 0x6651, 0x664E,
@ -1710,7 +1592,7 @@ static const uint16_t gJapaneseMap[] = {
0x66DF, 0x66E8, 0x66EB, 0x66EC, 0x66EE, 0x66FA, 0x6705, 0x6707,
0x670E, 0x6713, 0x6719, 0x671C, 0x6720, 0x6722, 0x6733, 0x673E,
0x6745, 0x6747, 0x6748, 0x674C, 0x6754, 0x6755, 0x675D,
/* index 11562 */
/* index 10998 */
0x6766, 0x676C, 0x676E, 0x6774, 0x6776, 0x677B, 0x6781,
0x6784, 0x678E, 0x678F, 0x6791, 0x6793, 0x6796, 0x6798, 0x6799,
0x679B, 0x67B0, 0x67B1, 0x67B2, 0x67B5, 0x67BB, 0x67BC, 0x67BD,
@ -1723,7 +1605,7 @@ static const uint16_t gJapaneseMap[] = {
0x687A, 0x687B, 0x687C, 0x6882, 0x6884, 0x6886, 0x6888, 0x6896,
0x6898, 0x689A, 0x689C, 0x68A1, 0x68A3, 0x68A5, 0x68A9, 0x68AA,
0x68AE, 0x68B2, 0x68BB, 0x68C5, 0x68C8, 0x68CC, 0x68CF,
/* index 11656 */
/* index 11092 */
0x68D0, 0x68D1, 0x68D3, 0x68D6, 0x68D9, 0x68DC, 0x68DD,
0x68E5, 0x68E8, 0x68EA, 0x68EB, 0x68EC, 0x68ED, 0x68F0, 0x68F1,
0x68F5, 0x68F6, 0x68FB, 0x68FC, 0x68FD, 0x6906, 0x6909, 0x690A,
@ -1736,7 +1618,7 @@ static const uint16_t gJapaneseMap[] = {
0x69D6, 0x69D7, 0x69E2, 0x69E5, 0x69EE, 0x69EF, 0x69F1, 0x69F3,
0x69F5, 0x69FE, 0x6A00, 0x6A01, 0x6A03, 0x6A0F, 0x6A11, 0x6A15,
0x6A1A, 0x6A1D, 0x6A20, 0x6A24, 0x6A28, 0x6A30, 0x6A32,
/* index 11750 */
/* index 11186 */
0x6A34, 0x6A37, 0x6A3B, 0x6A3E, 0x6A3F, 0x6A45, 0x6A46,
0x6A49, 0x6A4A, 0x6A4E, 0x6A50, 0x6A51, 0x6A52, 0x6A55, 0x6A56,
0x6A5B, 0x6A64, 0x6A67, 0x6A6A, 0x6A71, 0x6A73, 0x6A7E, 0x6A81,
@ -1749,7 +1631,7 @@ static const uint16_t gJapaneseMap[] = {
0x6B24, 0x6B28, 0x6B2B, 0x6B2C, 0x6B2F, 0x6B35, 0x6B36, 0x6B3B,
0x6B3F, 0x6B46, 0x6B4A, 0x6B4D, 0x6B52, 0x6B56, 0x6B58, 0x6B5D,
0x6B60, 0x6B67, 0x6B6B, 0x6B6E, 0x6B70, 0x6B75, 0x6B7D,
/* index 11844 */
/* index 11280 */
0x6B7E, 0x6B82, 0x6B85, 0x6B97, 0x6B9B, 0x6B9F, 0x6BA0,
0x6BA2, 0x6BA3, 0x6BA8, 0x6BA9, 0x6BAC, 0x6BAD, 0x6BAE, 0x6BB0,
0x6BB8, 0x6BB9, 0x6BBD, 0x6BBE, 0x6BC3, 0x6BC4, 0x6BC9, 0x6BCC,
@ -1762,7 +1644,7 @@ static const uint16_t gJapaneseMap[] = {
0x6C7B, 0x6C85, 0x6C86, 0x6C87, 0x6C89, 0x6C94, 0x6C95, 0x6C97,
0x6C98, 0x6C9C, 0x6C9F, 0x6CB0, 0x6CB2, 0x6CB4, 0x6CC2, 0x6CC6,
0x6CCD, 0x6CCF, 0x6CD0, 0x6CD1, 0x6CD2, 0x6CD4, 0x6CD6,
/* index 11938 */
/* index 11374 */
0x6CDA, 0x6CDC, 0x6CE0, 0x6CE7, 0x6CE9, 0x6CEB, 0x6CEC,
0x6CEE, 0x6CF2, 0x6CF4, 0x6D04, 0x6D07, 0x6D0A, 0x6D0E, 0x6D0F,
0x6D11, 0x6D13, 0x6D1A, 0x6D26, 0x6D27, 0x6D28, 0x6C67, 0x6D2E,
@ -1775,7 +1657,7 @@ static const uint16_t gJapaneseMap[] = {
0x6E04, 0x6E1E, 0x6E22, 0x6E27, 0x6E32, 0x6E36, 0x6E39, 0x6E3B,
0x6E3C, 0x6E44, 0x6E45, 0x6E48, 0x6E49, 0x6E4B, 0x6E4F, 0x6E51,
0x6E52, 0x6E53, 0x6E54, 0x6E57, 0x6E5C, 0x6E5D, 0x6E5E,
/* index 12032 */
/* index 11468 */
0x6E62, 0x6E63, 0x6E68, 0x6E73, 0x6E7B, 0x6E7D, 0x6E8D,
0x6E93, 0x6E99, 0x6EA0, 0x6EA7, 0x6EAD, 0x6EAE, 0x6EB1, 0x6EB3,
0x6EBB, 0x6EBF, 0x6EC0, 0x6EC1, 0x6EC3, 0x6EC7, 0x6EC8, 0x6ECA,
@ -1788,7 +1670,7 @@ static const uint16_t gJapaneseMap[] = {
0x6F8D, 0x6F90, 0x6F92, 0x6F93, 0x6F94, 0x6F96, 0x6F9A, 0x6F9F,
0x6FA0, 0x6FA5, 0x6FA6, 0x6FA7, 0x6FA8, 0x6FAE, 0x6FAF, 0x6FB0,
0x6FB5, 0x6FB6, 0x6FBC, 0x6FC5, 0x6FC7, 0x6FC8, 0x6FCA,
/* index 12126 */
/* index 11562 */
0x6FDA, 0x6FDE, 0x6FE8, 0x6FE9, 0x6FF0, 0x6FF5, 0x6FF9,
0x6FFC, 0x6FFD, 0x7000, 0x7005, 0x7006, 0x7007, 0x700D, 0x7017,
0x7020, 0x7023, 0x702F, 0x7034, 0x7037, 0x7039, 0x703C, 0x7043,
@ -1801,7 +1683,7 @@ static const uint16_t gJapaneseMap[] = {
0x710C, 0x710F, 0x711E, 0x7120, 0x712B, 0x712D, 0x712F, 0x7130,
0x7131, 0x7138, 0x7141, 0x7145, 0x7146, 0x7147, 0x714A, 0x714B,
0x7150, 0x7152, 0x7157, 0x715A, 0x715C, 0x715E, 0x7160,
/* index 12220 */
/* index 11656 */
0x7168, 0x7179, 0x7180, 0x7185, 0x7187, 0x718C, 0x7192,
0x719A, 0x719B, 0x71A0, 0x71A2, 0x71AF, 0x71B0, 0x71B2, 0x71B3,
0x71BA, 0x71BF, 0x71C0, 0x71C1, 0x71C4, 0x71CB, 0x71CC, 0x71D3,
@ -1814,7 +1696,7 @@ static const uint16_t gJapaneseMap[] = {
0x728D, 0x728E, 0x7293, 0x729B, 0x72A8, 0x72AD, 0x72AE, 0x72B1,
0x72B4, 0x72BE, 0x72C1, 0x72C7, 0x72C9, 0x72CC, 0x72D5, 0x72D6,
0x72D8, 0x72DF, 0x72E5, 0x72F3, 0x72F4, 0x72FA, 0x72FB,
/* index 12314 */
/* index 11750 */
0x72FE, 0x7302, 0x7304, 0x7305, 0x7307, 0x730B, 0x730D,
0x7312, 0x7313, 0x7318, 0x7319, 0x731E, 0x7322, 0x7324, 0x7327,
0x7328, 0x732C, 0x7331, 0x7332, 0x7335, 0x733A, 0x733B, 0x733D,
@ -1827,7 +1709,7 @@ static const uint16_t gJapaneseMap[] = {
0x73C5, 0x73C6, 0x73C9, 0x73CB, 0x73CC, 0x73CF, 0x73D2, 0x73D3,
0x73D6, 0x73D9, 0x73DD, 0x73E1, 0x73E3, 0x73E6, 0x73E7, 0x73E9,
0x73F4, 0x73F5, 0x73F7, 0x73F9, 0x73FA, 0x73FB, 0x73FD,
/* index 12408 */
/* index 11844 */
0x73FF, 0x7400, 0x7401, 0x7404, 0x7407, 0x740A, 0x7411,
0x741A, 0x741B, 0x7424, 0x7426, 0x7428, 0x7429, 0x742A, 0x742B,
0x742C, 0x742D, 0x742E, 0x742F, 0x7430, 0x7431, 0x7439, 0x7440,
@ -1840,7 +1722,7 @@ static const uint16_t gJapaneseMap[] = {
0x74BB, 0x74BF, 0x74C8, 0x74C9, 0x74CC, 0x74D0, 0x74D3, 0x74D8,
0x74DA, 0x74DB, 0x74DE, 0x74DF, 0x74E4, 0x74E8, 0x74EA, 0x74EB,
0x74EF, 0x74F4, 0x74FA, 0x74FB, 0x74FC, 0x74FF, 0x7506,
/* index 12502 */
/* index 11938 */
0x7512, 0x7516, 0x7517, 0x7520, 0x7521, 0x7524, 0x7527,
0x7529, 0x752A, 0x752F, 0x7536, 0x7539, 0x753D, 0x753E, 0x753F,
0x7540, 0x7543, 0x7547, 0x7548, 0x754E, 0x7550, 0x7552, 0x7557,
@ -1853,7 +1735,7 @@ static const uint16_t gJapaneseMap[] = {
0x7608, 0x760A, 0x760C, 0x760F, 0x7612, 0x7613, 0x7615, 0x7616,
0x7619, 0x761B, 0x761C, 0x761D, 0x761E, 0x7623, 0x7625, 0x7626,
0x7629, 0x762D, 0x7632, 0x7633, 0x7635, 0x7638, 0x7639,
/* index 12596 */
/* index 12032 */
0x763A, 0x763C, 0x764A, 0x7640, 0x7641, 0x7643, 0x7644,
0x7645, 0x7649, 0x764B, 0x7655, 0x7659, 0x765F, 0x7664, 0x7665,
0x766D, 0x766E, 0x766F, 0x7671, 0x7674, 0x7681, 0x7685, 0x768C,
@ -1866,7 +1748,7 @@ static const uint16_t gJapaneseMap[] = {
0x772E, 0x772F, 0x7734, 0x7735, 0x7736, 0x7739, 0x773D, 0x773E,
0x7742, 0x7745, 0x7746, 0x774A, 0x774D, 0x774E, 0x774F, 0x7752,
0x7756, 0x7757, 0x775C, 0x775E, 0x775F, 0x7760, 0x7762,
/* index 12690 */
/* index 12126 */
0x7764, 0x7767, 0x776A, 0x776C, 0x7770, 0x7772, 0x7773,
0x7774, 0x777A, 0x777D, 0x7780, 0x7784, 0x778C, 0x778D, 0x7794,
0x7795, 0x7796, 0x779A, 0x779F, 0x77A2, 0x77A7, 0x77AA, 0x77AE,
@ -1879,7 +1761,7 @@ static const uint16_t gJapaneseMap[] = {
0x7863, 0x7864, 0x7868, 0x786A, 0x786E, 0x787A, 0x787E, 0x788A,
0x788F, 0x7894, 0x7898, 0x78A1, 0x789D, 0x789E, 0x789F, 0x78A4,
0x78A8, 0x78AC, 0x78AD, 0x78B0, 0x78B1, 0x78B2, 0x78B3,
/* index 12784 */
/* index 12220 */
0x78BB, 0x78BD, 0x78BF, 0x78C7, 0x78C8, 0x78C9, 0x78CC,
0x78CE, 0x78D2, 0x78D3, 0x78D5, 0x78D6, 0x78E4, 0x78DB, 0x78DF,
0x78E0, 0x78E1, 0x78E6, 0x78EA, 0x78F2, 0x78F3, 0x7900, 0x78F6,
@ -1892,7 +1774,7 @@ static const uint16_t gJapaneseMap[] = {
0x7998, 0x799B, 0x799C, 0x79A1, 0x79A8, 0x79A9, 0x79AB, 0x79AF,
0x79B1, 0x79B4, 0x79B8, 0x79BB, 0x79C2, 0x79C4, 0x79C7, 0x79C8,
0x79CA, 0x79CF, 0x79D4, 0x79D6, 0x79DA, 0x79DD, 0x79DE,
/* index 12878 */
/* index 12314 */
0x79E0, 0x79E2, 0x79E5, 0x79EA, 0x79EB, 0x79ED, 0x79F1,
0x79F8, 0x79FC, 0x7A02, 0x7A03, 0x7A07, 0x7A09, 0x7A0A, 0x7A0C,
0x7A11, 0x7A15, 0x7A1B, 0x7A1E, 0x7A21, 0x7A27, 0x7A2B, 0x7A2D,
@ -1905,7 +1787,7 @@ static const uint16_t gJapaneseMap[] = {
0x7AD1, 0x7ADB, 0x7AE8, 0x7AE9, 0x7AEB, 0x7AEC, 0x7AF1, 0x7AF4,
0x7AFB, 0x7AFD, 0x7AFE, 0x7B07, 0x7B14, 0x7B1F, 0x7B23, 0x7B27,
0x7B29, 0x7B2A, 0x7B2B, 0x7B2D, 0x7B2E, 0x7B2F, 0x7B30,
/* index 12972 */
/* index 12408 */
0x7B31, 0x7B34, 0x7B3D, 0x7B3F, 0x7B40, 0x7B41, 0x7B47,
0x7B4E, 0x7B55, 0x7B60, 0x7B64, 0x7B66, 0x7B69, 0x7B6A, 0x7B6D,
0x7B6F, 0x7B72, 0x7B73, 0x7B77, 0x7B84, 0x7B89, 0x7B8E, 0x7B90,
@ -1918,7 +1800,7 @@ static const uint16_t gJapaneseMap[] = {
0x7C20, 0x7C25, 0x7C26, 0x7C28, 0x7C2C, 0x7C31, 0x7C33, 0x7C34,
0x7C36, 0x7C39, 0x7C3A, 0x7C46, 0x7C4A, 0x7C55, 0x7C51, 0x7C52,
0x7C53, 0x7C59, 0x7C5A, 0x7C5B, 0x7C5C, 0x7C5D, 0x7C5E,
/* index 13066 */
/* index 12502 */
0x7C61, 0x7C63, 0x7C67, 0x7C69, 0x7C6D, 0x7C6E, 0x7C70,
0x7C72, 0x7C79, 0x7C7C, 0x7C7D, 0x7C86, 0x7C87, 0x7C8F, 0x7C94,
0x7C9E, 0x7CA0, 0x7CA6, 0x7CB0, 0x7CB6, 0x7CB7, 0x7CBA, 0x7CBB,
@ -1931,7 +1813,7 @@ static const uint16_t gJapaneseMap[] = {
0x7D5C, 0x7D5D, 0x7D65, 0x7D67, 0x7D6A, 0x7D70, 0x7D78, 0x7D7A,
0x7D7B, 0x7D7F, 0x7D81, 0x7D82, 0x7D83, 0x7D85, 0x7D86, 0x7D88,
0x7D8B, 0x7D8C, 0x7D8D, 0x7D91, 0x7D96, 0x7D97, 0x7D9D,
/* index 13160 */
/* index 12596 */
0x7D9E, 0x7DA6, 0x7DA7, 0x7DAA, 0x7DB3, 0x7DB6, 0x7DB7,
0x7DB9, 0x7DC2, 0x7DC3, 0x7DC4, 0x7DC5, 0x7DC6, 0x7DCC, 0x7DCD,
0x7DCE, 0x7DD7, 0x7DD9, 0x7E00, 0x7DE2, 0x7DE5, 0x7DE6, 0x7DEA,
@ -1944,7 +1826,7 @@ static const uint16_t gJapaneseMap[] = {
0x7E9A, 0x7E9D, 0x7E9E, 0x7F3C, 0x7F3B, 0x7F3D, 0x7F3E, 0x7F3F,
0x7F43, 0x7F44, 0x7F47, 0x7F4F, 0x7F52, 0x7F53, 0x7F5B, 0x7F5C,
0x7F5D, 0x7F61, 0x7F63, 0x7F64, 0x7F65, 0x7F66, 0x7F6D,
/* index 13254 */
/* index 12690 */
0x7F71, 0x7F7D, 0x7F7E, 0x7F7F, 0x7F80, 0x7F8B, 0x7F8D,
0x7F8F, 0x7F90, 0x7F91, 0x7F96, 0x7F97, 0x7F9C, 0x7FA1, 0x7FA2,
0x7FA6, 0x7FAA, 0x7FAD, 0x7FB4, 0x7FBC, 0x7FBF, 0x7FC0, 0x7FC3,
@ -1957,7 +1839,7 @@ static const uint16_t gJapaneseMap[] = {
0x8071, 0x8075, 0x8081, 0x8088, 0x808E, 0x809C, 0x809E, 0x80A6,
0x80A7, 0x80AB, 0x80B8, 0x80B9, 0x80C8, 0x80CD, 0x80CF, 0x80D2,
0x80D4, 0x80D5, 0x80D7, 0x80D8, 0x80E0, 0x80ED, 0x80EE,
/* index 13348 */
/* index 12784 */
0x80F0, 0x80F2, 0x80F3, 0x80F6, 0x80F9, 0x80FA, 0x80FE,
0x8103, 0x810B, 0x8116, 0x8117, 0x8118, 0x811C, 0x811E, 0x8120,
0x8124, 0x8127, 0x812C, 0x8130, 0x8135, 0x813A, 0x813C, 0x8145,
@ -1970,7 +1852,7 @@ static const uint16_t gJapaneseMap[] = {
0x81F6, 0x81F8, 0x81F9, 0x81FD, 0x81FF, 0x8200, 0x8203, 0x820F,
0x8213, 0x8214, 0x8219, 0x821A, 0x821D, 0x8221, 0x8222, 0x8228,
0x8232, 0x8234, 0x823A, 0x8243, 0x8244, 0x8245, 0x8246,
/* index 13442 */
/* index 12878 */
0x824B, 0x824E, 0x824F, 0x8251, 0x8256, 0x825C, 0x8260,
0x8263, 0x8267, 0x826D, 0x8274, 0x827B, 0x827D, 0x827F, 0x8280,
0x8281, 0x8283, 0x8284, 0x8287, 0x8289, 0x828A, 0x828E, 0x8291,
@ -1983,7 +1865,7 @@ static const uint16_t gJapaneseMap[] = {
0x8321, 0x8322, 0x832C, 0x832D, 0x832E, 0x8330, 0x8333, 0x8337,
0x833A, 0x833C, 0x833D, 0x8342, 0x8343, 0x8344, 0x8347, 0x834D,
0x834E, 0x8351, 0x8355, 0x8356, 0x8357, 0x8370, 0x8378,
/* index 13536 */
/* index 12972 */
0x837D, 0x837F, 0x8380, 0x8382, 0x8384, 0x8386, 0x838D,
0x8392, 0x8394, 0x8395, 0x8398, 0x8399, 0x839B, 0x839C, 0x839D,
0x83A6, 0x83A7, 0x83A9, 0x83AC, 0x83BE, 0x83BF, 0x83C0, 0x83C7,
@ -1996,7 +1878,7 @@ static const uint16_t gJapaneseMap[] = {
0x8481, 0x8485, 0x8492, 0x8493, 0x8495, 0x849E, 0x84A6, 0x84A8,
0x84A9, 0x84AA, 0x84AF, 0x84B1, 0x84B4, 0x84BA, 0x84BD, 0x84BE,
0x84C0, 0x84C2, 0x84C7, 0x84C8, 0x84CC, 0x84CF, 0x84D3,
/* index 13630 */
/* index 13066 */
0x84DC, 0x84E7, 0x84EA, 0x84EF, 0x84F0, 0x84F1, 0x84F2,
0x84F7, 0x8532, 0x84FA, 0x84FB, 0x84FD, 0x8502, 0x8503, 0x8507,
0x850C, 0x850E, 0x8510, 0x851C, 0x851E, 0x8522, 0x8523, 0x8524,
@ -2009,7 +1891,7 @@ static const uint16_t gJapaneseMap[] = {
0x85B6, 0x85B7, 0x85B8, 0x85BC, 0x85BD, 0x85BE, 0x85BF, 0x85C2,
0x85C7, 0x85CA, 0x85CB, 0x85CE, 0x85AD, 0x85D8, 0x85DA, 0x85DF,
0x85E0, 0x85E6, 0x85E8, 0x85ED, 0x85F3, 0x85F6, 0x85FC,
/* index 13724 */
/* index 13160 */
0x85FF, 0x8600, 0x8604, 0x8605, 0x860D, 0x860E, 0x8610,
0x8611, 0x8612, 0x8618, 0x8619, 0x861B, 0x861E, 0x8621, 0x8627,
0x8629, 0x8636, 0x8638, 0x863A, 0x863C, 0x863D, 0x8640, 0x8642,
@ -2022,7 +1904,7 @@ static const uint16_t gJapaneseMap[] = {
0x86DC, 0x86E0, 0x86E3, 0x86E5, 0x86E7, 0x8688, 0x86FA, 0x86FC,
0x86FD, 0x8704, 0x8705, 0x8707, 0x870B, 0x870E, 0x870F, 0x8710,
0x8713, 0x8714, 0x8719, 0x871E, 0x871F, 0x8721, 0x8723,
/* index 13818 */
/* index 13254 */
0x8728, 0x872E, 0x872F, 0x8731, 0x8732, 0x8739, 0x873A,
0x873C, 0x873D, 0x873E, 0x8740, 0x8743, 0x8745, 0x874D, 0x8758,
0x875D, 0x8761, 0x8764, 0x8765, 0x876F, 0x8771, 0x8772, 0x877B,
@ -2035,7 +1917,7 @@ static const uint16_t gJapaneseMap[] = {
0x8801, 0x8803, 0x8806, 0x8809, 0x880A, 0x880B, 0x8810, 0x8819,
0x8812, 0x8813, 0x8814, 0x8818, 0x881A, 0x881B, 0x881C, 0x881E,
0x881F, 0x8828, 0x882D, 0x882E, 0x8830, 0x8832, 0x8835,
/* index 13912 */
/* index 13348 */
0x883A, 0x883C, 0x8841, 0x8843, 0x8845, 0x8848, 0x8849,
0x884A, 0x884B, 0x884E, 0x8851, 0x8855, 0x8856, 0x8858, 0x885A,
0x885C, 0x885F, 0x8860, 0x8864, 0x8869, 0x8871, 0x8879, 0x887B,
@ -2048,7 +1930,7 @@ static const uint16_t gJapaneseMap[] = {
0x8939, 0x893A, 0x893E, 0x8940, 0x8942, 0x8945, 0x8946, 0x8949,
0x894F, 0x8952, 0x8957, 0x895A, 0x895B, 0x895C, 0x8961, 0x8962,
0x8963, 0x896B, 0x896E, 0x8970, 0x8973, 0x8975, 0x897A,
/* index 14006 */
/* index 13442 */
0x897B, 0x897C, 0x897D, 0x8989, 0x898D, 0x8990, 0x8994,
0x8995, 0x899B, 0x899C, 0x899F, 0x89A0, 0x89A5, 0x89B0, 0x89B4,
0x89B5, 0x89B6, 0x89B7, 0x89BC, 0x89D4, 0x89D5, 0x89D6, 0x89D7,
@ -2061,7 +1943,7 @@ static const uint16_t gJapaneseMap[] = {
0x8A76, 0x8A77, 0x8A79, 0x8A7A, 0x8A7B, 0x8A7E, 0x8A7F, 0x8A80,
0x8A83, 0x8A86, 0x8A8B, 0x8A8F, 0x8A90, 0x8A92, 0x8A96, 0x8A97,
0x8A99, 0x8A9F, 0x8AA7, 0x8AA9, 0x8AAE, 0x8AAF, 0x8AB3,
/* index 14100 */
/* index 13536 */
0x8AB6, 0x8AB7, 0x8ABB, 0x8ABE, 0x8AC3, 0x8AC6, 0x8AC8,
0x8AC9, 0x8ACA, 0x8AD1, 0x8AD3, 0x8AD4, 0x8AD5, 0x8AD7, 0x8ADD,
0x8ADF, 0x8AEC, 0x8AF0, 0x8AF4, 0x8AF5, 0x8AF6, 0x8AFC, 0x8AFF,
@ -2074,7 +1956,7 @@ static const uint16_t gJapaneseMap[] = {
0x8C49, 0x8C4B, 0x8C4F, 0x8C51, 0x8C53, 0x8C54, 0x8C57, 0x8C58,
0x8C5B, 0x8C5D, 0x8C59, 0x8C63, 0x8C64, 0x8C66, 0x8C68, 0x8C69,
0x8C6D, 0x8C73, 0x8C75, 0x8C76, 0x8C7B, 0x8C7E, 0x8C86,
/* index 14194 */
/* index 13630 */
0x8C87, 0x8C8B, 0x8C90, 0x8C92, 0x8C93, 0x8C99, 0x8C9B,
0x8C9C, 0x8CA4, 0x8CB9, 0x8CBA, 0x8CC5, 0x8CC6, 0x8CC9, 0x8CCB,
0x8CCF, 0x8CD6, 0x8CD5, 0x8CD9, 0x8CDD, 0x8CE1, 0x8CE8, 0x8CEC,
@ -2087,7 +1969,7 @@ static const uint16_t gJapaneseMap[] = {
0x8DD7, 0x8DD9, 0x8DE4, 0x8DE5, 0x8DE7, 0x8DEC, 0x8DF0, 0x8DBC,
0x8DF1, 0x8DF2, 0x8DF4, 0x8DFD, 0x8E01, 0x8E04, 0x8E05, 0x8E06,
0x8E0B, 0x8E11, 0x8E14, 0x8E16, 0x8E20, 0x8E21, 0x8E22,
/* index 14288 */
/* index 13724 */
0x8E23, 0x8E26, 0x8E27, 0x8E31, 0x8E33, 0x8E36, 0x8E37,
0x8E38, 0x8E39, 0x8E3D, 0x8E40, 0x8E41, 0x8E4B, 0x8E4D, 0x8E4E,
0x8E4F, 0x8E54, 0x8E5B, 0x8E5C, 0x8E5D, 0x8E5E, 0x8E61, 0x8E62,
@ -2100,7 +1982,7 @@ static const uint16_t gJapaneseMap[] = {
0x8F08, 0x8F0F, 0x8F10, 0x8F16, 0x8F17, 0x8F18, 0x8F1E, 0x8F20,
0x8F21, 0x8F23, 0x8F25, 0x8F27, 0x8F28, 0x8F2C, 0x8F2D, 0x8F2E,
0x8F34, 0x8F35, 0x8F36, 0x8F37, 0x8F3A, 0x8F40, 0x8F41,
/* index 14382 */
/* index 13818 */
0x8F43, 0x8F47, 0x8F4F, 0x8F51, 0x8F52, 0x8F53, 0x8F54,
0x8F55, 0x8F58, 0x8F5D, 0x8F5E, 0x8F65, 0x8F9D, 0x8FA0, 0x8FA1,
0x8FA4, 0x8FA5, 0x8FA6, 0x8FB5, 0x8FB6, 0x8FB8, 0x8FBE, 0x8FC0,
@ -2113,7 +1995,7 @@ static const uint16_t gJapaneseMap[] = {
0x9088, 0x908B, 0x908C, 0x908E, 0x9090, 0x9095, 0x9097, 0x9098,
0x9099, 0x909B, 0x90A0, 0x90A1, 0x90A2, 0x90A5, 0x90B0, 0x90B2,
0x90B3, 0x90B4, 0x90B6, 0x90BD, 0x90CC, 0x90BE, 0x90C3,
/* index 14476 */
/* index 13912 */
0x90C4, 0x90C5, 0x90C7, 0x90C8, 0x90D5, 0x90D7, 0x90D8,
0x90D9, 0x90DC, 0x90DD, 0x90DF, 0x90E5, 0x90D2, 0x90F6, 0x90EB,
0x90EF, 0x90F0, 0x90F4, 0x90FE, 0x90FF, 0x9100, 0x9104, 0x9105,
@ -2126,7 +2008,7 @@ static const uint16_t gJapaneseMap[] = {
0x918A, 0x918E, 0x9191, 0x9193, 0x9194, 0x9195, 0x9198, 0x919E,
0x91A1, 0x91A6, 0x91A8, 0x91AC, 0x91AD, 0x91AE, 0x91B0, 0x91B1,
0x91B2, 0x91B3, 0x91B6, 0x91BB, 0x91BC, 0x91BD, 0x91BF,
/* index 14570 */
/* index 14006 */
0x91C2, 0x91C3, 0x91C5, 0x91D3, 0x91D4, 0x91D7, 0x91D9,
0x91DA, 0x91DE, 0x91E4, 0x91E5, 0x91E9, 0x91EA, 0x91EC, 0x91ED,
0x91EE, 0x91EF, 0x91F0, 0x91F1, 0x91F7, 0x91F9, 0x91FB, 0x91FD,
@ -2139,7 +2021,7 @@ static const uint16_t gJapaneseMap[] = {
0x9265, 0x9267, 0x9268, 0x9269, 0x926E, 0x926F, 0x9270, 0x9275,
0x9276, 0x9277, 0x9278, 0x9279, 0x927B, 0x927C, 0x927D, 0x927F,
0x9288, 0x9289, 0x928A, 0x928D, 0x928E, 0x9292, 0x9297,
/* index 14664 */
/* index 14100 */
0x9299, 0x929F, 0x92A0, 0x92A4, 0x92A5, 0x92A7, 0x92A8,
0x92AB, 0x92AF, 0x92B2, 0x92B6, 0x92B8, 0x92BA, 0x92BB, 0x92BC,
0x92BD, 0x92BF, 0x92C0, 0x92C1, 0x92C2, 0x92C3, 0x92C5, 0x92C6,
@ -2152,7 +2034,7 @@ static const uint16_t gJapaneseMap[] = {
0x9347, 0x9348, 0x9349, 0x9350, 0x9351, 0x9352, 0x9355, 0x9357,
0x9358, 0x935A, 0x935E, 0x9364, 0x9365, 0x9367, 0x9369, 0x936A,
0x936D, 0x936F, 0x9370, 0x9371, 0x9373, 0x9374, 0x9376,
/* index 14758 */
/* index 14194 */
0x937A, 0x937D, 0x937F, 0x9380, 0x9381, 0x9382, 0x9388,
0x938A, 0x938B, 0x938D, 0x938F, 0x9392, 0x9395, 0x9398, 0x939B,
0x939E, 0x93A1, 0x93A3, 0x93A4, 0x93A6, 0x93A8, 0x93AB, 0x93B4,
@ -2165,7 +2047,7 @@ static const uint16_t gJapaneseMap[] = {
0x943D, 0x9443, 0x9445, 0x9448, 0x944A, 0x944C, 0x9455, 0x9459,
0x945C, 0x945F, 0x9461, 0x9463, 0x9468, 0x946B, 0x946D, 0x946E,
0x946F, 0x9471, 0x9472, 0x9484, 0x9483, 0x9578, 0x9579,
/* index 14852 */
/* index 14288 */
0x957E, 0x9584, 0x9588, 0x958C, 0x958D, 0x958E, 0x959D,
0x959E, 0x959F, 0x95A1, 0x95A6, 0x95A9, 0x95AB, 0x95AC, 0x95B4,
0x95B6, 0x95BA, 0x95BD, 0x95BF, 0x95C6, 0x95C8, 0x95C9, 0x95CB,
@ -2178,7 +2060,7 @@ static const uint16_t gJapaneseMap[] = {
0x969D, 0x969F, 0x96A4, 0x96A5, 0x96A6, 0x96A9, 0x96AE, 0x96AF,
0x96B3, 0x96BA, 0x96CA, 0x96D2, 0x5DB2, 0x96D8, 0x96DA, 0x96DD,
0x96DE, 0x96DF, 0x96E9, 0x96EF, 0x96F1, 0x96FA, 0x9702,
/* index 14946 */
/* index 14382 */
0x9703, 0x9705, 0x9709, 0x971A, 0x971B, 0x971D, 0x9721,
0x9722, 0x9723, 0x9728, 0x9731, 0x9733, 0x9741, 0x9743, 0x974A,
0x974E, 0x974F, 0x9755, 0x9757, 0x9758, 0x975A, 0x975B, 0x9763,
@ -2191,7 +2073,7 @@ static const uint16_t gJapaneseMap[] = {
0x97DE, 0x97E0, 0x97DB, 0x97E1, 0x97E4, 0x97EF, 0x97F1, 0x97F4,
0x97F7, 0x97F8, 0x97FA, 0x9807, 0x980A, 0x9819, 0x980D, 0x980E,
0x9814, 0x9816, 0x981C, 0x981E, 0x9820, 0x9823, 0x9826,
/* index 15040 */
/* index 14476 */
0x982B, 0x982E, 0x982F, 0x9830, 0x9832, 0x9833, 0x9835,
0x9825, 0x983E, 0x9844, 0x9847, 0x984A, 0x9851, 0x9852, 0x9853,
0x9856, 0x9857, 0x9859, 0x985A, 0x9862, 0x9863, 0x9865, 0x9866,
@ -2204,7 +2086,7 @@ static const uint16_t gJapaneseMap[] = {
0x9940, 0x9941, 0x9946, 0x9947, 0x9948, 0x994D, 0x994E, 0x9954,
0x9958, 0x9959, 0x995B, 0x995C, 0x995E, 0x995F, 0x9960, 0x999B,
0x999D, 0x999F, 0x99A6, 0x99B0, 0x99B1, 0x99B2, 0x99B5,
/* index 15134 */
/* index 14570 */
0x99B9, 0x99BA, 0x99BD, 0x99BF, 0x99C3, 0x99C9, 0x99D3,
0x99D4, 0x99D9, 0x99DA, 0x99DC, 0x99DE, 0x99E7, 0x99EA, 0x99EB,
0x99EC, 0x99F0, 0x99F4, 0x99F5, 0x99F9, 0x99FD, 0x99FE, 0x9A02,
@ -2217,7 +2099,7 @@ static const uint16_t gJapaneseMap[] = {
0x9AD2, 0x9AD5, 0x9AD6, 0x9AD7, 0x9ADB, 0x9ADC, 0x9AE0, 0x9AE4,
0x9AE5, 0x9AE7, 0x9AE9, 0x9AEC, 0x9AF2, 0x9AF3, 0x9AF5, 0x9AF9,
0x9AFA, 0x9AFD, 0x9AFF, 0x9B00, 0x9B01, 0x9B02, 0x9B03,
/* index 15228 */
/* index 14664 */
0x9B04, 0x9B05, 0x9B08, 0x9B09, 0x9B0B, 0x9B0C, 0x9B0D,
0x9B0E, 0x9B10, 0x9B12, 0x9B16, 0x9B19, 0x9B1B, 0x9B1C, 0x9B20,
0x9B26, 0x9B2B, 0x9B2D, 0x9B33, 0x9B34, 0x9B35, 0x9B37, 0x9B39,
@ -2230,7 +2112,7 @@ static const uint16_t gJapaneseMap[] = {
0x9BB7, 0x9BB8, 0x9BBB, 0x9BBC, 0x9BBE, 0x9BBF, 0x9BC1, 0x9BC7,
0x9BC8, 0x9BCE, 0x9BD0, 0x9BD7, 0x9BD8, 0x9BDD, 0x9BDF, 0x9BE5,
0x9BE7, 0x9BEA, 0x9BEB, 0x9BEF, 0x9BF3, 0x9BF7, 0x9BF8,
/* index 15322 */
/* index 14758 */
0x9BF9, 0x9BFA, 0x9BFD, 0x9BFF, 0x9C00, 0x9C02, 0x9C0B,
0x9C0F, 0x9C11, 0x9C16, 0x9C18, 0x9C19, 0x9C1A, 0x9C1C, 0x9C1E,
0x9C22, 0x9C23, 0x9C26, 0x9C27, 0x9C28, 0x9C29, 0x9C2A, 0x9C31,
@ -2243,7 +2125,7 @@ static const uint16_t gJapaneseMap[] = {
0x9D33, 0x9D34, 0x9D3A, 0x9D3C, 0x9D45, 0x9D3D, 0x9D42, 0x9D43,
0x9D47, 0x9D4A, 0x9D53, 0x9D54, 0x9D5F, 0x9D63, 0x9D62, 0x9D65,
0x9D69, 0x9D6A, 0x9D6B, 0x9D70, 0x9D76, 0x9D77, 0x9D7B,
/* index 15416 */
/* index 14852 */
0x9D7C, 0x9D7E, 0x9D83, 0x9D84, 0x9D86, 0x9D8A, 0x9D8D,
0x9D8E, 0x9D92, 0x9D93, 0x9D95, 0x9D96, 0x9D97, 0x9D98, 0x9DA1,
0x9DAA, 0x9DAC, 0x9DAE, 0x9DB1, 0x9DB5, 0x9DB9, 0x9DBC, 0x9DBF,
@ -2256,7 +2138,7 @@ static const uint16_t gJapaneseMap[] = {
0x9EA4, 0x9EA8, 0x9EAC, 0x9EAE, 0x9EAF, 0x9EB0, 0x9EB3, 0x9EB4,
0x9EB5, 0x9EC6, 0x9EC8, 0x9ECB, 0x9ED5, 0x9EDF, 0x9EE4, 0x9EE7,
0x9EEC, 0x9EED, 0x9EEE, 0x9EF0, 0x9EF1, 0x9EF2, 0x9EF5,
/* index 15510 */
/* index 14946 */
0x9EF8, 0x9EFF, 0x9F02, 0x9F03, 0x9F09, 0x9F0F, 0x9F10,
0x9F11, 0x9F12, 0x9F14, 0x9F16, 0x9F17, 0x9F19, 0x9F1A, 0x9F1B,
0x9F1F, 0x9F22, 0x9F26, 0x9F2A, 0x9F2B, 0x9F2F, 0x9F31, 0x9F32,

Просмотреть файл

@ -28,9 +28,4 @@
#define NS_UNICODETOISO2022JP_CID \
{0x4f76e100, 0xd71c, 0x11d2, {0x8a, 0xac, 0x0, 0x60, 0x8, 0x11, 0xa8, 0x36}}
// Class ID for our UnicodeToJISx0201 charset converter
// {BA615191-1DFA-11d3-B3BF-00805F8A6670}
#define NS_UNICODETOJISX0201_CID \
{0xba615191, 0x1dfa, 0x11d3, {0xb3, 0xbf, 0x0, 0x80, 0x5f, 0x8a, 0x66, 0x70}}
#endif /* nsUCVJA2CID_h___ */

Просмотреть файл

@ -1,18 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsUnicodeToJISx0201.h"
#include "nsUCVJADll.h"
#include "nsUCConstructors.h"
nsresult
nsUnicodeToJISx0201Constructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult)
{
return CreateTableEncoder(u1ByteCharset,
(uMappingTable*) &g_uf0201Mapping, 1,
aOuter, aIID, aResult);
}

Просмотреть файл

@ -1,23 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsUnicodeToJISx0201_h___
#define nsUnicodeToJISx0201_h___
#include "nsID.h"
class nsISupports;
/**
* A character set converter from Unicode to JISx0201.
*
* @created 17/Feb/1999
* @author Catalin Rotaru [CATA]
*/
nsresult
nsUnicodeToJISx0201Constructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult);
#endif /* nsUnicodeToJISx0201_h___ */

Просмотреть файл

@ -1,132 +0,0 @@
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/*========================================================
This is a Generated file. Please don't edit it.
The tool which used to generate this file is called fromu.
If you have any problem of this file. Please contact
Netscape Client International Team or
ftang@netscape <Frank Tang>
Table in Debug form
Begin of Item 0000
Format 0
srcBegin = 0000
srcEnd = 00A0
destBegin = 0000
End of Item 0000
Begin of Item 0001
Format 0
srcBegin = 0404
srcEnd = 040C
destBegin = 00B4
End of Item 0001
Begin of Item 0002
Format 0
srcBegin = 0418
srcEnd = 041F
destBegin = 00E9
End of Item 0002
Begin of Item 0003
Format 0
srcBegin = 0438
srcEnd = 043F
destBegin = 00C9
End of Item 0003
Begin of Item 0004
Format 0
srcBegin = 0454
srcEnd = 045C
destBegin = 00A4
End of Item 0004
Begin of Item 0005
Format 1
srcBegin = 00A4
srcEnd = 00AD
mappingOffset = 0000
Mapping =
00BD FFFD FFFD FFFD FFFD FFFD FFFD FFFD
FFFD 00AD
End of Item 0005
Begin of Item 0006
Format 1
srcBegin = 0401
srcEnd = 045F
mappingOffset = 000A
Mapping =
00B3 00B1 00B2 FFFD FFFD FFFD FFFD FFFD
FFFD FFFD FFFD FFFD FFFD 00BE 00BF 00E1
00E2 00F7 00E7 00E4 00E5 00F6 00FA FFFD
FFFD FFFD FFFD FFFD FFFD FFFD FFFD 00F2
00F3 00F4 00F5 00E6 00E8 00E3 00FE 00FB
00FD 00FF 00F9 00F8 00FC 00E0 00F1 00C1
00C2 00D7 00C7 00C4 00C5 00D6 00DA FFFD
FFFD FFFD FFFD FFFD FFFD FFFD FFFD 00D2
00D3 00D4 00D5 00C6 00C8 00C3 00DE 00DB
00DD 00DF 00D9 00D8 00DC 00C0 00D1 FFFD
00A3 00A1 00A2 FFFD FFFD FFFD FFFD FFFD
FFFD FFFD FFFD FFFD FFFD 00AE 00AF
End of Item 0006
Begin of Item 0007
Format 2
srcBegin = 2116
destBegin = 00B0
End of Item 0007
========================================================*/
/* Offset=0x0000 ItemOfList */
0x0008,
/*-------------------------------------------------------*/
/* Offset=0x0001 offsetToFormatArray */
0x0004,
/*-------------------------------------------------------*/
/* Offset=0x0002 offsetToMapCellArray */
0x0007,
/*-------------------------------------------------------*/
/* Offset=0x0003 offsetToMappingTable */
0x001F,
/*-------------------------------------------------------*/
/* Offset=0x0004 Start of Format Array */
/* Total of Format 0 : 0x0005 */
/* Total of Format 1 : 0x0002 */
/* Total of Format 2 : 0x0001 */
/* Total of Format 3 : 0x0000 */
0x0000, 0x2110, 0x0000,
/*-------------------------------------------------------*/
/* Offset=0x0007 Start of MapCell Array */
/* 0000 */ 0x0000, 0x00A0, 0x0000,
/* 0001 */ 0x0404, 0x040C, 0x00B4,
/* 0002 */ 0x0418, 0x041F, 0x00E9,
/* 0003 */ 0x0438, 0x043F, 0x00C9,
/* 0004 */ 0x0454, 0x045C, 0x00A4,
/* 0005 */ 0x00A4, 0x00AD, 0x0000,
/* 0006 */ 0x0401, 0x045F, 0x000A,
/* 0007 */ 0x2116, 0x0000, 0x00B0,
/*-------------------------------------------------------*/
/* Offset=0x001F Start of MappingTable */
/* 0000 */ 0x00BD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0008 */ 0xFFFD, 0x00AD, 0x00B3, 0x00B1, 0x00B2, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0010 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x00BE,
/* 0018 */ 0x00BF, 0x00E1, 0x00E2, 0x00F7, 0x00E7, 0x00E4, 0x00E5, 0x00F6,
/* 0020 */ 0x00FA, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0028 */ 0xFFFD, 0x00F2, 0x00F3, 0x00F4, 0x00F5, 0x00E6, 0x00E8, 0x00E3,
/* 0030 */ 0x00FE, 0x00FB, 0x00FD, 0x00FF, 0x00F9, 0x00F8, 0x00FC, 0x00E0,
/* 0038 */ 0x00F1, 0x00C1, 0x00C2, 0x00D7, 0x00C7, 0x00C4, 0x00C5, 0x00D6,
/* 0040 */ 0x00DA, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0048 */ 0xFFFD, 0x00D2, 0x00D3, 0x00D4, 0x00D5, 0x00C6, 0x00C8, 0x00C3,
/* 0050 */ 0x00DE, 0x00DB, 0x00DD, 0x00DF, 0x00D9, 0x00D8, 0x00DC, 0x00C0,
/* 0058 */ 0x00D1, 0xFFFD, 0x00A3, 0x00A1, 0x00A2, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0060 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x00AE,
/* 0068 */ 0x00AF,
/* End of table Total Length = 0x0088 * 2 */

Просмотреть файл

@ -1,112 +0,0 @@
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/*========================================================
This is a Generated file. Please don't edit it.
The tool which used to generate this file is called fromu.
If you have any problem of this file. Please contact
Netscape Client International Team or
ftang@netscape <Frank Tang>
Table in Debug form
Begin of Item 0000
Format 0
srcBegin = 0000
srcEnd = 00A0
destBegin = 0000
End of Item 0000
Begin of Item 0001
Format 0
srcBegin = 00A4
srcEnd = 00AC
destBegin = 0454
End of Item 0001
Begin of Item 0002
Format 0
srcBegin = 00B4
srcEnd = 00BC
destBegin = 0404
End of Item 0002
Begin of Item 0003
Format 0
srcBegin = 00C9
srcEnd = 00D0
destBegin = 0438
End of Item 0003
Begin of Item 0004
Format 0
srcBegin = 00E9
srcEnd = 00F0
destBegin = 0418
End of Item 0004
Begin of Item 0005
Format 1
srcBegin = 00A1
srcEnd = 00FF
mappingOffset = 0000
Mapping =
0452 0453 0451 FFFD FFFD FFFD FFFD FFFD
FFFD FFFD FFFD FFFD 00AD 045E 045F 2116
0402 0403 0401 FFFD FFFD FFFD FFFD FFFD
FFFD FFFD FFFD FFFD 00A4 040E 040F 044E
0430 0431 0446 0434 0435 0444 0433 0445
FFFD FFFD FFFD FFFD FFFD FFFD FFFD FFFD
044F 0440 0441 0442 0443 0436 0432 044C
044B 0437 0448 044D 0449 0447 044A 042E
0410 0411 0426 0414 0415 0424 0413 0425
FFFD FFFD FFFD FFFD FFFD FFFD FFFD FFFD
042F 0420 0421 0422 0423 0416 0412 042C
042B 0417 0428 042D 0429 0427 042A
End of Item 0005
========================================================*/
/* Offset=0x0000 ItemOfList */
0x0006,
/*-------------------------------------------------------*/
/* Offset=0x0001 offsetToFormatArray */
0x0004,
/*-------------------------------------------------------*/
/* Offset=0x0002 offsetToMapCellArray */
0x0006,
/*-------------------------------------------------------*/
/* Offset=0x0003 offsetToMappingTable */
0x0018,
/*-------------------------------------------------------*/
/* Offset=0x0004 Start of Format Array */
/* Total of Format 0 : 0x0005 */
/* Total of Format 1 : 0x0001 */
/* Total of Format 2 : 0x0000 */
/* Total of Format 3 : 0x0000 */
0x0000, 0x0010,
/*-------------------------------------------------------*/
/* Offset=0x0006 Start of MapCell Array */
/* 0000 */ 0x0000, 0x00A0, 0x0000,
/* 0001 */ 0x00A4, 0x00AC, 0x0454,
/* 0002 */ 0x00B4, 0x00BC, 0x0404,
/* 0003 */ 0x00C9, 0x00D0, 0x0438,
/* 0004 */ 0x00E9, 0x00F0, 0x0418,
/* 0005 */ 0x00A1, 0x00FF, 0x0000,
/*-------------------------------------------------------*/
/* Offset=0x0018 Start of MappingTable */
/* 0000 */ 0x0452, 0x0453, 0x0451, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0008 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x00AD, 0x045E, 0x045F, 0x2116,
/* 0010 */ 0x0402, 0x0403, 0x0401, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0018 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0x00A4, 0x040E, 0x040F, 0x044E,
/* 0020 */ 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, 0x0445,
/* 0028 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0030 */ 0x044F, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, 0x044C,
/* 0038 */ 0x044B, 0x0437, 0x0448, 0x044D, 0x0449, 0x0447, 0x044A, 0x042E,
/* 0040 */ 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, 0x0425,
/* 0048 */ 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD, 0xFFFD,
/* 0050 */ 0x042F, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, 0x042C,
/* 0058 */ 0x042B, 0x0417, 0x0428, 0x042D, 0x0429, 0x0427, 0x042A,
/* End of table Total Length = 0x0077 * 2 */

Просмотреть файл

@ -1,19 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsUCConstructors.h"
#include "nsISO88596ToUnicode.h"
#include "nsISO88596EToUnicode.h"
//----------------------------------------------------------------------
// Global functions and data [declaration]
nsresult
nsISO88596EToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult)
{
return nsISO88596ToUnicodeConstructor(aOuter, aIID, aResult);
}

Просмотреть файл

@ -1,21 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsISO88596EToUnicode_h___
#define nsISO88596EToUnicode_h___
#include "nsISupports.h"
/**
* A character set converter from ISO88596 to Unicode.
*
* @created 20/Apr/1999
* @author Catalin Rotaru [CATA]
*/
nsresult
nsISO88596EToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult);
#endif /* nsISO88596EToUnicode_h___ */

Просмотреть файл

@ -1,16 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsUCConstructors.h"
#include "nsISO88596ToUnicode.h"
#include "nsISO88596IToUnicode.h"
nsresult
nsISO88596IToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult)
{
return nsISO88596ToUnicodeConstructor(aOuter, aIID, aResult);
}

Просмотреть файл

@ -1,21 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsISO88596IToUnicode_h___
#define nsISO88596IToUnicode_h___
#include "nsISupports.h"
/**
* A character set converter from ISO88596I to Unicode.
*
* @created 20/Apr/1999
* @author Catalin Rotaru [CATA]
*/
nsresult
nsISO88596IToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult);
#endif /* nsISO88596IToUnicode_h___ */

Просмотреть файл

@ -1,18 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsISO88598ToUnicode.h"
#include "nsISO88598EToUnicode.h"
//----------------------------------------------------------------------
// Global functions and data [declaration]
nsresult
nsISO88598EToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult)
{
return nsISO88598ToUnicodeConstructor(aOuter, aIID, aResult);
}

Просмотреть файл

@ -1,21 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsISO88598EToUnicode_h___
#define nsISO88598EToUnicode_h___
#include "nsISupports.h"
/**
* A character set converter from ISO88598 to Unicode.
*
* @created 20/Apr/1999
* @author Catalin Rotaru [CATA]
*/
nsresult
nsISO88598EToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult);
#endif /* nsISO88598EToUnicode_h___ */

Просмотреть файл

@ -1,26 +0,0 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsUCConstructors.h"
#include "nsISOIR111ToUnicode.h"
#include "mozilla/Telemetry.h"
using namespace mozilla;
//----------------------------------------------------------------------
// Global functions and data [declaration]
nsresult
nsISOIR111ToUnicodeConstructor(nsISupports *aOuter, REFNSIID aIID,
void **aResult)
{
static const uint16_t g_utMappingTable[] = {
#include "iso-ir-111.ut"
};
Telemetry::Accumulate(Telemetry::DECODER_INSTANTIATED_ISOIR111, true);
return CreateOneByteDecoder((uMappingTable*) &g_utMappingTable,
aOuter, aIID, aResult);
}

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше