@@ -625,17 +504,13 @@ class DeviceRgbCS extends ColorSpace {
q += alpha01;
q += alpha01;
}
}
}
}
-
getOutputLength(inputLength, alpha01) {
getOutputLength(inputLength, alpha01) {
return inputLength * (3 + alpha01) / 3 | 0;
return inputLength * (3 + alpha01) / 3 | 0;
}
}
-
isPassthrough(bits) {
isPassthrough(bits) {
return bits === 8;
return bits === 8;
}
}
-
}
}
-
const DeviceCmykCS = function DeviceCmykCSClosure() {
const DeviceCmykCS = function DeviceCmykCSClosure() {
function convertToRgb(src, srcOffset, srcScale, dest, destOffset) {
function convertToRgb(src, srcOffset, srcScale, dest, destOffset) {
const c = src[srcOffset] * srcScale;
const c = src[srcOffset] * srcScale;
@@ -646,35 +521,27 @@ const DeviceCmykCS = function DeviceCmykCSClosure() {
dest[destOffset + 1] = 255 + c * (8.841041422036149 * c + 60.118027045597366 * m + 6.871425592049007 * y + 31.159100130055922 * k + -79.2970844816548) + m * (-15.310361306967817 * m + 17.575251261109482 * y + 131.35250912493976 * k - 190.9453302588951) + y * (4.444339102852739 * y + 9.8632861493405 * k - 24.86741582555878) + k * (-20.737325471181034 * k - 187.80453709719578);
dest[destOffset + 1] = 255 + c * (8.841041422036149 * c + 60.118027045597366 * m + 6.871425592049007 * y + 31.159100130055922 * k + -79.2970844816548) + m * (-15.310361306967817 * m + 17.575251261109482 * y + 131.35250912493976 * k - 190.9453302588951) + y * (4.444339102852739 * y + 9.8632861493405 * k - 24.86741582555878) + k * (-20.737325471181034 * k - 187.80453709719578);
dest[destOffset + 2] = 255 + c * (0.8842522430003296 * c + 8.078677503112928 * m + 30.89978309703729 * y - 0.23883238689178934 * k + -14.183576799673286) + m * (10.49593273432072 * m + 63.02378494754052 * y + 50.606957656360734 * k - 112.23884253719248) + y * (0.03296041114873217 * y + 115.60384449646641 * k + -193.58209356861505) + k * (-22.33816807309886 * k - 180.12613974708367);
dest[destOffset + 2] = 255 + c * (0.8842522430003296 * c + 8.078677503112928 * m + 30.89978309703729 * y - 0.23883238689178934 * k + -14.183576799673286) + m * (10.49593273432072 * m + 63.02378494754052 * y + 50.606957656360734 * k - 112.23884253719248) + y * (0.03296041114873217 * y + 115.60384449646641 * k + -193.58209356861505) + k * (-22.33816807309886 * k - 180.12613974708367);
throw new Error(`The API version "${apiVersion}" does not match ` + `the Worker version "${workerVersion}".`);
throw new Error(`The API version "${apiVersion}" does not match ` + `the Worker version "${workerVersion}".`);
}
}
-
const enumerableProperties = [];
const enumerableProperties = [];
-
for (const property in []) {
for (const property in []) {
enumerableProperties.push(property);
enumerableProperties.push(property);
}
}
-
if (enumerableProperties.length) {
if (enumerableProperties.length) {
throw new Error("The `Array.prototype` contains unexpected enumerable properties: " + enumerableProperties.join(", ") + "; thus breaking e.g. `for...in` iteration of `Array`s.");
throw new Error("The `Array.prototype` contains unexpected enumerable properties: " + enumerableProperties.join(", ") + "; thus breaking e.g. `for...in` iteration of `Array`s.");
}
}
-
if (typeof ReadableStream === "undefined") {
if (typeof ReadableStream === "undefined") {
const partialMsg = "The browser/environment lacks native support for critical " + "functionality used by the PDF.js library (e.g. `ReadableStream`); ";
const partialMsg = "The browser/environment lacks native support for critical " + "functionality used by the PDF.js library (e.g. `ReadableStream`); ";
-
if (_is_node.isNodeJS) {
if (_is_node.isNodeJS) {
throw new Error(partialMsg + "please use a `legacy`-build instead.");
throw new Error(partialMsg + "please use a `legacy`-build instead.");
}
}
-
throw new Error(partialMsg + "please update to a supported browser.");
throw new Error(partialMsg + "please update to a supported browser.");