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CAAA,IAAK,CAAxC,EAA2C;MACzCwF,CAAA,CAAExF,CAAF,KAASwF,CAAA,CAAExF,CAAA,GAAI,CAAN,IAAWwF,CAAA,CAAExF,CAAA,GAAI,CAAN,CAAZ,IAAyB,CAAjC;IADyC;EATnB;AADgB;;;;;UC5xE5C;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACPA,IAAAyD,KAAA,GAAAC,mBAAA;AACA,IAAAwqC,KAAA,GAAAxqC,mBAAA;AACA,IAAAyqC,IAAA,GAAAzqC,mBAAA;AACA,IAAA0qC,IAAA,GAAA1qC,mBAAA;AAGA,MAAM2qC,YAAA,GAC8B,UADpC;AAGA,MAAMC,UAAA,GAC8B,WADpC","sources":["webpack://pdfjs-dist/image_decoders/pdf.image_decoders/webpack/universalModuleDefinition","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/shared/util.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/jbig2.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/core_utils.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/primitives.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/base_stream.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/arithmetic_decoder.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/ccitt.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/jpg.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/shared/image_utils.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/core/jpx.js","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/webpack/bootstrap","webpack://pdfjs-dist/image_decoders/pdf.image_decoders/src/pdf.image_decoders.js"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = root.pdfjsImageDecoders = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine(\"pdfjs-dist/image_decoders/pdf.image_decoders\", [], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"pdfjs-dist/image_decoders/pdf.image_decoders\"] = factory();\n\telse\n\t\troot[\"pdfjs-dist/image_decoders/pdf.image_decoders\"] = factory();\n})(globalThis, () => {\nreturn ","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/* globals process */\n\n// NW.js / Electron is a browser context, but copies some Node.js objects; see\n// http://docs.nwjs.io/en/latest/For%20Users/Advanced/JavaScript%20Contexts%20in%20NW.js/#access-nodejs-and-nwjs-api-in-browser-context\n// https://www.electronjs.org/docs/api/process#processversionselectron-readonly\n// https://www.electronjs.org/docs/api/process#processtype-readonly\nconst isNodeJS =\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) &&\n typeof process === \"object\" &&\n process + \"\" === \"[object process]\" &&\n !process.versions.nw &&\n !(process.versions.electron && process.type && process.type !== \"browser\");\n\nconst IDENTITY_MATRIX = [1, 0, 0, 1, 0, 0];\nconst FONT_IDENTITY_MATRIX = [0.001, 0, 0, 0.001, 0, 0];\n\nconst MAX_IMAGE_SIZE_TO_CACHE = 10e6; // Ten megabytes.\n\n// Represent the percentage of the height of a single-line field over\n// the font size. Acrobat seems to use this value.\nconst LINE_FACTOR = 1.35;\nconst LINE_DESCENT_FACTOR = 0.35;\nconst BASELINE_FACTOR = LINE_DESCENT_FACTOR / LINE_FACTOR;\n\n/**\n * Refer to the `WorkerTransport.getRenderingIntent`-method in the API, to see\n * how these flags are being used:\n * - ANY, DISPLAY, and PRINT are the normal rendering intents, note the\n * `PDFPageProxy.{render, getOperatorList, getAnnotations}`-methods.\n * - ANNOTATIONS_FORMS, ANNOTATIONS_STORAGE, ANNOTATIONS_DISABLE control which\n * annotations are rendered onto the canvas (i.e. by being included in the\n * operatorList), note the `PDFPageProxy.{render, getOperatorList}`-methods\n * and their `annotationMode`-option.\n * - OPLIST is used with the `PDFPageProxy.getOperatorList`-method, note the\n * `OperatorList`-constructor (on the worker-thread).\n */\nconst RenderingIntentFlag = {\n ANY: 0x01,\n DISPLAY: 0x02,\n PRINT: 0x04,\n SAVE: 0x08,\n ANNOTATIONS_FORMS: 0x10,\n ANNOTATIONS_STORAGE: 0x20,\n ANNOTATIONS_DISABLE: 0x40,\n OPLIST: 0x100,\n};\n\nconst AnnotationMode = {\n DISABLE: 0,\n ENABLE: 1,\n ENABLE_FORMS: 2,\n ENABLE_STORAGE: 3,\n};\n\nconst AnnotationEditorPrefix = \"pdfjs_internal_editor_\";\n\nconst AnnotationEditorType = {\n DISABLE: -1,\n NONE: 0,\n FREETEXT: 3,\n STAMP: 13,\n INK: 15,\n};\n\nconst AnnotationEditorParamsType = {\n RESIZE: 1,\n CREATE: 2,\n FREETEXT_SIZE: 11,\n FREETEXT_COLOR: 12,\n FREETEXT_OPACITY: 13,\n INK_COLOR: 21,\n INK_THICKNESS: 22,\n INK_OPACITY: 23,\n};\n\n// Permission flags from Table 22, Section 7.6.3.2 of the PDF specification.\nconst PermissionFlag = {\n PRINT: 0x04,\n MODIFY_CONTENTS: 0x08,\n COPY: 0x10,\n MODIFY_ANNOTATIONS: 0x20,\n FILL_INTERACTIVE_FORMS: 0x100,\n COPY_FOR_ACCESSIBILITY: 0x200,\n ASSEMBLE: 0x400,\n PRINT_HIGH_QUALITY: 0x800,\n};\n\nconst TextRenderingMode = {\n FILL: 0,\n STROKE: 1,\n FILL_STROKE: 2,\n INVISIBLE: 3,\n FILL_ADD_TO_PATH: 4,\n STROKE_ADD_TO_PATH: 5,\n FILL_STROKE_ADD_TO_PATH: 6,\n ADD_TO_PATH: 7,\n FILL_STROKE_MASK: 3,\n ADD_TO_PATH_FLAG: 4,\n};\n\nconst ImageKind = {\n GRAYSCALE_1BPP: 1,\n RGB_24BPP: 2,\n RGBA_32BPP: 3,\n};\n\nconst AnnotationType = {\n TEXT: 1,\n LINK: 2,\n FREETEXT: 3,\n LINE: 4,\n SQUARE: 5,\n CIRCLE: 6,\n POLYGON: 7,\n POLYLINE: 8,\n HIGHLIGHT: 9,\n UNDERLINE: 10,\n SQUIGGLY: 11,\n STRIKEOUT: 12,\n STAMP: 13,\n CARET: 14,\n INK: 15,\n POPUP: 16,\n FILEATTACHMENT: 17,\n SOUND: 18,\n MOVIE: 19,\n WIDGET: 20,\n SCREEN: 21,\n PRINTERMARK: 22,\n TRAPNET: 23,\n WATERMARK: 24,\n THREED: 25,\n REDACT: 26,\n};\n\nconst AnnotationReplyType = {\n GROUP: \"Group\",\n REPLY: \"R\",\n};\n\nconst AnnotationFlag = {\n INVISIBLE: 0x01,\n HIDDEN: 0x02,\n PRINT: 0x04,\n NOZOOM: 0x08,\n NOROTATE: 0x10,\n NOVIEW: 0x20,\n READONLY: 0x40,\n LOCKED: 0x80,\n TOGGLENOVIEW: 0x100,\n LOCKEDCONTENTS: 0x200,\n};\n\nconst AnnotationFieldFlag = {\n READONLY: 0x0000001,\n REQUIRED: 0x0000002,\n NOEXPORT: 0x0000004,\n MULTILINE: 0x0001000,\n PASSWORD: 0x0002000,\n NOTOGGLETOOFF: 0x0004000,\n RADIO: 0x0008000,\n PUSHBUTTON: 0x0010000,\n COMBO: 0x0020000,\n EDIT: 0x0040000,\n SORT: 0x0080000,\n FILESELECT: 0x0100000,\n MULTISELECT: 0x0200000,\n DONOTSPELLCHECK: 0x0400000,\n DONOTSCROLL: 0x0800000,\n COMB: 0x1000000,\n RICHTEXT: 0x2000000,\n RADIOSINUNISON: 0x2000000,\n COMMITONSELCHANGE: 0x4000000,\n};\n\nconst AnnotationBorderStyleType = {\n SOLID: 1,\n DASHED: 2,\n BEVELED: 3,\n INSET: 4,\n UNDERLINE: 5,\n};\n\nconst AnnotationActionEventType = {\n E: \"Mouse Enter\",\n X: \"Mouse Exit\",\n D: \"Mouse Down\",\n U: \"Mouse Up\",\n Fo: \"Focus\",\n Bl: \"Blur\",\n PO: \"PageOpen\",\n PC: \"PageClose\",\n PV: \"PageVisible\",\n PI: \"PageInvisible\",\n K: \"Keystroke\",\n F: \"Format\",\n V: \"Validate\",\n C: \"Calculate\",\n};\n\nconst DocumentActionEventType = {\n WC: \"WillClose\",\n WS: \"WillSave\",\n DS: \"DidSave\",\n WP: \"WillPrint\",\n DP: \"DidPrint\",\n};\n\nconst PageActionEventType = {\n O: \"PageOpen\",\n C: \"PageClose\",\n};\n\nconst VerbosityLevel = {\n ERRORS: 0,\n WARNINGS: 1,\n INFOS: 5,\n};\n\nconst CMapCompressionType = {\n NONE: 0,\n BINARY: 1,\n};\n\n// All the possible operations for an operator list.\nconst OPS = {\n // Intentionally start from 1 so it is easy to spot bad operators that will be\n // 0's.\n // PLEASE NOTE: We purposely keep any removed operators commented out, since\n // re-numbering the list would risk breaking third-party users.\n dependency: 1,\n setLineWidth: 2,\n setLineCap: 3,\n setLineJoin: 4,\n setMiterLimit: 5,\n setDash: 6,\n setRenderingIntent: 7,\n setFlatness: 8,\n setGState: 9,\n save: 10,\n restore: 11,\n transform: 12,\n moveTo: 13,\n lineTo: 14,\n curveTo: 15,\n curveTo2: 16,\n curveTo3: 17,\n closePath: 18,\n rectangle: 19,\n stroke: 20,\n closeStroke: 21,\n fill: 22,\n eoFill: 23,\n fillStroke: 24,\n eoFillStroke: 25,\n closeFillStroke: 26,\n closeEOFillStroke: 27,\n endPath: 28,\n clip: 29,\n eoClip: 30,\n beginText: 31,\n endText: 32,\n setCharSpacing: 33,\n setWordSpacing: 34,\n setHScale: 35,\n setLeading: 36,\n setFont: 37,\n setTextRenderingMode: 38,\n setTextRise: 39,\n moveText: 40,\n setLeadingMoveText: 41,\n setTextMatrix: 42,\n nextLine: 43,\n showText: 44,\n showSpacedText: 45,\n nextLineShowText: 46,\n nextLineSetSpacingShowText: 47,\n setCharWidth: 48,\n setCharWidthAndBounds: 49,\n setStrokeColorSpace: 50,\n setFillColorSpace: 51,\n setStrokeColor: 52,\n setStrokeColorN: 53,\n setFillColor: 54,\n setFillColorN: 55,\n setStrokeGray: 56,\n setFillGray: 57,\n setStrokeRGBColor: 58,\n setFillRGBColor: 59,\n setStrokeCMYKColor: 60,\n setFillCMYKColor: 61,\n shadingFill: 62,\n beginInlineImage: 63,\n beginImageData: 64,\n endInlineImage: 65,\n paintXObject: 66,\n markPoint: 67,\n markPointProps: 68,\n beginMarkedContent: 69,\n beginMarkedContentProps: 70,\n endMarkedContent: 71,\n beginCompat: 72,\n endCompat: 73,\n paintFormXObjectBegin: 74,\n paintFormXObjectEnd: 75,\n beginGroup: 76,\n endGroup: 77,\n // beginAnnotations: 78,\n // endAnnotations: 79,\n beginAnnotation: 80,\n endAnnotation: 81,\n // paintJpegXObject: 82,\n paintImageMaskXObject: 83,\n paintImageMaskXObjectGroup: 84,\n paintImageXObject: 85,\n paintInlineImageXObject: 86,\n paintInlineImageXObjectGroup: 87,\n paintImageXObjectRepeat: 88,\n paintImageMaskXObjectRepeat: 89,\n paintSolidColorImageMask: 90,\n constructPath: 91,\n};\n\nconst PasswordResponses = {\n NEED_PASSWORD: 1,\n INCORRECT_PASSWORD: 2,\n};\n\nlet verbosity = VerbosityLevel.WARNINGS;\n\nfunction setVerbosityLevel(level) {\n if (Number.isInteger(level)) {\n verbosity = level;\n }\n}\n\nfunction getVerbosityLevel() {\n return verbosity;\n}\n\n// A notice for devs. These are good for things that are helpful to devs, such\n// as warning that Workers were disabled, which is important to devs but not\n// end users.\nfunction info(msg) {\n if (verbosity >= VerbosityLevel.INFOS) {\n console.log(`Info: ${msg}`);\n }\n}\n\n// Non-fatal warnings.\nfunction warn(msg) {\n if (verbosity >= VerbosityLevel.WARNINGS) {\n console.log(`Warning: ${msg}`);\n }\n}\n\nfunction unreachable(msg) {\n throw new Error(msg);\n}\n\nfunction assert(cond, msg) {\n if (!cond) {\n unreachable(msg);\n }\n}\n\n// Checks if URLs use one of the allowed protocols, e.g. to avoid XSS.\nfunction _isValidProtocol(url) {\n switch (url?.protocol) {\n case \"http:\":\n case \"https:\":\n case \"ftp:\":\n case \"mailto:\":\n case \"tel:\":\n return true;\n default:\n return false;\n }\n}\n\n/**\n * Attempts to create a valid absolute URL.\n *\n * @param {URL|string} url - An absolute, or relative, URL.\n * @param {URL|string} [baseUrl] - An absolute URL.\n * @param {Object} [options]\n * @returns Either a valid {URL}, or `null` otherwise.\n */\nfunction createValidAbsoluteUrl(url, baseUrl = null, options = null) {\n if (!url) {\n return null;\n }\n try {\n if (options && typeof url === \"string\") {\n // Let URLs beginning with \"www.\" default to using the \"http://\" protocol.\n if (options.addDefaultProtocol && url.startsWith(\"www.\")) {\n const dots = url.match(/\\./g);\n // Avoid accidentally matching a *relative* URL pointing to a file named\n // e.g. \"www.pdf\" or similar.\n if (dots?.length >= 2) {\n url = `http://${url}`;\n }\n }\n\n // According to ISO 32000-1:2008, section 12.6.4.7, URIs should be encoded\n // in 7-bit ASCII. Some bad PDFs use UTF-8 encoding; see bug 1122280.\n if (options.tryConvertEncoding) {\n try {\n url = stringToUTF8String(url);\n } catch {}\n }\n }\n\n const absoluteUrl = baseUrl ? new URL(url, baseUrl) : new URL(url);\n if (_isValidProtocol(absoluteUrl)) {\n return absoluteUrl;\n }\n } catch {\n /* `new URL()` will throw on incorrect data. */\n }\n return null;\n}\n\nfunction shadow(obj, prop, value, nonSerializable = false) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n prop in obj,\n `shadow: Property \"${prop && prop.toString()}\" not found in object.`\n );\n }\n Object.defineProperty(obj, prop, {\n value,\n enumerable: !nonSerializable,\n configurable: true,\n writable: false,\n });\n return value;\n}\n\n/**\n * @type {any}\n */\nconst BaseException = (function BaseExceptionClosure() {\n // eslint-disable-next-line no-shadow\n function BaseException(message, name) {\n if (this.constructor === BaseException) {\n unreachable(\"Cannot initialize BaseException.\");\n }\n this.message = message;\n this.name = name;\n }\n BaseException.prototype = new Error();\n BaseException.constructor = BaseException;\n\n return BaseException;\n})();\n\nclass PasswordException extends BaseException {\n constructor(msg, code) {\n super(msg, \"PasswordException\");\n this.code = code;\n }\n}\n\nclass UnknownErrorException extends BaseException {\n constructor(msg, details) {\n super(msg, \"UnknownErrorException\");\n this.details = details;\n }\n}\n\nclass InvalidPDFException extends BaseException {\n constructor(msg) {\n super(msg, \"InvalidPDFException\");\n }\n}\n\nclass MissingPDFException extends BaseException {\n constructor(msg) {\n super(msg, \"MissingPDFException\");\n }\n}\n\nclass UnexpectedResponseException extends BaseException {\n constructor(msg, status) {\n super(msg, \"UnexpectedResponseException\");\n this.status = status;\n }\n}\n\n/**\n * Error caused during parsing PDF data.\n */\nclass FormatError extends BaseException {\n constructor(msg) {\n super(msg, \"FormatError\");\n }\n}\n\n/**\n * Error used to indicate task cancellation.\n */\nclass AbortException extends BaseException {\n constructor(msg) {\n super(msg, \"AbortException\");\n }\n}\n\nfunction bytesToString(bytes) {\n if (typeof bytes !== \"object\" || bytes?.length === undefined) {\n unreachable(\"Invalid argument for bytesToString\");\n }\n const length = bytes.length;\n const MAX_ARGUMENT_COUNT = 8192;\n if (length < MAX_ARGUMENT_COUNT) {\n return String.fromCharCode.apply(null, bytes);\n }\n const strBuf = [];\n for (let i = 0; i < length; i += MAX_ARGUMENT_COUNT) {\n const chunkEnd = Math.min(i + MAX_ARGUMENT_COUNT, length);\n const chunk = bytes.subarray(i, chunkEnd);\n strBuf.push(String.fromCharCode.apply(null, chunk));\n }\n return strBuf.join(\"\");\n}\n\nfunction stringToBytes(str) {\n if (typeof str !== \"string\") {\n unreachable(\"Invalid argument for stringToBytes\");\n }\n const length = str.length;\n const bytes = new Uint8Array(length);\n for (let i = 0; i < length; ++i) {\n bytes[i] = str.charCodeAt(i) & 0xff;\n }\n return bytes;\n}\n\nfunction string32(value) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n typeof value === \"number\" && Math.abs(value) < 2 ** 32,\n `string32: Unexpected input \"${value}\".`\n );\n }\n return String.fromCharCode(\n (value >> 24) & 0xff,\n (value >> 16) & 0xff,\n (value >> 8) & 0xff,\n value & 0xff\n );\n}\n\nfunction objectSize(obj) {\n return Object.keys(obj).length;\n}\n\n// Ensure that the returned Object has a `null` prototype; hence why\n// `Object.fromEntries(...)` is not used.\nfunction objectFromMap(map) {\n const obj = Object.create(null);\n for (const [key, value] of map) {\n obj[key] = value;\n }\n return obj;\n}\n\n// Checks the endianness of the platform.\nfunction isLittleEndian() {\n const buffer8 = new Uint8Array(4);\n buffer8[0] = 1;\n const view32 = new Uint32Array(buffer8.buffer, 0, 1);\n return view32[0] === 1;\n}\n\n// Checks if it's possible to eval JS expressions.\nfunction isEvalSupported() {\n try {\n new Function(\"\"); // eslint-disable-line no-new, no-new-func\n return true;\n } catch {\n return false;\n }\n}\n\nclass FeatureTest {\n static get isLittleEndian() {\n return shadow(this, \"isLittleEndian\", isLittleEndian());\n }\n\n static get isEvalSupported() {\n return shadow(this, \"isEvalSupported\", isEvalSupported());\n }\n\n static get isOffscreenCanvasSupported() {\n return shadow(\n this,\n \"isOffscreenCanvasSupported\",\n typeof OffscreenCanvas !== \"undefined\"\n );\n }\n\n static get platform() {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"GENERIC\")) &&\n typeof navigator === \"undefined\"\n ) {\n return shadow(this, \"platform\", { isWin: false, isMac: false });\n }\n return shadow(this, \"platform\", {\n isWin: navigator.platform.includes(\"Win\"),\n isMac: navigator.platform.includes(\"Mac\"),\n });\n }\n\n static get isCSSRoundSupported() {\n return shadow(\n this,\n \"isCSSRoundSupported\",\n globalThis.CSS?.supports?.(\"width: round(1.5px, 1px)\")\n );\n }\n}\n\nconst hexNumbers = [...Array(256).keys()].map(n =>\n n.toString(16).padStart(2, \"0\")\n);\n\nclass Util {\n static makeHexColor(r, g, b) {\n return `#${hexNumbers[r]}${hexNumbers[g]}${hexNumbers[b]}`;\n }\n\n // Apply a scaling matrix to some min/max values.\n // If a scaling factor is negative then min and max must be\n // swaped.\n static scaleMinMax(transform, minMax) {\n let temp;\n if (transform[0]) {\n if (transform[0] < 0) {\n temp = minMax[0];\n minMax[0] = minMax[1];\n minMax[1] = temp;\n }\n minMax[0] *= transform[0];\n minMax[1] *= transform[0];\n\n if (transform[3] < 0) {\n temp = minMax[2];\n minMax[2] = minMax[3];\n minMax[3] = temp;\n }\n minMax[2] *= transform[3];\n minMax[3] *= transform[3];\n } else {\n temp = minMax[0];\n minMax[0] = minMax[2];\n minMax[2] = temp;\n temp = minMax[1];\n minMax[1] = minMax[3];\n minMax[3] = temp;\n\n if (transform[1] < 0) {\n temp = minMax[2];\n minMax[2] = minMax[3];\n minMax[3] = temp;\n }\n minMax[2] *= transform[1];\n minMax[3] *= transform[1];\n\n if (transform[2] < 0) {\n temp = minMax[0];\n minMax[0] = minMax[1];\n minMax[1] = temp;\n }\n minMax[0] *= transform[2];\n minMax[1] *= transform[2];\n }\n minMax[0] += transform[4];\n minMax[1] += transform[4];\n minMax[2] += transform[5];\n minMax[3] += transform[5];\n }\n\n // Concatenates two transformation matrices together and returns the result.\n static transform(m1, m2) {\n return [\n m1[0] * m2[0] + m1[2] * m2[1],\n m1[1] * m2[0] + m1[3] * m2[1],\n m1[0] * m2[2] + m1[2] * m2[3],\n m1[1] * m2[2] + m1[3] * m2[3],\n m1[0] * m2[4] + m1[2] * m2[5] + m1[4],\n m1[1] * m2[4] + m1[3] * m2[5] + m1[5],\n ];\n }\n\n // For 2d affine transforms\n static applyTransform(p, m) {\n const xt = p[0] * m[0] + p[1] * m[2] + m[4];\n const yt = p[0] * m[1] + p[1] * m[3] + m[5];\n return [xt, yt];\n }\n\n static applyInverseTransform(p, m) {\n const d = m[0] * m[3] - m[1] * m[2];\n const xt = (p[0] * m[3] - p[1] * m[2] + m[2] * m[5] - m[4] * m[3]) / d;\n const yt = (-p[0] * m[1] + p[1] * m[0] + m[4] * m[1] - m[5] * m[0]) / d;\n return [xt, yt];\n }\n\n // Applies the transform to the rectangle and finds the minimum axially\n // aligned bounding box.\n static getAxialAlignedBoundingBox(r, m) {\n const p1 = this.applyTransform(r, m);\n const p2 = this.applyTransform(r.slice(2, 4), m);\n const p3 = this.applyTransform([r[0], r[3]], m);\n const p4 = this.applyTransform([r[2], r[1]], m);\n return [\n Math.min(p1[0], p2[0], p3[0], p4[0]),\n Math.min(p1[1], p2[1], p3[1], p4[1]),\n Math.max(p1[0], p2[0], p3[0], p4[0]),\n Math.max(p1[1], p2[1], p3[1], p4[1]),\n ];\n }\n\n static inverseTransform(m) {\n const d = m[0] * m[3] - m[1] * m[2];\n return [\n m[3] / d,\n -m[1] / d,\n -m[2] / d,\n m[0] / d,\n (m[2] * m[5] - m[4] * m[3]) / d,\n (m[4] * m[1] - m[5] * m[0]) / d,\n ];\n }\n\n // This calculation uses Singular Value Decomposition.\n // The SVD can be represented with formula A = USV. We are interested in the\n // matrix S here because it represents the scale values.\n static singularValueDecompose2dScale(m) {\n const transpose = [m[0], m[2], m[1], m[3]];\n\n // Multiply matrix m with its transpose.\n const a = m[0] * transpose[0] + m[1] * transpose[2];\n const b = m[0] * transpose[1] + m[1] * transpose[3];\n const c = m[2] * transpose[0] + m[3] * transpose[2];\n const d = m[2] * transpose[1] + m[3] * transpose[3];\n\n // Solve the second degree polynomial to get roots.\n const first = (a + d) / 2;\n const second = Math.sqrt((a + d) ** 2 - 4 * (a * d - c * b)) / 2;\n const sx = first + second || 1;\n const sy = first - second || 1;\n\n // Scale values are the square roots of the eigenvalues.\n return [Math.sqrt(sx), Math.sqrt(sy)];\n }\n\n // Normalize rectangle rect=[x1, y1, x2, y2] so that (x1,y1) < (x2,y2)\n // For coordinate systems whose origin lies in the bottom-left, this\n // means normalization to (BL,TR) ordering. For systems with origin in the\n // top-left, this means (TL,BR) ordering.\n static normalizeRect(rect) {\n const r = rect.slice(0); // clone rect\n if (rect[0] > rect[2]) {\n r[0] = rect[2];\n r[2] = rect[0];\n }\n if (rect[1] > rect[3]) {\n r[1] = rect[3];\n r[3] = rect[1];\n }\n return r;\n }\n\n // Returns a rectangle [x1, y1, x2, y2] corresponding to the\n // intersection of rect1 and rect2. If no intersection, returns 'null'\n // The rectangle coordinates of rect1, rect2 should be [x1, y1, x2, y2]\n static intersect(rect1, rect2) {\n const xLow = Math.max(\n Math.min(rect1[0], rect1[2]),\n Math.min(rect2[0], rect2[2])\n );\n const xHigh = Math.min(\n Math.max(rect1[0], rect1[2]),\n Math.max(rect2[0], rect2[2])\n );\n if (xLow > xHigh) {\n return null;\n }\n const yLow = Math.max(\n Math.min(rect1[1], rect1[3]),\n Math.min(rect2[1], rect2[3])\n );\n const yHigh = Math.min(\n Math.max(rect1[1], rect1[3]),\n Math.max(rect2[1], rect2[3])\n );\n if (yLow > yHigh) {\n return null;\n }\n\n return [xLow, yLow, xHigh, yHigh];\n }\n\n // From https://github.com/adobe-webplatform/Snap.svg/blob/b365287722a72526000ac4bfcf0ce4cac2faa015/src/path.js#L852\n static bezierBoundingBox(x0, y0, x1, y1, x2, y2, x3, y3) {\n const tvalues = [],\n bounds = [[], []];\n let a, b, c, t, t1, t2, b2ac, sqrtb2ac;\n for (let i = 0; i < 2; ++i) {\n if (i === 0) {\n b = 6 * x0 - 12 * x1 + 6 * x2;\n a = -3 * x0 + 9 * x1 - 9 * x2 + 3 * x3;\n c = 3 * x1 - 3 * x0;\n } else {\n b = 6 * y0 - 12 * y1 + 6 * y2;\n a = -3 * y0 + 9 * y1 - 9 * y2 + 3 * y3;\n c = 3 * y1 - 3 * y0;\n }\n if (Math.abs(a) < 1e-12) {\n if (Math.abs(b) < 1e-12) {\n continue;\n }\n t = -c / b;\n if (0 < t && t < 1) {\n tvalues.push(t);\n }\n continue;\n }\n b2ac = b * b - 4 * c * a;\n sqrtb2ac = Math.sqrt(b2ac);\n if (b2ac < 0) {\n continue;\n }\n t1 = (-b + sqrtb2ac) / (2 * a);\n if (0 < t1 && t1 < 1) {\n tvalues.push(t1);\n }\n t2 = (-b - sqrtb2ac) / (2 * a);\n if (0 < t2 && t2 < 1) {\n tvalues.push(t2);\n }\n }\n\n let j = tvalues.length,\n mt;\n const jlen = j;\n while (j--) {\n t = tvalues[j];\n mt = 1 - t;\n bounds[0][j] =\n mt * mt * mt * x0 +\n 3 * mt * mt * t * x1 +\n 3 * mt * t * t * x2 +\n t * t * t * x3;\n bounds[1][j] =\n mt * mt * mt * y0 +\n 3 * mt * mt * t * y1 +\n 3 * mt * t * t * y2 +\n t * t * t * y3;\n }\n\n bounds[0][jlen] = x0;\n bounds[1][jlen] = y0;\n bounds[0][jlen + 1] = x3;\n bounds[1][jlen + 1] = y3;\n bounds[0].length = bounds[1].length = jlen + 2;\n\n return [\n Math.min(...bounds[0]),\n Math.min(...bounds[1]),\n Math.max(...bounds[0]),\n Math.max(...bounds[1]),\n ];\n }\n}\n\nconst PDFStringTranslateTable = [\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x2d8,\n 0x2c7, 0x2c6, 0x2d9, 0x2dd, 0x2db, 0x2da, 0x2dc, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n 0, 0, 0, 0, 0, 0, 0, 0, 0x2022, 0x2020, 0x2021, 0x2026, 0x2014, 0x2013, 0x192,\n 0x2044, 0x2039, 0x203a, 0x2212, 0x2030, 0x201e, 0x201c, 0x201d, 0x2018,\n 0x2019, 0x201a, 0x2122, 0xfb01, 0xfb02, 0x141, 0x152, 0x160, 0x178, 0x17d,\n 0x131, 0x142, 0x153, 0x161, 0x17e, 0, 0x20ac,\n];\n\nfunction stringToPDFString(str) {\n if (str[0] >= \"\\xEF\") {\n let encoding;\n if (str[0] === \"\\xFE\" && str[1] === \"\\xFF\") {\n encoding = \"utf-16be\";\n } else if (str[0] === \"\\xFF\" && str[1] === \"\\xFE\") {\n encoding = \"utf-16le\";\n } else if (str[0] === \"\\xEF\" && str[1] === \"\\xBB\" && str[2] === \"\\xBF\") {\n encoding = \"utf-8\";\n }\n\n if (encoding) {\n try {\n const decoder = new TextDecoder(encoding, { fatal: true });\n const buffer = stringToBytes(str);\n return decoder.decode(buffer);\n } catch (ex) {\n warn(`stringToPDFString: \"${ex}\".`);\n }\n }\n }\n // ISO Latin 1\n const strBuf = [];\n for (let i = 0, ii = str.length; i < ii; i++) {\n const code = PDFStringTranslateTable[str.charCodeAt(i)];\n strBuf.push(code ? String.fromCharCode(code) : str.charAt(i));\n }\n return strBuf.join(\"\");\n}\n\nfunction stringToUTF8String(str) {\n return decodeURIComponent(escape(str));\n}\n\nfunction utf8StringToString(str) {\n return unescape(encodeURIComponent(str));\n}\n\nfunction isArrayBuffer(v) {\n return typeof v === \"object\" && v?.byteLength !== undefined;\n}\n\nfunction isArrayEqual(arr1, arr2) {\n if (arr1.length !== arr2.length) {\n return false;\n }\n for (let i = 0, ii = arr1.length; i < ii; i++) {\n if (arr1[i] !== arr2[i]) {\n return false;\n }\n }\n return true;\n}\n\nfunction getModificationDate(date = new Date()) {\n const buffer = [\n date.getUTCFullYear().toString(),\n (date.getUTCMonth() + 1).toString().padStart(2, \"0\"),\n date.getUTCDate().toString().padStart(2, \"0\"),\n date.getUTCHours().toString().padStart(2, \"0\"),\n date.getUTCMinutes().toString().padStart(2, \"0\"),\n date.getUTCSeconds().toString().padStart(2, \"0\"),\n ];\n\n return buffer.join(\"\");\n}\n\nclass PromiseCapability {\n #settled = false;\n\n constructor() {\n /**\n * @type {Promise<any>} The Promise object.\n */\n this.promise = new Promise((resolve, reject) => {\n /**\n * @type {function} Fulfills the Promise.\n */\n this.resolve = data => {\n this.#settled = true;\n resolve(data);\n };\n\n /**\n * @type {function} Rejects the Promise.\n */\n this.reject = reason => {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(reason instanceof Error, 'Expected valid \"reason\" argument.');\n }\n this.#settled = true;\n reject(reason);\n };\n });\n }\n\n /**\n * @type {boolean} If the Promise has been fulfilled/rejected.\n */\n get settled() {\n return this.#settled;\n }\n}\n\nlet NormalizeRegex = null;\nlet NormalizationMap = null;\nfunction normalizeUnicode(str) {\n if (!NormalizeRegex) {\n // In order to generate the following regex:\n // - create a PDF containing all the chars in the range 0000-FFFF with\n // a NFKC which is different of the char.\n // - copy and paste all those chars and get the ones where NFKC is\n // required.\n // It appears that most the chars here contain some ligatures.\n NormalizeRegex =\n /([\\u00a0\\u00b5\\u037e\\u0eb3\\u2000-\\u200a\\u202f\\u2126\\ufb00-\\ufb04\\ufb06\\ufb20-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40-\\ufb41\\ufb43-\\ufb44\\ufb46-\\ufba1\\ufba4-\\ufba9\\ufbae-\\ufbb1\\ufbd3-\\ufbdc\\ufbde-\\ufbe7\\ufbea-\\ufbf8\\ufbfc-\\ufbfd\\ufc00-\\ufc5d\\ufc64-\\ufcf1\\ufcf5-\\ufd3d\\ufd88\\ufdf4\\ufdfa-\\ufdfb\\ufe71\\ufe77\\ufe79\\ufe7b\\ufe7d]+)|(\\ufb05+)/gu;\n NormalizationMap = new Map([[\"ſt\", \"ſt\"]]);\n }\n return str.replaceAll(NormalizeRegex, (_, p1, p2) => {\n return p1 ? p1.normalize(\"NFKC\") : NormalizationMap.get(p2);\n });\n}\n\nfunction getUuid() {\n if (\n (typeof PDFJSDev !== \"undefined\" && PDFJSDev.test(\"MOZCENTRAL\")) ||\n (typeof crypto !== \"undefined\" && typeof crypto?.randomUUID === \"function\")\n ) {\n return crypto.randomUUID();\n }\n const buf = new Uint8Array(32);\n if (\n typeof crypto !== \"undefined\" &&\n typeof crypto?.getRandomValues === \"function\"\n ) {\n crypto.getRandomValues(buf);\n } else {\n for (let i = 0; i < 32; i++) {\n buf[i] = Math.floor(Math.random() * 255);\n }\n }\n return bytesToString(buf);\n}\n\nconst AnnotationPrefix = \"pdfjs_internal_id_\";\n\nexport {\n AbortException,\n AnnotationActionEventType,\n AnnotationBorderStyleType,\n AnnotationEditorParamsType,\n AnnotationEditorPrefix,\n AnnotationEditorType,\n AnnotationFieldFlag,\n AnnotationFlag,\n AnnotationMode,\n AnnotationPrefix,\n AnnotationReplyType,\n AnnotationType,\n assert,\n BaseException,\n BASELINE_FACTOR,\n bytesToString,\n CMapCompressionType,\n createValidAbsoluteUrl,\n DocumentActionEventType,\n FeatureTest,\n FONT_IDENTITY_MATRIX,\n FormatError,\n getModificationDate,\n getUuid,\n getVerbosityLevel,\n IDENTITY_MATRIX,\n ImageKind,\n info,\n InvalidPDFException,\n isArrayBuffer,\n isArrayEqual,\n isNodeJS,\n LINE_DESCENT_FACTOR,\n LINE_FACTOR,\n MAX_IMAGE_SIZE_TO_CACHE,\n MissingPDFException,\n normalizeUnicode,\n objectFromMap,\n objectSize,\n OPS,\n PageActionEventType,\n PasswordException,\n PasswordResponses,\n PermissionFlag,\n PromiseCapability,\n RenderingIntentFlag,\n setVerbosityLevel,\n shadow,\n string32,\n stringToBytes,\n stringToPDFString,\n stringToUTF8String,\n TextRenderingMode,\n UnexpectedResponseException,\n UnknownErrorException,\n unreachable,\n utf8StringToString,\n Util,\n VerbosityLevel,\n warn,\n};\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { BaseException, shadow } from \"../shared/util.js\";\nimport { log2, readInt8, readUint16, readUint32 } from \"./core_utils.js\";\nimport { ArithmeticDecoder } from \"./arithmetic_decoder.js\";\nimport { CCITTFaxDecoder } from \"./ccitt.js\";\n\nclass Jbig2Error extends BaseException {\n constructor(msg) {\n super(`JBIG2 error: ${msg}`, \"Jbig2Error\");\n }\n}\n\n// Utility data structures\nclass ContextCache {\n getContexts(id) {\n if (id in this) {\n return this[id];\n }\n return (this[id] = new Int8Array(1 << 16));\n }\n}\n\nclass DecodingContext {\n constructor(data, start, end) {\n this.data = data;\n this.start = start;\n this.end = end;\n }\n\n get decoder() {\n const decoder = new ArithmeticDecoder(this.data, this.start, this.end);\n return shadow(this, \"decoder\", decoder);\n }\n\n get contextCache() {\n const cache = new ContextCache();\n return shadow(this, \"contextCache\", cache);\n }\n}\n\nconst MAX_INT_32 = 2 ** 31 - 1;\nconst MIN_INT_32 = -(2 ** 31);\n\n// Annex A. Arithmetic Integer Decoding Procedure\n// A.2 Procedure for decoding values\nfunction decodeInteger(contextCache, procedure, decoder) {\n const contexts = contextCache.getContexts(procedure);\n let prev = 1;\n\n function readBits(length) {\n let v = 0;\n for (let i = 0; i < length; i++) {\n const bit = decoder.readBit(contexts, prev);\n prev = prev < 256 ? (prev << 1) | bit : (((prev << 1) | bit) & 511) | 256;\n v = (v << 1) | bit;\n }\n return v >>> 0;\n }\n\n const sign = readBits(1);\n // prettier-ignore\n /* eslint-disable no-nested-ternary */\n const value = readBits(1) ?\n (readBits(1) ?\n (readBits(1) ?\n (readBits(1) ?\n (readBits(1) ?\n (readBits(32) + 4436) :\n readBits(12) + 340) :\n readBits(8) + 84) :\n readBits(6) + 20) :\n readBits(4) + 4) :\n readBits(2);\n /* eslint-enable no-nested-ternary */\n let signedValue;\n if (sign === 0) {\n signedValue = value;\n } else if (value > 0) {\n signedValue = -value;\n }\n // Ensure that the integer value doesn't underflow or overflow.\n if (signedValue >= MIN_INT_32 && signedValue <= MAX_INT_32) {\n return signedValue;\n }\n return null;\n}\n\n// A.3 The IAID decoding procedure\nfunction decodeIAID(contextCache, decoder, codeLength) {\n const contexts = contextCache.getContexts(\"IAID\");\n\n let prev = 1;\n for (let i = 0; i < codeLength; i++) {\n const bit = decoder.readBit(contexts, prev);\n prev = (prev << 1) | bit;\n }\n if (codeLength < 31) {\n return prev & ((1 << codeLength) - 1);\n }\n return prev & 0x7fffffff;\n}\n\n// 7.3 Segment types\nconst SegmentTypes = [\n \"SymbolDictionary\",\n null,\n null,\n null,\n \"IntermediateTextRegion\",\n null,\n \"ImmediateTextRegion\",\n \"ImmediateLosslessTextRegion\",\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n \"PatternDictionary\",\n null,\n null,\n null,\n \"IntermediateHalftoneRegion\",\n null,\n \"ImmediateHalftoneRegion\",\n \"ImmediateLosslessHalftoneRegion\",\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n \"IntermediateGenericRegion\",\n null,\n \"ImmediateGenericRegion\",\n \"ImmediateLosslessGenericRegion\",\n \"IntermediateGenericRefinementRegion\",\n null,\n \"ImmediateGenericRefinementRegion\",\n \"ImmediateLosslessGenericRefinementRegion\",\n null,\n null,\n null,\n null,\n \"PageInformation\",\n \"EndOfPage\",\n \"EndOfStripe\",\n \"EndOfFile\",\n \"Profiles\",\n \"Tables\",\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n null,\n \"Extension\",\n];\n\nconst CodingTemplates = [\n [\n { x: -1, y: -2 },\n { x: 0, y: -2 },\n { x: 1, y: -2 },\n { x: -2, y: -1 },\n { x: -1, y: -1 },\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: 2, y: -1 },\n { x: -4, y: 0 },\n { x: -3, y: 0 },\n { x: -2, y: 0 },\n { x: -1, y: 0 },\n ],\n [\n { x: -1, y: -2 },\n { x: 0, y: -2 },\n { x: 1, y: -2 },\n { x: 2, y: -2 },\n { x: -2, y: -1 },\n { x: -1, y: -1 },\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: 2, y: -1 },\n { x: -3, y: 0 },\n { x: -2, y: 0 },\n { x: -1, y: 0 },\n ],\n [\n { x: -1, y: -2 },\n { x: 0, y: -2 },\n { x: 1, y: -2 },\n { x: -2, y: -1 },\n { x: -1, y: -1 },\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: -2, y: 0 },\n { x: -1, y: 0 },\n ],\n [\n { x: -3, y: -1 },\n { x: -2, y: -1 },\n { x: -1, y: -1 },\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: -4, y: 0 },\n { x: -3, y: 0 },\n { x: -2, y: 0 },\n { x: -1, y: 0 },\n ],\n];\n\nconst RefinementTemplates = [\n {\n coding: [\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: -1, y: 0 },\n ],\n reference: [\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: -1, y: 0 },\n { x: 0, y: 0 },\n { x: 1, y: 0 },\n { x: -1, y: 1 },\n { x: 0, y: 1 },\n { x: 1, y: 1 },\n ],\n },\n {\n coding: [\n { x: -1, y: -1 },\n { x: 0, y: -1 },\n { x: 1, y: -1 },\n { x: -1, y: 0 },\n ],\n reference: [\n { x: 0, y: -1 },\n { x: -1, y: 0 },\n { x: 0, y: 0 },\n { x: 1, y: 0 },\n { x: 0, y: 1 },\n { x: 1, y: 1 },\n ],\n },\n];\n\n// See 6.2.5.7 Decoding the bitmap.\nconst ReusedContexts = [\n 0x9b25, // 10011 0110010 0101\n 0x0795, // 0011 110010 101\n 0x00e5, // 001 11001 01\n 0x0195, // 011001 0101\n];\n\nconst RefinementReusedContexts = [\n 0x0020, // '000' + '0' (coding) + '00010000' + '0' (reference)\n 0x0008, // '0000' + '001000'\n];\n\nfunction decodeBitmapTemplate0(width, height, decodingContext) {\n const decoder = decodingContext.decoder;\n const contexts = decodingContext.contextCache.getContexts(\"GB\");\n const bitmap = [];\n let contextLabel, i, j, pixel, row, row1, row2;\n\n // ...ooooo....\n // ..ooooooo... Context template for current pixel (X)\n // .ooooX...... (concatenate values of 'o'-pixels to get contextLabel)\n const OLD_PIXEL_MASK = 0x7bf7; // 01111 0111111 0111\n\n for (i = 0; i < height; i++) {\n row = bitmap[i] = new Uint8Array(width);\n row1 = i < 1 ? row : bitmap[i - 1];\n row2 = i < 2 ? row : bitmap[i - 2];\n\n // At the beginning of each row:\n // Fill contextLabel with pixels that are above/right of (X)\n contextLabel =\n (row2[0] << 13) |\n (row2[1] << 12) |\n (row2[2] << 11) |\n (row1[0] << 7) |\n (row1[1] << 6) |\n (row1[2] << 5) |\n (row1[3] << 4);\n\n for (j = 0; j < width; j++) {\n row[j] = pixel = decoder.readBit(contexts, contextLabel);\n\n // At each pixel: Clear contextLabel pixels that are shifted\n // out of the context, then add new ones.\n contextLabel =\n ((contextLabel & OLD_PIXEL_MASK) << 1) |\n (j + 3 < width ? row2[j + 3] << 11 : 0) |\n (j + 4 < width ? row1[j + 4] << 4 : 0) |\n pixel;\n }\n }\n\n return bitmap;\n}\n\n// 6.2 Generic Region Decoding Procedure\nfunction decodeBitmap(\n mmr,\n width,\n height,\n templateIndex,\n prediction,\n skip,\n at,\n decodingContext\n) {\n if (mmr) {\n const input = new Reader(\n decodingContext.data,\n decodingContext.start,\n decodingContext.end\n );\n return decodeMMRBitmap(input, width, height, false);\n }\n\n // Use optimized version for the most common case\n if (\n templateIndex === 0 &&\n !skip &&\n !prediction &&\n at.length === 4 &&\n at[0].x === 3 &&\n at[0].y === -1 &&\n at[1].x === -3 &&\n at[1].y === -1 &&\n at[2].x === 2 &&\n at[2].y === -2 &&\n at[3].x === -2 &&\n at[3].y === -2\n ) {\n return decodeBitmapTemplate0(width, height, decodingContext);\n }\n\n const useskip = !!skip;\n const template = CodingTemplates[templateIndex].concat(at);\n\n // Sorting is non-standard, and it is not required. But sorting increases\n // the number of template bits that can be reused from the previous\n // contextLabel in the main loop.\n template.sort(function (a, b) {\n return a.y - b.y || a.x - b.x;\n });\n\n const templateLength = template.length;\n const templateX = new Int8Array(templateLength);\n const templateY = new Int8Array(templateLength);\n const changingTemplateEntries = [];\n let reuseMask = 0,\n minX = 0,\n maxX = 0,\n minY = 0;\n let c, k;\n\n for (k = 0; k < templateLength; k++) {\n templateX[k] = template[k].x;\n templateY[k] = template[k].y;\n minX = Math.min(minX, template[k].x);\n maxX = Math.max(maxX, template[k].x);\n minY = Math.min(minY, template[k].y);\n // Check if the template pixel appears in two consecutive context labels,\n // so it can be reused. Otherwise, we add it to the list of changing\n // template entries.\n if (\n k < templateLength - 1 &&\n template[k].y === template[k + 1].y &&\n template[k].x === template[k + 1].x - 1\n ) {\n reuseMask |= 1 << (templateLength - 1 - k);\n } else {\n changingTemplateEntries.push(k);\n }\n }\n const changingEntriesLength = changingTemplateEntries.length;\n\n const changingTemplateX = new Int8Array(changingEntriesLength);\n const changingTemplateY = new Int8Array(changingEntriesLength);\n const changingTemplateBit = new Uint16Array(changingEntriesLength);\n for (c = 0; c < changingEntriesLength; c++) {\n k = changingTemplateEntries[c];\n changingTemplateX[c] = template[k].x;\n changingTemplateY[c] = template[k].y;\n changingTemplateBit[c] = 1 << (templateLength - 1 - k);\n }\n\n // Get the safe bounding box edges from the width, height, minX, maxX, minY\n const sbb_left = -minX;\n const sbb_top = -minY;\n const sbb_right = width - maxX;\n\n const pseudoPixelContext = ReusedContexts[templateIndex];\n let row = new Uint8Array(width);\n const bitmap = [];\n\n const decoder = decodingContext.decoder;\n const contexts = decodingContext.contextCache.getContexts(\"GB\");\n\n let ltp = 0,\n j,\n i0,\n j0,\n contextLabel = 0,\n bit,\n shift;\n for (let i = 0; i < height; i++) {\n if (prediction) {\n const sltp = decoder.readBit(contexts, pseudoPixelContext);\n ltp ^= sltp;\n if (ltp) {\n bitmap.push(row); // duplicate previous row\n continue;\n }\n }\n row = new Uint8Array(row);\n bitmap.push(row);\n for (j = 0; j < width; j++) {\n if (useskip && skip[i][j]) {\n row[j] = 0;\n continue;\n }\n // Are we in the middle of a scanline, so we can reuse contextLabel\n // bits?\n if (j >= sbb_left && j < sbb_right && i >= sbb_top) {\n // If yes, we can just shift the bits that are reusable and only\n // fetch the remaining ones.\n contextLabel = (contextLabel << 1) & reuseMask;\n for (k = 0; k < changingEntriesLength; k++) {\n i0 = i + changingTemplateY[k];\n j0 = j + changingTemplateX[k];\n bit = bitmap[i0][j0];\n if (bit) {\n bit = changingTemplateBit[k];\n contextLabel |= bit;\n }\n }\n } else {\n // compute the contextLabel from scratch\n contextLabel = 0;\n shift = templateLength - 1;\n for (k = 0; k < templateLength; k++, shift--) {\n j0 = j + templateX[k];\n if (j0 >= 0 && j0 < width) {\n i0 = i + templateY[k];\n if (i0 >= 0) {\n bit = bitmap[i0][j0];\n if (bit) {\n contextLabel |= bit << shift;\n }\n }\n }\n }\n }\n const pixel = decoder.readBit(contexts, contextLabel);\n row[j] = pixel;\n }\n }\n return bitmap;\n}\n\n// 6.3.2 Generic Refinement Region Decoding Procedure\nfunction decodeRefinement(\n width,\n height,\n templateIndex,\n referenceBitmap,\n offsetX,\n offsetY,\n prediction,\n at,\n decodingContext\n) {\n let codingTemplate = RefinementTemplates[templateIndex].coding;\n if (templateIndex === 0) {\n codingTemplate = codingTemplate.concat([at[0]]);\n }\n const codingTemplateLength = codingTemplate.length;\n const codingTemplateX = new Int32Array(codingTemplateLength);\n const codingTemplateY = new Int32Array(codingTemplateLength);\n let k;\n for (k = 0; k < codingTemplateLength; k++) {\n codingTemplateX[k] = codingTemplate[k].x;\n codingTemplateY[k] = codingTemplate[k].y;\n }\n\n let referenceTemplate = RefinementTemplates[templateIndex].reference;\n if (templateIndex === 0) {\n referenceTemplate = referenceTemplate.concat([at[1]]);\n }\n const referenceTemplateLength = referenceTemplate.length;\n const referenceTemplateX = new Int32Array(referenceTemplateLength);\n const referenceTemplateY = new Int32Array(referenceTemplateLength);\n for (k = 0; k < referenceTemplateLength; k++) {\n referenceTemplateX[k] = referenceTemplate[k].x;\n referenceTemplateY[k] = referenceTemplate[k].y;\n }\n const referenceWidth = referenceBitmap[0].length;\n const referenceHeight = referenceBitmap.length;\n\n const pseudoPixelContext = RefinementReusedContexts[templateIndex];\n const bitmap = [];\n\n const decoder = decodingContext.decoder;\n const contexts = decodingContext.contextCache.getContexts(\"GR\");\n\n let ltp = 0;\n for (let i = 0; i < height; i++) {\n if (prediction) {\n const sltp = decoder.readBit(contexts, pseudoPixelContext);\n ltp ^= sltp;\n if (ltp) {\n throw new Jbig2Error(\"prediction is not supported\");\n }\n }\n const row = new Uint8Array(width);\n bitmap.push(row);\n for (let j = 0; j < width; j++) {\n let i0, j0;\n let contextLabel = 0;\n for (k = 0; k < codingTemplateLength; k++) {\n i0 = i + codingTemplateY[k];\n j0 = j + codingTemplateX[k];\n if (i0 < 0 || j0 < 0 || j0 >= width) {\n contextLabel <<= 1; // out of bound pixel\n } else {\n contextLabel = (contextLabel << 1) | bitmap[i0][j0];\n }\n }\n for (k = 0; k < referenceTemplateLength; k++) {\n i0 = i + referenceTemplateY[k] - offsetY;\n j0 = j + referenceTemplateX[k] - offsetX;\n if (i0 < 0 || i0 >= referenceHeight || j0 < 0 || j0 >= referenceWidth) {\n contextLabel <<= 1; // out of bound pixel\n } else {\n contextLabel = (contextLabel << 1) | referenceBitmap[i0][j0];\n }\n }\n const pixel = decoder.readBit(contexts, contextLabel);\n row[j] = pixel;\n }\n }\n\n return bitmap;\n}\n\n// 6.5.5 Decoding the symbol dictionary\nfunction decodeSymbolDictionary(\n huffman,\n refinement,\n symbols,\n numberOfNewSymbols,\n numberOfExportedSymbols,\n huffmanTables,\n templateIndex,\n at,\n refinementTemplateIndex,\n refinementAt,\n decodingContext,\n huffmanInput\n) {\n if (huffman && refinement) {\n throw new Jbig2Error(\"symbol refinement with Huffman is not supported\");\n }\n\n const newSymbols = [];\n let currentHeight = 0;\n let symbolCodeLength = log2(symbols.length + numberOfNewSymbols);\n\n const decoder = decodingContext.decoder;\n const contextCache = decodingContext.contextCache;\n let tableB1, symbolWidths;\n if (huffman) {\n tableB1 = getStandardTable(1); // standard table B.1\n symbolWidths = [];\n symbolCodeLength = Math.max(symbolCodeLength, 1); // 6.5.8.2.3\n }\n\n while (newSymbols.length < numberOfNewSymbols) {\n const deltaHeight = huffman\n ? huffmanTables.tableDeltaHeight.decode(huffmanInput)\n : decodeInteger(contextCache, \"IADH\", decoder); // 6.5.6\n currentHeight += deltaHeight;\n let currentWidth = 0,\n totalWidth = 0;\n const firstSymbol = huffman ? symbolWidths.length : 0;\n while (true) {\n const deltaWidth = huffman\n ? huffmanTables.tableDeltaWidth.decode(huffmanInput)\n : decodeInteger(contextCache, \"IADW\", decoder); // 6.5.7\n if (deltaWidth === null) {\n break; // OOB\n }\n currentWidth += deltaWidth;\n totalWidth += currentWidth;\n let bitmap;\n if (refinement) {\n // 6.5.8.2 Refinement/aggregate-coded symbol bitmap\n const numberOfInstances = decodeInteger(contextCache, \"IAAI\", decoder);\n if (numberOfInstances > 1) {\n bitmap = decodeTextRegion(\n huffman,\n refinement,\n currentWidth,\n currentHeight,\n 0,\n numberOfInstances,\n 1, // strip size\n symbols.concat(newSymbols),\n symbolCodeLength,\n 0, // transposed\n 0, // ds offset\n 1, // top left 7.4.3.1.1\n 0, // OR operator\n huffmanTables,\n refinementTemplateIndex,\n refinementAt,\n decodingContext,\n 0,\n huffmanInput\n );\n } else {\n const symbolId = decodeIAID(contextCache, decoder, symbolCodeLength);\n const rdx = decodeInteger(contextCache, \"IARDX\", decoder); // 6.4.11.3\n const rdy = decodeInteger(contextCache, \"IARDY\", decoder); // 6.4.11.4\n const symbol =\n symbolId < symbols.length\n ? symbols[symbolId]\n : newSymbols[symbolId - symbols.length];\n bitmap = decodeRefinement(\n currentWidth,\n currentHeight,\n refinementTemplateIndex,\n symbol,\n rdx,\n rdy,\n false,\n refinementAt,\n decodingContext\n );\n }\n newSymbols.push(bitmap);\n } else if (huffman) {\n // Store only symbol width and decode a collective bitmap when the\n // height class is done.\n symbolWidths.push(currentWidth);\n } else {\n // 6.5.8.1 Direct-coded symbol bitmap\n bitmap = decodeBitmap(\n false,\n currentWidth,\n currentHeight,\n templateIndex,\n false,\n null,\n at,\n decodingContext\n );\n newSymbols.push(bitmap);\n }\n }\n if (huffman && !refinement) {\n // 6.5.9 Height class collective bitmap\n const bitmapSize = huffmanTables.tableBitmapSize.decode(huffmanInput);\n huffmanInput.byteAlign();\n let collectiveBitmap;\n if (bitmapSize === 0) {\n // Uncompressed collective bitmap\n collectiveBitmap = readUncompressedBitmap(\n huffmanInput,\n totalWidth,\n currentHeight\n );\n } else {\n // MMR collective bitmap\n const originalEnd = huffmanInput.end;\n const bitmapEnd = huffmanInput.position + bitmapSize;\n huffmanInput.end = bitmapEnd;\n collectiveBitmap = decodeMMRBitmap(\n huffmanInput,\n totalWidth,\n currentHeight,\n false\n );\n huffmanInput.end = originalEnd;\n huffmanInput.position = bitmapEnd;\n }\n const numberOfSymbolsDecoded = symbolWidths.length;\n if (firstSymbol === numberOfSymbolsDecoded - 1) {\n // collectiveBitmap is a single symbol.\n newSymbols.push(collectiveBitmap);\n } else {\n // Divide collectiveBitmap into symbols.\n let i,\n y,\n xMin = 0,\n xMax,\n bitmapWidth,\n symbolBitmap;\n for (i = firstSymbol; i < numberOfSymbolsDecoded; i++) {\n bitmapWidth = symbolWidths[i];\n xMax = xMin + bitmapWidth;\n symbolBitmap = [];\n for (y = 0; y < currentHeight; y++) {\n symbolBitmap.push(collectiveBitmap[y].subarray(xMin, xMax));\n }\n newSymbols.push(symbolBitmap);\n xMin = xMax;\n }\n }\n }\n }\n\n // 6.5.10 Exported symbols\n const exportedSymbols = [],\n flags = [];\n let currentFlag = false,\n i,\n ii;\n const totalSymbolsLength = symbols.length + numberOfNewSymbols;\n while (flags.length < totalSymbolsLength) {\n let runLength = huffman\n ? tableB1.decode(huffmanInput)\n : decodeInteger(contextCache, \"IAEX\", decoder);\n while (runLength--) {\n flags.push(currentFlag);\n }\n currentFlag = !currentFlag;\n }\n for (i = 0, ii = symbols.length; i < ii; i++) {\n if (flags[i]) {\n exportedSymbols.push(symbols[i]);\n }\n }\n for (let j = 0; j < numberOfNewSymbols; i++, j++) {\n if (flags[i]) {\n exportedSymbols.push(newSymbols[j]);\n }\n }\n return exportedSymbols;\n}\n\nfunction decodeTextRegion(\n huffman,\n refinement,\n width,\n height,\n defaultPixelValue,\n numberOfSymbolInstances,\n stripSize,\n inputSymbols,\n symbolCodeLength,\n transposed,\n dsOffset,\n referenceCorner,\n combinationOperator,\n huffmanTables,\n refinementTemplateIndex,\n refinementAt,\n decodingContext,\n logStripSize,\n huffmanInput\n) {\n if (huffman && refinement) {\n throw new Jbig2Error(\"refinement with Huffman is not supported\");\n }\n\n // Prepare bitmap\n const bitmap = [];\n let i, row;\n for (i = 0; i < height; i++) {\n row = new Uint8Array(width);\n if (defaultPixelValue) {\n for (let j = 0; j < width; j++) {\n row[j] = defaultPixelValue;\n }\n }\n bitmap.push(row);\n }\n\n const decoder = decodingContext.decoder;\n const contextCache = decodingContext.contextCache;\n\n let stripT = huffman\n ? -huffmanTables.tableDeltaT.decode(huffmanInput)\n : -decodeInteger(contextCache, \"IADT\", decoder); // 6.4.6\n let firstS = 0;\n i = 0;\n while (i < numberOfSymbolInstances) {\n const deltaT = huffman\n ? huffmanTables.tableDeltaT.decode(huffmanInput)\n : decodeInteger(contextCache, \"IADT\", decoder); // 6.4.6\n stripT += deltaT;\n\n const deltaFirstS = huffman\n ? huffmanTables.tableFirstS.decode(huffmanInput)\n : decodeInteger(contextCache, \"IAFS\", decoder); // 6.4.7\n firstS += deltaFirstS;\n let currentS = firstS;\n do {\n let currentT = 0; // 6.4.9\n if (stripSize > 1) {\n currentT = huffman\n ? huffmanInput.readBits(logStripSize)\n : decodeInteger(contextCache, \"IAIT\", decoder);\n }\n const t = stripSize * stripT + currentT;\n const symbolId = huffman\n ? huffmanTables.symbolIDTable.decode(huffmanInput)\n : decodeIAID(contextCache, decoder, symbolCodeLength);\n const applyRefinement =\n refinement &&\n (huffman\n ? huffmanInput.readBit()\n : decodeInteger(contextCache, \"IARI\", decoder));\n let symbolBitmap = inputSymbols[symbolId];\n let symbolWidth = symbolBitmap[0].length;\n let symbolHeight = symbolBitmap.length;\n if (applyRefinement) {\n const rdw = decodeInteger(contextCache, \"IARDW\", decoder); // 6.4.11.1\n const rdh = decodeInteger(contextCache, \"IARDH\", decoder); // 6.4.11.2\n const rdx = decodeInteger(contextCache, \"IARDX\", decoder); // 6.4.11.3\n const rdy = decodeInteger(contextCache, \"IARDY\", decoder); // 6.4.11.4\n symbolWidth += rdw;\n symbolHeight += rdh;\n symbolBitmap = decodeRefinement(\n symbolWidth,\n symbolHeight,\n refinementTemplateIndex,\n symbolBitmap,\n (rdw >> 1) + rdx,\n (rdh >> 1) + rdy,\n false,\n refinementAt,\n decodingContext\n );\n }\n const offsetT = t - (referenceCorner & 1 ? 0 : symbolHeight - 1);\n const offsetS = currentS - (referenceCorner & 2 ? symbolWidth - 1 : 0);\n let s2, t2, symbolRow;\n if (transposed) {\n // Place Symbol Bitmap from T1,S1\n for (s2 = 0; s2 < symbolHeight; s2++) {\n row = bitmap[offsetS + s2];\n if (!row) {\n continue;\n }\n symbolRow = symbolBitmap[s2];\n // To ignore Parts of Symbol bitmap which goes\n // outside bitmap region\n const maxWidth = Math.min(width - offsetT, symbolWidth);\n switch (combinationOperator) {\n case 0: // OR\n for (t2 = 0; t2 < maxWidth; t2++) {\n row[offsetT + t2] |= symbolRow[t2];\n }\n break;\n case 2: // XOR\n for (t2 = 0; t2 < maxWidth; t2++) {\n row[offsetT + t2] ^= symbolRow[t2];\n }\n break;\n default:\n throw new Jbig2Error(\n `operator ${combinationOperator} is not supported`\n );\n }\n }\n currentS += symbolHeight - 1;\n } else {\n for (t2 = 0; t2 < symbolHeight; t2++) {\n row = bitmap[offsetT + t2];\n if (!row) {\n continue;\n }\n symbolRow = symbolBitmap[t2];\n switch (combinationOperator) {\n case 0: // OR\n for (s2 = 0; s2 < symbolWidth; s2++) {\n row[offsetS + s2] |= symbolRow[s2];\n }\n break;\n case 2: // XOR\n for (s2 = 0; s2 < symbolWidth; s2++) {\n row[offsetS + s2] ^= symbolRow[s2];\n }\n break;\n default:\n throw new Jbig2Error(\n `operator ${combinationOperator} is not supported`\n );\n }\n }\n currentS += symbolWidth - 1;\n }\n i++;\n const deltaS = huffman\n ? huffmanTables.tableDeltaS.decode(huffmanInput)\n : decodeInteger(contextCache, \"IADS\", decoder); // 6.4.8\n if (deltaS === null) {\n break; // OOB\n }\n currentS += deltaS + dsOffset;\n } while (true);\n }\n return bitmap;\n}\n\nfunction decodePatternDictionary(\n mmr,\n patternWidth,\n patternHeight,\n maxPatternIndex,\n template,\n decodingContext\n) {\n const at = [];\n if (!mmr) {\n at.push({\n x: -patternWidth,\n y: 0,\n });\n if (template === 0) {\n at.push(\n {\n x: -3,\n y: -1,\n },\n {\n x: 2,\n y: -2,\n },\n {\n x: -2,\n y: -2,\n }\n );\n }\n }\n const collectiveWidth = (maxPatternIndex + 1) * patternWidth;\n const collectiveBitmap = decodeBitmap(\n mmr,\n collectiveWidth,\n patternHeight,\n template,\n false,\n null,\n at,\n decodingContext\n );\n // Divide collective bitmap into patterns.\n const patterns = [];\n for (let i = 0; i <= maxPatternIndex; i++) {\n const patternBitmap = [];\n const xMin = patternWidth * i;\n const xMax = xMin + patternWidth;\n for (let y = 0; y < patternHeight; y++) {\n patternBitmap.push(collectiveBitmap[y].subarray(xMin, xMax));\n }\n patterns.push(patternBitmap);\n }\n return patterns;\n}\n\nfunction decodeHalftoneRegion(\n mmr,\n patterns,\n template,\n regionWidth,\n regionHeight,\n defaultPixelValue,\n enableSkip,\n combinationOperator,\n gridWidth,\n gridHeight,\n gridOffsetX,\n gridOffsetY,\n gridVectorX,\n gridVectorY,\n decodingContext\n) {\n const skip = null;\n if (enableSkip) {\n throw new Jbig2Error(\"skip is not supported\");\n }\n if (combinationOperator !== 0) {\n throw new Jbig2Error(\n `operator \"${combinationOperator}\" is not supported in halftone region`\n );\n }\n\n // Prepare bitmap.\n const regionBitmap = [];\n let i, j, row;\n for (i = 0; i < regionHeight; i++) {\n row = new Uint8Array(regionWidth);\n if (defaultPixelValue) {\n for (j = 0; j < regionWidth; j++) {\n row[j] = defaultPixelValue;\n }\n }\n regionBitmap.push(row);\n }\n\n const numberOfPatterns = patterns.length;\n const pattern0 = patterns[0];\n const patternWidth = pattern0[0].length,\n patternHeight = pattern0.length;\n const bitsPerValue = log2(numberOfPatterns);\n const at = [];\n if (!mmr) {\n at.push({\n x: template <= 1 ? 3 : 2,\n y: -1,\n });\n if (template === 0) {\n at.push(\n {\n x: -3,\n y: -1,\n },\n {\n x: 2,\n y: -2,\n },\n {\n x: -2,\n y: -2,\n }\n );\n }\n }\n // Annex C. Gray-scale Image Decoding Procedure.\n const grayScaleBitPlanes = [];\n let mmrInput, bitmap;\n if (mmr) {\n // MMR bit planes are in one continuous stream. Only EOFB codes indicate\n // the end of each bitmap, so EOFBs must be decoded.\n mmrInput = new Reader(\n decodingContext.data,\n decodingContext.start,\n decodingContext.end\n );\n }\n for (i = bitsPerValue - 1; i >= 0; i--) {\n if (mmr) {\n bitmap = decodeMMRBitmap(mmrInput, gridWidth, gridHeight, true);\n } else {\n bitmap = decodeBitmap(\n false,\n gridWidth,\n gridHeight,\n template,\n false,\n skip,\n at,\n decodingContext\n );\n }\n grayScaleBitPlanes[i] = bitmap;\n }\n // 6.6.5.2 Rendering the patterns.\n let mg, ng, bit, patternIndex, patternBitmap, x, y, patternRow, regionRow;\n for (mg = 0; mg < gridHeight; mg++) {\n for (ng = 0; ng < gridWidth; ng++) {\n bit = 0;\n patternIndex = 0;\n for (j = bitsPerValue - 1; j >= 0; j--) {\n bit ^= grayScaleBitPlanes[j][mg][ng]; // Gray decoding\n patternIndex |= bit << j;\n }\n patternBitmap = patterns[patternIndex];\n x = (gridOffsetX + mg * gridVectorY + ng * gridVectorX) >> 8;\n y = (gridOffsetY + mg * gridVectorX - ng * gridVectorY) >> 8;\n // Draw patternBitmap at (x, y).\n if (\n x >= 0 &&\n x + patternWidth <= regionWidth &&\n y >= 0 &&\n y + patternHeight <= regionHeight\n ) {\n for (i = 0; i < patternHeight; i++) {\n regionRow = regionBitmap[y + i];\n patternRow = patternBitmap[i];\n for (j = 0; j < patternWidth; j++) {\n regionRow[x + j] |= patternRow[j];\n }\n }\n } else {\n let regionX, regionY;\n for (i = 0; i < patternHeight; i++) {\n regionY = y + i;\n if (regionY < 0 || regionY >= regionHeight) {\n continue;\n }\n regionRow = regionBitmap[regionY];\n patternRow = patternBitmap[i];\n for (j = 0; j < patternWidth; j++) {\n regionX = x + j;\n if (regionX >= 0 && regionX < regionWidth) {\n regionRow[regionX] |= patternRow[j];\n }\n }\n }\n }\n }\n }\n return regionBitmap;\n}\n\nfunction readSegmentHeader(data, start) {\n const segmentHeader = {};\n segmentHeader.number = readUint32(data, start);\n const flags = data[start + 4];\n const segmentType = flags & 0x3f;\n if (!SegmentTypes[segmentType]) {\n throw new Jbig2Error(\"invalid segment type: \" + segmentType);\n }\n segmentHeader.type = segmentType;\n segmentHeader.typeName = SegmentTypes[segmentType];\n segmentHeader.deferredNonRetain = !!(flags & 0x80);\n\n const pageAssociationFieldSize = !!(flags & 0x40);\n const referredFlags = data[start + 5];\n let referredToCount = (referredFlags >> 5) & 7;\n const retainBits = [referredFlags & 31];\n let position = start + 6;\n if (referredFlags === 7) {\n referredToCount = readUint32(data, position - 1) & 0x1fffffff;\n position += 3;\n let bytes = (referredToCount + 7) >> 3;\n retainBits[0] = data[position++];\n while (--bytes > 0) {\n retainBits.push(data[position++]);\n }\n } else if (referredFlags === 5 || referredFlags === 6) {\n throw new Jbig2Error(\"invalid referred-to flags\");\n }\n\n segmentHeader.retainBits = retainBits;\n\n let referredToSegmentNumberSize = 4;\n if (segmentHeader.number <= 256) {\n referredToSegmentNumberSize = 1;\n } else if (segmentHeader.number <= 65536) {\n referredToSegmentNumberSize = 2;\n }\n const referredTo = [];\n let i, ii;\n for (i = 0; i < referredToCount; i++) {\n let number;\n if (referredToSegmentNumberSize === 1) {\n number = data[position];\n } else if (referredToSegmentNumberSize === 2) {\n number = readUint16(data, position);\n } else {\n number = readUint32(data, position);\n }\n referredTo.push(number);\n position += referredToSegmentNumberSize;\n }\n segmentHeader.referredTo = referredTo;\n if (!pageAssociationFieldSize) {\n segmentHeader.pageAssociation = data[position++];\n } else {\n segmentHeader.pageAssociation = readUint32(data, position);\n position += 4;\n }\n segmentHeader.length = readUint32(data, position);\n position += 4;\n\n if (segmentHeader.length === 0xffffffff) {\n // 7.2.7 Segment data length, unknown segment length\n if (segmentType === 38) {\n // ImmediateGenericRegion\n const genericRegionInfo = readRegionSegmentInformation(data, position);\n const genericRegionSegmentFlags =\n data[position + RegionSegmentInformationFieldLength];\n const genericRegionMmr = !!(genericRegionSegmentFlags & 1);\n // searching for the segment end\n const searchPatternLength = 6;\n const searchPattern = new Uint8Array(searchPatternLength);\n if (!genericRegionMmr) {\n searchPattern[0] = 0xff;\n searchPattern[1] = 0xac;\n }\n searchPattern[2] = (genericRegionInfo.height >>> 24) & 0xff;\n searchPattern[3] = (genericRegionInfo.height >> 16) & 0xff;\n searchPattern[4] = (genericRegionInfo.height >> 8) & 0xff;\n searchPattern[5] = genericRegionInfo.height & 0xff;\n for (i = position, ii = data.length; i < ii; i++) {\n let j = 0;\n while (j < searchPatternLength && searchPattern[j] === data[i + j]) {\n j++;\n }\n if (j === searchPatternLength) {\n segmentHeader.length = i + searchPatternLength;\n break;\n }\n }\n if (segmentHeader.length === 0xffffffff) {\n throw new Jbig2Error(\"segment end was not found\");\n }\n } else {\n throw new Jbig2Error(\"invalid unknown segment length\");\n }\n }\n segmentHeader.headerEnd = position;\n return segmentHeader;\n}\n\nfunction readSegments(header, data, start, end) {\n const segments = [];\n let position = start;\n while (position < end) {\n const segmentHeader = readSegmentHeader(data, position);\n position = segmentHeader.headerEnd;\n const segment = {\n header: segmentHeader,\n data,\n };\n if (!header.randomAccess) {\n segment.start = position;\n position += segmentHeader.length;\n segment.end = position;\n }\n segments.push(segment);\n if (segmentHeader.type === 51) {\n break; // end of file is found\n }\n }\n if (header.randomAccess) {\n for (let i = 0, ii = segments.length; i < ii; i++) {\n segments[i].start = position;\n position += segments[i].header.length;\n segments[i].end = position;\n }\n }\n return segments;\n}\n\n// 7.4.1 Region segment information field\nfunction readRegionSegmentInformation(data, start) {\n return {\n width: readUint32(data, start),\n height: readUint32(data, start + 4),\n x: readUint32(data, start + 8),\n y: readUint32(data, start + 12),\n combinationOperator: data[start + 16] & 7,\n };\n}\nconst RegionSegmentInformationFieldLength = 17;\n\nfunction processSegment(segment, visitor) {\n const header = segment.header;\n\n const data = segment.data,\n end = segment.end;\n let position = segment.start;\n let args, at, i, atLength;\n switch (header.type) {\n case 0: // SymbolDictionary\n // 7.4.2 Symbol dictionary segment syntax\n const dictionary = {};\n const dictionaryFlags = readUint16(data, position); // 7.4.2.1.1\n dictionary.huffman = !!(dictionaryFlags & 1);\n dictionary.refinement = !!(dictionaryFlags & 2);\n dictionary.huffmanDHSelector = (dictionaryFlags >> 2) & 3;\n dictionary.huffmanDWSelector = (dictionaryFlags >> 4) & 3;\n dictionary.bitmapSizeSelector = (dictionaryFlags >> 6) & 1;\n dictionary.aggregationInstancesSelector = (dictionaryFlags >> 7) & 1;\n dictionary.bitmapCodingContextUsed = !!(dictionaryFlags & 256);\n dictionary.bitmapCodingContextRetained = !!(dictionaryFlags & 512);\n dictionary.template = (dictionaryFlags >> 10) & 3;\n dictionary.refinementTemplate = (dictionaryFlags >> 12) & 1;\n position += 2;\n if (!dictionary.huffman) {\n atLength = dictionary.template === 0 ? 4 : 1;\n at = [];\n for (i = 0; i < atLength; i++) {\n at.push({\n x: readInt8(data, position),\n y: readInt8(data, position + 1),\n });\n position += 2;\n }\n dictionary.at = at;\n }\n if (dictionary.refinement && !dictionary.refinementTemplate) {\n at = [];\n for (i = 0; i < 2; i++) {\n at.push({\n x: readInt8(data, position),\n y: readInt8(data, position + 1),\n });\n position += 2;\n }\n dictionary.refinementAt = at;\n }\n dictionary.numberOfExportedSymbols = readUint32(data, position);\n position += 4;\n dictionary.numberOfNewSymbols = readUint32(data, position);\n position += 4;\n args = [\n dictionary,\n header.number,\n header.referredTo,\n data,\n position,\n end,\n ];\n break;\n case 6: // ImmediateTextRegion\n case 7: // ImmediateLosslessTextRegion\n const textRegion = {};\n textRegion.info = readRegionSegmentInformation(data, position);\n position += RegionSegmentInformationFieldLength;\n const textRegionSegmentFlags = readUint16(data, position);\n position += 2;\n textRegion.huffman = !!(textRegionSegmentFlags & 1);\n textRegion.refinement = !!(textRegionSegmentFlags & 2);\n textRegion.logStripSize = (textRegionSegmentFlags >> 2) & 3;\n textRegion.stripSize = 1 << textRegion.logStripSize;\n textRegion.referenceCorner = (textRegionSegmentFlags >> 4) & 3;\n textRegion.transposed = !!(textRegionSegmentFlags & 64);\n textRegion.combinationOperator = (textRegionSegmentFlags >> 7) & 3;\n textRegion.defaultPixelValue = (textRegionSegmentFlags >> 9) & 1;\n textRegion.dsOffset = (textRegionSegmentFlags << 17) >> 27;\n textRegion.refinementTemplate = (textRegionSegmentFlags >> 15) & 1;\n if (textRegion.huffman) {\n const textRegionHuffmanFlags = readUint16(data, position);\n position += 2;\n textRegion.huffmanFS = textRegionHuffmanFlags & 3;\n textRegion.huffmanDS = (textRegionHuffmanFlags >> 2) & 3;\n textRegion.huffmanDT = (textRegionHuffmanFlags >> 4) & 3;\n textRegion.huffmanRefinementDW = (textRegionHuffmanFlags >> 6) & 3;\n textRegion.huffmanRefinementDH = (textRegionHuffmanFlags >> 8) & 3;\n textRegion.huffmanRefinementDX = (textRegionHuffmanFlags >> 10) & 3;\n textRegion.huffmanRefinementDY = (textRegionHuffmanFlags >> 12) & 3;\n textRegion.huffmanRefinementSizeSelector = !!(\n textRegionHuffmanFlags & 0x4000\n );\n }\n if (textRegion.refinement && !textRegion.refinementTemplate) {\n at = [];\n for (i = 0; i < 2; i++) {\n at.push({\n x: readInt8(data, position),\n y: readInt8(data, position + 1),\n });\n position += 2;\n }\n textRegion.refinementAt = at;\n }\n textRegion.numberOfSymbolInstances = readUint32(data, position);\n position += 4;\n args = [textRegion, header.referredTo, data, position, end];\n break;\n case 16: // PatternDictionary\n // 7.4.4. Pattern dictionary segment syntax\n const patternDictionary = {};\n const patternDictionaryFlags = data[position++];\n patternDictionary.mmr = !!(patternDictionaryFlags & 1);\n patternDictionary.template = (patternDictionaryFlags >> 1) & 3;\n patternDictionary.patternWidth = data[position++];\n patternDictionary.patternHeight = data[position++];\n patternDictionary.maxPatternIndex = readUint32(data, position);\n position += 4;\n args = [patternDictionary, header.number, data, position, end];\n break;\n case 22: // ImmediateHalftoneRegion\n case 23: // ImmediateLosslessHalftoneRegion\n // 7.4.5 Halftone region segment syntax\n const halftoneRegion = {};\n halftoneRegion.info = readRegionSegmentInformation(data, position);\n position += RegionSegmentInformationFieldLength;\n const halftoneRegionFlags = data[position++];\n halftoneRegion.mmr = !!(halftoneRegionFlags & 1);\n halftoneRegion.template = (halftoneRegionFlags >> 1) & 3;\n halftoneRegion.enableSkip = !!(halftoneRegionFlags & 8);\n halftoneRegion.combinationOperator = (halftoneRegionFlags >> 4) & 7;\n halftoneRegion.defaultPixelValue = (halftoneRegionFlags >> 7) & 1;\n halftoneRegion.gridWidth = readUint32(data, position);\n position += 4;\n halftoneRegion.gridHeight = readUint32(data, position);\n position += 4;\n halftoneRegion.gridOffsetX = readUint32(data, position) & 0xffffffff;\n position += 4;\n halftoneRegion.gridOffsetY = readUint32(data, position) & 0xffffffff;\n position += 4;\n halftoneRegion.gridVectorX = readUint16(data, position);\n position += 2;\n halftoneRegion.gridVectorY = readUint16(data, position);\n position += 2;\n args = [halftoneRegion, header.referredTo, data, position, end];\n break;\n case 38: // ImmediateGenericRegion\n case 39: // ImmediateLosslessGenericRegion\n const genericRegion = {};\n genericRegion.info = readRegionSegmentInformation(data, position);\n position += RegionSegmentInformationFieldLength;\n const genericRegionSegmentFlags = data[position++];\n genericRegion.mmr = !!(genericRegionSegmentFlags & 1);\n genericRegion.template = (genericRegionSegmentFlags >> 1) & 3;\n genericRegion.prediction = !!(genericRegionSegmentFlags & 8);\n if (!genericRegion.mmr) {\n atLength = genericRegion.template === 0 ? 4 : 1;\n at = [];\n for (i = 0; i < atLength; i++) {\n at.push({\n x: readInt8(data, position),\n y: readInt8(data, position + 1),\n });\n position += 2;\n }\n genericRegion.at = at;\n }\n args = [genericRegion, data, position, end];\n break;\n case 48: // PageInformation\n const pageInfo = {\n width: readUint32(data, position),\n height: readUint32(data, position + 4),\n resolutionX: readUint32(data, position + 8),\n resolutionY: readUint32(data, position + 12),\n };\n if (pageInfo.height === 0xffffffff) {\n delete pageInfo.height;\n }\n const pageSegmentFlags = data[position + 16];\n readUint16(data, position + 17); // pageStripingInformation\n pageInfo.lossless = !!(pageSegmentFlags & 1);\n pageInfo.refinement = !!(pageSegmentFlags & 2);\n pageInfo.defaultPixelValue = (pageSegmentFlags >> 2) & 1;\n pageInfo.combinationOperator = (pageSegmentFlags >> 3) & 3;\n pageInfo.requiresBuffer = !!(pageSegmentFlags & 32);\n pageInfo.combinationOperatorOverride = !!(pageSegmentFlags & 64);\n args = [pageInfo];\n break;\n case 49: // EndOfPage\n break;\n case 50: // EndOfStripe\n break;\n case 51: // EndOfFile\n break;\n case 53: // Tables\n args = [header.number, data, position, end];\n break;\n case 62: // 7.4.15 defines 2 extension types which\n // are comments and can be ignored.\n break;\n default:\n throw new Jbig2Error(\n `segment type ${header.typeName}(${header.type}) is not implemented`\n );\n }\n const callbackName = \"on\" + header.typeName;\n if (callbackName in visitor) {\n // eslint-disable-next-line prefer-spread\n visitor[callbackName].apply(visitor, args);\n }\n}\n\nfunction processSegments(segments, visitor) {\n for (let i = 0, ii = segments.length; i < ii; i++) {\n processSegment(segments[i], visitor);\n }\n}\n\nfunction parseJbig2Chunks(chunks) {\n const visitor = new SimpleSegmentVisitor();\n for (let i = 0, ii = chunks.length; i < ii; i++) {\n const chunk = chunks[i];\n const segments = readSegments({}, chunk.data, chunk.start, chunk.end);\n processSegments(segments, visitor);\n }\n return visitor.buffer;\n}\n\nfunction parseJbig2(data) {\n if (typeof PDFJSDev === \"undefined\" || !PDFJSDev.test(\"IMAGE_DECODERS\")) {\n throw new Error(\"Not implemented: parseJbig2\");\n }\n const end = data.length;\n let position = 0;\n\n if (\n data[position] !== 0x97 ||\n data[position + 1] !== 0x4a ||\n data[position + 2] !== 0x42 ||\n data[position + 3] !== 0x32 ||\n data[position + 4] !== 0x0d ||\n data[position + 5] !== 0x0a ||\n data[position + 6] !== 0x1a ||\n data[position + 7] !== 0x0a\n ) {\n throw new Jbig2Error(\"parseJbig2 - invalid header.\");\n }\n\n const header = Object.create(null);\n position += 8;\n const flags = data[position++];\n header.randomAccess = !(flags & 1);\n if (!(flags & 2)) {\n header.numberOfPages = readUint32(data, position);\n position += 4;\n }\n\n const segments = readSegments(header, data, position, end);\n const visitor = new SimpleSegmentVisitor();\n processSegments(segments, visitor);\n\n const { width, height } = visitor.currentPageInfo;\n const bitPacked = visitor.buffer;\n const imgData = new Uint8ClampedArray(width * height);\n let q = 0,\n k = 0;\n for (let i = 0; i < height; i++) {\n let mask = 0,\n buffer;\n for (let j = 0; j < width; j++) {\n if (!mask) {\n mask = 128;\n buffer = bitPacked[k++];\n }\n imgData[q++] = buffer & mask ? 0 : 255;\n mask >>= 1;\n }\n }\n\n return { imgData, width, height };\n}\n\nclass SimpleSegmentVisitor {\n onPageInformation(info) {\n this.currentPageInfo = info;\n const rowSize = (info.width + 7) >> 3;\n const buffer = new Uint8ClampedArray(rowSize * info.height);\n // The contents of ArrayBuffers are initialized to 0.\n // Fill the buffer with 0xFF only if info.defaultPixelValue is set\n if (info.defaultPixelValue) {\n buffer.fill(0xff);\n }\n this.buffer = buffer;\n }\n\n drawBitmap(regionInfo, bitmap) {\n const pageInfo = this.currentPageInfo;\n const width = regionInfo.width,\n height = regionInfo.height;\n const rowSize = (pageInfo.width + 7) >> 3;\n const combinationOperator = pageInfo.combinationOperatorOverride\n ? regionInfo.combinationOperator\n : pageInfo.combinationOperator;\n const buffer = this.buffer;\n const mask0 = 128 >> (regionInfo.x & 7);\n let offset0 = regionInfo.y * rowSize + (regionInfo.x >> 3);\n let i, j, mask, offset;\n switch (combinationOperator) {\n case 0: // OR\n for (i = 0; i < height; i++) {\n mask = mask0;\n offset = offset0;\n for (j = 0; j < width; j++) {\n if (bitmap[i][j]) {\n buffer[offset] |= mask;\n }\n mask >>= 1;\n if (!mask) {\n mask = 128;\n offset++;\n }\n }\n offset0 += rowSize;\n }\n break;\n case 2: // XOR\n for (i = 0; i < height; i++) {\n mask = mask0;\n offset = offset0;\n for (j = 0; j < width; j++) {\n if (bitmap[i][j]) {\n buffer[offset] ^= mask;\n }\n mask >>= 1;\n if (!mask) {\n mask = 128;\n offset++;\n }\n }\n offset0 += rowSize;\n }\n break;\n default:\n throw new Jbig2Error(\n `operator ${combinationOperator} is not supported`\n );\n }\n }\n\n onImmediateGenericRegion(region, data, start, end) {\n const regionInfo = region.info;\n const decodingContext = new DecodingContext(data, start, end);\n const bitmap = decodeBitmap(\n region.mmr,\n regionInfo.width,\n regionInfo.height,\n region.template,\n region.prediction,\n null,\n region.at,\n decodingContext\n );\n this.drawBitmap(regionInfo, bitmap);\n }\n\n onImmediateLosslessGenericRegion() {\n this.onImmediateGenericRegion(...arguments);\n }\n\n onSymbolDictionary(\n dictionary,\n currentSegment,\n referredSegments,\n data,\n start,\n end\n ) {\n let huffmanTables, huffmanInput;\n if (dictionary.huffman) {\n huffmanTables = getSymbolDictionaryHuffmanTables(\n dictionary,\n referredSegments,\n this.customTables\n );\n huffmanInput = new Reader(data, start, end);\n }\n\n // Combines exported symbols from all referred segments\n let symbols = this.symbols;\n if (!symbols) {\n this.symbols = symbols = {};\n }\n\n const inputSymbols = [];\n for (const referredSegment of referredSegments) {\n const referredSymbols = symbols[referredSegment];\n // referredSymbols is undefined when we have a reference to a Tables\n // segment instead of a SymbolDictionary.\n if (referredSymbols) {\n inputSymbols.push(...referredSymbols);\n }\n }\n\n const decodingContext = new DecodingContext(data, start, end);\n symbols[currentSegment] = decodeSymbolDictionary(\n dictionary.huffman,\n dictionary.refinement,\n inputSymbols,\n dictionary.numberOfNewSymbols,\n dictionary.numberOfExportedSymbols,\n huffmanTables,\n dictionary.template,\n dictionary.at,\n dictionary.refinementTemplate,\n dictionary.refinementAt,\n decodingContext,\n huffmanInput\n );\n }\n\n onImmediateTextRegion(region, referredSegments, data, start, end) {\n const regionInfo = region.info;\n let huffmanTables, huffmanInput;\n\n // Combines exported symbols from all referred segments\n const symbols = this.symbols;\n const inputSymbols = [];\n for (const referredSegment of referredSegments) {\n const referredSymbols = symbols[referredSegment];\n // referredSymbols is undefined when we have a reference to a Tables\n // segment instead of a SymbolDictionary.\n if (referredSymbols) {\n inputSymbols.push(...referredSymbols);\n }\n }\n const symbolCodeLength = log2(inputSymbols.length);\n if (region.huffman) {\n huffmanInput = new Reader(data, start, end);\n huffmanTables = getTextRegionHuffmanTables(\n region,\n referredSegments,\n this.customTables,\n inputSymbols.length,\n huffmanInput\n );\n }\n\n const decodingContext = new DecodingContext(data, start, end);\n const bitmap = decodeTextRegion(\n region.huffman,\n region.refinement,\n regionInfo.width,\n regionInfo.height,\n region.defaultPixelValue,\n region.numberOfSymbolInstances,\n region.stripSize,\n inputSymbols,\n symbolCodeLength,\n region.transposed,\n region.dsOffset,\n region.referenceCorner,\n region.combinationOperator,\n huffmanTables,\n region.refinementTemplate,\n region.refinementAt,\n decodingContext,\n region.logStripSize,\n huffmanInput\n );\n this.drawBitmap(regionInfo, bitmap);\n }\n\n onImmediateLosslessTextRegion() {\n this.onImmediateTextRegion(...arguments);\n }\n\n onPatternDictionary(dictionary, currentSegment, data, start, end) {\n let patterns = this.patterns;\n if (!patterns) {\n this.patterns = patterns = {};\n }\n const decodingContext = new DecodingContext(data, start, end);\n patterns[currentSegment] = decodePatternDictionary(\n dictionary.mmr,\n dictionary.patternWidth,\n dictionary.patternHeight,\n dictionary.maxPatternIndex,\n dictionary.template,\n decodingContext\n );\n }\n\n onImmediateHalftoneRegion(region, referredSegments, data, start, end) {\n // HalftoneRegion refers to exactly one PatternDictionary.\n const patterns = this.patterns[referredSegments[0]];\n const regionInfo = region.info;\n const decodingContext = new DecodingContext(data, start, end);\n const bitmap = decodeHalftoneRegion(\n region.mmr,\n patterns,\n region.template,\n regionInfo.width,\n regionInfo.height,\n region.defaultPixelValue,\n region.enableSkip,\n region.combinationOperator,\n region.gridWidth,\n region.gridHeight,\n region.gridOffsetX,\n region.gridOffsetY,\n region.gridVectorX,\n region.gridVectorY,\n decodingContext\n );\n this.drawBitmap(regionInfo, bitmap);\n }\n\n onImmediateLosslessHalftoneRegion() {\n this.onImmediateHalftoneRegion(...arguments);\n }\n\n onTables(currentSegment, data, start, end) {\n let customTables = this.customTables;\n if (!customTables) {\n this.customTables = customTables = {};\n }\n customTables[currentSegment] = decodeTablesSegment(data, start, end);\n }\n}\n\nclass HuffmanLine {\n constructor(lineData) {\n if (lineData.length === 2) {\n // OOB line.\n this.isOOB = true;\n this.rangeLow = 0;\n this.prefixLength = lineData[0];\n this.rangeLength = 0;\n this.prefixCode = lineData[1];\n this.isLowerRange = false;\n } else {\n // Normal, upper range or lower range line.\n // Upper range lines are processed like normal lines.\n this.isOOB = false;\n this.rangeLow = lineData[0];\n this.prefixLength = lineData[1];\n this.rangeLength = lineData[2];\n this.prefixCode = lineData[3];\n this.isLowerRange = lineData[4] === \"lower\";\n }\n }\n}\n\nclass HuffmanTreeNode {\n constructor(line) {\n this.children = [];\n if (line) {\n // Leaf node\n this.isLeaf = true;\n this.rangeLength = line.rangeLength;\n this.rangeLow = line.rangeLow;\n this.isLowerRange = line.isLowerRange;\n this.isOOB = line.isOOB;\n } else {\n // Intermediate or root node\n this.isLeaf = false;\n }\n }\n\n buildTree(line, shift) {\n const bit = (line.prefixCode >> shift) & 1;\n if (shift <= 0) {\n // Create a leaf node.\n this.children[bit] = new HuffmanTreeNode(line);\n } else {\n // Create an intermediate node and continue recursively.\n let node = this.children[bit];\n if (!node) {\n this.children[bit] = node = new HuffmanTreeNode(null);\n }\n node.buildTree(line, shift - 1);\n }\n }\n\n decodeNode(reader) {\n if (this.isLeaf) {\n if (this.isOOB) {\n return null;\n }\n const htOffset = reader.readBits(this.rangeLength);\n return this.rangeLow + (this.isLowerRange ? -htOffset : htOffset);\n }\n const node = this.children[reader.readBit()];\n if (!node) {\n throw new Jbig2Error(\"invalid Huffman data\");\n }\n return node.decodeNode(reader);\n }\n}\n\nclass HuffmanTable {\n constructor(lines, prefixCodesDone) {\n if (!prefixCodesDone) {\n this.assignPrefixCodes(lines);\n }\n // Create Huffman tree.\n this.rootNode = new HuffmanTreeNode(null);\n for (let i = 0, ii = lines.length; i < ii; i++) {\n const line = lines[i];\n if (line.prefixLength > 0) {\n this.rootNode.buildTree(line, line.prefixLength - 1);\n }\n }\n }\n\n decode(reader) {\n return this.rootNode.decodeNode(reader);\n }\n\n assignPrefixCodes(lines) {\n // Annex B.3 Assigning the prefix codes.\n const linesLength = lines.length;\n let prefixLengthMax = 0;\n for (let i = 0; i < linesLength; i++) {\n prefixLengthMax = Math.max(prefixLengthMax, lines[i].prefixLength);\n }\n\n const histogram = new Uint32Array(prefixLengthMax + 1);\n for (let i = 0; i < linesLength; i++) {\n histogram[lines[i].prefixLength]++;\n }\n let currentLength = 1,\n firstCode = 0,\n currentCode,\n currentTemp,\n line;\n histogram[0] = 0;\n\n while (currentLength <= prefixLengthMax) {\n firstCode = (firstCode + histogram[currentLength - 1]) << 1;\n currentCode = firstCode;\n currentTemp = 0;\n while (currentTemp < linesLength) {\n line = lines[currentTemp];\n if (line.prefixLength === currentLength) {\n line.prefixCode = currentCode;\n currentCode++;\n }\n currentTemp++;\n }\n currentLength++;\n }\n }\n}\n\nfunction decodeTablesSegment(data, start, end) {\n // Decodes a Tables segment, i.e., a custom Huffman table.\n // Annex B.2 Code table structure.\n const flags = data[start];\n const lowestValue = readUint32(data, start + 1) & 0xffffffff;\n const highestValue = readUint32(data, start + 5) & 0xffffffff;\n const reader = new Reader(data, start + 9, end);\n\n const prefixSizeBits = ((flags >> 1) & 7) + 1;\n const rangeSizeBits = ((flags >> 4) & 7) + 1;\n const lines = [];\n let prefixLength,\n rangeLength,\n currentRangeLow = lowestValue;\n\n // Normal table lines\n do {\n prefixLength = reader.readBits(prefixSizeBits);\n rangeLength = reader.readBits(rangeSizeBits);\n lines.push(\n new HuffmanLine([currentRangeLow, prefixLength, rangeLength, 0])\n );\n currentRangeLow += 1 << rangeLength;\n } while (currentRangeLow < highestValue);\n\n // Lower range table line\n prefixLength = reader.readBits(prefixSizeBits);\n lines.push(new HuffmanLine([lowestValue - 1, prefixLength, 32, 0, \"lower\"]));\n\n // Upper range table line\n prefixLength = reader.readBits(prefixSizeBits);\n lines.push(new HuffmanLine([highestValue, prefixLength, 32, 0]));\n\n if (flags & 1) {\n // Out-of-band table line\n prefixLength = reader.readBits(prefixSizeBits);\n lines.push(new HuffmanLine([prefixLength, 0]));\n }\n\n return new HuffmanTable(lines, false);\n}\n\nconst standardTablesCache = {};\n\nfunction getStandardTable(number) {\n // Annex B.5 Standard Huffman tables.\n let table = standardTablesCache[number];\n if (table) {\n return table;\n }\n let lines;\n switch (number) {\n case 1:\n lines = [\n [0, 1, 4, 0x0],\n [16, 2, 8, 0x2],\n [272, 3, 16, 0x6],\n [65808, 3, 32, 0x7], // upper\n ];\n break;\n case 2:\n lines = [\n [0, 1, 0, 0x0],\n [1, 2, 0, 0x2],\n [2, 3, 0, 0x6],\n [3, 4, 3, 0xe],\n [11, 5, 6, 0x1e],\n [75, 6, 32, 0x3e], // upper\n [6, 0x3f], // OOB\n ];\n break;\n case 3:\n lines = [\n [-256, 8, 8, 0xfe],\n [0, 1, 0, 0x0],\n [1, 2, 0, 0x2],\n [2, 3, 0, 0x6],\n [3, 4, 3, 0xe],\n [11, 5, 6, 0x1e],\n [-257, 8, 32, 0xff, \"lower\"],\n [75, 7, 32, 0x7e], // upper\n [6, 0x3e], // OOB\n ];\n break;\n case 4:\n lines = [\n [1, 1, 0, 0x0],\n [2, 2, 0, 0x2],\n [3, 3, 0, 0x6],\n [4, 4, 3, 0xe],\n [12, 5, 6, 0x1e],\n [76, 5, 32, 0x1f], // upper\n ];\n break;\n case 5:\n lines = [\n [-255, 7, 8, 0x7e],\n [1, 1, 0, 0x0],\n [2, 2, 0, 0x2],\n [3, 3, 0, 0x6],\n [4, 4, 3, 0xe],\n [12, 5, 6, 0x1e],\n [-256, 7, 32, 0x7f, \"lower\"],\n [76, 6, 32, 0x3e], // upper\n ];\n break;\n case 6:\n lines = [\n [-2048, 5, 10, 0x1c],\n [-1024, 4, 9, 0x8],\n [-512, 4, 8, 0x9],\n [-256, 4, 7, 0xa],\n [-128, 5, 6, 0x1d],\n [-64, 5, 5, 0x1e],\n [-32, 4, 5, 0xb],\n [0, 2, 7, 0x0],\n [128, 3, 7, 0x2],\n [256, 3, 8, 0x3],\n [512, 4, 9, 0xc],\n [1024, 4, 10, 0xd],\n [-2049, 6, 32, 0x3e, \"lower\"],\n [2048, 6, 32, 0x3f], // upper\n ];\n break;\n case 7:\n lines = [\n [-1024, 4, 9, 0x8],\n [-512, 3, 8, 0x0],\n [-256, 4, 7, 0x9],\n [-128, 5, 6, 0x1a],\n [-64, 5, 5, 0x1b],\n [-32, 4, 5, 0xa],\n [0, 4, 5, 0xb],\n [32, 5, 5, 0x1c],\n [64, 5, 6, 0x1d],\n [128, 4, 7, 0xc],\n [256, 3, 8, 0x1],\n [512, 3, 9, 0x2],\n [1024, 3, 10, 0x3],\n [-1025, 5, 32, 0x1e, \"lower\"],\n [2048, 5, 32, 0x1f], // upper\n ];\n break;\n case 8:\n lines = [\n [-15, 8, 3, 0xfc],\n [-7, 9, 1, 0x1fc],\n [-5, 8, 1, 0xfd],\n [-3, 9, 0, 0x1fd],\n [-2, 7, 0, 0x7c],\n [-1, 4, 0, 0xa],\n [0, 2, 1, 0x0],\n [2, 5, 0, 0x1a],\n [3, 6, 0, 0x3a],\n [4, 3, 4, 0x4],\n [20, 6, 1, 0x3b],\n [22, 4, 4, 0xb],\n [38, 4, 5, 0xc],\n [70, 5, 6, 0x1b],\n [134, 5, 7, 0x1c],\n [262, 6, 7, 0x3c],\n [390, 7, 8, 0x7d],\n [646, 6, 10, 0x3d],\n [-16, 9, 32, 0x1fe, \"lower\"],\n [1670, 9, 32, 0x1ff], // upper\n [2, 0x1], // OOB\n ];\n break;\n case 9:\n lines = [\n [-31, 8, 4, 0xfc],\n [-15, 9, 2, 0x1fc],\n [-11, 8, 2, 0xfd],\n [-7, 9, 1, 0x1fd],\n [-5, 7, 1, 0x7c],\n [-3, 4, 1, 0xa],\n [-1, 3, 1, 0x2],\n [1, 3, 1, 0x3],\n [3, 5, 1, 0x1a],\n [5, 6, 1, 0x3a],\n [7, 3, 5, 0x4],\n [39, 6, 2, 0x3b],\n [43, 4, 5, 0xb],\n [75, 4, 6, 0xc],\n [139, 5, 7, 0x1b],\n [267, 5, 8, 0x1c],\n [523, 6, 8, 0x3c],\n [779, 7, 9, 0x7d],\n [1291, 6, 11, 0x3d],\n [-32, 9, 32, 0x1fe, \"lower\"],\n [3339, 9, 32, 0x1ff], // upper\n [2, 0x0], // OOB\n ];\n break;\n case 10:\n lines = [\n [-21, 7, 4, 0x7a],\n [-5, 8, 0, 0xfc],\n [-4, 7, 0, 0x7b],\n [-3, 5, 0, 0x18],\n [-2, 2, 2, 0x0],\n [2, 5, 0, 0x19],\n [3, 6, 0, 0x36],\n [4, 7, 0, 0x7c],\n [5, 8, 0, 0xfd],\n [6, 2, 6, 0x1],\n [70, 5, 5, 0x1a],\n [102, 6, 5, 0x37],\n [134, 6, 6, 0x38],\n [198, 6, 7, 0x39],\n [326, 6, 8, 0x3a],\n [582, 6, 9, 0x3b],\n [1094, 6, 10, 0x3c],\n [2118, 7, 11, 0x7d],\n [-22, 8, 32, 0xfe, \"lower\"],\n [4166, 8, 32, 0xff], // upper\n [2, 0x2], // OOB\n ];\n break;\n case 11:\n lines = [\n [1, 1, 0, 0x0],\n [2, 2, 1, 0x2],\n [4, 4, 0, 0xc],\n [5, 4, 1, 0xd],\n [7, 5, 1, 0x1c],\n [9, 5, 2, 0x1d],\n [13, 6, 2, 0x3c],\n [17, 7, 2, 0x7a],\n [21, 7, 3, 0x7b],\n [29, 7, 4, 0x7c],\n [45, 7, 5, 0x7d],\n [77, 7, 6, 0x7e],\n [141, 7, 32, 0x7f], // upper\n ];\n break;\n case 12:\n lines = [\n [1, 1, 0, 0x0],\n [2, 2, 0, 0x2],\n [3, 3, 1, 0x6],\n [5, 5, 0, 0x1c],\n [6, 5, 1, 0x1d],\n [8, 6, 1, 0x3c],\n [10, 7, 0, 0x7a],\n [11, 7, 1, 0x7b],\n [13, 7, 2, 0x7c],\n [17, 7, 3, 0x7d],\n [25, 7, 4, 0x7e],\n [41, 8, 5, 0xfe],\n [73, 8, 32, 0xff], // upper\n ];\n break;\n case 13:\n lines = [\n [1, 1, 0, 0x0],\n [2, 3, 0, 0x4],\n [3, 4, 0, 0xc],\n [4, 5, 0, 0x1c],\n [5, 4, 1, 0xd],\n [7, 3, 3, 0x5],\n [15, 6, 1, 0x3a],\n [17, 6, 2, 0x3b],\n [21, 6, 3, 0x3c],\n [29, 6, 4, 0x3d],\n [45, 6, 5, 0x3e],\n [77, 7, 6, 0x7e],\n [141, 7, 32, 0x7f], // upper\n ];\n break;\n case 14:\n lines = [\n [-2, 3, 0, 0x4],\n [-1, 3, 0, 0x5],\n [0, 1, 0, 0x0],\n [1, 3, 0, 0x6],\n [2, 3, 0, 0x7],\n ];\n break;\n case 15:\n lines = [\n [-24, 7, 4, 0x7c],\n [-8, 6, 2, 0x3c],\n [-4, 5, 1, 0x1c],\n [-2, 4, 0, 0xc],\n [-1, 3, 0, 0x4],\n [0, 1, 0, 0x0],\n [1, 3, 0, 0x5],\n [2, 4, 0, 0xd],\n [3, 5, 1, 0x1d],\n [5, 6, 2, 0x3d],\n [9, 7, 4, 0x7d],\n [-25, 7, 32, 0x7e, \"lower\"],\n [25, 7, 32, 0x7f], // upper\n ];\n break;\n default:\n throw new Jbig2Error(`standard table B.${number} does not exist`);\n }\n\n for (let i = 0, ii = lines.length; i < ii; i++) {\n lines[i] = new HuffmanLine(lines[i]);\n }\n table = new HuffmanTable(lines, true);\n standardTablesCache[number] = table;\n return table;\n}\n\nclass Reader {\n constructor(data, start, end) {\n this.data = data;\n this.start = start;\n this.end = end;\n this.position = start;\n this.shift = -1;\n this.currentByte = 0;\n }\n\n readBit() {\n if (this.shift < 0) {\n if (this.position >= this.end) {\n throw new Jbig2Error(\"end of data while reading bit\");\n }\n this.currentByte = this.data[this.position++];\n this.shift = 7;\n }\n const bit = (this.currentByte >> this.shift) & 1;\n this.shift--;\n return bit;\n }\n\n readBits(numBits) {\n let result = 0,\n i;\n for (i = numBits - 1; i >= 0; i--) {\n result |= this.readBit() << i;\n }\n return result;\n }\n\n byteAlign() {\n this.shift = -1;\n }\n\n next() {\n if (this.position >= this.end) {\n return -1;\n }\n return this.data[this.position++];\n }\n}\n\nfunction getCustomHuffmanTable(index, referredTo, customTables) {\n // Returns a Tables segment that has been earlier decoded.\n // See 7.4.2.1.6 (symbol dictionary) or 7.4.3.1.6 (text region).\n let currentIndex = 0;\n for (let i = 0, ii = referredTo.length; i < ii; i++) {\n const table = customTables[referredTo[i]];\n if (table) {\n if (index === currentIndex) {\n return table;\n }\n currentIndex++;\n }\n }\n throw new Jbig2Error(\"can't find custom Huffman table\");\n}\n\nfunction getTextRegionHuffmanTables(\n textRegion,\n referredTo,\n customTables,\n numberOfSymbols,\n reader\n) {\n // 7.4.3.1.7 Symbol ID Huffman table decoding\n\n // Read code lengths for RUNCODEs 0...34.\n const codes = [];\n for (let i = 0; i <= 34; i++) {\n const codeLength = reader.readBits(4);\n codes.push(new HuffmanLine([i, codeLength, 0, 0]));\n }\n // Assign Huffman codes for RUNCODEs.\n const runCodesTable = new HuffmanTable(codes, false);\n\n // Read a Huffman code using the assignment above.\n // Interpret the RUNCODE codes and the additional bits (if any).\n codes.length = 0;\n for (let i = 0; i < numberOfSymbols; ) {\n const codeLength = runCodesTable.decode(reader);\n if (codeLength >= 32) {\n let repeatedLength, numberOfRepeats, j;\n switch (codeLength) {\n case 32:\n if (i === 0) {\n throw new Jbig2Error(\"no previous value in symbol ID table\");\n }\n numberOfRepeats = reader.readBits(2) + 3;\n repeatedLength = codes[i - 1].prefixLength;\n break;\n case 33:\n numberOfRepeats = reader.readBits(3) + 3;\n repeatedLength = 0;\n break;\n case 34:\n numberOfRepeats = reader.readBits(7) + 11;\n repeatedLength = 0;\n break;\n default:\n throw new Jbig2Error(\"invalid code length in symbol ID table\");\n }\n for (j = 0; j < numberOfRepeats; j++) {\n codes.push(new HuffmanLine([i, repeatedLength, 0, 0]));\n i++;\n }\n } else {\n codes.push(new HuffmanLine([i, codeLength, 0, 0]));\n i++;\n }\n }\n reader.byteAlign();\n const symbolIDTable = new HuffmanTable(codes, false);\n\n // 7.4.3.1.6 Text region segment Huffman table selection\n\n let customIndex = 0,\n tableFirstS,\n tableDeltaS,\n tableDeltaT;\n\n switch (textRegion.huffmanFS) {\n case 0:\n case 1:\n tableFirstS = getStandardTable(textRegion.huffmanFS + 6);\n break;\n case 3:\n tableFirstS = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n break;\n default:\n throw new Jbig2Error(\"invalid Huffman FS selector\");\n }\n\n switch (textRegion.huffmanDS) {\n case 0:\n case 1:\n case 2:\n tableDeltaS = getStandardTable(textRegion.huffmanDS + 8);\n break;\n case 3:\n tableDeltaS = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n break;\n default:\n throw new Jbig2Error(\"invalid Huffman DS selector\");\n }\n\n switch (textRegion.huffmanDT) {\n case 0:\n case 1:\n case 2:\n tableDeltaT = getStandardTable(textRegion.huffmanDT + 11);\n break;\n case 3:\n tableDeltaT = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n break;\n default:\n throw new Jbig2Error(\"invalid Huffman DT selector\");\n }\n\n if (textRegion.refinement) {\n // Load tables RDW, RDH, RDX and RDY.\n throw new Jbig2Error(\"refinement with Huffman is not supported\");\n }\n\n return {\n symbolIDTable,\n tableFirstS,\n tableDeltaS,\n tableDeltaT,\n };\n}\n\nfunction getSymbolDictionaryHuffmanTables(\n dictionary,\n referredTo,\n customTables\n) {\n // 7.4.2.1.6 Symbol dictionary segment Huffman table selection\n\n let customIndex = 0,\n tableDeltaHeight,\n tableDeltaWidth;\n switch (dictionary.huffmanDHSelector) {\n case 0:\n case 1:\n tableDeltaHeight = getStandardTable(dictionary.huffmanDHSelector + 4);\n break;\n case 3:\n tableDeltaHeight = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n break;\n default:\n throw new Jbig2Error(\"invalid Huffman DH selector\");\n }\n\n switch (dictionary.huffmanDWSelector) {\n case 0:\n case 1:\n tableDeltaWidth = getStandardTable(dictionary.huffmanDWSelector + 2);\n break;\n case 3:\n tableDeltaWidth = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n break;\n default:\n throw new Jbig2Error(\"invalid Huffman DW selector\");\n }\n\n let tableBitmapSize, tableAggregateInstances;\n if (dictionary.bitmapSizeSelector) {\n tableBitmapSize = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n customIndex++;\n } else {\n tableBitmapSize = getStandardTable(1);\n }\n\n if (dictionary.aggregationInstancesSelector) {\n tableAggregateInstances = getCustomHuffmanTable(\n customIndex,\n referredTo,\n customTables\n );\n } else {\n tableAggregateInstances = getStandardTable(1);\n }\n\n return {\n tableDeltaHeight,\n tableDeltaWidth,\n tableBitmapSize,\n tableAggregateInstances,\n };\n}\n\nfunction readUncompressedBitmap(reader, width, height) {\n const bitmap = [];\n for (let y = 0; y < height; y++) {\n const row = new Uint8Array(width);\n bitmap.push(row);\n for (let x = 0; x < width; x++) {\n row[x] = reader.readBit();\n }\n reader.byteAlign();\n }\n return bitmap;\n}\n\nfunction decodeMMRBitmap(input, width, height, endOfBlock) {\n // MMR is the same compression algorithm as the PDF filter\n // CCITTFaxDecode with /K -1.\n const params = {\n K: -1,\n Columns: width,\n Rows: height,\n BlackIs1: true,\n EndOfBlock: endOfBlock,\n };\n const decoder = new CCITTFaxDecoder(input, params);\n const bitmap = [];\n let currentByte,\n eof = false;\n\n for (let y = 0; y < height; y++) {\n const row = new Uint8Array(width);\n bitmap.push(row);\n let shift = -1;\n for (let x = 0; x < width; x++) {\n if (shift < 0) {\n currentByte = decoder.readNextChar();\n if (currentByte === -1) {\n // Set the rest of the bits to zero.\n currentByte = 0;\n eof = true;\n }\n shift = 7;\n }\n row[x] = (currentByte >> shift) & 1;\n shift--;\n }\n }\n\n if (endOfBlock && !eof) {\n // Read until EOFB has been consumed.\n const lookForEOFLimit = 5;\n for (let i = 0; i < lookForEOFLimit; i++) {\n if (decoder.readNextChar() === -1) {\n break;\n }\n }\n }\n\n return bitmap;\n}\n\nclass Jbig2Image {\n parseChunks(chunks) {\n return parseJbig2Chunks(chunks);\n }\n\n parse(data) {\n if (typeof PDFJSDev === \"undefined\" || !PDFJSDev.test(\"IMAGE_DECODERS\")) {\n throw new Error(\"Not implemented: Jbig2Image.parse\");\n }\n const { imgData, width, height } = parseJbig2(data);\n this.width = width;\n this.height = height;\n return imgData;\n }\n}\n\nexport { Jbig2Image };\n","/* Copyright 2019 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n AnnotationEditorPrefix,\n assert,\n BaseException,\n objectSize,\n stringToPDFString,\n warn,\n} from \"../shared/util.js\";\nimport { Dict, isName, Ref, RefSet } from \"./primitives.js\";\nimport { BaseStream } from \"./base_stream.js\";\n\nconst PDF_VERSION_REGEXP = /^[1-9]\\.\\d$/;\n\nfunction getLookupTableFactory(initializer) {\n let lookup;\n return function () {\n if (initializer) {\n lookup = Object.create(null);\n initializer(lookup);\n initializer = null;\n }\n return lookup;\n };\n}\n\nclass MissingDataException extends BaseException {\n constructor(begin, end) {\n super(`Missing data [${begin}, ${end})`, \"MissingDataException\");\n this.begin = begin;\n this.end = end;\n }\n}\n\nclass ParserEOFException extends BaseException {\n constructor(msg) {\n super(msg, \"ParserEOFException\");\n }\n}\n\nclass XRefEntryException extends BaseException {\n constructor(msg) {\n super(msg, \"XRefEntryException\");\n }\n}\n\nclass XRefParseException extends BaseException {\n constructor(msg) {\n super(msg, \"XRefParseException\");\n }\n}\n\n/**\n * Combines multiple ArrayBuffers into a single Uint8Array.\n * @param {Array<ArrayBuffer>} arr - An array of ArrayBuffers.\n * @returns {Uint8Array}\n */\nfunction arrayBuffersToBytes(arr) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n for (const item of arr) {\n assert(\n item instanceof ArrayBuffer,\n \"arrayBuffersToBytes - expected an ArrayBuffer.\"\n );\n }\n }\n const length = arr.length;\n if (length === 0) {\n return new Uint8Array(0);\n }\n if (length === 1) {\n return new Uint8Array(arr[0]);\n }\n let dataLength = 0;\n for (let i = 0; i < length; i++) {\n dataLength += arr[i].byteLength;\n }\n const data = new Uint8Array(dataLength);\n let pos = 0;\n for (let i = 0; i < length; i++) {\n const item = new Uint8Array(arr[i]);\n data.set(item, pos);\n pos += item.byteLength;\n }\n return data;\n}\n\n/**\n * Get the value of an inheritable property.\n *\n * If the PDF specification explicitly lists a property in a dictionary as\n * inheritable, then the value of the property may be present in the dictionary\n * itself or in one or more parents of the dictionary.\n *\n * If the key is not found in the tree, `undefined` is returned. Otherwise,\n * the value for the key is returned or, if `stopWhenFound` is `false`, a list\n * of values is returned.\n *\n * @param {Dict} dict - Dictionary from where to start the traversal.\n * @param {string} key - The key of the property to find the value for.\n * @param {boolean} getArray - Whether or not the value should be fetched as an\n * array. The default value is `false`.\n * @param {boolean} stopWhenFound - Whether or not to stop the traversal when\n * the key is found. If set to `false`, we always walk up the entire parent\n * chain, for example to be able to find `\\Resources` placed on multiple\n * levels of the tree. The default value is `true`.\n */\nfunction getInheritableProperty({\n dict,\n key,\n getArray = false,\n stopWhenFound = true,\n}) {\n let values;\n const visited = new RefSet();\n\n while (dict instanceof Dict && !(dict.objId && visited.has(dict.objId))) {\n if (dict.objId) {\n visited.put(dict.objId);\n }\n const value = getArray ? dict.getArray(key) : dict.get(key);\n if (value !== undefined) {\n if (stopWhenFound) {\n return value;\n }\n (values ||= []).push(value);\n }\n dict = dict.get(\"Parent\");\n }\n return values;\n}\n\n// prettier-ignore\nconst ROMAN_NUMBER_MAP = [\n \"\", \"C\", \"CC\", \"CCC\", \"CD\", \"D\", \"DC\", \"DCC\", \"DCCC\", \"CM\",\n \"\", \"X\", \"XX\", \"XXX\", \"XL\", \"L\", \"LX\", \"LXX\", \"LXXX\", \"XC\",\n \"\", \"I\", \"II\", \"III\", \"IV\", \"V\", \"VI\", \"VII\", \"VIII\", \"IX\"\n];\n\n/**\n * Converts positive integers to (upper case) Roman numerals.\n * @param {number} number - The number that should be converted.\n * @param {boolean} lowerCase - Indicates if the result should be converted\n * to lower case letters. The default value is `false`.\n * @returns {string} The resulting Roman number.\n */\nfunction toRomanNumerals(number, lowerCase = false) {\n assert(\n Number.isInteger(number) && number > 0,\n \"The number should be a positive integer.\"\n );\n const romanBuf = [];\n let pos;\n // Thousands\n while (number >= 1000) {\n number -= 1000;\n romanBuf.push(\"M\");\n }\n // Hundreds\n pos = (number / 100) | 0;\n number %= 100;\n romanBuf.push(ROMAN_NUMBER_MAP[pos]);\n // Tens\n pos = (number / 10) | 0;\n number %= 10;\n romanBuf.push(ROMAN_NUMBER_MAP[10 + pos]);\n // Ones\n romanBuf.push(ROMAN_NUMBER_MAP[20 + number]); // eslint-disable-line unicorn/no-array-push-push\n\n const romanStr = romanBuf.join(\"\");\n return lowerCase ? romanStr.toLowerCase() : romanStr;\n}\n\n// Calculate the base 2 logarithm of the number `x`. This differs from the\n// native function in the sense that it returns the ceiling value and that it\n// returns 0 instead of `Infinity`/`NaN` for `x` values smaller than/equal to 0.\nfunction log2(x) {\n if (x <= 0) {\n return 0;\n }\n return Math.ceil(Math.log2(x));\n}\n\nfunction readInt8(data, offset) {\n return (data[offset] << 24) >> 24;\n}\n\nfunction readUint16(data, offset) {\n return (data[offset] << 8) | data[offset + 1];\n}\n\nfunction readUint32(data, offset) {\n return (\n ((data[offset] << 24) |\n (data[offset + 1] << 16) |\n (data[offset + 2] << 8) |\n data[offset + 3]) >>>\n 0\n );\n}\n\n// Checks if ch is one of the following characters: SPACE, TAB, CR or LF.\nfunction isWhiteSpace(ch) {\n return ch === 0x20 || ch === 0x09 || ch === 0x0d || ch === 0x0a;\n}\n\n/**\n * AcroForm field names use an array like notation to refer to\n * repeated XFA elements e.g. foo.bar[nnn].\n * see: XFA Spec Chapter 3 - Repeated Elements\n *\n * @param {string} path - XFA path name.\n * @returns {Array} - Array of Objects with the name and pos of\n * each part of the path.\n */\nfunction parseXFAPath(path) {\n const positionPattern = /(.+)\\[(\\d+)\\]$/;\n return path.split(\".\").map(component => {\n const m = component.match(positionPattern);\n if (m) {\n return { name: m[1], pos: parseInt(m[2], 10) };\n }\n return { name: component, pos: 0 };\n });\n}\n\nfunction escapePDFName(str) {\n const buffer = [];\n let start = 0;\n for (let i = 0, ii = str.length; i < ii; i++) {\n const char = str.charCodeAt(i);\n // Whitespace or delimiters aren't regular chars, so escape them.\n if (\n char < 0x21 ||\n char > 0x7e ||\n char === 0x23 /* # */ ||\n char === 0x28 /* ( */ ||\n char === 0x29 /* ) */ ||\n char === 0x3c /* < */ ||\n char === 0x3e /* > */ ||\n char === 0x5b /* [ */ ||\n char === 0x5d /* ] */ ||\n char === 0x7b /* { */ ||\n char === 0x7d /* } */ ||\n char === 0x2f /* / */ ||\n char === 0x25 /* % */\n ) {\n if (start < i) {\n buffer.push(str.substring(start, i));\n }\n buffer.push(`#${char.toString(16)}`);\n start = i + 1;\n }\n }\n\n if (buffer.length === 0) {\n return str;\n }\n\n if (start < str.length) {\n buffer.push(str.substring(start, str.length));\n }\n\n return buffer.join(\"\");\n}\n\n// Replace \"(\", \")\", \"\\n\", \"\\r\" and \"\\\" by \"\\(\", \"\\)\", \"\\\\n\", \"\\\\r\" and \"\\\\\"\n// in order to write it in a PDF file.\nfunction escapeString(str) {\n return str.replaceAll(/([()\\\\\\n\\r])/g, match => {\n if (match === \"\\n\") {\n return \"\\\\n\";\n } else if (match === \"\\r\") {\n return \"\\\\r\";\n }\n return `\\\\${match}`;\n });\n}\n\nfunction _collectJS(entry, xref, list, parents) {\n if (!entry) {\n return;\n }\n\n let parent = null;\n if (entry instanceof Ref) {\n if (parents.has(entry)) {\n // If we've already found entry then we've a cycle.\n return;\n }\n parent = entry;\n parents.put(parent);\n entry = xref.fetch(entry);\n }\n if (Array.isArray(entry)) {\n for (const element of entry) {\n _collectJS(element, xref, list, parents);\n }\n } else if (entry instanceof Dict) {\n if (isName(entry.get(\"S\"), \"JavaScript\")) {\n const js = entry.get(\"JS\");\n let code;\n if (js instanceof BaseStream) {\n code = js.getString();\n } else if (typeof js === \"string\") {\n code = js;\n }\n code &&= stringToPDFString(code).replaceAll(\"\\x00\", \"\");\n if (code) {\n list.push(code);\n }\n }\n _collectJS(entry.getRaw(\"Next\"), xref, list, parents);\n }\n\n if (parent) {\n parents.remove(parent);\n }\n}\n\nfunction collectActions(xref, dict, eventType) {\n const actions = Object.create(null);\n const additionalActionsDicts = getInheritableProperty({\n dict,\n key: \"AA\",\n stopWhenFound: false,\n });\n if (additionalActionsDicts) {\n // additionalActionsDicts contains dicts from ancestors\n // as they're found in the tree from bottom to top.\n // So the dicts are visited in reverse order to guarantee\n // that actions from elder ancestors will be overwritten\n // by ones from younger ancestors.\n for (let i = additionalActionsDicts.length - 1; i >= 0; i--) {\n const additionalActions = additionalActionsDicts[i];\n if (!(additionalActions instanceof Dict)) {\n continue;\n }\n for (const key of additionalActions.getKeys()) {\n const action = eventType[key];\n if (!action) {\n continue;\n }\n const actionDict = additionalActions.getRaw(key);\n const parents = new RefSet();\n const list = [];\n _collectJS(actionDict, xref, list, parents);\n if (list.length > 0) {\n actions[action] = list;\n }\n }\n }\n }\n // Collect the Action if any (we may have one on pushbutton).\n if (dict.has(\"A\")) {\n const actionDict = dict.get(\"A\");\n const parents = new RefSet();\n const list = [];\n _collectJS(actionDict, xref, list, parents);\n if (list.length > 0) {\n actions.Action = list;\n }\n }\n return objectSize(actions) > 0 ? actions : null;\n}\n\nconst XMLEntities = {\n /* < */ 0x3c: \"<\",\n /* > */ 0x3e: \">\",\n /* & */ 0x26: \"&\",\n /* \" */ 0x22: \""\",\n /* ' */ 0x27: \"'\",\n};\n\nfunction encodeToXmlString(str) {\n const buffer = [];\n let start = 0;\n for (let i = 0, ii = str.length; i < ii; i++) {\n const char = str.codePointAt(i);\n if (0x20 <= char && char <= 0x7e) {\n // ascii\n const entity = XMLEntities[char];\n if (entity) {\n if (start < i) {\n buffer.push(str.substring(start, i));\n }\n buffer.push(entity);\n start = i + 1;\n }\n } else {\n if (start < i) {\n buffer.push(str.substring(start, i));\n }\n buffer.push(`&#x${char.toString(16).toUpperCase()};`);\n if (char > 0xd7ff && (char < 0xe000 || char > 0xfffd)) {\n // char is represented by two u16\n i++;\n }\n start = i + 1;\n }\n }\n\n if (buffer.length === 0) {\n return str;\n }\n if (start < str.length) {\n buffer.push(str.substring(start, str.length));\n }\n return buffer.join(\"\");\n}\n\nfunction validateFontName(fontFamily, mustWarn = false) {\n // See https://developer.mozilla.org/en-US/docs/Web/CSS/string.\n const m = /^(\"|').*(\"|')$/.exec(fontFamily);\n if (m && m[1] === m[2]) {\n const re = new RegExp(`[^\\\\\\\\]${m[1]}`);\n if (re.test(fontFamily.slice(1, -1))) {\n if (mustWarn) {\n warn(`FontFamily contains unescaped ${m[1]}: ${fontFamily}.`);\n }\n return false;\n }\n } else {\n // See https://developer.mozilla.org/en-US/docs/Web/CSS/custom-ident.\n for (const ident of fontFamily.split(/[ \\t]+/)) {\n if (/^(\\d|(-(\\d|-)))/.test(ident) || !/^[\\w-\\\\]+$/.test(ident)) {\n if (mustWarn) {\n warn(`FontFamily contains invalid <custom-ident>: ${fontFamily}.`);\n }\n return false;\n }\n }\n }\n return true;\n}\n\nfunction validateCSSFont(cssFontInfo) {\n // See https://developer.mozilla.org/en-US/docs/Web/CSS/font-style.\n const DEFAULT_CSS_FONT_OBLIQUE = \"14\";\n // See https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight.\n const DEFAULT_CSS_FONT_WEIGHT = \"400\";\n const CSS_FONT_WEIGHT_VALUES = new Set([\n \"100\",\n \"200\",\n \"300\",\n \"400\",\n \"500\",\n \"600\",\n \"700\",\n \"800\",\n \"900\",\n \"1000\",\n \"normal\",\n \"bold\",\n \"bolder\",\n \"lighter\",\n ]);\n\n const { fontFamily, fontWeight, italicAngle } = cssFontInfo;\n\n if (!validateFontName(fontFamily, true)) {\n return false;\n }\n\n const weight = fontWeight ? fontWeight.toString() : \"\";\n cssFontInfo.fontWeight = CSS_FONT_WEIGHT_VALUES.has(weight)\n ? weight\n : DEFAULT_CSS_FONT_WEIGHT;\n\n const angle = parseFloat(italicAngle);\n cssFontInfo.italicAngle =\n isNaN(angle) || angle < -90 || angle > 90\n ? DEFAULT_CSS_FONT_OBLIQUE\n : italicAngle.toString();\n\n return true;\n}\n\nfunction recoverJsURL(str) {\n // Attempt to recover valid URLs from `JS` entries with certain\n // white-listed formats:\n // - window.open('http://example.com')\n // - app.launchURL('http://example.com', true)\n // - xfa.host.gotoURL('http://example.com')\n const URL_OPEN_METHODS = [\"app.launchURL\", \"window.open\", \"xfa.host.gotoURL\"];\n const regex = new RegExp(\n \"^\\\\s*(\" +\n URL_OPEN_METHODS.join(\"|\").replaceAll(\".\", \"\\\\.\") +\n \")\\\\((?:'|\\\")([^'\\\"]*)(?:'|\\\")(?:,\\\\s*(\\\\w+)\\\\)|\\\\))\",\n \"i\"\n );\n\n const jsUrl = regex.exec(str);\n if (jsUrl?.[2]) {\n const url = jsUrl[2];\n let newWindow = false;\n\n if (jsUrl[3] === \"true\" && jsUrl[1] === \"app.launchURL\") {\n newWindow = true;\n }\n return { url, newWindow };\n }\n\n return null;\n}\n\nfunction numberToString(value) {\n if (Number.isInteger(value)) {\n return value.toString();\n }\n\n const roundedValue = Math.round(value * 100);\n if (roundedValue % 100 === 0) {\n return (roundedValue / 100).toString();\n }\n\n if (roundedValue % 10 === 0) {\n return value.toFixed(1);\n }\n\n return value.toFixed(2);\n}\n\nfunction getNewAnnotationsMap(annotationStorage) {\n if (!annotationStorage) {\n return null;\n }\n const newAnnotationsByPage = new Map();\n // The concept of page in a XFA is very different, so\n // editing is just not implemented.\n for (const [key, value] of annotationStorage) {\n if (!key.startsWith(AnnotationEditorPrefix)) {\n continue;\n }\n let annotations = newAnnotationsByPage.get(value.pageIndex);\n if (!annotations) {\n annotations = [];\n newAnnotationsByPage.set(value.pageIndex, annotations);\n }\n annotations.push(value);\n }\n return newAnnotationsByPage.size > 0 ? newAnnotationsByPage : null;\n}\n\nfunction isAscii(str) {\n return /^[\\x00-\\x7F]*$/.test(str);\n}\n\nfunction stringToUTF16HexString(str) {\n const buf = [];\n for (let i = 0, ii = str.length; i < ii; i++) {\n const char = str.charCodeAt(i);\n buf.push(\n ((char >> 8) & 0xff).toString(16).padStart(2, \"0\"),\n (char & 0xff).toString(16).padStart(2, \"0\")\n );\n }\n return buf.join(\"\");\n}\n\nfunction stringToUTF16String(str, bigEndian = false) {\n const buf = [];\n if (bigEndian) {\n buf.push(\"\\xFE\\xFF\");\n }\n for (let i = 0, ii = str.length; i < ii; i++) {\n const char = str.charCodeAt(i);\n buf.push(\n String.fromCharCode((char >> 8) & 0xff),\n String.fromCharCode(char & 0xff)\n );\n }\n return buf.join(\"\");\n}\n\nfunction getRotationMatrix(rotation, width, height) {\n switch (rotation) {\n case 90:\n return [0, 1, -1, 0, width, 0];\n case 180:\n return [-1, 0, 0, -1, width, height];\n case 270:\n return [0, -1, 1, 0, 0, height];\n default:\n throw new Error(\"Invalid rotation\");\n }\n}\n\nexport {\n arrayBuffersToBytes,\n collectActions,\n encodeToXmlString,\n escapePDFName,\n escapeString,\n getInheritableProperty,\n getLookupTableFactory,\n getNewAnnotationsMap,\n getRotationMatrix,\n isAscii,\n isWhiteSpace,\n log2,\n MissingDataException,\n numberToString,\n ParserEOFException,\n parseXFAPath,\n PDF_VERSION_REGEXP,\n readInt8,\n readUint16,\n readUint32,\n recoverJsURL,\n stringToUTF16HexString,\n stringToUTF16String,\n toRomanNumerals,\n validateCSSFont,\n validateFontName,\n XRefEntryException,\n XRefParseException,\n};\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { assert, shadow, unreachable } from \"../shared/util.js\";\n\nconst CIRCULAR_REF = Symbol(\"CIRCULAR_REF\");\nconst EOF = Symbol(\"EOF\");\n\nlet CmdCache = Object.create(null);\nlet NameCache = Object.create(null);\nlet RefCache = Object.create(null);\n\nfunction clearPrimitiveCaches() {\n CmdCache = Object.create(null);\n NameCache = Object.create(null);\n RefCache = Object.create(null);\n}\n\nclass Name {\n constructor(name) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n typeof name !== \"string\"\n ) {\n unreachable('Name: The \"name\" must be a string.');\n }\n this.name = name;\n }\n\n static get(name) {\n // eslint-disable-next-line no-restricted-syntax\n return (NameCache[name] ||= new Name(name));\n }\n}\n\nclass Cmd {\n constructor(cmd) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n typeof cmd !== \"string\"\n ) {\n unreachable('Cmd: The \"cmd\" must be a string.');\n }\n this.cmd = cmd;\n }\n\n static get(cmd) {\n // eslint-disable-next-line no-restricted-syntax\n return (CmdCache[cmd] ||= new Cmd(cmd));\n }\n}\n\nconst nonSerializable = function nonSerializableClosure() {\n return nonSerializable; // Creating closure on some variable.\n};\n\nclass Dict {\n constructor(xref = null) {\n // Map should only be used internally, use functions below to access.\n this._map = Object.create(null);\n this.xref = xref;\n this.objId = null;\n this.suppressEncryption = false;\n this.__nonSerializable__ = nonSerializable; // Disable cloning of the Dict.\n }\n\n assignXref(newXref) {\n this.xref = newXref;\n }\n\n get size() {\n return Object.keys(this._map).length;\n }\n\n // Automatically dereferences Ref objects.\n get(key1, key2, key3) {\n let value = this._map[key1];\n if (value === undefined && key2 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key2.length < key1.length\n ) {\n unreachable(\"Dict.get: Expected keys to be ordered by length.\");\n }\n value = this._map[key2];\n if (value === undefined && key3 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key3.length < key2.length\n ) {\n unreachable(\"Dict.get: Expected keys to be ordered by length.\");\n }\n value = this._map[key3];\n }\n }\n if (value instanceof Ref && this.xref) {\n return this.xref.fetch(value, this.suppressEncryption);\n }\n return value;\n }\n\n // Same as get(), but returns a promise and uses fetchIfRefAsync().\n async getAsync(key1, key2, key3) {\n let value = this._map[key1];\n if (value === undefined && key2 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key2.length < key1.length\n ) {\n unreachable(\"Dict.getAsync: Expected keys to be ordered by length.\");\n }\n value = this._map[key2];\n if (value === undefined && key3 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key3.length < key2.length\n ) {\n unreachable(\"Dict.getAsync: Expected keys to be ordered by length.\");\n }\n value = this._map[key3];\n }\n }\n if (value instanceof Ref && this.xref) {\n return this.xref.fetchAsync(value, this.suppressEncryption);\n }\n return value;\n }\n\n // Same as get(), but dereferences all elements if the result is an Array.\n getArray(key1, key2, key3) {\n let value = this._map[key1];\n if (value === undefined && key2 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key2.length < key1.length\n ) {\n unreachable(\"Dict.getArray: Expected keys to be ordered by length.\");\n }\n value = this._map[key2];\n if (value === undefined && key3 !== undefined) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n key3.length < key2.length\n ) {\n unreachable(\"Dict.getArray: Expected keys to be ordered by length.\");\n }\n value = this._map[key3];\n }\n }\n if (value instanceof Ref && this.xref) {\n value = this.xref.fetch(value, this.suppressEncryption);\n }\n\n if (Array.isArray(value)) {\n value = value.slice(); // Ensure that we don't modify the Dict data.\n for (let i = 0, ii = value.length; i < ii; i++) {\n if (value[i] instanceof Ref && this.xref) {\n value[i] = this.xref.fetch(value[i], this.suppressEncryption);\n }\n }\n }\n return value;\n }\n\n // No dereferencing.\n getRaw(key) {\n return this._map[key];\n }\n\n getKeys() {\n return Object.keys(this._map);\n }\n\n // No dereferencing.\n getRawValues() {\n return Object.values(this._map);\n }\n\n set(key, value) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n if (typeof key !== \"string\") {\n unreachable('Dict.set: The \"key\" must be a string.');\n } else if (value === undefined) {\n unreachable('Dict.set: The \"value\" cannot be undefined.');\n }\n }\n this._map[key] = value;\n }\n\n has(key) {\n return this._map[key] !== undefined;\n }\n\n forEach(callback) {\n for (const key in this._map) {\n callback(key, this.get(key));\n }\n }\n\n static get empty() {\n const emptyDict = new Dict(null);\n\n emptyDict.set = (key, value) => {\n unreachable(\"Should not call `set` on the empty dictionary.\");\n };\n return shadow(this, \"empty\", emptyDict);\n }\n\n static merge({ xref, dictArray, mergeSubDicts = false }) {\n const mergedDict = new Dict(xref),\n properties = new Map();\n\n for (const dict of dictArray) {\n if (!(dict instanceof Dict)) {\n continue;\n }\n for (const [key, value] of Object.entries(dict._map)) {\n let property = properties.get(key);\n if (property === undefined) {\n property = [];\n properties.set(key, property);\n } else if (!mergeSubDicts || !(value instanceof Dict)) {\n // Ignore additional entries, if either:\n // - This is a \"shallow\" merge, where only the first element matters.\n // - The value is *not* a `Dict`, since other types cannot be merged.\n continue;\n }\n property.push(value);\n }\n }\n for (const [name, values] of properties) {\n if (values.length === 1 || !(values[0] instanceof Dict)) {\n mergedDict._map[name] = values[0];\n continue;\n }\n const subDict = new Dict(xref);\n\n for (const dict of values) {\n for (const [key, value] of Object.entries(dict._map)) {\n if (subDict._map[key] === undefined) {\n subDict._map[key] = value;\n }\n }\n }\n if (subDict.size > 0) {\n mergedDict._map[name] = subDict;\n }\n }\n properties.clear();\n\n return mergedDict.size > 0 ? mergedDict : Dict.empty;\n }\n\n clone() {\n const dict = new Dict(this.xref);\n for (const key of this.getKeys()) {\n dict.set(key, this.getRaw(key));\n }\n return dict;\n }\n}\n\nclass Ref {\n constructor(num, gen) {\n this.num = num;\n this.gen = gen;\n }\n\n toString() {\n // This function is hot, so we make the string as compact as possible.\n // |this.gen| is almost always zero, so we treat that case specially.\n if (this.gen === 0) {\n return `${this.num}R`;\n }\n return `${this.num}R${this.gen}`;\n }\n\n static fromString(str) {\n const ref = RefCache[str];\n if (ref) {\n return ref;\n }\n const m = /^(\\d+)R(\\d*)$/.exec(str);\n if (!m || m[1] === \"0\") {\n return null;\n }\n\n // eslint-disable-next-line no-restricted-syntax\n return (RefCache[str] = new Ref(\n parseInt(m[1]),\n !m[2] ? 0 : parseInt(m[2])\n ));\n }\n\n static get(num, gen) {\n const key = gen === 0 ? `${num}R` : `${num}R${gen}`;\n // eslint-disable-next-line no-restricted-syntax\n return (RefCache[key] ||= new Ref(num, gen));\n }\n}\n\n// The reference is identified by number and generation.\n// This structure stores only one instance of the reference.\nclass RefSet {\n constructor(parent = null) {\n if (\n (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) &&\n parent &&\n !(parent instanceof RefSet)\n ) {\n unreachable('RefSet: Invalid \"parent\" value.');\n }\n this._set = new Set(parent?._set);\n }\n\n has(ref) {\n return this._set.has(ref.toString());\n }\n\n put(ref) {\n this._set.add(ref.toString());\n }\n\n remove(ref) {\n this._set.delete(ref.toString());\n }\n\n [Symbol.iterator]() {\n return this._set.values();\n }\n\n clear() {\n this._set.clear();\n }\n}\n\nclass RefSetCache {\n constructor() {\n this._map = new Map();\n }\n\n get size() {\n return this._map.size;\n }\n\n get(ref) {\n return this._map.get(ref.toString());\n }\n\n has(ref) {\n return this._map.has(ref.toString());\n }\n\n put(ref, obj) {\n this._map.set(ref.toString(), obj);\n }\n\n putAlias(ref, aliasRef) {\n this._map.set(ref.toString(), this.get(aliasRef));\n }\n\n [Symbol.iterator]() {\n return this._map.values();\n }\n\n clear() {\n this._map.clear();\n }\n}\n\nfunction isName(v, name) {\n return v instanceof Name && (name === undefined || v.name === name);\n}\n\nfunction isCmd(v, cmd) {\n return v instanceof Cmd && (cmd === undefined || v.cmd === cmd);\n}\n\nfunction isDict(v, type) {\n return (\n v instanceof Dict && (type === undefined || isName(v.get(\"Type\"), type))\n );\n}\n\nfunction isRefsEqual(v1, v2) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n v1 instanceof Ref && v2 instanceof Ref,\n \"isRefsEqual: Both parameters should be `Ref`s.\"\n );\n }\n return v1.num === v2.num && v1.gen === v2.gen;\n}\n\nexport {\n CIRCULAR_REF,\n clearPrimitiveCaches,\n Cmd,\n Dict,\n EOF,\n isCmd,\n isDict,\n isName,\n isRefsEqual,\n Name,\n Ref,\n RefSet,\n RefSetCache,\n};\n","/* Copyright 2021 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { bytesToString, shadow, unreachable } from \"../shared/util.js\";\n\nclass BaseStream {\n constructor() {\n if (this.constructor === BaseStream) {\n unreachable(\"Cannot initialize BaseStream.\");\n }\n }\n\n // eslint-disable-next-line getter-return\n get length() {\n unreachable(\"Abstract getter `length` accessed\");\n }\n\n // eslint-disable-next-line getter-return\n get isEmpty() {\n unreachable(\"Abstract getter `isEmpty` accessed\");\n }\n\n get isDataLoaded() {\n return shadow(this, \"isDataLoaded\", true);\n }\n\n getByte() {\n unreachable(\"Abstract method `getByte` called\");\n }\n\n getBytes(length) {\n unreachable(\"Abstract method `getBytes` called\");\n }\n\n peekByte() {\n const peekedByte = this.getByte();\n if (peekedByte !== -1) {\n this.pos--;\n }\n return peekedByte;\n }\n\n peekBytes(length) {\n const bytes = this.getBytes(length);\n this.pos -= bytes.length;\n return bytes;\n }\n\n getUint16() {\n const b0 = this.getByte();\n const b1 = this.getByte();\n if (b0 === -1 || b1 === -1) {\n return -1;\n }\n return (b0 << 8) + b1;\n }\n\n getInt32() {\n const b0 = this.getByte();\n const b1 = this.getByte();\n const b2 = this.getByte();\n const b3 = this.getByte();\n return (b0 << 24) + (b1 << 16) + (b2 << 8) + b3;\n }\n\n getByteRange(begin, end) {\n unreachable(\"Abstract method `getByteRange` called\");\n }\n\n getString(length) {\n return bytesToString(this.getBytes(length));\n }\n\n skip(n) {\n this.pos += n || 1;\n }\n\n reset() {\n unreachable(\"Abstract method `reset` called\");\n }\n\n moveStart() {\n unreachable(\"Abstract method `moveStart` called\");\n }\n\n makeSubStream(start, length, dict = null) {\n unreachable(\"Abstract method `makeSubStream` called\");\n }\n\n /**\n * @returns {Array | null}\n */\n getBaseStreams() {\n return null;\n }\n}\n\nexport { BaseStream };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n// Table C-2\nconst QeTable = [\n { qe: 0x5601, nmps: 1, nlps: 1, switchFlag: 1 },\n { qe: 0x3401, nmps: 2, nlps: 6, switchFlag: 0 },\n { qe: 0x1801, nmps: 3, nlps: 9, switchFlag: 0 },\n { qe: 0x0ac1, nmps: 4, nlps: 12, switchFlag: 0 },\n { qe: 0x0521, nmps: 5, nlps: 29, switchFlag: 0 },\n { qe: 0x0221, nmps: 38, nlps: 33, switchFlag: 0 },\n { qe: 0x5601, nmps: 7, nlps: 6, switchFlag: 1 },\n { qe: 0x5401, nmps: 8, nlps: 14, switchFlag: 0 },\n { qe: 0x4801, nmps: 9, nlps: 14, switchFlag: 0 },\n { qe: 0x3801, nmps: 10, nlps: 14, switchFlag: 0 },\n { qe: 0x3001, nmps: 11, nlps: 17, switchFlag: 0 },\n { qe: 0x2401, nmps: 12, nlps: 18, switchFlag: 0 },\n { qe: 0x1c01, nmps: 13, nlps: 20, switchFlag: 0 },\n { qe: 0x1601, nmps: 29, nlps: 21, switchFlag: 0 },\n { qe: 0x5601, nmps: 15, nlps: 14, switchFlag: 1 },\n { qe: 0x5401, nmps: 16, nlps: 14, switchFlag: 0 },\n { qe: 0x5101, nmps: 17, nlps: 15, switchFlag: 0 },\n { qe: 0x4801, nmps: 18, nlps: 16, switchFlag: 0 },\n { qe: 0x3801, nmps: 19, nlps: 17, switchFlag: 0 },\n { qe: 0x3401, nmps: 20, nlps: 18, switchFlag: 0 },\n { qe: 0x3001, nmps: 21, nlps: 19, switchFlag: 0 },\n { qe: 0x2801, nmps: 22, nlps: 19, switchFlag: 0 },\n { qe: 0x2401, nmps: 23, nlps: 20, switchFlag: 0 },\n { qe: 0x2201, nmps: 24, nlps: 21, switchFlag: 0 },\n { qe: 0x1c01, nmps: 25, nlps: 22, switchFlag: 0 },\n { qe: 0x1801, nmps: 26, nlps: 23, switchFlag: 0 },\n { qe: 0x1601, nmps: 27, nlps: 24, switchFlag: 0 },\n { qe: 0x1401, nmps: 28, nlps: 25, switchFlag: 0 },\n { qe: 0x1201, nmps: 29, nlps: 26, switchFlag: 0 },\n { qe: 0x1101, nmps: 30, nlps: 27, switchFlag: 0 },\n { qe: 0x0ac1, nmps: 31, nlps: 28, switchFlag: 0 },\n { qe: 0x09c1, nmps: 32, nlps: 29, switchFlag: 0 },\n { qe: 0x08a1, nmps: 33, nlps: 30, switchFlag: 0 },\n { qe: 0x0521, nmps: 34, nlps: 31, switchFlag: 0 },\n { qe: 0x0441, nmps: 35, nlps: 32, switchFlag: 0 },\n { qe: 0x02a1, nmps: 36, nlps: 33, switchFlag: 0 },\n { qe: 0x0221, nmps: 37, nlps: 34, switchFlag: 0 },\n { qe: 0x0141, nmps: 38, nlps: 35, switchFlag: 0 },\n { qe: 0x0111, nmps: 39, nlps: 36, switchFlag: 0 },\n { qe: 0x0085, nmps: 40, nlps: 37, switchFlag: 0 },\n { qe: 0x0049, nmps: 41, nlps: 38, switchFlag: 0 },\n { qe: 0x0025, nmps: 42, nlps: 39, switchFlag: 0 },\n { qe: 0x0015, nmps: 43, nlps: 40, switchFlag: 0 },\n { qe: 0x0009, nmps: 44, nlps: 41, switchFlag: 0 },\n { qe: 0x0005, nmps: 45, nlps: 42, switchFlag: 0 },\n { qe: 0x0001, nmps: 45, nlps: 43, switchFlag: 0 },\n { qe: 0x5601, nmps: 46, nlps: 46, switchFlag: 0 },\n];\n\n/**\n * This class implements the QM Coder decoding as defined in\n * JPEG 2000 Part I Final Committee Draft Version 1.0\n * Annex C.3 Arithmetic decoding procedure\n * available at http://www.jpeg.org/public/fcd15444-1.pdf\n *\n * The arithmetic decoder is used in conjunction with context models to decode\n * JPEG2000 and JBIG2 streams.\n */\nclass ArithmeticDecoder {\n // C.3.5 Initialisation of the decoder (INITDEC)\n constructor(data, start, end) {\n this.data = data;\n this.bp = start;\n this.dataEnd = end;\n\n this.chigh = data[start];\n this.clow = 0;\n\n this.byteIn();\n\n this.chigh = ((this.chigh << 7) & 0xffff) | ((this.clow >> 9) & 0x7f);\n this.clow = (this.clow << 7) & 0xffff;\n this.ct -= 7;\n this.a = 0x8000;\n }\n\n // C.3.4 Compressed data input (BYTEIN)\n byteIn() {\n const data = this.data;\n let bp = this.bp;\n\n if (data[bp] === 0xff) {\n if (data[bp + 1] > 0x8f) {\n this.clow += 0xff00;\n this.ct = 8;\n } else {\n bp++;\n this.clow += data[bp] << 9;\n this.ct = 7;\n this.bp = bp;\n }\n } else {\n bp++;\n this.clow += bp < this.dataEnd ? data[bp] << 8 : 0xff00;\n this.ct = 8;\n this.bp = bp;\n }\n if (this.clow > 0xffff) {\n this.chigh += this.clow >> 16;\n this.clow &= 0xffff;\n }\n }\n\n // C.3.2 Decoding a decision (DECODE)\n readBit(contexts, pos) {\n // Contexts are packed into 1 byte:\n // highest 7 bits carry cx.index, lowest bit carries cx.mps\n let cx_index = contexts[pos] >> 1,\n cx_mps = contexts[pos] & 1;\n const qeTableIcx = QeTable[cx_index];\n const qeIcx = qeTableIcx.qe;\n let d;\n let a = this.a - qeIcx;\n\n if (this.chigh < qeIcx) {\n // exchangeLps\n if (a < qeIcx) {\n a = qeIcx;\n d = cx_mps;\n cx_index = qeTableIcx.nmps;\n } else {\n a = qeIcx;\n d = 1 ^ cx_mps;\n if (qeTableIcx.switchFlag === 1) {\n cx_mps = d;\n }\n cx_index = qeTableIcx.nlps;\n }\n } else {\n this.chigh -= qeIcx;\n if ((a & 0x8000) !== 0) {\n this.a = a;\n return cx_mps;\n }\n // exchangeMps\n if (a < qeIcx) {\n d = 1 ^ cx_mps;\n if (qeTableIcx.switchFlag === 1) {\n cx_mps = d;\n }\n cx_index = qeTableIcx.nlps;\n } else {\n d = cx_mps;\n cx_index = qeTableIcx.nmps;\n }\n }\n // C.3.3 renormD;\n do {\n if (this.ct === 0) {\n this.byteIn();\n }\n\n a <<= 1;\n this.chigh = ((this.chigh << 1) & 0xffff) | ((this.clow >> 15) & 1);\n this.clow = (this.clow << 1) & 0xffff;\n this.ct--;\n } while ((a & 0x8000) === 0);\n this.a = a;\n\n contexts[pos] = (cx_index << 1) | cx_mps;\n return d;\n }\n}\n\nexport { ArithmeticDecoder };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/* Copyright 1996-2003 Glyph & Cog, LLC\n *\n * The CCITT stream implementation contained in this file is a JavaScript port\n * of XPDF's implementation, made available under the Apache 2.0 open source\n * license.\n */\n\nimport { FormatError, info } from \"../shared/util.js\";\n\n/**\n * @typedef {Object} CCITTFaxDecoderSource\n * @property {function} next - Method that return one byte of data for decoding,\n * or -1 when EOF is reached.\n */\n\nconst ccittEOL = -2;\nconst ccittEOF = -1;\nconst twoDimPass = 0;\nconst twoDimHoriz = 1;\nconst twoDimVert0 = 2;\nconst twoDimVertR1 = 3;\nconst twoDimVertL1 = 4;\nconst twoDimVertR2 = 5;\nconst twoDimVertL2 = 6;\nconst twoDimVertR3 = 7;\nconst twoDimVertL3 = 8;\n\n// prettier-ignore\nconst twoDimTable = [\n [-1, -1], [-1, -1], // 000000x\n [7, twoDimVertL3], // 0000010\n [7, twoDimVertR3], // 0000011\n [6, twoDimVertL2], [6, twoDimVertL2], // 000010x\n [6, twoDimVertR2], [6, twoDimVertR2], // 000011x\n [4, twoDimPass], [4, twoDimPass], // 0001xxx\n [4, twoDimPass], [4, twoDimPass],\n [4, twoDimPass], [4, twoDimPass],\n [4, twoDimPass], [4, twoDimPass],\n [3, twoDimHoriz], [3, twoDimHoriz], // 001xxxx\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimHoriz], [3, twoDimHoriz],\n [3, twoDimVertL1], [3, twoDimVertL1], // 010xxxx\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertL1], [3, twoDimVertL1],\n [3, twoDimVertR1], [3, twoDimVertR1], // 011xxxx\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [3, twoDimVertR1], [3, twoDimVertR1],\n [1, twoDimVert0], [1, twoDimVert0], // 1xxxxxx\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0],\n [1, twoDimVert0], [1, twoDimVert0]\n];\n\n// prettier-ignore\nconst whiteTable1 = [\n [-1, -1], // 00000\n [12, ccittEOL], // 00001\n [-1, -1], [-1, -1], // 0001x\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 001xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 010xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 011xx\n [11, 1792], [11, 1792], // 1000x\n [12, 1984], // 10010\n [12, 2048], // 10011\n [12, 2112], // 10100\n [12, 2176], // 10101\n [12, 2240], // 10110\n [12, 2304], // 10111\n [11, 1856], [11, 1856], // 1100x\n [11, 1920], [11, 1920], // 1101x\n [12, 2368], // 11100\n [12, 2432], // 11101\n [12, 2496], // 11110\n [12, 2560] // 11111\n];\n\n// prettier-ignore\nconst whiteTable2 = [\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 0000000xx\n [8, 29], [8, 29], // 00000010x\n [8, 30], [8, 30], // 00000011x\n [8, 45], [8, 45], // 00000100x\n [8, 46], [8, 46], // 00000101x\n [7, 22], [7, 22], [7, 22], [7, 22], // 0000011xx\n [7, 23], [7, 23], [7, 23], [7, 23], // 0000100xx\n [8, 47], [8, 47], // 00001010x\n [8, 48], [8, 48], // 00001011x\n [6, 13], [6, 13], [6, 13], [6, 13], // 000011xxx\n [6, 13], [6, 13], [6, 13], [6, 13],\n [7, 20], [7, 20], [7, 20], [7, 20], // 0001000xx\n [8, 33], [8, 33], // 00010010x\n [8, 34], [8, 34], // 00010011x\n [8, 35], [8, 35], // 00010100x\n [8, 36], [8, 36], // 00010101x\n [8, 37], [8, 37], // 00010110x\n [8, 38], [8, 38], // 00010111x\n [7, 19], [7, 19], [7, 19], [7, 19], // 0001100xx\n [8, 31], [8, 31], // 00011010x\n [8, 32], [8, 32], // 00011011x\n [6, 1], [6, 1], [6, 1], [6, 1], // 000111xxx\n [6, 1], [6, 1], [6, 1], [6, 1],\n [6, 12], [6, 12], [6, 12], [6, 12], // 001000xxx\n [6, 12], [6, 12], [6, 12], [6, 12],\n [8, 53], [8, 53], // 00100100x\n [8, 54], [8, 54], // 00100101x\n [7, 26], [7, 26], [7, 26], [7, 26], // 0010011xx\n [8, 39], [8, 39], // 00101000x\n [8, 40], [8, 40], // 00101001x\n [8, 41], [8, 41], // 00101010x\n [8, 42], [8, 42], // 00101011x\n [8, 43], [8, 43], // 00101100x\n [8, 44], [8, 44], // 00101101x\n [7, 21], [7, 21], [7, 21], [7, 21], // 0010111xx\n [7, 28], [7, 28], [7, 28], [7, 28], // 0011000xx\n [8, 61], [8, 61], // 00110010x\n [8, 62], [8, 62], // 00110011x\n [8, 63], [8, 63], // 00110100x\n [8, 0], [8, 0], // 00110101x\n [8, 320], [8, 320], // 00110110x\n [8, 384], [8, 384], // 00110111x\n [5, 10], [5, 10], [5, 10], [5, 10], // 00111xxxx\n [5, 10], [5, 10], [5, 10], [5, 10],\n [5, 10], [5, 10], [5, 10], [5, 10],\n [5, 10], [5, 10], [5, 10], [5, 10],\n [5, 11], [5, 11], [5, 11], [5, 11], // 01000xxxx\n [5, 11], [5, 11], [5, 11], [5, 11],\n [5, 11], [5, 11], [5, 11], [5, 11],\n [5, 11], [5, 11], [5, 11], [5, 11],\n [7, 27], [7, 27], [7, 27], [7, 27], // 0100100xx\n [8, 59], [8, 59], // 01001010x\n [8, 60], [8, 60], // 01001011x\n [9, 1472], // 010011000\n [9, 1536], // 010011001\n [9, 1600], // 010011010\n [9, 1728], // 010011011\n [7, 18], [7, 18], [7, 18], [7, 18], // 0100111xx\n [7, 24], [7, 24], [7, 24], [7, 24], // 0101000xx\n [8, 49], [8, 49], // 01010010x\n [8, 50], [8, 50], // 01010011x\n [8, 51], [8, 51], // 01010100x\n [8, 52], [8, 52], // 01010101x\n [7, 25], [7, 25], [7, 25], [7, 25], // 0101011xx\n [8, 55], [8, 55], // 01011000x\n [8, 56], [8, 56], // 01011001x\n [8, 57], [8, 57], // 01011010x\n [8, 58], [8, 58], // 01011011x\n [6, 192], [6, 192], [6, 192], [6, 192], // 010111xxx\n [6, 192], [6, 192], [6, 192], [6, 192],\n [6, 1664], [6, 1664], [6, 1664], [6, 1664], // 011000xxx\n [6, 1664], [6, 1664], [6, 1664], [6, 1664],\n [8, 448], [8, 448], // 01100100x\n [8, 512], [8, 512], // 01100101x\n [9, 704], // 011001100\n [9, 768], // 011001101\n [8, 640], [8, 640], // 01100111x\n [8, 576], [8, 576], // 01101000x\n [9, 832], // 011010010\n [9, 896], // 011010011\n [9, 960], // 011010100\n [9, 1024], // 011010101\n [9, 1088], // 011010110\n [9, 1152], // 011010111\n [9, 1216], // 011011000\n [9, 1280], // 011011001\n [9, 1344], // 011011010\n [9, 1408], // 011011011\n [7, 256], [7, 256], [7, 256], [7, 256], // 0110111xx\n [4, 2], [4, 2], [4, 2], [4, 2], // 0111xxxxx\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 2], [4, 2], [4, 2], [4, 2],\n [4, 3], [4, 3], [4, 3], [4, 3], // 1000xxxxx\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [4, 3], [4, 3], [4, 3], [4, 3],\n [5, 128], [5, 128], [5, 128], [5, 128], // 10010xxxx\n [5, 128], [5, 128], [5, 128], [5, 128],\n [5, 128], [5, 128], [5, 128], [5, 128],\n [5, 128], [5, 128], [5, 128], [5, 128],\n [5, 8], [5, 8], [5, 8], [5, 8], // 10011xxxx\n [5, 8], [5, 8], [5, 8], [5, 8],\n [5, 8], [5, 8], [5, 8], [5, 8],\n [5, 8], [5, 8], [5, 8], [5, 8],\n [5, 9], [5, 9], [5, 9], [5, 9], // 10100xxxx\n [5, 9], [5, 9], [5, 9], [5, 9],\n [5, 9], [5, 9], [5, 9], [5, 9],\n [5, 9], [5, 9], [5, 9], [5, 9],\n [6, 16], [6, 16], [6, 16], [6, 16], // 101010xxx\n [6, 16], [6, 16], [6, 16], [6, 16],\n [6, 17], [6, 17], [6, 17], [6, 17], // 101011xxx\n [6, 17], [6, 17], [6, 17], [6, 17],\n [4, 4], [4, 4], [4, 4], [4, 4], // 1011xxxxx\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 4], [4, 4], [4, 4], [4, 4],\n [4, 5], [4, 5], [4, 5], [4, 5], // 1100xxxxx\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [4, 5], [4, 5], [4, 5], [4, 5],\n [6, 14], [6, 14], [6, 14], [6, 14], // 110100xxx\n [6, 14], [6, 14], [6, 14], [6, 14],\n [6, 15], [6, 15], [6, 15], [6, 15], // 110101xxx\n [6, 15], [6, 15], [6, 15], [6, 15],\n [5, 64], [5, 64], [5, 64], [5, 64], // 11011xxxx\n [5, 64], [5, 64], [5, 64], [5, 64],\n [5, 64], [5, 64], [5, 64], [5, 64],\n [5, 64], [5, 64], [5, 64], [5, 64],\n [4, 6], [4, 6], [4, 6], [4, 6], // 1110xxxxx\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 6], [4, 6], [4, 6], [4, 6],\n [4, 7], [4, 7], [4, 7], [4, 7], // 1111xxxxx\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7],\n [4, 7], [4, 7], [4, 7], [4, 7]\n];\n\n// prettier-ignore\nconst blackTable1 = [\n [-1, -1], [-1, -1], // 000000000000x\n [12, ccittEOL], [12, ccittEOL], // 000000000001x\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000001xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000010xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000011xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000100xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000101xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000110xx\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 00000000111xx\n [11, 1792], [11, 1792], [11, 1792], [11, 1792], // 00000001000xx\n [12, 1984], [12, 1984], // 000000010010x\n [12, 2048], [12, 2048], // 000000010011x\n [12, 2112], [12, 2112], // 000000010100x\n [12, 2176], [12, 2176], // 000000010101x\n [12, 2240], [12, 2240], // 000000010110x\n [12, 2304], [12, 2304], // 000000010111x\n [11, 1856], [11, 1856], [11, 1856], [11, 1856], // 00000001100xx\n [11, 1920], [11, 1920], [11, 1920], [11, 1920], // 00000001101xx\n [12, 2368], [12, 2368], // 000000011100x\n [12, 2432], [12, 2432], // 000000011101x\n [12, 2496], [12, 2496], // 000000011110x\n [12, 2560], [12, 2560], // 000000011111x\n [10, 18], [10, 18], [10, 18], [10, 18], // 0000001000xxx\n [10, 18], [10, 18], [10, 18], [10, 18],\n [12, 52], [12, 52], // 000000100100x\n [13, 640], // 0000001001010\n [13, 704], // 0000001001011\n [13, 768], // 0000001001100\n [13, 832], // 0000001001101\n [12, 55], [12, 55], // 000000100111x\n [12, 56], [12, 56], // 000000101000x\n [13, 1280], // 0000001010010\n [13, 1344], // 0000001010011\n [13, 1408], // 0000001010100\n [13, 1472], // 0000001010101\n [12, 59], [12, 59], // 000000101011x\n [12, 60], [12, 60], // 000000101100x\n [13, 1536], // 0000001011010\n [13, 1600], // 0000001011011\n [11, 24], [11, 24], [11, 24], [11, 24], // 00000010111xx\n [11, 25], [11, 25], [11, 25], [11, 25], // 00000011000xx\n [13, 1664], // 0000001100100\n [13, 1728], // 0000001100101\n [12, 320], [12, 320], // 000000110011x\n [12, 384], [12, 384], // 000000110100x\n [12, 448], [12, 448], // 000000110101x\n [13, 512], // 0000001101100\n [13, 576], // 0000001101101\n [12, 53], [12, 53], // 000000110111x\n [12, 54], [12, 54], // 000000111000x\n [13, 896], // 0000001110010\n [13, 960], // 0000001110011\n [13, 1024], // 0000001110100\n [13, 1088], // 0000001110101\n [13, 1152], // 0000001110110\n [13, 1216], // 0000001110111\n [10, 64], [10, 64], [10, 64], [10, 64], // 0000001111xxx\n [10, 64], [10, 64], [10, 64], [10, 64]\n];\n\n// prettier-ignore\nconst blackTable2 = [\n [8, 13], [8, 13], [8, 13], [8, 13], // 00000100xxxx\n [8, 13], [8, 13], [8, 13], [8, 13],\n [8, 13], [8, 13], [8, 13], [8, 13],\n [8, 13], [8, 13], [8, 13], [8, 13],\n [11, 23], [11, 23], // 00000101000x\n [12, 50], // 000001010010\n [12, 51], // 000001010011\n [12, 44], // 000001010100\n [12, 45], // 000001010101\n [12, 46], // 000001010110\n [12, 47], // 000001010111\n [12, 57], // 000001011000\n [12, 58], // 000001011001\n [12, 61], // 000001011010\n [12, 256], // 000001011011\n [10, 16], [10, 16], [10, 16], [10, 16], // 0000010111xx\n [10, 17], [10, 17], [10, 17], [10, 17], // 0000011000xx\n [12, 48], // 000001100100\n [12, 49], // 000001100101\n [12, 62], // 000001100110\n [12, 63], // 000001100111\n [12, 30], // 000001101000\n [12, 31], // 000001101001\n [12, 32], // 000001101010\n [12, 33], // 000001101011\n [12, 40], // 000001101100\n [12, 41], // 000001101101\n [11, 22], [11, 22], // 00000110111x\n [8, 14], [8, 14], [8, 14], [8, 14], // 00000111xxxx\n [8, 14], [8, 14], [8, 14], [8, 14],\n [8, 14], [8, 14], [8, 14], [8, 14],\n [8, 14], [8, 14], [8, 14], [8, 14],\n [7, 10], [7, 10], [7, 10], [7, 10], // 0000100xxxxx\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 10], [7, 10], [7, 10], [7, 10],\n [7, 11], [7, 11], [7, 11], [7, 11], // 0000101xxxxx\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [7, 11], [7, 11], [7, 11], [7, 11],\n [9, 15], [9, 15], [9, 15], [9, 15], // 000011000xxx\n [9, 15], [9, 15], [9, 15], [9, 15],\n [12, 128], // 000011001000\n [12, 192], // 000011001001\n [12, 26], // 000011001010\n [12, 27], // 000011001011\n [12, 28], // 000011001100\n [12, 29], // 000011001101\n [11, 19], [11, 19], // 00001100111x\n [11, 20], [11, 20], // 00001101000x\n [12, 34], // 000011010010\n [12, 35], // 000011010011\n [12, 36], // 000011010100\n [12, 37], // 000011010101\n [12, 38], // 000011010110\n [12, 39], // 000011010111\n [11, 21], [11, 21], // 00001101100x\n [12, 42], // 000011011010\n [12, 43], // 000011011011\n [10, 0], [10, 0], [10, 0], [10, 0], // 0000110111xx\n [7, 12], [7, 12], [7, 12], [7, 12], // 0000111xxxxx\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12],\n [7, 12], [7, 12], [7, 12], [7, 12]\n];\n\n// prettier-ignore\nconst blackTable3 = [\n [-1, -1], [-1, -1], [-1, -1], [-1, -1], // 0000xx\n [6, 9], // 000100\n [6, 8], // 000101\n [5, 7], [5, 7], // 00011x\n [4, 6], [4, 6], [4, 6], [4, 6], // 0010xx\n [4, 5], [4, 5], [4, 5], [4, 5], // 0011xx\n [3, 1], [3, 1], [3, 1], [3, 1], // 010xxx\n [3, 1], [3, 1], [3, 1], [3, 1],\n [3, 4], [3, 4], [3, 4], [3, 4], // 011xxx\n [3, 4], [3, 4], [3, 4], [3, 4],\n [2, 3], [2, 3], [2, 3], [2, 3], // 10xxxx\n [2, 3], [2, 3], [2, 3], [2, 3],\n [2, 3], [2, 3], [2, 3], [2, 3],\n [2, 3], [2, 3], [2, 3], [2, 3],\n [2, 2], [2, 2], [2, 2], [2, 2], // 11xxxx\n [2, 2], [2, 2], [2, 2], [2, 2],\n [2, 2], [2, 2], [2, 2], [2, 2],\n [2, 2], [2, 2], [2, 2], [2, 2]\n];\n\n/**\n * @param {CCITTFaxDecoderSource} source - The data which should be decoded.\n * @param {Object} [options] - Decoding options.\n */\nclass CCITTFaxDecoder {\n constructor(source, options = {}) {\n if (!source || typeof source.next !== \"function\") {\n throw new Error('CCITTFaxDecoder - invalid \"source\" parameter.');\n }\n this.source = source;\n this.eof = false;\n\n this.encoding = options.K || 0;\n this.eoline = options.EndOfLine || false;\n this.byteAlign = options.EncodedByteAlign || false;\n this.columns = options.Columns || 1728;\n this.rows = options.Rows || 0;\n this.eoblock = options.EndOfBlock ?? true;\n this.black = options.BlackIs1 || false;\n\n this.codingLine = new Uint32Array(this.columns + 1);\n this.refLine = new Uint32Array(this.columns + 2);\n\n this.codingLine[0] = this.columns;\n this.codingPos = 0;\n\n this.row = 0;\n this.nextLine2D = this.encoding < 0;\n this.inputBits = 0;\n this.inputBuf = 0;\n this.outputBits = 0;\n this.rowsDone = false;\n\n let code1;\n while ((code1 = this._lookBits(12)) === 0) {\n this._eatBits(1);\n }\n if (code1 === 1) {\n this._eatBits(12);\n }\n if (this.encoding > 0) {\n this.nextLine2D = !this._lookBits(1);\n this._eatBits(1);\n }\n }\n\n readNextChar() {\n if (this.eof) {\n return -1;\n }\n const refLine = this.refLine;\n const codingLine = this.codingLine;\n const columns = this.columns;\n\n let refPos, blackPixels, bits, i;\n\n if (this.outputBits === 0) {\n if (this.rowsDone) {\n this.eof = true;\n }\n if (this.eof) {\n return -1;\n }\n this.err = false;\n\n let code1, code2, code3;\n if (this.nextLine2D) {\n for (i = 0; codingLine[i] < columns; ++i) {\n refLine[i] = codingLine[i];\n }\n refLine[i++] = columns;\n refLine[i] = columns;\n codingLine[0] = 0;\n this.codingPos = 0;\n refPos = 0;\n blackPixels = 0;\n\n while (codingLine[this.codingPos] < columns) {\n code1 = this._getTwoDimCode();\n switch (code1) {\n case twoDimPass:\n this._addPixels(refLine[refPos + 1], blackPixels);\n if (refLine[refPos + 1] < columns) {\n refPos += 2;\n }\n break;\n case twoDimHoriz:\n code1 = code2 = 0;\n if (blackPixels) {\n do {\n code1 += code3 = this._getBlackCode();\n } while (code3 >= 64);\n do {\n code2 += code3 = this._getWhiteCode();\n } while (code3 >= 64);\n } else {\n do {\n code1 += code3 = this._getWhiteCode();\n } while (code3 >= 64);\n do {\n code2 += code3 = this._getBlackCode();\n } while (code3 >= 64);\n }\n this._addPixels(codingLine[this.codingPos] + code1, blackPixels);\n if (codingLine[this.codingPos] < columns) {\n this._addPixels(\n codingLine[this.codingPos] + code2,\n blackPixels ^ 1\n );\n }\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n break;\n case twoDimVertR3:\n this._addPixels(refLine[refPos] + 3, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n ++refPos;\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVertR2:\n this._addPixels(refLine[refPos] + 2, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n ++refPos;\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVertR1:\n this._addPixels(refLine[refPos] + 1, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n ++refPos;\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVert0:\n this._addPixels(refLine[refPos], blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n ++refPos;\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVertL3:\n this._addPixelsNeg(refLine[refPos] - 3, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n if (refPos > 0) {\n --refPos;\n } else {\n ++refPos;\n }\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVertL2:\n this._addPixelsNeg(refLine[refPos] - 2, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n if (refPos > 0) {\n --refPos;\n } else {\n ++refPos;\n }\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case twoDimVertL1:\n this._addPixelsNeg(refLine[refPos] - 1, blackPixels);\n blackPixels ^= 1;\n if (codingLine[this.codingPos] < columns) {\n if (refPos > 0) {\n --refPos;\n } else {\n ++refPos;\n }\n while (\n refLine[refPos] <= codingLine[this.codingPos] &&\n refLine[refPos] < columns\n ) {\n refPos += 2;\n }\n }\n break;\n case ccittEOF:\n this._addPixels(columns, 0);\n this.eof = true;\n break;\n default:\n info(\"bad 2d code\");\n this._addPixels(columns, 0);\n this.err = true;\n }\n }\n } else {\n codingLine[0] = 0;\n this.codingPos = 0;\n blackPixels = 0;\n while (codingLine[this.codingPos] < columns) {\n code1 = 0;\n if (blackPixels) {\n do {\n code1 += code3 = this._getBlackCode();\n } while (code3 >= 64);\n } else {\n do {\n code1 += code3 = this._getWhiteCode();\n } while (code3 >= 64);\n }\n this._addPixels(codingLine[this.codingPos] + code1, blackPixels);\n blackPixels ^= 1;\n }\n }\n\n let gotEOL = false;\n\n if (this.byteAlign) {\n this.inputBits &= ~7;\n }\n\n if (!this.eoblock && this.row === this.rows - 1) {\n this.rowsDone = true;\n } else {\n code1 = this._lookBits(12);\n if (this.eoline) {\n while (code1 !== ccittEOF && code1 !== 1) {\n this._eatBits(1);\n code1 = this._lookBits(12);\n }\n } else {\n while (code1 === 0) {\n this._eatBits(1);\n code1 = this._lookBits(12);\n }\n }\n if (code1 === 1) {\n this._eatBits(12);\n gotEOL = true;\n } else if (code1 === ccittEOF) {\n this.eof = true;\n }\n }\n\n if (!this.eof && this.encoding > 0 && !this.rowsDone) {\n this.nextLine2D = !this._lookBits(1);\n this._eatBits(1);\n }\n\n if (this.eoblock && gotEOL && this.byteAlign) {\n code1 = this._lookBits(12);\n if (code1 === 1) {\n this._eatBits(12);\n if (this.encoding > 0) {\n this._lookBits(1);\n this._eatBits(1);\n }\n if (this.encoding >= 0) {\n for (i = 0; i < 4; ++i) {\n code1 = this._lookBits(12);\n if (code1 !== 1) {\n info(\"bad rtc code: \" + code1);\n }\n this._eatBits(12);\n if (this.encoding > 0) {\n this._lookBits(1);\n this._eatBits(1);\n }\n }\n }\n this.eof = true;\n }\n } else if (this.err && this.eoline) {\n while (true) {\n code1 = this._lookBits(13);\n if (code1 === ccittEOF) {\n this.eof = true;\n return -1;\n }\n if (code1 >> 1 === 1) {\n break;\n }\n this._eatBits(1);\n }\n this._eatBits(12);\n if (this.encoding > 0) {\n this._eatBits(1);\n this.nextLine2D = !(code1 & 1);\n }\n }\n\n this.outputBits =\n codingLine[0] > 0\n ? codingLine[(this.codingPos = 0)]\n : codingLine[(this.codingPos = 1)];\n this.row++;\n }\n\n let c;\n if (this.outputBits >= 8) {\n c = this.codingPos & 1 ? 0 : 0xff;\n this.outputBits -= 8;\n if (this.outputBits === 0 && codingLine[this.codingPos] < columns) {\n this.codingPos++;\n this.outputBits =\n codingLine[this.codingPos] - codingLine[this.codingPos - 1];\n }\n } else {\n bits = 8;\n c = 0;\n do {\n if (typeof this.outputBits !== \"number\") {\n throw new FormatError(\n 'Invalid /CCITTFaxDecode data, \"outputBits\" must be a number.'\n );\n }\n\n if (this.outputBits > bits) {\n c <<= bits;\n if (!(this.codingPos & 1)) {\n c |= 0xff >> (8 - bits);\n }\n this.outputBits -= bits;\n bits = 0;\n } else {\n c <<= this.outputBits;\n if (!(this.codingPos & 1)) {\n c |= 0xff >> (8 - this.outputBits);\n }\n bits -= this.outputBits;\n this.outputBits = 0;\n if (codingLine[this.codingPos] < columns) {\n this.codingPos++;\n this.outputBits =\n codingLine[this.codingPos] - codingLine[this.codingPos - 1];\n } else if (bits > 0) {\n c <<= bits;\n bits = 0;\n }\n }\n } while (bits);\n }\n if (this.black) {\n c ^= 0xff;\n }\n return c;\n }\n\n /**\n * @private\n */\n _addPixels(a1, blackPixels) {\n const codingLine = this.codingLine;\n let codingPos = this.codingPos;\n\n if (a1 > codingLine[codingPos]) {\n if (a1 > this.columns) {\n info(\"row is wrong length\");\n this.err = true;\n a1 = this.columns;\n }\n if ((codingPos & 1) ^ blackPixels) {\n ++codingPos;\n }\n\n codingLine[codingPos] = a1;\n }\n this.codingPos = codingPos;\n }\n\n /**\n * @private\n */\n _addPixelsNeg(a1, blackPixels) {\n const codingLine = this.codingLine;\n let codingPos = this.codingPos;\n\n if (a1 > codingLine[codingPos]) {\n if (a1 > this.columns) {\n info(\"row is wrong length\");\n this.err = true;\n a1 = this.columns;\n }\n if ((codingPos & 1) ^ blackPixels) {\n ++codingPos;\n }\n\n codingLine[codingPos] = a1;\n } else if (a1 < codingLine[codingPos]) {\n if (a1 < 0) {\n info(\"invalid code\");\n this.err = true;\n a1 = 0;\n }\n while (codingPos > 0 && a1 < codingLine[codingPos - 1]) {\n --codingPos;\n }\n codingLine[codingPos] = a1;\n }\n\n this.codingPos = codingPos;\n }\n\n /**\n * This function returns the code found from the table.\n * The start and end parameters set the boundaries for searching the table.\n * The limit parameter is optional. Function returns an array with three\n * values. The first array element indicates whether a valid code is being\n * returned. The second array element is the actual code. The third array\n * element indicates whether EOF was reached.\n * @private\n */\n _findTableCode(start, end, table, limit) {\n const limitValue = limit || 0;\n for (let i = start; i <= end; ++i) {\n let code = this._lookBits(i);\n if (code === ccittEOF) {\n return [true, 1, false];\n }\n if (i < end) {\n code <<= end - i;\n }\n if (!limitValue || code >= limitValue) {\n const p = table[code - limitValue];\n if (p[0] === i) {\n this._eatBits(i);\n return [true, p[1], true];\n }\n }\n }\n return [false, 0, false];\n }\n\n /**\n * @private\n */\n _getTwoDimCode() {\n let code = 0;\n let p;\n if (this.eoblock) {\n code = this._lookBits(7);\n p = twoDimTable[code];\n if (p?.[0] > 0) {\n this._eatBits(p[0]);\n return p[1];\n }\n } else {\n const result = this._findTableCode(1, 7, twoDimTable);\n if (result[0] && result[2]) {\n return result[1];\n }\n }\n info(\"Bad two dim code\");\n return ccittEOF;\n }\n\n /**\n * @private\n */\n _getWhiteCode() {\n let code = 0;\n let p;\n if (this.eoblock) {\n code = this._lookBits(12);\n if (code === ccittEOF) {\n return 1;\n }\n\n p = code >> 5 === 0 ? whiteTable1[code] : whiteTable2[code >> 3];\n\n if (p[0] > 0) {\n this._eatBits(p[0]);\n return p[1];\n }\n } else {\n let result = this._findTableCode(1, 9, whiteTable2);\n if (result[0]) {\n return result[1];\n }\n\n result = this._findTableCode(11, 12, whiteTable1);\n if (result[0]) {\n return result[1];\n }\n }\n info(\"bad white code\");\n this._eatBits(1);\n return 1;\n }\n\n /**\n * @private\n */\n _getBlackCode() {\n let code, p;\n if (this.eoblock) {\n code = this._lookBits(13);\n if (code === ccittEOF) {\n return 1;\n }\n if (code >> 7 === 0) {\n p = blackTable1[code];\n } else if (code >> 9 === 0 && code >> 7 !== 0) {\n p = blackTable2[(code >> 1) - 64];\n } else {\n p = blackTable3[code >> 7];\n }\n\n if (p[0] > 0) {\n this._eatBits(p[0]);\n return p[1];\n }\n } else {\n let result = this._findTableCode(2, 6, blackTable3);\n if (result[0]) {\n return result[1];\n }\n\n result = this._findTableCode(7, 12, blackTable2, 64);\n if (result[0]) {\n return result[1];\n }\n\n result = this._findTableCode(10, 13, blackTable1);\n if (result[0]) {\n return result[1];\n }\n }\n info(\"bad black code\");\n this._eatBits(1);\n return 1;\n }\n\n /**\n * @private\n */\n _lookBits(n) {\n let c;\n while (this.inputBits < n) {\n if ((c = this.source.next()) === -1) {\n if (this.inputBits === 0) {\n return ccittEOF;\n }\n return (this.inputBuf << (n - this.inputBits)) & (0xffff >> (16 - n));\n }\n this.inputBuf = (this.inputBuf << 8) | c;\n this.inputBits += 8;\n }\n return (this.inputBuf >> (this.inputBits - n)) & (0xffff >> (16 - n));\n }\n\n /**\n * @private\n */\n _eatBits(n) {\n if ((this.inputBits -= n) < 0) {\n this.inputBits = 0;\n }\n }\n}\n\nexport { CCITTFaxDecoder };\n","/* Copyright 2014 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the 'License');\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an 'AS IS' BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { assert, BaseException, warn } from \"../shared/util.js\";\nimport { grayToRGBA } from \"../shared/image_utils.js\";\nimport { readUint16 } from \"./core_utils.js\";\n\nclass JpegError extends BaseException {\n constructor(msg) {\n super(`JPEG error: ${msg}`, \"JpegError\");\n }\n}\n\nclass DNLMarkerError extends BaseException {\n constructor(message, scanLines) {\n super(message, \"DNLMarkerError\");\n this.scanLines = scanLines;\n }\n}\n\nclass EOIMarkerError extends BaseException {\n constructor(msg) {\n super(msg, \"EOIMarkerError\");\n }\n}\n\n/**\n * This code was forked from https://github.com/notmasteryet/jpgjs.\n * The original version was created by GitHub user notmasteryet.\n *\n * - The JPEG specification can be found in the ITU CCITT Recommendation T.81\n * (www.w3.org/Graphics/JPEG/itu-t81.pdf)\n * - The JFIF specification can be found in the JPEG File Interchange Format\n * (www.w3.org/Graphics/JPEG/jfif3.pdf)\n * - The Adobe Application-Specific JPEG markers in the\n * Supporting the DCT Filters in PostScript Level 2, Technical Note #5116\n * (partners.adobe.com/public/developer/en/ps/sdk/5116.DCT_Filter.pdf)\n */\n\n// prettier-ignore\nconst dctZigZag = new Uint8Array([\n 0,\n 1, 8,\n 16, 9, 2,\n 3, 10, 17, 24,\n 32, 25, 18, 11, 4,\n 5, 12, 19, 26, 33, 40,\n 48, 41, 34, 27, 20, 13, 6,\n 7, 14, 21, 28, 35, 42, 49, 56,\n 57, 50, 43, 36, 29, 22, 15,\n 23, 30, 37, 44, 51, 58,\n 59, 52, 45, 38, 31,\n 39, 46, 53, 60,\n 61, 54, 47,\n 55, 62,\n 63\n]);\n\nconst dctCos1 = 4017; // cos(pi/16)\nconst dctSin1 = 799; // sin(pi/16)\nconst dctCos3 = 3406; // cos(3*pi/16)\nconst dctSin3 = 2276; // sin(3*pi/16)\nconst dctCos6 = 1567; // cos(6*pi/16)\nconst dctSin6 = 3784; // sin(6*pi/16)\nconst dctSqrt2 = 5793; // sqrt(2)\nconst dctSqrt1d2 = 2896; // sqrt(2) / 2\n\nfunction buildHuffmanTable(codeLengths, values) {\n let k = 0,\n i,\n j,\n length = 16;\n while (length > 0 && !codeLengths[length - 1]) {\n length--;\n }\n const code = [{ children: [], index: 0 }];\n let p = code[0],\n q;\n for (i = 0; i < length; i++) {\n for (j = 0; j < codeLengths[i]; j++) {\n p = code.pop();\n p.children[p.index] = values[k];\n while (p.index > 0) {\n p = code.pop();\n }\n p.index++;\n code.push(p);\n while (code.length <= i) {\n code.push((q = { children: [], index: 0 }));\n p.children[p.index] = q.children;\n p = q;\n }\n k++;\n }\n if (i + 1 < length) {\n // p here points to last code\n code.push((q = { children: [], index: 0 }));\n p.children[p.index] = q.children;\n p = q;\n }\n }\n return code[0].children;\n}\n\nfunction getBlockBufferOffset(component, row, col) {\n return 64 * ((component.blocksPerLine + 1) * row + col);\n}\n\nfunction decodeScan(\n data,\n offset,\n frame,\n components,\n resetInterval,\n spectralStart,\n spectralEnd,\n successivePrev,\n successive,\n parseDNLMarker = false\n) {\n const mcusPerLine = frame.mcusPerLine;\n const progressive = frame.progressive;\n\n const startOffset = offset;\n let bitsData = 0,\n bitsCount = 0;\n\n function readBit() {\n if (bitsCount > 0) {\n bitsCount--;\n return (bitsData >> bitsCount) & 1;\n }\n bitsData = data[offset++];\n if (bitsData === 0xff) {\n const nextByte = data[offset++];\n if (nextByte) {\n if (nextByte === /* DNL = */ 0xdc && parseDNLMarker) {\n offset += 2; // Skip marker length.\n\n const scanLines = readUint16(data, offset);\n offset += 2;\n if (scanLines > 0 && scanLines !== frame.scanLines) {\n throw new DNLMarkerError(\n \"Found DNL marker (0xFFDC) while parsing scan data\",\n scanLines\n );\n }\n } else if (nextByte === /* EOI = */ 0xd9) {\n if (parseDNLMarker) {\n // NOTE: only 8-bit JPEG images are supported in this decoder.\n const maybeScanLines = blockRow * (frame.precision === 8 ? 8 : 0);\n // Heuristic to attempt to handle corrupt JPEG images with too\n // large `scanLines` parameter, by falling back to the currently\n // parsed number of scanLines when it's at least (approximately)\n // one \"half\" order of magnitude smaller than expected (fixes\n // issue10880.pdf, issue10989.pdf, issue15492.pdf).\n if (\n maybeScanLines > 0 &&\n Math.round(frame.scanLines / maybeScanLines) >= 5\n ) {\n throw new DNLMarkerError(\n \"Found EOI marker (0xFFD9) while parsing scan data, \" +\n \"possibly caused by incorrect `scanLines` parameter\",\n maybeScanLines\n );\n }\n }\n throw new EOIMarkerError(\n \"Found EOI marker (0xFFD9) while parsing scan data\"\n );\n }\n throw new JpegError(\n `unexpected marker ${((bitsData << 8) | nextByte).toString(16)}`\n );\n }\n // unstuff 0\n }\n bitsCount = 7;\n return bitsData >>> 7;\n }\n\n function decodeHuffman(tree) {\n let node = tree;\n while (true) {\n node = node[readBit()];\n switch (typeof node) {\n case \"number\":\n return node;\n case \"object\":\n continue;\n }\n throw new JpegError(\"invalid huffman sequence\");\n }\n }\n\n function receive(length) {\n let n = 0;\n while (length > 0) {\n n = (n << 1) | readBit();\n length--;\n }\n return n;\n }\n\n function receiveAndExtend(length) {\n if (length === 1) {\n return readBit() === 1 ? 1 : -1;\n }\n const n = receive(length);\n if (n >= 1 << (length - 1)) {\n return n;\n }\n return n + (-1 << length) + 1;\n }\n\n function decodeBaseline(component, blockOffset) {\n const t = decodeHuffman(component.huffmanTableDC);\n const diff = t === 0 ? 0 : receiveAndExtend(t);\n component.blockData[blockOffset] = component.pred += diff;\n let k = 1;\n while (k < 64) {\n const rs = decodeHuffman(component.huffmanTableAC);\n const s = rs & 15,\n r = rs >> 4;\n if (s === 0) {\n if (r < 15) {\n break;\n }\n k += 16;\n continue;\n }\n k += r;\n const z = dctZigZag[k];\n component.blockData[blockOffset + z] = receiveAndExtend(s);\n k++;\n }\n }\n\n function decodeDCFirst(component, blockOffset) {\n const t = decodeHuffman(component.huffmanTableDC);\n const diff = t === 0 ? 0 : receiveAndExtend(t) << successive;\n component.blockData[blockOffset] = component.pred += diff;\n }\n\n function decodeDCSuccessive(component, blockOffset) {\n component.blockData[blockOffset] |= readBit() << successive;\n }\n\n let eobrun = 0;\n function decodeACFirst(component, blockOffset) {\n if (eobrun > 0) {\n eobrun--;\n return;\n }\n let k = spectralStart;\n const e = spectralEnd;\n while (k <= e) {\n const rs = decodeHuffman(component.huffmanTableAC);\n const s = rs & 15,\n r = rs >> 4;\n if (s === 0) {\n if (r < 15) {\n eobrun = receive(r) + (1 << r) - 1;\n break;\n }\n k += 16;\n continue;\n }\n k += r;\n const z = dctZigZag[k];\n component.blockData[blockOffset + z] =\n receiveAndExtend(s) * (1 << successive);\n k++;\n }\n }\n\n let successiveACState = 0,\n successiveACNextValue;\n function decodeACSuccessive(component, blockOffset) {\n let k = spectralStart;\n const e = spectralEnd;\n let r = 0;\n let s;\n let rs;\n while (k <= e) {\n const offsetZ = blockOffset + dctZigZag[k];\n const sign = component.blockData[offsetZ] < 0 ? -1 : 1;\n switch (successiveACState) {\n case 0: // initial state\n rs = decodeHuffman(component.huffmanTableAC);\n s = rs & 15;\n r = rs >> 4;\n if (s === 0) {\n if (r < 15) {\n eobrun = receive(r) + (1 << r);\n successiveACState = 4;\n } else {\n r = 16;\n successiveACState = 1;\n }\n } else {\n if (s !== 1) {\n throw new JpegError(\"invalid ACn encoding\");\n }\n successiveACNextValue = receiveAndExtend(s);\n successiveACState = r ? 2 : 3;\n }\n continue;\n case 1: // skipping r zero items\n case 2:\n if (component.blockData[offsetZ]) {\n component.blockData[offsetZ] += sign * (readBit() << successive);\n } else {\n r--;\n if (r === 0) {\n successiveACState = successiveACState === 2 ? 3 : 0;\n }\n }\n break;\n case 3: // set value for a zero item\n if (component.blockData[offsetZ]) {\n component.blockData[offsetZ] += sign * (readBit() << successive);\n } else {\n component.blockData[offsetZ] = successiveACNextValue << successive;\n successiveACState = 0;\n }\n break;\n case 4: // eob\n if (component.blockData[offsetZ]) {\n component.blockData[offsetZ] += sign * (readBit() << successive);\n }\n break;\n }\n k++;\n }\n if (successiveACState === 4) {\n eobrun--;\n if (eobrun === 0) {\n successiveACState = 0;\n }\n }\n }\n\n let blockRow = 0;\n function decodeMcu(component, decode, mcu, row, col) {\n const mcuRow = (mcu / mcusPerLine) | 0;\n const mcuCol = mcu % mcusPerLine;\n blockRow = mcuRow * component.v + row;\n const blockCol = mcuCol * component.h + col;\n const blockOffset = getBlockBufferOffset(component, blockRow, blockCol);\n decode(component, blockOffset);\n }\n\n function decodeBlock(component, decode, mcu) {\n blockRow = (mcu / component.blocksPerLine) | 0;\n const blockCol = mcu % component.blocksPerLine;\n const blockOffset = getBlockBufferOffset(component, blockRow, blockCol);\n decode(component, blockOffset);\n }\n\n const componentsLength = components.length;\n let component, i, j, k, n;\n let decodeFn;\n if (progressive) {\n if (spectralStart === 0) {\n decodeFn = successivePrev === 0 ? decodeDCFirst : decodeDCSuccessive;\n } else {\n decodeFn = successivePrev === 0 ? decodeACFirst : decodeACSuccessive;\n }\n } else {\n decodeFn = decodeBaseline;\n }\n\n let mcu = 0,\n fileMarker;\n const mcuExpected =\n componentsLength === 1\n ? components[0].blocksPerLine * components[0].blocksPerColumn\n : mcusPerLine * frame.mcusPerColumn;\n\n let h, v;\n while (mcu <= mcuExpected) {\n // reset interval stuff\n const mcuToRead = resetInterval\n ? Math.min(mcuExpected - mcu, resetInterval)\n : mcuExpected;\n\n // The `mcuToRead === 0` case should only occur when all of the expected\n // MCU data has been already parsed, i.e. when `mcu === mcuExpected`, but\n // some corrupt JPEG images contain more data than intended and we thus\n // want to skip over any extra RSTx markers below (fixes issue11794.pdf).\n if (mcuToRead > 0) {\n for (i = 0; i < componentsLength; i++) {\n components[i].pred = 0;\n }\n eobrun = 0;\n\n if (componentsLength === 1) {\n component = components[0];\n for (n = 0; n < mcuToRead; n++) {\n decodeBlock(component, decodeFn, mcu);\n mcu++;\n }\n } else {\n for (n = 0; n < mcuToRead; n++) {\n for (i = 0; i < componentsLength; i++) {\n component = components[i];\n h = component.h;\n v = component.v;\n for (j = 0; j < v; j++) {\n for (k = 0; k < h; k++) {\n decodeMcu(component, decodeFn, mcu, j, k);\n }\n }\n }\n mcu++;\n }\n }\n }\n\n // find marker\n bitsCount = 0;\n fileMarker = findNextFileMarker(data, offset);\n if (!fileMarker) {\n break; // Reached the end of the image data without finding any marker.\n }\n if (fileMarker.invalid) {\n // Some bad images seem to pad Scan blocks with e.g. zero bytes, skip\n // past those to attempt to find a valid marker (fixes issue4090.pdf).\n const partialMsg = mcuToRead > 0 ? \"unexpected\" : \"excessive\";\n warn(\n `decodeScan - ${partialMsg} MCU data, current marker is: ${fileMarker.invalid}`\n );\n offset = fileMarker.offset;\n }\n if (fileMarker.marker >= 0xffd0 && fileMarker.marker <= 0xffd7) {\n // RSTx\n offset += 2;\n } else {\n break;\n }\n }\n\n return offset - startOffset;\n}\n\n// A port of poppler's IDCT method which in turn is taken from:\n// Christoph Loeffler, Adriaan Ligtenberg, George S. Moschytz,\n// 'Practical Fast 1-D DCT Algorithms with 11 Multiplications',\n// IEEE Intl. Conf. on Acoustics, Speech & Signal Processing, 1989,\n// 988-991.\nfunction quantizeAndInverse(component, blockBufferOffset, p) {\n const qt = component.quantizationTable,\n blockData = component.blockData;\n let v0, v1, v2, v3, v4, v5, v6, v7;\n let p0, p1, p2, p3, p4, p5, p6, p7;\n let t;\n\n if (!qt) {\n throw new JpegError(\"missing required Quantization Table.\");\n }\n\n // inverse DCT on rows\n for (let row = 0; row < 64; row += 8) {\n // gather block data\n p0 = blockData[blockBufferOffset + row];\n p1 = blockData[blockBufferOffset + row + 1];\n p2 = blockData[blockBufferOffset + row + 2];\n p3 = blockData[blockBufferOffset + row + 3];\n p4 = blockData[blockBufferOffset + row + 4];\n p5 = blockData[blockBufferOffset + row + 5];\n p6 = blockData[blockBufferOffset + row + 6];\n p7 = blockData[blockBufferOffset + row + 7];\n\n // dequant p0\n p0 *= qt[row];\n\n // check for all-zero AC coefficients\n if ((p1 | p2 | p3 | p4 | p5 | p6 | p7) === 0) {\n t = (dctSqrt2 * p0 + 512) >> 10;\n p[row] = t;\n p[row + 1] = t;\n p[row + 2] = t;\n p[row + 3] = t;\n p[row + 4] = t;\n p[row + 5] = t;\n p[row + 6] = t;\n p[row + 7] = t;\n continue;\n }\n // dequant p1 ... p7\n p1 *= qt[row + 1];\n p2 *= qt[row + 2];\n p3 *= qt[row + 3];\n p4 *= qt[row + 4];\n p5 *= qt[row + 5];\n p6 *= qt[row + 6];\n p7 *= qt[row + 7];\n\n // stage 4\n v0 = (dctSqrt2 * p0 + 128) >> 8;\n v1 = (dctSqrt2 * p4 + 128) >> 8;\n v2 = p2;\n v3 = p6;\n v4 = (dctSqrt1d2 * (p1 - p7) + 128) >> 8;\n v7 = (dctSqrt1d2 * (p1 + p7) + 128) >> 8;\n v5 = p3 << 4;\n v6 = p5 << 4;\n\n // stage 3\n v0 = (v0 + v1 + 1) >> 1;\n v1 = v0 - v1;\n t = (v2 * dctSin6 + v3 * dctCos6 + 128) >> 8;\n v2 = (v2 * dctCos6 - v3 * dctSin6 + 128) >> 8;\n v3 = t;\n v4 = (v4 + v6 + 1) >> 1;\n v6 = v4 - v6;\n v7 = (v7 + v5 + 1) >> 1;\n v5 = v7 - v5;\n\n // stage 2\n v0 = (v0 + v3 + 1) >> 1;\n v3 = v0 - v3;\n v1 = (v1 + v2 + 1) >> 1;\n v2 = v1 - v2;\n t = (v4 * dctSin3 + v7 * dctCos3 + 2048) >> 12;\n v4 = (v4 * dctCos3 - v7 * dctSin3 + 2048) >> 12;\n v7 = t;\n t = (v5 * dctSin1 + v6 * dctCos1 + 2048) >> 12;\n v5 = (v5 * dctCos1 - v6 * dctSin1 + 2048) >> 12;\n v6 = t;\n\n // stage 1\n p[row] = v0 + v7;\n p[row + 7] = v0 - v7;\n p[row + 1] = v1 + v6;\n p[row + 6] = v1 - v6;\n p[row + 2] = v2 + v5;\n p[row + 5] = v2 - v5;\n p[row + 3] = v3 + v4;\n p[row + 4] = v3 - v4;\n }\n\n // inverse DCT on columns\n for (let col = 0; col < 8; ++col) {\n p0 = p[col];\n p1 = p[col + 8];\n p2 = p[col + 16];\n p3 = p[col + 24];\n p4 = p[col + 32];\n p5 = p[col + 40];\n p6 = p[col + 48];\n p7 = p[col + 56];\n\n // check for all-zero AC coefficients\n if ((p1 | p2 | p3 | p4 | p5 | p6 | p7) === 0) {\n t = (dctSqrt2 * p0 + 8192) >> 14;\n // Convert to 8-bit.\n if (t < -2040) {\n t = 0;\n } else if (t >= 2024) {\n t = 255;\n } else {\n t = (t + 2056) >> 4;\n }\n blockData[blockBufferOffset + col] = t;\n blockData[blockBufferOffset + col + 8] = t;\n blockData[blockBufferOffset + col + 16] = t;\n blockData[blockBufferOffset + col + 24] = t;\n blockData[blockBufferOffset + col + 32] = t;\n blockData[blockBufferOffset + col + 40] = t;\n blockData[blockBufferOffset + col + 48] = t;\n blockData[blockBufferOffset + col + 56] = t;\n continue;\n }\n\n // stage 4\n v0 = (dctSqrt2 * p0 + 2048) >> 12;\n v1 = (dctSqrt2 * p4 + 2048) >> 12;\n v2 = p2;\n v3 = p6;\n v4 = (dctSqrt1d2 * (p1 - p7) + 2048) >> 12;\n v7 = (dctSqrt1d2 * (p1 + p7) + 2048) >> 12;\n v5 = p3;\n v6 = p5;\n\n // stage 3\n // Shift v0 by 128.5 << 5 here, so we don't need to shift p0...p7 when\n // converting to UInt8 range later.\n v0 = ((v0 + v1 + 1) >> 1) + 4112;\n v1 = v0 - v1;\n t = (v2 * dctSin6 + v3 * dctCos6 + 2048) >> 12;\n v2 = (v2 * dctCos6 - v3 * dctSin6 + 2048) >> 12;\n v3 = t;\n v4 = (v4 + v6 + 1) >> 1;\n v6 = v4 - v6;\n v7 = (v7 + v5 + 1) >> 1;\n v5 = v7 - v5;\n\n // stage 2\n v0 = (v0 + v3 + 1) >> 1;\n v3 = v0 - v3;\n v1 = (v1 + v2 + 1) >> 1;\n v2 = v1 - v2;\n t = (v4 * dctSin3 + v7 * dctCos3 + 2048) >> 12;\n v4 = (v4 * dctCos3 - v7 * dctSin3 + 2048) >> 12;\n v7 = t;\n t = (v5 * dctSin1 + v6 * dctCos1 + 2048) >> 12;\n v5 = (v5 * dctCos1 - v6 * dctSin1 + 2048) >> 12;\n v6 = t;\n\n // stage 1\n p0 = v0 + v7;\n p7 = v0 - v7;\n p1 = v1 + v6;\n p6 = v1 - v6;\n p2 = v2 + v5;\n p5 = v2 - v5;\n p3 = v3 + v4;\n p4 = v3 - v4;\n\n // Convert to 8-bit integers.\n if (p0 < 16) {\n p0 = 0;\n } else if (p0 >= 4080) {\n p0 = 255;\n } else {\n p0 >>= 4;\n }\n if (p1 < 16) {\n p1 = 0;\n } else if (p1 >= 4080) {\n p1 = 255;\n } else {\n p1 >>= 4;\n }\n if (p2 < 16) {\n p2 = 0;\n } else if (p2 >= 4080) {\n p2 = 255;\n } else {\n p2 >>= 4;\n }\n if (p3 < 16) {\n p3 = 0;\n } else if (p3 >= 4080) {\n p3 = 255;\n } else {\n p3 >>= 4;\n }\n if (p4 < 16) {\n p4 = 0;\n } else if (p4 >= 4080) {\n p4 = 255;\n } else {\n p4 >>= 4;\n }\n if (p5 < 16) {\n p5 = 0;\n } else if (p5 >= 4080) {\n p5 = 255;\n } else {\n p5 >>= 4;\n }\n if (p6 < 16) {\n p6 = 0;\n } else if (p6 >= 4080) {\n p6 = 255;\n } else {\n p6 >>= 4;\n }\n if (p7 < 16) {\n p7 = 0;\n } else if (p7 >= 4080) {\n p7 = 255;\n } else {\n p7 >>= 4;\n }\n\n // store block data\n blockData[blockBufferOffset + col] = p0;\n blockData[blockBufferOffset + col + 8] = p1;\n blockData[blockBufferOffset + col + 16] = p2;\n blockData[blockBufferOffset + col + 24] = p3;\n blockData[blockBufferOffset + col + 32] = p4;\n blockData[blockBufferOffset + col + 40] = p5;\n blockData[blockBufferOffset + col + 48] = p6;\n blockData[blockBufferOffset + col + 56] = p7;\n }\n}\n\nfunction buildComponentData(frame, component) {\n const blocksPerLine = component.blocksPerLine;\n const blocksPerColumn = component.blocksPerColumn;\n const computationBuffer = new Int16Array(64);\n\n for (let blockRow = 0; blockRow < blocksPerColumn; blockRow++) {\n for (let blockCol = 0; blockCol < blocksPerLine; blockCol++) {\n const offset = getBlockBufferOffset(component, blockRow, blockCol);\n quantizeAndInverse(component, offset, computationBuffer);\n }\n }\n return component.blockData;\n}\n\nfunction findNextFileMarker(data, currentPos, startPos = currentPos) {\n const maxPos = data.length - 1;\n let newPos = startPos < currentPos ? startPos : currentPos;\n\n if (currentPos >= maxPos) {\n return null; // Don't attempt to read non-existent data and just return.\n }\n const currentMarker = readUint16(data, currentPos);\n if (currentMarker >= 0xffc0 && currentMarker <= 0xfffe) {\n return {\n invalid: null,\n marker: currentMarker,\n offset: currentPos,\n };\n }\n let newMarker = readUint16(data, newPos);\n while (!(newMarker >= 0xffc0 && newMarker <= 0xfffe)) {\n if (++newPos >= maxPos) {\n return null; // Don't attempt to read non-existent data and just return.\n }\n newMarker = readUint16(data, newPos);\n }\n return {\n invalid: currentMarker.toString(16),\n marker: newMarker,\n offset: newPos,\n };\n}\n\nclass JpegImage {\n constructor({ decodeTransform = null, colorTransform = -1 } = {}) {\n this._decodeTransform = decodeTransform;\n this._colorTransform = colorTransform;\n }\n\n parse(data, { dnlScanLines = null } = {}) {\n function readDataBlock() {\n const length = readUint16(data, offset);\n offset += 2;\n let endOffset = offset + length - 2;\n\n const fileMarker = findNextFileMarker(data, endOffset, offset);\n if (fileMarker?.invalid) {\n warn(\n \"readDataBlock - incorrect length, current marker is: \" +\n fileMarker.invalid\n );\n endOffset = fileMarker.offset;\n }\n\n const array = data.subarray(offset, endOffset);\n offset += array.length;\n return array;\n }\n\n function prepareComponents(frame) {\n const mcusPerLine = Math.ceil(frame.samplesPerLine / 8 / frame.maxH);\n const mcusPerColumn = Math.ceil(frame.scanLines / 8 / frame.maxV);\n for (const component of frame.components) {\n const blocksPerLine = Math.ceil(\n (Math.ceil(frame.samplesPerLine / 8) * component.h) / frame.maxH\n );\n const blocksPerColumn = Math.ceil(\n (Math.ceil(frame.scanLines / 8) * component.v) / frame.maxV\n );\n const blocksPerLineForMcu = mcusPerLine * component.h;\n const blocksPerColumnForMcu = mcusPerColumn * component.v;\n\n const blocksBufferSize =\n 64 * blocksPerColumnForMcu * (blocksPerLineForMcu + 1);\n component.blockData = new Int16Array(blocksBufferSize);\n component.blocksPerLine = blocksPerLine;\n component.blocksPerColumn = blocksPerColumn;\n }\n frame.mcusPerLine = mcusPerLine;\n frame.mcusPerColumn = mcusPerColumn;\n }\n\n let offset = 0;\n let jfif = null;\n let adobe = null;\n let frame, resetInterval;\n let numSOSMarkers = 0;\n const quantizationTables = [];\n const huffmanTablesAC = [],\n huffmanTablesDC = [];\n\n let fileMarker = readUint16(data, offset);\n offset += 2;\n if (fileMarker !== /* SOI (Start of Image) = */ 0xffd8) {\n throw new JpegError(\"SOI not found\");\n }\n fileMarker = readUint16(data, offset);\n offset += 2;\n\n markerLoop: while (fileMarker !== /* EOI (End of Image) = */ 0xffd9) {\n let i, j, l;\n switch (fileMarker) {\n case 0xffe0: // APP0 (Application Specific)\n case 0xffe1: // APP1\n case 0xffe2: // APP2\n case 0xffe3: // APP3\n case 0xffe4: // APP4\n case 0xffe5: // APP5\n case 0xffe6: // APP6\n case 0xffe7: // APP7\n case 0xffe8: // APP8\n case 0xffe9: // APP9\n case 0xffea: // APP10\n case 0xffeb: // APP11\n case 0xffec: // APP12\n case 0xffed: // APP13\n case 0xffee: // APP14\n case 0xffef: // APP15\n case 0xfffe: // COM (Comment)\n const appData = readDataBlock();\n\n if (fileMarker === 0xffe0) {\n // 'JFIF\\x00'\n if (\n appData[0] === 0x4a &&\n appData[1] === 0x46 &&\n appData[2] === 0x49 &&\n appData[3] === 0x46 &&\n appData[4] === 0\n ) {\n jfif = {\n version: { major: appData[5], minor: appData[6] },\n densityUnits: appData[7],\n xDensity: (appData[8] << 8) | appData[9],\n yDensity: (appData[10] << 8) | appData[11],\n thumbWidth: appData[12],\n thumbHeight: appData[13],\n thumbData: appData.subarray(\n 14,\n 14 + 3 * appData[12] * appData[13]\n ),\n };\n }\n }\n // TODO APP1 - Exif\n if (fileMarker === 0xffee) {\n // 'Adobe'\n if (\n appData[0] === 0x41 &&\n appData[1] === 0x64 &&\n appData[2] === 0x6f &&\n appData[3] === 0x62 &&\n appData[4] === 0x65\n ) {\n adobe = {\n version: (appData[5] << 8) | appData[6],\n flags0: (appData[7] << 8) | appData[8],\n flags1: (appData[9] << 8) | appData[10],\n transformCode: appData[11],\n };\n }\n }\n break;\n\n case 0xffdb: // DQT (Define Quantization Tables)\n const quantizationTablesLength = readUint16(data, offset);\n offset += 2;\n const quantizationTablesEnd = quantizationTablesLength + offset - 2;\n let z;\n while (offset < quantizationTablesEnd) {\n const quantizationTableSpec = data[offset++];\n const tableData = new Uint16Array(64);\n if (quantizationTableSpec >> 4 === 0) {\n // 8 bit values\n for (j = 0; j < 64; j++) {\n z = dctZigZag[j];\n tableData[z] = data[offset++];\n }\n } else if (quantizationTableSpec >> 4 === 1) {\n // 16 bit values\n for (j = 0; j < 64; j++) {\n z = dctZigZag[j];\n tableData[z] = readUint16(data, offset);\n offset += 2;\n }\n } else {\n throw new JpegError(\"DQT - invalid table spec\");\n }\n quantizationTables[quantizationTableSpec & 15] = tableData;\n }\n break;\n\n case 0xffc0: // SOF0 (Start of Frame, Baseline DCT)\n case 0xffc1: // SOF1 (Start of Frame, Extended DCT)\n case 0xffc2: // SOF2 (Start of Frame, Progressive DCT)\n if (frame) {\n throw new JpegError(\"Only single frame JPEGs supported\");\n }\n offset += 2; // Skip marker length.\n\n frame = {};\n frame.extended = fileMarker === 0xffc1;\n frame.progressive = fileMarker === 0xffc2;\n frame.precision = data[offset++];\n const sofScanLines = readUint16(data, offset);\n offset += 2;\n frame.scanLines = dnlScanLines || sofScanLines;\n frame.samplesPerLine = readUint16(data, offset);\n offset += 2;\n frame.components = [];\n frame.componentIds = {};\n const componentsCount = data[offset++];\n let maxH = 0,\n maxV = 0;\n for (i = 0; i < componentsCount; i++) {\n const componentId = data[offset];\n const h = data[offset + 1] >> 4;\n const v = data[offset + 1] & 15;\n if (maxH < h) {\n maxH = h;\n }\n if (maxV < v) {\n maxV = v;\n }\n const qId = data[offset + 2];\n l = frame.components.push({\n h,\n v,\n quantizationId: qId,\n quantizationTable: null, // See comment below.\n });\n frame.componentIds[componentId] = l - 1;\n offset += 3;\n }\n frame.maxH = maxH;\n frame.maxV = maxV;\n prepareComponents(frame);\n break;\n\n case 0xffc4: // DHT (Define Huffman Tables)\n const huffmanLength = readUint16(data, offset);\n offset += 2;\n for (i = 2; i < huffmanLength; ) {\n const huffmanTableSpec = data[offset++];\n const codeLengths = new Uint8Array(16);\n let codeLengthSum = 0;\n for (j = 0; j < 16; j++, offset++) {\n codeLengthSum += codeLengths[j] = data[offset];\n }\n const huffmanValues = new Uint8Array(codeLengthSum);\n for (j = 0; j < codeLengthSum; j++, offset++) {\n huffmanValues[j] = data[offset];\n }\n i += 17 + codeLengthSum;\n\n (huffmanTableSpec >> 4 === 0 ? huffmanTablesDC : huffmanTablesAC)[\n huffmanTableSpec & 15\n ] = buildHuffmanTable(codeLengths, huffmanValues);\n }\n break;\n\n case 0xffdd: // DRI (Define Restart Interval)\n offset += 2; // Skip marker length.\n\n resetInterval = readUint16(data, offset);\n offset += 2;\n break;\n\n case 0xffda: // SOS (Start of Scan)\n // A DNL marker (0xFFDC), if it exists, is only allowed at the end\n // of the first scan segment and may only occur once in an image.\n // Furthermore, to prevent an infinite loop, do *not* attempt to\n // parse DNL markers during re-parsing of the JPEG scan data.\n const parseDNLMarker = ++numSOSMarkers === 1 && !dnlScanLines;\n\n offset += 2; // Skip marker length.\n\n const selectorsCount = data[offset++],\n components = [];\n for (i = 0; i < selectorsCount; i++) {\n const index = data[offset++];\n const componentIndex = frame.componentIds[index];\n const component = frame.components[componentIndex];\n component.index = index;\n const tableSpec = data[offset++];\n component.huffmanTableDC = huffmanTablesDC[tableSpec >> 4];\n component.huffmanTableAC = huffmanTablesAC[tableSpec & 15];\n components.push(component);\n }\n const spectralStart = data[offset++],\n spectralEnd = data[offset++],\n successiveApproximation = data[offset++];\n try {\n const processed = decodeScan(\n data,\n offset,\n frame,\n components,\n resetInterval,\n spectralStart,\n spectralEnd,\n successiveApproximation >> 4,\n successiveApproximation & 15,\n parseDNLMarker\n );\n offset += processed;\n } catch (ex) {\n if (ex instanceof DNLMarkerError) {\n warn(`${ex.message} -- attempting to re-parse the JPEG image.`);\n return this.parse(data, { dnlScanLines: ex.scanLines });\n } else if (ex instanceof EOIMarkerError) {\n warn(`${ex.message} -- ignoring the rest of the image data.`);\n break markerLoop;\n }\n throw ex;\n }\n break;\n\n case 0xffdc: // DNL (Define Number of Lines)\n // Ignore the marker, since it's being handled in `decodeScan`.\n offset += 4;\n break;\n\n case 0xffff: // Fill bytes\n if (data[offset] !== 0xff) {\n // Avoid skipping a valid marker.\n offset--;\n }\n break;\n\n default:\n // Could be incorrect encoding -- the last 0xFF byte of the previous\n // block could have been eaten by the encoder, hence we fallback to\n // `startPos = offset - 3` when looking for the next valid marker.\n const nextFileMarker = findNextFileMarker(\n data,\n /* currentPos = */ offset - 2,\n /* startPos = */ offset - 3\n );\n if (nextFileMarker?.invalid) {\n warn(\n \"JpegImage.parse - unexpected data, current marker is: \" +\n nextFileMarker.invalid\n );\n offset = nextFileMarker.offset;\n break;\n }\n if (!nextFileMarker || offset >= data.length - 1) {\n warn(\n \"JpegImage.parse - reached the end of the image data \" +\n \"without finding an EOI marker (0xFFD9).\"\n );\n break markerLoop;\n }\n throw new JpegError(\n \"JpegImage.parse - unknown marker: \" + fileMarker.toString(16)\n );\n }\n fileMarker = readUint16(data, offset);\n offset += 2;\n }\n\n this.width = frame.samplesPerLine;\n this.height = frame.scanLines;\n this.jfif = jfif;\n this.adobe = adobe;\n this.components = [];\n for (const component of frame.components) {\n // Prevent errors when DQT markers are placed after SOF{n} markers,\n // by assigning the `quantizationTable` entry after the entire image\n // has been parsed (fixes issue7406.pdf).\n const quantizationTable = quantizationTables[component.quantizationId];\n if (quantizationTable) {\n component.quantizationTable = quantizationTable;\n }\n\n this.components.push({\n index: component.index,\n output: buildComponentData(frame, component),\n scaleX: component.h / frame.maxH,\n scaleY: component.v / frame.maxV,\n blocksPerLine: component.blocksPerLine,\n blocksPerColumn: component.blocksPerColumn,\n });\n }\n this.numComponents = this.components.length;\n return undefined;\n }\n\n _getLinearizedBlockData(width, height, isSourcePDF = false) {\n const scaleX = this.width / width,\n scaleY = this.height / height;\n\n let component, componentScaleX, componentScaleY, blocksPerScanline;\n let x, y, i, j, k;\n let index;\n let offset = 0;\n let output;\n const numComponents = this.components.length;\n const dataLength = width * height * numComponents;\n const data = new Uint8ClampedArray(dataLength);\n const xScaleBlockOffset = new Uint32Array(width);\n const mask3LSB = 0xfffffff8; // used to clear the 3 LSBs\n let lastComponentScaleX;\n\n for (i = 0; i < numComponents; i++) {\n component = this.components[i];\n componentScaleX = component.scaleX * scaleX;\n componentScaleY = component.scaleY * scaleY;\n offset = i;\n output = component.output;\n blocksPerScanline = (component.blocksPerLine + 1) << 3;\n // Precalculate the `xScaleBlockOffset`. Since it doesn't depend on the\n // component data, that's only necessary when `componentScaleX` changes.\n if (componentScaleX !== lastComponentScaleX) {\n for (x = 0; x < width; x++) {\n j = 0 | (x * componentScaleX);\n xScaleBlockOffset[x] = ((j & mask3LSB) << 3) | (j & 7);\n }\n lastComponentScaleX = componentScaleX;\n }\n // linearize the blocks of the component\n for (y = 0; y < height; y++) {\n j = 0 | (y * componentScaleY);\n index = (blocksPerScanline * (j & mask3LSB)) | ((j & 7) << 3);\n for (x = 0; x < width; x++) {\n data[offset] = output[index + xScaleBlockOffset[x]];\n offset += numComponents;\n }\n }\n }\n\n // decodeTransform contains pairs of multiplier (-256..256) and additive\n let transform = this._decodeTransform;\n\n // In PDF files, JPEG images with CMYK colour spaces are usually inverted\n // (this can be observed by extracting the raw image data).\n // Since the conversion algorithms (see below) were written primarily for\n // the PDF use-cases, attempting to use `JpegImage` to parse standalone\n // JPEG (CMYK) images may thus result in inverted images (see issue 9513).\n //\n // Unfortunately it's not (always) possible to tell, from the image data\n // alone, if it needs to be inverted. Thus in an attempt to provide better\n // out-of-box behaviour when `JpegImage` is used standalone, default to\n // inverting JPEG (CMYK) images if and only if the image data does *not*\n // come from a PDF file and no `decodeTransform` was passed by the user.\n if (!isSourcePDF && numComponents === 4 && !transform) {\n transform = new Int32Array([-256, 255, -256, 255, -256, 255, -256, 255]);\n }\n\n if (transform) {\n for (i = 0; i < dataLength; ) {\n for (j = 0, k = 0; j < numComponents; j++, i++, k += 2) {\n data[i] = ((data[i] * transform[k]) >> 8) + transform[k + 1];\n }\n }\n }\n return data;\n }\n\n get _isColorConversionNeeded() {\n if (this.adobe) {\n // The adobe transform marker overrides any previous setting.\n return !!this.adobe.transformCode;\n }\n if (this.numComponents === 3) {\n if (this._colorTransform === 0) {\n // If the Adobe transform marker is not present and the image\n // dictionary has a 'ColorTransform' entry, explicitly set to `0`,\n // then the colours should *not* be transformed.\n return false;\n } else if (\n this.components[0].index === /* \"R\" = */ 0x52 &&\n this.components[1].index === /* \"G\" = */ 0x47 &&\n this.components[2].index === /* \"B\" = */ 0x42\n ) {\n // If the three components are indexed as RGB in ASCII\n // then the colours should *not* be transformed.\n return false;\n }\n return true;\n }\n // `this.numComponents !== 3`\n if (this._colorTransform === 1) {\n // If the Adobe transform marker is not present and the image\n // dictionary has a 'ColorTransform' entry, explicitly set to `1`,\n // then the colours should be transformed.\n return true;\n }\n return false;\n }\n\n _convertYccToRgb(data) {\n let Y, Cb, Cr;\n for (let i = 0, length = data.length; i < length; i += 3) {\n Y = data[i];\n Cb = data[i + 1];\n Cr = data[i + 2];\n data[i] = Y - 179.456 + 1.402 * Cr;\n data[i + 1] = Y + 135.459 - 0.344 * Cb - 0.714 * Cr;\n data[i + 2] = Y - 226.816 + 1.772 * Cb;\n }\n return data;\n }\n\n _convertYccToRgba(data, out) {\n for (let i = 0, j = 0, length = data.length; i < length; i += 3, j += 4) {\n const Y = data[i];\n const Cb = data[i + 1];\n const Cr = data[i + 2];\n out[j] = Y - 179.456 + 1.402 * Cr;\n out[j + 1] = Y + 135.459 - 0.344 * Cb - 0.714 * Cr;\n out[j + 2] = Y - 226.816 + 1.772 * Cb;\n out[j + 3] = 255;\n }\n return out;\n }\n\n _convertYcckToRgb(data) {\n let Y, Cb, Cr, k;\n let offset = 0;\n for (let i = 0, length = data.length; i < length; i += 4) {\n Y = data[i];\n Cb = data[i + 1];\n Cr = data[i + 2];\n k = data[i + 3];\n\n data[offset++] =\n -122.67195406894 +\n Cb *\n (-6.60635669420364e-5 * Cb +\n 0.000437130475926232 * Cr -\n 5.4080610064599e-5 * Y +\n 0.00048449797120281 * k -\n 0.154362151871126) +\n Cr *\n (-0.000957964378445773 * Cr +\n 0.000817076911346625 * Y -\n 0.00477271405408747 * k +\n 1.53380253221734) +\n Y *\n (0.000961250184130688 * Y -\n 0.00266257332283933 * k +\n 0.48357088451265) +\n k * (-0.000336197177618394 * k + 0.484791561490776);\n\n data[offset++] =\n 107.268039397724 +\n Cb *\n (2.19927104525741e-5 * Cb -\n 0.000640992018297945 * Cr +\n 0.000659397001245577 * Y +\n 0.000426105652938837 * k -\n 0.176491792462875) +\n Cr *\n (-0.000778269941513683 * Cr +\n 0.00130872261408275 * Y +\n 0.000770482631801132 * k -\n 0.151051492775562) +\n Y *\n (0.00126935368114843 * Y -\n 0.00265090189010898 * k +\n 0.25802910206845) +\n k * (-0.000318913117588328 * k - 0.213742400323665);\n\n data[offset++] =\n -20.810012546947 +\n Cb *\n (-0.000570115196973677 * Cb -\n 2.63409051004589e-5 * Cr +\n 0.0020741088115012 * Y -\n 0.00288260236853442 * k +\n 0.814272968359295) +\n Cr *\n (-1.53496057440975e-5 * Cr -\n 0.000132689043961446 * Y +\n 0.000560833691242812 * k -\n 0.195152027534049) +\n Y *\n (0.00174418132927582 * Y -\n 0.00255243321439347 * k +\n 0.116935020465145) +\n k * (-0.000343531996510555 * k + 0.24165260232407);\n }\n // Ensure that only the converted RGB data is returned.\n return data.subarray(0, offset);\n }\n\n _convertYcckToRgba(data) {\n for (let i = 0, length = data.length; i < length; i += 4) {\n const Y = data[i];\n const Cb = data[i + 1];\n const Cr = data[i + 2];\n const k = data[i + 3];\n\n data[i] =\n -122.67195406894 +\n Cb *\n (-6.60635669420364e-5 * Cb +\n 0.000437130475926232 * Cr -\n 5.4080610064599e-5 * Y +\n 0.00048449797120281 * k -\n 0.154362151871126) +\n Cr *\n (-0.000957964378445773 * Cr +\n 0.000817076911346625 * Y -\n 0.00477271405408747 * k +\n 1.53380253221734) +\n Y *\n (0.000961250184130688 * Y -\n 0.00266257332283933 * k +\n 0.48357088451265) +\n k * (-0.000336197177618394 * k + 0.484791561490776);\n\n data[i + 1] =\n 107.268039397724 +\n Cb *\n (2.19927104525741e-5 * Cb -\n 0.000640992018297945 * Cr +\n 0.000659397001245577 * Y +\n 0.000426105652938837 * k -\n 0.176491792462875) +\n Cr *\n (-0.000778269941513683 * Cr +\n 0.00130872261408275 * Y +\n 0.000770482631801132 * k -\n 0.151051492775562) +\n Y *\n (0.00126935368114843 * Y -\n 0.00265090189010898 * k +\n 0.25802910206845) +\n k * (-0.000318913117588328 * k - 0.213742400323665);\n\n data[i + 2] =\n -20.810012546947 +\n Cb *\n (-0.000570115196973677 * Cb -\n 2.63409051004589e-5 * Cr +\n 0.0020741088115012 * Y -\n 0.00288260236853442 * k +\n 0.814272968359295) +\n Cr *\n (-1.53496057440975e-5 * Cr -\n 0.000132689043961446 * Y +\n 0.000560833691242812 * k -\n 0.195152027534049) +\n Y *\n (0.00174418132927582 * Y -\n 0.00255243321439347 * k +\n 0.116935020465145) +\n k * (-0.000343531996510555 * k + 0.24165260232407);\n data[i + 3] = 255;\n }\n return data;\n }\n\n _convertYcckToCmyk(data) {\n let Y, Cb, Cr;\n for (let i = 0, length = data.length; i < length; i += 4) {\n Y = data[i];\n Cb = data[i + 1];\n Cr = data[i + 2];\n data[i] = 434.456 - Y - 1.402 * Cr;\n data[i + 1] = 119.541 - Y + 0.344 * Cb + 0.714 * Cr;\n data[i + 2] = 481.816 - Y - 1.772 * Cb;\n // K in data[i + 3] is unchanged\n }\n return data;\n }\n\n _convertCmykToRgb(data) {\n let c, m, y, k;\n let offset = 0;\n for (let i = 0, length = data.length; i < length; i += 4) {\n c = data[i];\n m = data[i + 1];\n y = data[i + 2];\n k = data[i + 3];\n\n data[offset++] =\n 255 +\n c *\n (-0.00006747147073602441 * c +\n 0.0008379262121013727 * m +\n 0.0002894718188643294 * y +\n 0.003264231057537806 * k -\n 1.1185611867203937) +\n m *\n (0.000026374107616089405 * m -\n 0.00008626949158638572 * y -\n 0.0002748769067499491 * k -\n 0.02155688794978967) +\n y *\n (-0.00003878099212869363 * y -\n 0.0003267808279485286 * k +\n 0.0686742238595345) -\n k * (0.0003361971776183937 * k + 0.7430659151342254);\n\n data[offset++] =\n 255 +\n c *\n (0.00013596372813588848 * c +\n 0.000924537132573585 * m +\n 0.00010567359618683593 * y +\n 0.0004791864687436512 * k -\n 0.3109689587515875) +\n m *\n (-0.00023545346108370344 * m +\n 0.0002702845253534714 * y +\n 0.0020200308977307156 * k -\n 0.7488052167015494) +\n y *\n (0.00006834815998235662 * y +\n 0.00015168452363460973 * k -\n 0.09751927774728933) -\n k * (0.0003189131175883281 * k + 0.7364883807733168);\n\n data[offset++] =\n 255 +\n c *\n (0.000013598650411385307 * c +\n 0.00012423956175490851 * m +\n 0.0004751985097583589 * y -\n 0.0000036729317476630422 * k -\n 0.05562186980264034) +\n m *\n (0.00016141380598724676 * m +\n 0.0009692239130725186 * y +\n 0.0007782692450036253 * k -\n 0.44015232367526463) +\n y *\n (5.068882914068769e-7 * y +\n 0.0017778369011375071 * k -\n 0.7591454649749609) -\n k * (0.0003435319965105553 * k + 0.7063770186160144);\n }\n // Ensure that only the converted RGB data is returned.\n return data.subarray(0, offset);\n }\n\n _convertCmykToRgba(data) {\n for (let i = 0, length = data.length; i < length; i += 4) {\n const c = data[i];\n const m = data[i + 1];\n const y = data[i + 2];\n const k = data[i + 3];\n\n data[i] =\n 255 +\n c *\n (-0.00006747147073602441 * c +\n 0.0008379262121013727 * m +\n 0.0002894718188643294 * y +\n 0.003264231057537806 * k -\n 1.1185611867203937) +\n m *\n (0.000026374107616089405 * m -\n 0.00008626949158638572 * y -\n 0.0002748769067499491 * k -\n 0.02155688794978967) +\n y *\n (-0.00003878099212869363 * y -\n 0.0003267808279485286 * k +\n 0.0686742238595345) -\n k * (0.0003361971776183937 * k + 0.7430659151342254);\n\n data[i + 1] =\n 255 +\n c *\n (0.00013596372813588848 * c +\n 0.000924537132573585 * m +\n 0.00010567359618683593 * y +\n 0.0004791864687436512 * k -\n 0.3109689587515875) +\n m *\n (-0.00023545346108370344 * m +\n 0.0002702845253534714 * y +\n 0.0020200308977307156 * k -\n 0.7488052167015494) +\n y *\n (0.00006834815998235662 * y +\n 0.00015168452363460973 * k -\n 0.09751927774728933) -\n k * (0.0003189131175883281 * k + 0.7364883807733168);\n\n data[i + 2] =\n 255 +\n c *\n (0.000013598650411385307 * c +\n 0.00012423956175490851 * m +\n 0.0004751985097583589 * y -\n 0.0000036729317476630422 * k -\n 0.05562186980264034) +\n m *\n (0.00016141380598724676 * m +\n 0.0009692239130725186 * y +\n 0.0007782692450036253 * k -\n 0.44015232367526463) +\n y *\n (5.068882914068769e-7 * y +\n 0.0017778369011375071 * k -\n 0.7591454649749609) -\n k * (0.0003435319965105553 * k + 0.7063770186160144);\n data[i + 3] = 255;\n }\n return data;\n }\n\n getData({\n width,\n height,\n forceRGBA = false,\n forceRGB = false,\n isSourcePDF = false,\n }) {\n if (typeof PDFJSDev === \"undefined\" || PDFJSDev.test(\"TESTING\")) {\n assert(\n isSourcePDF === true,\n 'JpegImage.getData: Unexpected \"isSourcePDF\" value for PDF files.'\n );\n }\n if (this.numComponents > 4) {\n throw new JpegError(\"Unsupported color mode\");\n }\n // Type of data: Uint8ClampedArray(width * height * numComponents)\n const data = this._getLinearizedBlockData(width, height, isSourcePDF);\n\n if (this.numComponents === 1 && (forceRGBA || forceRGB)) {\n const len = data.length * (forceRGBA ? 4 : 3);\n const rgbaData = new Uint8ClampedArray(len);\n let offset = 0;\n if (forceRGBA) {\n grayToRGBA(data, new Uint32Array(rgbaData.buffer));\n } else {\n for (const grayColor of data) {\n rgbaData[offset++] = grayColor;\n rgbaData[offset++] = grayColor;\n rgbaData[offset++] = grayColor;\n }\n }\n return rgbaData;\n } else if (this.numComponents === 3 && this._isColorConversionNeeded) {\n if (forceRGBA) {\n const rgbaData = new Uint8ClampedArray((data.length / 3) * 4);\n return this._convertYccToRgba(data, rgbaData);\n }\n return this._convertYccToRgb(data);\n } else if (this.numComponents === 4) {\n if (this._isColorConversionNeeded) {\n if (forceRGBA) {\n return this._convertYcckToRgba(data);\n }\n if (forceRGB) {\n return this._convertYcckToRgb(data);\n }\n return this._convertYcckToCmyk(data);\n } else if (forceRGBA) {\n return this._convertCmykToRgba(data);\n } else if (forceRGB) {\n return this._convertCmykToRgb(data);\n }\n }\n return data;\n }\n}\n\nexport { JpegImage };\n","/* Copyright 2022 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { FeatureTest, ImageKind } from \"./util.js\";\n\nfunction convertToRGBA(params) {\n switch (params.kind) {\n case ImageKind.GRAYSCALE_1BPP:\n return convertBlackAndWhiteToRGBA(params);\n case ImageKind.RGB_24BPP:\n return convertRGBToRGBA(params);\n }\n\n return null;\n}\n\nfunction convertBlackAndWhiteToRGBA({\n src,\n srcPos = 0,\n dest,\n width,\n height,\n nonBlackColor = 0xffffffff,\n inverseDecode = false,\n}) {\n const black = FeatureTest.isLittleEndian ? 0xff000000 : 0x000000ff;\n const [zeroMapping, oneMapping] = inverseDecode\n ? [nonBlackColor, black]\n : [black, nonBlackColor];\n const widthInSource = width >> 3;\n const widthRemainder = width & 7;\n const srcLength = src.length;\n dest = new Uint32Array(dest.buffer);\n let destPos = 0;\n\n for (let i = 0; i < height; i++) {\n for (const max = srcPos + widthInSource; srcPos < max; srcPos++) {\n const elem = srcPos < srcLength ? src[srcPos] : 255;\n dest[destPos++] = elem & 0b10000000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1000000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b100000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b10000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1000 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b100 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b10 ? oneMapping : zeroMapping;\n dest[destPos++] = elem & 0b1 ? oneMapping : zeroMapping;\n }\n if (widthRemainder === 0) {\n continue;\n }\n const elem = srcPos < srcLength ? src[srcPos++] : 255;\n for (let j = 0; j < widthRemainder; j++) {\n dest[destPos++] = elem & (1 << (7 - j)) ? oneMapping : zeroMapping;\n }\n }\n return { srcPos, destPos };\n}\n\nfunction convertRGBToRGBA({\n src,\n srcPos = 0,\n dest,\n destPos = 0,\n width,\n height,\n}) {\n let i = 0;\n const len32 = src.length >> 2;\n const src32 = new Uint32Array(src.buffer, srcPos, len32);\n\n if (FeatureTest.isLittleEndian) {\n // It's a way faster to do the shuffle manually instead of working\n // component by component with some Uint8 arrays.\n for (; i < len32 - 2; i += 3, destPos += 4) {\n const s1 = src32[i]; // R2B1G1R1\n const s2 = src32[i + 1]; // G3R3B2G2\n const s3 = src32[i + 2]; // B4G4R4B3\n\n dest[destPos] = s1 | 0xff000000;\n dest[destPos + 1] = (s1 >>> 24) | (s2 << 8) | 0xff000000;\n dest[destPos + 2] = (s2 >>> 16) | (s3 << 16) | 0xff000000;\n dest[destPos + 3] = (s3 >>> 8) | 0xff000000;\n }\n\n for (let j = i * 4, jj = src.length; j < jj; j += 3) {\n dest[destPos++] =\n src[j] | (src[j + 1] << 8) | (src[j + 2] << 16) | 0xff000000;\n }\n } else {\n for (; i < len32 - 2; i += 3, destPos += 4) {\n const s1 = src32[i]; // R1G1B1R2\n const s2 = src32[i + 1]; // G2B2R3G3\n const s3 = src32[i + 2]; // B3R4G4B4\n\n dest[destPos] = s1 | 0xff;\n dest[destPos + 1] = (s1 << 24) | (s2 >>> 8) | 0xff;\n dest[destPos + 2] = (s2 << 16) | (s3 >>> 16) | 0xff;\n dest[destPos + 3] = (s3 << 8) | 0xff;\n }\n\n for (let j = i * 4, jj = src.length; j < jj; j += 3) {\n dest[destPos++] =\n (src[j] << 24) | (src[j + 1] << 16) | (src[j + 2] << 8) | 0xff;\n }\n }\n\n return { srcPos, destPos };\n}\n\nfunction grayToRGBA(src, dest) {\n if (FeatureTest.isLittleEndian) {\n for (let i = 0, ii = src.length; i < ii; i++) {\n dest[i] = (src[i] * 0x10101) | 0xff000000;\n }\n } else {\n for (let i = 0, ii = src.length; i < ii; i++) {\n dest[i] = (src[i] * 0x1010100) | 0x000000ff;\n }\n }\n}\n\nexport { convertBlackAndWhiteToRGBA, convertToRGBA, grayToRGBA };\n","/* Copyright 2012 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { BaseException, info, unreachable, warn } from \"../shared/util.js\";\nimport { log2, readUint16, readUint32 } from \"./core_utils.js\";\nimport { ArithmeticDecoder } from \"./arithmetic_decoder.js\";\n\nclass JpxError extends BaseException {\n constructor(msg) {\n super(`JPX error: ${msg}`, \"JpxError\");\n }\n}\n\n// Table E.1\nconst SubbandsGainLog2 = {\n LL: 0,\n LH: 1,\n HL: 1,\n HH: 2,\n};\n\nclass JpxImage {\n constructor() {\n this.failOnCorruptedImage = false;\n }\n\n parse(data) {\n const head = readUint16(data, 0);\n // No box header, immediate start of codestream (SOC)\n if (head === 0xff4f) {\n this.parseCodestream(data, 0, data.length);\n return;\n }\n\n const length = data.length;\n let position = 0;\n while (position < length) {\n let headerSize = 8;\n let lbox = readUint32(data, position);\n const tbox = readUint32(data, position + 4);\n position += headerSize;\n if (lbox === 1) {\n // XLBox: read UInt64 according to spec.\n // JavaScript's int precision of 53 bit should be sufficient here.\n lbox =\n readUint32(data, position) * 4294967296 +\n readUint32(data, position + 4);\n position += 8;\n headerSize += 8;\n }\n if (lbox === 0) {\n lbox = length - position + headerSize;\n }\n if (lbox < headerSize) {\n throw new JpxError(\"Invalid box field size\");\n }\n const dataLength = lbox - headerSize;\n let jumpDataLength = true;\n switch (tbox) {\n case 0x6a703268: // 'jp2h'\n jumpDataLength = false; // parsing child boxes\n break;\n case 0x636f6c72: // 'colr'\n // Colorspaces are not used, the CS from the PDF is used.\n const method = data[position];\n if (method === 1) {\n // enumerated colorspace\n const colorspace = readUint32(data, position + 3);\n switch (colorspace) {\n case 16: // this indicates a sRGB colorspace\n case 17: // this indicates a grayscale colorspace\n case 18: // this indicates a YUV colorspace\n break;\n default:\n warn(\"Unknown colorspace \" + colorspace);\n break;\n }\n } else if (method === 2) {\n info(\"ICC profile not supported\");\n }\n break;\n case 0x6a703263: // 'jp2c'\n this.parseCodestream(data, position, position + dataLength);\n break;\n case 0x6a502020: // 'jP\\024\\024'\n if (readUint32(data, position) !== 0x0d0a870a) {\n warn(\"Invalid JP2 signature\");\n }\n break;\n // The following header types are valid but currently not used:\n case 0x6a501a1a: // 'jP\\032\\032'\n case 0x66747970: // 'ftyp'\n case 0x72726571: // 'rreq'\n case 0x72657320: // 'res '\n case 0x69686472: // 'ihdr'\n break;\n default:\n const headerType = String.fromCharCode(\n (tbox >> 24) & 0xff,\n (tbox >> 16) & 0xff,\n (tbox >> 8) & 0xff,\n tbox & 0xff\n );\n warn(`Unsupported header type ${tbox} (${headerType}).`);\n break;\n }\n if (jumpDataLength) {\n position += dataLength;\n }\n }\n }\n\n parseImageProperties(stream) {\n let newByte = stream.getByte();\n while (newByte >= 0) {\n const oldByte = newByte;\n newByte = stream.getByte();\n const code = (oldByte << 8) | newByte;\n // Image and tile size (SIZ)\n if (code === 0xff51) {\n stream.skip(4);\n const Xsiz = stream.getInt32() >>> 0; // Byte 4\n const Ysiz = stream.getInt32() >>> 0; // Byte 8\n const XOsiz = stream.getInt32() >>> 0; // Byte 12\n const YOsiz = stream.getInt32() >>> 0; // Byte 16\n stream.skip(16);\n const Csiz = stream.getUint16(); // Byte 36\n this.width = Xsiz - XOsiz;\n this.height = Ysiz - YOsiz;\n this.componentsCount = Csiz;\n // Results are always returned as `Uint8ClampedArray`s.\n this.bitsPerComponent = 8;\n return;\n }\n }\n throw new JpxError(\"No size marker found in JPX stream\");\n }\n\n parseCodestream(data, start, end) {\n const context = {};\n let doNotRecover = false;\n try {\n let position = start;\n while (position + 1 < end) {\n const code = readUint16(data, position);\n position += 2;\n\n let length = 0,\n j,\n sqcd,\n spqcds,\n spqcdSize,\n scalarExpounded,\n tile;\n switch (code) {\n case 0xff4f: // Start of codestream (SOC)\n context.mainHeader = true;\n break;\n case 0xffd9: // End of codestream (EOC)\n break;\n case 0xff51: // Image and tile size (SIZ)\n length = readUint16(data, position);\n const siz = {};\n siz.Xsiz = readUint32(data, position + 4);\n siz.Ysiz = readUint32(data, position + 8);\n siz.XOsiz = readUint32(data, position + 12);\n siz.YOsiz = readUint32(data, position + 16);\n siz.XTsiz = readUint32(data, position + 20);\n siz.YTsiz = readUint32(data, position + 24);\n siz.XTOsiz = readUint32(data, position + 28);\n siz.YTOsiz = readUint32(data, position + 32);\n const componentsCount = readUint16(data, position + 36);\n siz.Csiz = componentsCount;\n const components = [];\n j = position + 38;\n for (let i = 0; i < componentsCount; i++) {\n const component = {\n precision: (data[j] & 0x7f) + 1,\n isSigned: !!(data[j] & 0x80),\n XRsiz: data[j + 1],\n YRsiz: data[j + 2],\n };\n j += 3;\n calculateComponentDimensions(component, siz);\n components.push(component);\n }\n context.SIZ = siz;\n context.components = components;\n calculateTileGrids(context, components);\n context.QCC = [];\n context.COC = [];\n break;\n case 0xff5c: // Quantization default (QCD)\n length = readUint16(data, position);\n const qcd = {};\n j = position + 2;\n sqcd = data[j++];\n switch (sqcd & 0x1f) {\n case 0:\n spqcdSize = 8;\n scalarExpounded = true;\n break;\n case 1:\n spqcdSize = 16;\n scalarExpounded = false;\n break;\n case 2:\n spqcdSize = 16;\n scalarExpounded = true;\n break;\n default:\n throw new Error(\"Invalid SQcd value \" + sqcd);\n }\n qcd.noQuantization = spqcdSize === 8;\n qcd.scalarExpounded = scalarExpounded;\n qcd.guardBits = sqcd >> 5;\n spqcds = [];\n while (j < length + position) {\n const spqcd = {};\n if (spqcdSize === 8) {\n spqcd.epsilon = data[j++] >> 3;\n spqcd.mu = 0;\n } else {\n spqcd.epsilon = data[j] >> 3;\n spqcd.mu = ((data[j] & 0x7) << 8) | data[j + 1];\n j += 2;\n }\n spqcds.push(spqcd);\n }\n qcd.SPqcds = spqcds;\n if (context.mainHeader) {\n context.QCD = qcd;\n } else {\n context.currentTile.QCD = qcd;\n context.currentTile.QCC = [];\n }\n break;\n case 0xff5d: // Quantization component (QCC)\n length = readUint16(data, position);\n const qcc = {};\n j = position + 2;\n let cqcc;\n if (context.SIZ.Csiz < 257) {\n cqcc = data[j++];\n } else {\n cqcc = readUint16(data, j);\n j += 2;\n }\n sqcd = data[j++];\n switch (sqcd & 0x1f) {\n case 0:\n spqcdSize = 8;\n scalarExpounded = true;\n break;\n case 1:\n spqcdSize = 16;\n scalarExpounded = false;\n break;\n case 2:\n spqcdSize = 16;\n scalarExpounded = true;\n break;\n default:\n throw new Error(\"Invalid SQcd value \" + sqcd);\n }\n qcc.noQuantization = spqcdSize === 8;\n qcc.scalarExpounded = scalarExpounded;\n qcc.guardBits = sqcd >> 5;\n spqcds = [];\n while (j < length + position) {\n const spqcd = {};\n if (spqcdSize === 8) {\n spqcd.epsilon = data[j++] >> 3;\n spqcd.mu = 0;\n } else {\n spqcd.epsilon = data[j] >> 3;\n spqcd.mu = ((data[j] & 0x7) << 8) | data[j + 1];\n j += 2;\n }\n spqcds.push(spqcd);\n }\n qcc.SPqcds = spqcds;\n if (context.mainHeader) {\n context.QCC[cqcc] = qcc;\n } else {\n context.currentTile.QCC[cqcc] = qcc;\n }\n break;\n case 0xff52: // Coding style default (COD)\n length = readUint16(data, position);\n const cod = {};\n j = position + 2;\n const scod = data[j++];\n cod.entropyCoderWithCustomPrecincts = !!(scod & 1);\n cod.sopMarkerUsed = !!(scod & 2);\n cod.ephMarkerUsed = !!(scod & 4);\n cod.progressionOrder = data[j++];\n cod.layersCount = readUint16(data, j);\n j += 2;\n cod.multipleComponentTransform = data[j++];\n\n cod.decompositionLevelsCount = data[j++];\n cod.xcb = (data[j++] & 0xf) + 2;\n cod.ycb = (data[j++] & 0xf) + 2;\n const blockStyle = data[j++];\n cod.selectiveArithmeticCodingBypass = !!(blockStyle & 1);\n cod.resetContextProbabilities = !!(blockStyle & 2);\n cod.terminationOnEachCodingPass = !!(blockStyle & 4);\n cod.verticallyStripe = !!(blockStyle & 8);\n cod.predictableTermination = !!(blockStyle & 16);\n cod.segmentationSymbolUsed = !!(blockStyle & 32);\n cod.reversibleTransformation = data[j++];\n if (cod.entropyCoderWithCustomPrecincts) {\n const precinctsSizes = [];\n while (j < length + position) {\n const precinctsSize = data[j++];\n precinctsSizes.push({\n PPx: precinctsSize & 0xf,\n PPy: precinctsSize >> 4,\n });\n }\n cod.precinctsSizes = precinctsSizes;\n }\n const unsupported = [];\n if (cod.selectiveArithmeticCodingBypass) {\n unsupported.push(\"selectiveArithmeticCodingBypass\");\n }\n if (cod.terminationOnEachCodingPass) {\n unsupported.push(\"terminationOnEachCodingPass\");\n }\n if (cod.verticallyStripe) {\n unsupported.push(\"verticallyStripe\");\n }\n if (cod.predictableTermination) {\n unsupported.push(\"predictableTermination\");\n }\n if (unsupported.length > 0) {\n doNotRecover = true;\n warn(`JPX: Unsupported COD options (${unsupported.join(\", \")}).`);\n }\n if (context.mainHeader) {\n context.COD = cod;\n } else {\n context.currentTile.COD = cod;\n context.currentTile.COC = [];\n }\n break;\n case 0xff90: // Start of tile-part (SOT)\n length = readUint16(data, position);\n tile = {};\n tile.index = readUint16(data, position + 2);\n tile.length = readUint32(data, position + 4);\n tile.dataEnd = tile.length + position - 2;\n tile.partIndex = data[position + 8];\n tile.partsCount = data[position + 9];\n\n context.mainHeader = false;\n if (tile.partIndex === 0) {\n // reset component specific settings\n tile.COD = context.COD;\n tile.COC = context.COC.slice(0); // clone of the global COC\n tile.QCD = context.QCD;\n tile.QCC = context.QCC.slice(0); // clone of the global COC\n }\n context.currentTile = tile;\n break;\n case 0xff93: // Start of data (SOD)\n tile = context.currentTile;\n if (tile.partIndex === 0) {\n initializeTile(context, tile.index);\n buildPackets(context);\n }\n\n // moving to the end of the data\n length = tile.dataEnd - position;\n parseTilePackets(context, data, position, length);\n break;\n case 0xff53: // Coding style component (COC)\n warn(\"JPX: Codestream code 0xFF53 (COC) is not implemented.\");\n /* falls through */\n case 0xff55: // Tile-part lengths, main header (TLM)\n case 0xff57: // Packet length, main header (PLM)\n case 0xff58: // Packet length, tile-part header (PLT)\n case 0xff64: // Comment (COM)\n length = readUint16(data, position);\n // skipping content\n break;\n default:\n throw new Error(\"Unknown codestream code: \" + code.toString(16));\n }\n position += length;\n }\n } catch (e) {\n if (doNotRecover || this.failOnCorruptedImage) {\n throw new JpxError(e.message);\n } else {\n warn(`JPX: Trying to recover from: \"${e.message}\".`);\n }\n }\n this.tiles = transformComponents(context);\n this.width = context.SIZ.Xsiz - context.SIZ.XOsiz;\n this.height = context.SIZ.Ysiz - context.SIZ.YOsiz;\n this.componentsCount = context.SIZ.Csiz;\n }\n}\n\nfunction calculateComponentDimensions(component, siz) {\n // Section B.2 Component mapping\n component.x0 = Math.ceil(siz.XOsiz / component.XRsiz);\n component.x1 = Math.ceil(siz.Xsiz / component.XRsiz);\n component.y0 = Math.ceil(siz.YOsiz / component.YRsiz);\n component.y1 = Math.ceil(siz.Ysiz / component.YRsiz);\n component.width = component.x1 - component.x0;\n component.height = component.y1 - component.y0;\n}\nfunction calculateTileGrids(context, components) {\n const siz = context.SIZ;\n // Section B.3 Division into tile and tile-components\n const tiles = [];\n let tile;\n const numXtiles = Math.ceil((siz.Xsiz - siz.XTOsiz) / siz.XTsiz);\n const numYtiles = Math.ceil((siz.Ysiz - siz.YTOsiz) / siz.YTsiz);\n for (let q = 0; q < numYtiles; q++) {\n for (let p = 0; p < numXtiles; p++) {\n tile = {};\n tile.tx0 = Math.max(siz.XTOsiz + p * siz.XTsiz, siz.XOsiz);\n tile.ty0 = Math.max(siz.YTOsiz + q * siz.YTsiz, siz.YOsiz);\n tile.tx1 = Math.min(siz.XTOsiz + (p + 1) * siz.XTsiz, siz.Xsiz);\n tile.ty1 = Math.min(siz.YTOsiz + (q + 1) * siz.YTsiz, siz.Ysiz);\n tile.width = tile.tx1 - tile.tx0;\n tile.height = tile.ty1 - tile.ty0;\n tile.components = [];\n tiles.push(tile);\n }\n }\n context.tiles = tiles;\n\n const componentsCount = siz.Csiz;\n for (let i = 0, ii = componentsCount; i < ii; i++) {\n const component = components[i];\n for (let j = 0, jj = tiles.length; j < jj; j++) {\n const tileComponent = {};\n tile = tiles[j];\n tileComponent.tcx0 = Math.ceil(tile.tx0 / component.XRsiz);\n tileComponent.tcy0 = Math.ceil(tile.ty0 / component.YRsiz);\n tileComponent.tcx1 = Math.ceil(tile.tx1 / component.XRsiz);\n tileComponent.tcy1 = Math.ceil(tile.ty1 / component.YRsiz);\n tileComponent.width = tileComponent.tcx1 - tileComponent.tcx0;\n tileComponent.height = tileComponent.tcy1 - tileComponent.tcy0;\n tile.components[i] = tileComponent;\n }\n }\n}\nfunction getBlocksDimensions(context, component, r) {\n const codOrCoc = component.codingStyleParameters;\n const result = {};\n if (!codOrCoc.entropyCoderWithCustomPrecincts) {\n result.PPx = 15;\n result.PPy = 15;\n } else {\n result.PPx = codOrCoc.precinctsSizes[r].PPx;\n result.PPy = codOrCoc.precinctsSizes[r].PPy;\n }\n // calculate codeblock size as described in section B.7\n result.xcb_ =\n r > 0\n ? Math.min(codOrCoc.xcb, result.PPx - 1)\n : Math.min(codOrCoc.xcb, result.PPx);\n result.ycb_ =\n r > 0\n ? Math.min(codOrCoc.ycb, result.PPy - 1)\n : Math.min(codOrCoc.ycb, result.PPy);\n return result;\n}\nfunction buildPrecincts(context, resolution, dimensions) {\n // Section B.6 Division resolution to precincts\n const precinctWidth = 1 << dimensions.PPx;\n const precinctHeight = 1 << dimensions.PPy;\n // Jasper introduces codeblock groups for mapping each subband codeblocks\n // to precincts. Precinct partition divides a resolution according to width\n // and height parameters. The subband that belongs to the resolution level\n // has a different size than the level, unless it is the zero resolution.\n\n // From Jasper documentation: jpeg2000.pdf, section K: Tier-2 coding:\n // The precinct partitioning for a particular subband is derived from a\n // partitioning of its parent LL band (i.e., the LL band at the next higher\n // resolution level)... The LL band associated with each resolution level is\n // divided into precincts... Each of the resulting precinct regions is then\n // mapped into its child subbands (if any) at the next lower resolution\n // level. This is accomplished by using the coordinate transformation\n // (u, v) = (ceil(x/2), ceil(y/2)) where (x, y) and (u, v) are the\n // coordinates of a point in the LL band and child subband, respectively.\n const isZeroRes = resolution.resLevel === 0;\n const precinctWidthInSubband = 1 << (dimensions.PPx + (isZeroRes ? 0 : -1));\n const precinctHeightInSubband = 1 << (dimensions.PPy + (isZeroRes ? 0 : -1));\n const numprecinctswide =\n resolution.trx1 > resolution.trx0\n ? Math.ceil(resolution.trx1 / precinctWidth) -\n Math.floor(resolution.trx0 / precinctWidth)\n : 0;\n const numprecinctshigh =\n resolution.try1 > resolution.try0\n ? Math.ceil(resolution.try1 / precinctHeight) -\n Math.floor(resolution.try0 / precinctHeight)\n : 0;\n const numprecincts = numprecinctswide * numprecinctshigh;\n\n resolution.precinctParameters = {\n precinctWidth,\n precinctHeight,\n numprecinctswide,\n numprecinctshigh,\n numprecincts,\n precinctWidthInSubband,\n precinctHeightInSubband,\n };\n}\nfunction buildCodeblocks(context, subband, dimensions) {\n // Section B.7 Division sub-band into code-blocks\n const xcb_ = dimensions.xcb_;\n const ycb_ = dimensions.ycb_;\n const codeblockWidth = 1 << xcb_;\n const codeblockHeight = 1 << ycb_;\n const cbx0 = subband.tbx0 >> xcb_;\n const cby0 = subband.tby0 >> ycb_;\n const cbx1 = (subband.tbx1 + codeblockWidth - 1) >> xcb_;\n const cby1 = (subband.tby1 + codeblockHeight - 1) >> ycb_;\n const precinctParameters = subband.resolution.precinctParameters;\n const codeblocks = [];\n const precincts = [];\n let i, j, codeblock, precinctNumber;\n for (j = cby0; j < cby1; j++) {\n for (i = cbx0; i < cbx1; i++) {\n codeblock = {\n cbx: i,\n cby: j,\n tbx0: codeblockWidth * i,\n tby0: codeblockHeight * j,\n tbx1: codeblockWidth * (i + 1),\n tby1: codeblockHeight * (j + 1),\n };\n\n codeblock.tbx0_ = Math.max(subband.tbx0, codeblock.tbx0);\n codeblock.tby0_ = Math.max(subband.tby0, codeblock.tby0);\n codeblock.tbx1_ = Math.min(subband.tbx1, codeblock.tbx1);\n codeblock.tby1_ = Math.min(subband.tby1, codeblock.tby1);\n\n // Calculate precinct number for this codeblock, codeblock position\n // should be relative to its subband, use actual dimension and position\n // See comment about codeblock group width and height\n const pi = Math.floor(\n (codeblock.tbx0_ - subband.tbx0) /\n precinctParameters.precinctWidthInSubband\n );\n const pj = Math.floor(\n (codeblock.tby0_ - subband.tby0) /\n precinctParameters.precinctHeightInSubband\n );\n precinctNumber = pi + pj * precinctParameters.numprecinctswide;\n\n codeblock.precinctNumber = precinctNumber;\n codeblock.subbandType = subband.type;\n codeblock.Lblock = 3;\n\n if (\n codeblock.tbx1_ <= codeblock.tbx0_ ||\n codeblock.tby1_ <= codeblock.tby0_\n ) {\n continue;\n }\n codeblocks.push(codeblock);\n // building precinct for the sub-band\n let precinct = precincts[precinctNumber];\n if (precinct !== undefined) {\n if (i < precinct.cbxMin) {\n precinct.cbxMin = i;\n } else if (i > precinct.cbxMax) {\n precinct.cbxMax = i;\n }\n if (j < precinct.cbyMin) {\n precinct.cbxMin = j;\n } else if (j > precinct.cbyMax) {\n precinct.cbyMax = j;\n }\n } else {\n precincts[precinctNumber] = precinct = {\n cbxMin: i,\n cbyMin: j,\n cbxMax: i,\n cbyMax: j,\n };\n }\n codeblock.precinct = precinct;\n }\n }\n subband.codeblockParameters = {\n codeblockWidth: xcb_,\n codeblockHeight: ycb_,\n numcodeblockwide: cbx1 - cbx0 + 1,\n numcodeblockhigh: cby1 - cby0 + 1,\n };\n subband.codeblocks = codeblocks;\n subband.precincts = precincts;\n}\nfunction createPacket(resolution, precinctNumber, layerNumber) {\n const precinctCodeblocks = [];\n // Section B.10.8 Order of info in packet\n const subbands = resolution.subbands;\n // sub-bands already ordered in 'LL', 'HL', 'LH', and 'HH' sequence\n for (let i = 0, ii = subbands.length; i < ii; i++) {\n const subband = subbands[i];\n const codeblocks = subband.codeblocks;\n for (let j = 0, jj = codeblocks.length; j < jj; j++) {\n const codeblock = codeblocks[j];\n if (codeblock.precinctNumber !== precinctNumber) {\n continue;\n }\n precinctCodeblocks.push(codeblock);\n }\n }\n return {\n layerNumber,\n codeblocks: precinctCodeblocks,\n };\n}\nfunction LayerResolutionComponentPositionIterator(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const layersCount = tile.codingStyleDefaultParameters.layersCount;\n const componentsCount = siz.Csiz;\n let maxDecompositionLevelsCount = 0;\n for (let q = 0; q < componentsCount; q++) {\n maxDecompositionLevelsCount = Math.max(\n maxDecompositionLevelsCount,\n tile.components[q].codingStyleParameters.decompositionLevelsCount\n );\n }\n\n let l = 0,\n r = 0,\n i = 0,\n k = 0;\n\n this.nextPacket = function JpxImage_nextPacket() {\n // Section B.12.1.1 Layer-resolution-component-position\n for (; l < layersCount; l++) {\n for (; r <= maxDecompositionLevelsCount; r++) {\n for (; i < componentsCount; i++) {\n const component = tile.components[i];\n if (r > component.codingStyleParameters.decompositionLevelsCount) {\n continue;\n }\n\n const resolution = component.resolutions[r];\n const numprecincts = resolution.precinctParameters.numprecincts;\n for (; k < numprecincts; ) {\n const packet = createPacket(resolution, k, l);\n k++;\n return packet;\n }\n k = 0;\n }\n i = 0;\n }\n r = 0;\n }\n throw new JpxError(\"Out of packets\");\n };\n}\nfunction ResolutionLayerComponentPositionIterator(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const layersCount = tile.codingStyleDefaultParameters.layersCount;\n const componentsCount = siz.Csiz;\n let maxDecompositionLevelsCount = 0;\n for (let q = 0; q < componentsCount; q++) {\n maxDecompositionLevelsCount = Math.max(\n maxDecompositionLevelsCount,\n tile.components[q].codingStyleParameters.decompositionLevelsCount\n );\n }\n\n let r = 0,\n l = 0,\n i = 0,\n k = 0;\n\n this.nextPacket = function JpxImage_nextPacket() {\n // Section B.12.1.2 Resolution-layer-component-position\n for (; r <= maxDecompositionLevelsCount; r++) {\n for (; l < layersCount; l++) {\n for (; i < componentsCount; i++) {\n const component = tile.components[i];\n if (r > component.codingStyleParameters.decompositionLevelsCount) {\n continue;\n }\n\n const resolution = component.resolutions[r];\n const numprecincts = resolution.precinctParameters.numprecincts;\n for (; k < numprecincts; ) {\n const packet = createPacket(resolution, k, l);\n k++;\n return packet;\n }\n k = 0;\n }\n i = 0;\n }\n l = 0;\n }\n throw new JpxError(\"Out of packets\");\n };\n}\nfunction ResolutionPositionComponentLayerIterator(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const layersCount = tile.codingStyleDefaultParameters.layersCount;\n const componentsCount = siz.Csiz;\n let l, r, c, p;\n let maxDecompositionLevelsCount = 0;\n for (c = 0; c < componentsCount; c++) {\n const component = tile.components[c];\n maxDecompositionLevelsCount = Math.max(\n maxDecompositionLevelsCount,\n component.codingStyleParameters.decompositionLevelsCount\n );\n }\n const maxNumPrecinctsInLevel = new Int32Array(\n maxDecompositionLevelsCount + 1\n );\n for (r = 0; r <= maxDecompositionLevelsCount; ++r) {\n let maxNumPrecincts = 0;\n for (c = 0; c < componentsCount; ++c) {\n const resolutions = tile.components[c].resolutions;\n if (r < resolutions.length) {\n maxNumPrecincts = Math.max(\n maxNumPrecincts,\n resolutions[r].precinctParameters.numprecincts\n );\n }\n }\n maxNumPrecinctsInLevel[r] = maxNumPrecincts;\n }\n l = 0;\n r = 0;\n c = 0;\n p = 0;\n\n this.nextPacket = function JpxImage_nextPacket() {\n // Section B.12.1.3 Resolution-position-component-layer\n for (; r <= maxDecompositionLevelsCount; r++) {\n for (; p < maxNumPrecinctsInLevel[r]; p++) {\n for (; c < componentsCount; c++) {\n const component = tile.components[c];\n if (r > component.codingStyleParameters.decompositionLevelsCount) {\n continue;\n }\n const resolution = component.resolutions[r];\n const numprecincts = resolution.precinctParameters.numprecincts;\n if (p >= numprecincts) {\n continue;\n }\n for (; l < layersCount; ) {\n const packet = createPacket(resolution, p, l);\n l++;\n return packet;\n }\n l = 0;\n }\n c = 0;\n }\n p = 0;\n }\n throw new JpxError(\"Out of packets\");\n };\n}\nfunction PositionComponentResolutionLayerIterator(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const layersCount = tile.codingStyleDefaultParameters.layersCount;\n const componentsCount = siz.Csiz;\n const precinctsSizes = getPrecinctSizesInImageScale(tile);\n const precinctsIterationSizes = precinctsSizes;\n let l = 0,\n r = 0,\n c = 0,\n px = 0,\n py = 0;\n\n this.nextPacket = function JpxImage_nextPacket() {\n // Section B.12.1.4 Position-component-resolution-layer\n for (; py < precinctsIterationSizes.maxNumHigh; py++) {\n for (; px < precinctsIterationSizes.maxNumWide; px++) {\n for (; c < componentsCount; c++) {\n const component = tile.components[c];\n const decompositionLevelsCount =\n component.codingStyleParameters.decompositionLevelsCount;\n for (; r <= decompositionLevelsCount; r++) {\n const resolution = component.resolutions[r];\n const sizeInImageScale =\n precinctsSizes.components[c].resolutions[r];\n const k = getPrecinctIndexIfExist(\n px,\n py,\n sizeInImageScale,\n precinctsIterationSizes,\n resolution\n );\n if (k === null) {\n continue;\n }\n for (; l < layersCount; ) {\n const packet = createPacket(resolution, k, l);\n l++;\n return packet;\n }\n l = 0;\n }\n r = 0;\n }\n c = 0;\n }\n px = 0;\n }\n throw new JpxError(\"Out of packets\");\n };\n}\nfunction ComponentPositionResolutionLayerIterator(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const layersCount = tile.codingStyleDefaultParameters.layersCount;\n const componentsCount = siz.Csiz;\n const precinctsSizes = getPrecinctSizesInImageScale(tile);\n let l = 0,\n r = 0,\n c = 0,\n px = 0,\n py = 0;\n\n this.nextPacket = function JpxImage_nextPacket() {\n // Section B.12.1.5 Component-position-resolution-layer\n for (; c < componentsCount; ++c) {\n const component = tile.components[c];\n const precinctsIterationSizes = precinctsSizes.components[c];\n const decompositionLevelsCount =\n component.codingStyleParameters.decompositionLevelsCount;\n for (; py < precinctsIterationSizes.maxNumHigh; py++) {\n for (; px < precinctsIterationSizes.maxNumWide; px++) {\n for (; r <= decompositionLevelsCount; r++) {\n const resolution = component.resolutions[r];\n const sizeInImageScale = precinctsIterationSizes.resolutions[r];\n const k = getPrecinctIndexIfExist(\n px,\n py,\n sizeInImageScale,\n precinctsIterationSizes,\n resolution\n );\n if (k === null) {\n continue;\n }\n for (; l < layersCount; ) {\n const packet = createPacket(resolution, k, l);\n l++;\n return packet;\n }\n l = 0;\n }\n r = 0;\n }\n px = 0;\n }\n py = 0;\n }\n throw new JpxError(\"Out of packets\");\n };\n}\nfunction getPrecinctIndexIfExist(\n pxIndex,\n pyIndex,\n sizeInImageScale,\n precinctIterationSizes,\n resolution\n) {\n const posX = pxIndex * precinctIterationSizes.minWidth;\n const posY = pyIndex * precinctIterationSizes.minHeight;\n if (\n posX % sizeInImageScale.width !== 0 ||\n posY % sizeInImageScale.height !== 0\n ) {\n return null;\n }\n const startPrecinctRowIndex =\n (posY / sizeInImageScale.width) *\n resolution.precinctParameters.numprecinctswide;\n return posX / sizeInImageScale.height + startPrecinctRowIndex;\n}\nfunction getPrecinctSizesInImageScale(tile) {\n const componentsCount = tile.components.length;\n let minWidth = Number.MAX_VALUE;\n let minHeight = Number.MAX_VALUE;\n let maxNumWide = 0;\n let maxNumHigh = 0;\n const sizePerComponent = new Array(componentsCount);\n for (let c = 0; c < componentsCount; c++) {\n const component = tile.components[c];\n const decompositionLevelsCount =\n component.codingStyleParameters.decompositionLevelsCount;\n const sizePerResolution = new Array(decompositionLevelsCount + 1);\n let minWidthCurrentComponent = Number.MAX_VALUE;\n let minHeightCurrentComponent = Number.MAX_VALUE;\n let maxNumWideCurrentComponent = 0;\n let maxNumHighCurrentComponent = 0;\n let scale = 1;\n for (let r = decompositionLevelsCount; r >= 0; --r) {\n const resolution = component.resolutions[r];\n const widthCurrentResolution =\n scale * resolution.precinctParameters.precinctWidth;\n const heightCurrentResolution =\n scale * resolution.precinctParameters.precinctHeight;\n minWidthCurrentComponent = Math.min(\n minWidthCurrentComponent,\n widthCurrentResolution\n );\n minHeightCurrentComponent = Math.min(\n minHeightCurrentComponent,\n heightCurrentResolution\n );\n maxNumWideCurrentComponent = Math.max(\n maxNumWideCurrentComponent,\n resolution.precinctParameters.numprecinctswide\n );\n maxNumHighCurrentComponent = Math.max(\n maxNumHighCurrentComponent,\n resolution.precinctParameters.numprecinctshigh\n );\n sizePerResolution[r] = {\n width: widthCurrentResolution,\n height: heightCurrentResolution,\n };\n scale <<= 1;\n }\n minWidth = Math.min(minWidth, minWidthCurrentComponent);\n minHeight = Math.min(minHeight, minHeightCurrentComponent);\n maxNumWide = Math.max(maxNumWide, maxNumWideCurrentComponent);\n maxNumHigh = Math.max(maxNumHigh, maxNumHighCurrentComponent);\n sizePerComponent[c] = {\n resolutions: sizePerResolution,\n minWidth: minWidthCurrentComponent,\n minHeight: minHeightCurrentComponent,\n maxNumWide: maxNumWideCurrentComponent,\n maxNumHigh: maxNumHighCurrentComponent,\n };\n }\n return {\n components: sizePerComponent,\n minWidth,\n minHeight,\n maxNumWide,\n maxNumHigh,\n };\n}\nfunction buildPackets(context) {\n const siz = context.SIZ;\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const componentsCount = siz.Csiz;\n // Creating resolutions and sub-bands for each component\n for (let c = 0; c < componentsCount; c++) {\n const component = tile.components[c];\n const decompositionLevelsCount =\n component.codingStyleParameters.decompositionLevelsCount;\n // Section B.5 Resolution levels and sub-bands\n const resolutions = [];\n const subbands = [];\n for (let r = 0; r <= decompositionLevelsCount; r++) {\n const blocksDimensions = getBlocksDimensions(context, component, r);\n const resolution = {};\n const scale = 1 << (decompositionLevelsCount - r);\n resolution.trx0 = Math.ceil(component.tcx0 / scale);\n resolution.try0 = Math.ceil(component.tcy0 / scale);\n resolution.trx1 = Math.ceil(component.tcx1 / scale);\n resolution.try1 = Math.ceil(component.tcy1 / scale);\n resolution.resLevel = r;\n buildPrecincts(context, resolution, blocksDimensions);\n resolutions.push(resolution);\n\n let subband;\n if (r === 0) {\n // one sub-band (LL) with last decomposition\n subband = {};\n subband.type = \"LL\";\n subband.tbx0 = Math.ceil(component.tcx0 / scale);\n subband.tby0 = Math.ceil(component.tcy0 / scale);\n subband.tbx1 = Math.ceil(component.tcx1 / scale);\n subband.tby1 = Math.ceil(component.tcy1 / scale);\n subband.resolution = resolution;\n buildCodeblocks(context, subband, blocksDimensions);\n subbands.push(subband);\n resolution.subbands = [subband];\n } else {\n const bscale = 1 << (decompositionLevelsCount - r + 1);\n const resolutionSubbands = [];\n // three sub-bands (HL, LH and HH) with rest of decompositions\n subband = {};\n subband.type = \"HL\";\n subband.tbx0 = Math.ceil(component.tcx0 / bscale - 0.5);\n subband.tby0 = Math.ceil(component.tcy0 / bscale);\n subband.tbx1 = Math.ceil(component.tcx1 / bscale - 0.5);\n subband.tby1 = Math.ceil(component.tcy1 / bscale);\n subband.resolution = resolution;\n buildCodeblocks(context, subband, blocksDimensions);\n subbands.push(subband);\n resolutionSubbands.push(subband);\n\n subband = {};\n subband.type = \"LH\";\n subband.tbx0 = Math.ceil(component.tcx0 / bscale);\n subband.tby0 = Math.ceil(component.tcy0 / bscale - 0.5);\n subband.tbx1 = Math.ceil(component.tcx1 / bscale);\n subband.tby1 = Math.ceil(component.tcy1 / bscale - 0.5);\n subband.resolution = resolution;\n buildCodeblocks(context, subband, blocksDimensions);\n subbands.push(subband);\n resolutionSubbands.push(subband);\n\n subband = {};\n subband.type = \"HH\";\n subband.tbx0 = Math.ceil(component.tcx0 / bscale - 0.5);\n subband.tby0 = Math.ceil(component.tcy0 / bscale - 0.5);\n subband.tbx1 = Math.ceil(component.tcx1 / bscale - 0.5);\n subband.tby1 = Math.ceil(component.tcy1 / bscale - 0.5);\n subband.resolution = resolution;\n buildCodeblocks(context, subband, blocksDimensions);\n subbands.push(subband);\n resolutionSubbands.push(subband);\n\n resolution.subbands = resolutionSubbands;\n }\n }\n component.resolutions = resolutions;\n component.subbands = subbands;\n }\n // Generate the packets sequence\n const progressionOrder = tile.codingStyleDefaultParameters.progressionOrder;\n switch (progressionOrder) {\n case 0:\n tile.packetsIterator = new LayerResolutionComponentPositionIterator(\n context\n );\n break;\n case 1:\n tile.packetsIterator = new ResolutionLayerComponentPositionIterator(\n context\n );\n break;\n case 2:\n tile.packetsIterator = new ResolutionPositionComponentLayerIterator(\n context\n );\n break;\n case 3:\n tile.packetsIterator = new PositionComponentResolutionLayerIterator(\n context\n );\n break;\n case 4:\n tile.packetsIterator = new ComponentPositionResolutionLayerIterator(\n context\n );\n break;\n default:\n throw new JpxError(`Unsupported progression order ${progressionOrder}`);\n }\n}\nfunction parseTilePackets(context, data, offset, dataLength) {\n let position = 0;\n let buffer,\n bufferSize = 0,\n skipNextBit = false;\n function readBits(count) {\n while (bufferSize < count) {\n const b = data[offset + position];\n position++;\n if (skipNextBit) {\n buffer = (buffer << 7) | b;\n bufferSize += 7;\n skipNextBit = false;\n } else {\n buffer = (buffer << 8) | b;\n bufferSize += 8;\n }\n if (b === 0xff) {\n skipNextBit = true;\n }\n }\n bufferSize -= count;\n return (buffer >>> bufferSize) & ((1 << count) - 1);\n }\n function skipMarkerIfEqual(value) {\n if (\n data[offset + position - 1] === 0xff &&\n data[offset + position] === value\n ) {\n skipBytes(1);\n return true;\n } else if (\n data[offset + position] === 0xff &&\n data[offset + position + 1] === value\n ) {\n skipBytes(2);\n return true;\n }\n return false;\n }\n function skipBytes(count) {\n position += count;\n }\n function alignToByte() {\n bufferSize = 0;\n if (skipNextBit) {\n position++;\n skipNextBit = false;\n }\n }\n function readCodingpasses() {\n if (readBits(1) === 0) {\n return 1;\n }\n if (readBits(1) === 0) {\n return 2;\n }\n let value = readBits(2);\n if (value < 3) {\n return value + 3;\n }\n value = readBits(5);\n if (value < 31) {\n return value + 6;\n }\n value = readBits(7);\n return value + 37;\n }\n const tileIndex = context.currentTile.index;\n const tile = context.tiles[tileIndex];\n const sopMarkerUsed = context.COD.sopMarkerUsed;\n const ephMarkerUsed = context.COD.ephMarkerUsed;\n const packetsIterator = tile.packetsIterator;\n while (position < dataLength) {\n alignToByte();\n if (sopMarkerUsed && skipMarkerIfEqual(0x91)) {\n // Skip also marker segment length and packet sequence ID\n skipBytes(4);\n }\n const packet = packetsIterator.nextPacket();\n if (!readBits(1)) {\n continue;\n }\n const layerNumber = packet.layerNumber,\n queue = [];\n let codeblock;\n for (let i = 0, ii = packet.codeblocks.length; i < ii; i++) {\n codeblock = packet.codeblocks[i];\n let precinct = codeblock.precinct;\n const codeblockColumn = codeblock.cbx - precinct.cbxMin;\n const codeblockRow = codeblock.cby - precinct.cbyMin;\n let codeblockIncluded = false;\n let firstTimeInclusion = false;\n let valueReady, zeroBitPlanesTree;\n if (codeblock.included !== undefined) {\n codeblockIncluded = !!readBits(1);\n } else {\n // reading inclusion tree\n precinct = codeblock.precinct;\n let inclusionTree;\n if (precinct.inclusionTree !== undefined) {\n inclusionTree = precinct.inclusionTree;\n } else {\n // building inclusion and zero bit-planes trees\n const width = precinct.cbxMax - precinct.cbxMin + 1;\n const height = precinct.cbyMax - precinct.cbyMin + 1;\n inclusionTree = new InclusionTree(width, height, layerNumber);\n zeroBitPlanesTree = new TagTree(width, height);\n precinct.inclusionTree = inclusionTree;\n precinct.zeroBitPlanesTree = zeroBitPlanesTree;\n for (let l = 0; l < layerNumber; l++) {\n if (readBits(1) !== 0) {\n throw new JpxError(\"Invalid tag tree\");\n }\n }\n }\n\n if (inclusionTree.reset(codeblockColumn, codeblockRow, layerNumber)) {\n while (true) {\n if (readBits(1)) {\n valueReady = !inclusionTree.nextLevel();\n if (valueReady) {\n codeblock.included = true;\n codeblockIncluded = firstTimeInclusion = true;\n break;\n }\n } else {\n inclusionTree.incrementValue(layerNumber);\n break;\n }\n }\n }\n }\n if (!codeblockIncluded) {\n continue;\n }\n if (firstTimeInclusion) {\n zeroBitPlanesTree = precinct.zeroBitPlanesTree;\n zeroBitPlanesTree.reset(codeblockColumn, codeblockRow);\n while (true) {\n if (readBits(1)) {\n valueReady = !zeroBitPlanesTree.nextLevel();\n if (valueReady) {\n break;\n }\n } else {\n zeroBitPlanesTree.incrementValue();\n }\n }\n codeblock.zeroBitPlanes = zeroBitPlanesTree.value;\n }\n const codingpasses = readCodingpasses();\n while (readBits(1)) {\n codeblock.Lblock++;\n }\n const codingpassesLog2 = log2(codingpasses);\n // rounding down log2\n const bits =\n (codingpasses < 1 << codingpassesLog2\n ? codingpassesLog2 - 1\n : codingpassesLog2) + codeblock.Lblock;\n const codedDataLength = readBits(bits);\n queue.push({\n codeblock,\n codingpasses,\n dataLength: codedDataLength,\n });\n }\n alignToByte();\n if (ephMarkerUsed) {\n skipMarkerIfEqual(0x92);\n }\n while (queue.length > 0) {\n const packetItem = queue.shift();\n codeblock = packetItem.codeblock;\n if (codeblock.data === undefined) {\n codeblock.data = [];\n }\n codeblock.data.push({\n data,\n start: offset + position,\n end: offset + position + packetItem.dataLength,\n codingpasses: packetItem.codingpasses,\n });\n position += packetItem.dataLength;\n }\n }\n return position;\n}\nfunction copyCoefficients(\n coefficients,\n levelWidth,\n levelHeight,\n subband,\n delta,\n mb,\n reversible,\n segmentationSymbolUsed,\n resetContextProbabilities\n) {\n const x0 = subband.tbx0;\n const y0 = subband.tby0;\n const width = subband.tbx1 - subband.tbx0;\n const codeblocks = subband.codeblocks;\n const right = subband.type.charAt(0) === \"H\" ? 1 : 0;\n const bottom = subband.type.charAt(1) === \"H\" ? levelWidth : 0;\n\n for (let i = 0, ii = codeblocks.length; i < ii; ++i) {\n const codeblock = codeblocks[i];\n const blockWidth = codeblock.tbx1_ - codeblock.tbx0_;\n const blockHeight = codeblock.tby1_ - codeblock.tby0_;\n if (blockWidth === 0 || blockHeight === 0) {\n continue;\n }\n if (codeblock.data === undefined) {\n continue;\n }\n\n const bitModel = new BitModel(\n blockWidth,\n blockHeight,\n codeblock.subbandType,\n codeblock.zeroBitPlanes,\n mb\n );\n let currentCodingpassType = 2; // first bit plane starts from cleanup\n\n // collect data\n const data = codeblock.data;\n let totalLength = 0,\n codingpasses = 0;\n let j, jj, dataItem;\n for (j = 0, jj = data.length; j < jj; j++) {\n dataItem = data[j];\n totalLength += dataItem.end - dataItem.start;\n codingpasses += dataItem.codingpasses;\n }\n const encodedData = new Uint8Array(totalLength);\n let position = 0;\n for (j = 0, jj = data.length; j < jj; j++) {\n dataItem = data[j];\n const chunk = dataItem.data.subarray(dataItem.start, dataItem.end);\n encodedData.set(chunk, position);\n position += chunk.length;\n }\n // decoding the item\n const decoder = new ArithmeticDecoder(encodedData, 0, totalLength);\n bitModel.setDecoder(decoder);\n\n for (j = 0; j < codingpasses; j++) {\n switch (currentCodingpassType) {\n case 0:\n bitModel.runSignificancePropagationPass();\n break;\n case 1:\n bitModel.runMagnitudeRefinementPass();\n break;\n case 2:\n bitModel.runCleanupPass();\n if (segmentationSymbolUsed) {\n bitModel.checkSegmentationSymbol();\n }\n break;\n }\n\n if (resetContextProbabilities) {\n bitModel.reset();\n }\n\n currentCodingpassType = (currentCodingpassType + 1) % 3;\n }\n\n let offset = codeblock.tbx0_ - x0 + (codeblock.tby0_ - y0) * width;\n const sign = bitModel.coefficentsSign;\n const magnitude = bitModel.coefficentsMagnitude;\n const bitsDecoded = bitModel.bitsDecoded;\n const magnitudeCorrection = reversible ? 0 : 0.5;\n let k, n, nb;\n position = 0;\n // Do the interleaving of Section F.3.3 here, so we do not need\n // to copy later. LL level is not interleaved, just copied.\n const interleave = subband.type !== \"LL\";\n for (j = 0; j < blockHeight; j++) {\n const row = (offset / width) | 0; // row in the non-interleaved subband\n const levelOffset = 2 * row * (levelWidth - width) + right + bottom;\n for (k = 0; k < blockWidth; k++) {\n n = magnitude[position];\n if (n !== 0) {\n n = (n + magnitudeCorrection) * delta;\n if (sign[position] !== 0) {\n n = -n;\n }\n nb = bitsDecoded[position];\n const pos = interleave ? levelOffset + (offset << 1) : offset;\n coefficients[pos] = reversible && nb >= mb ? n : n * (1 << (mb - nb));\n }\n offset++;\n position++;\n }\n offset += width - blockWidth;\n }\n }\n}\nfunction transformTile(context, tile, c) {\n const component = tile.components[c];\n const codingStyleParameters = component.codingStyleParameters;\n const quantizationParameters = component.quantizationParameters;\n const decompositionLevelsCount =\n codingStyleParameters.decompositionLevelsCount;\n const spqcds = quantizationParameters.SPqcds;\n const scalarExpounded = quantizationParameters.scalarExpounded;\n const guardBits = quantizationParameters.guardBits;\n const segmentationSymbolUsed = codingStyleParameters.segmentationSymbolUsed;\n const resetContextProbabilities =\n codingStyleParameters.resetContextProbabilities;\n const precision = context.components[c].precision;\n\n const reversible = codingStyleParameters.reversibleTransformation;\n const transform = reversible\n ? new ReversibleTransform()\n : new IrreversibleTransform();\n\n const subbandCoefficients = [];\n let b = 0;\n for (let i = 0; i <= decompositionLevelsCount; i++) {\n const resolution = component.resolutions[i];\n\n const width = resolution.trx1 - resolution.trx0;\n const height = resolution.try1 - resolution.try0;\n // Allocate space for the whole sublevel.\n const coefficients = new Float32Array(width * height);\n\n for (let j = 0, jj = resolution.subbands.length; j < jj; j++) {\n let mu, epsilon;\n if (!scalarExpounded) {\n // formula E-5\n mu = spqcds[0].mu;\n epsilon = spqcds[0].epsilon + (i > 0 ? 1 - i : 0);\n } else {\n mu = spqcds[b].mu;\n epsilon = spqcds[b].epsilon;\n b++;\n }\n\n const subband = resolution.subbands[j];\n const gainLog2 = SubbandsGainLog2[subband.type];\n\n // calculate quantization coefficient (Section E.1.1.1)\n const delta = reversible\n ? 1\n : 2 ** (precision + gainLog2 - epsilon) * (1 + mu / 2048);\n const mb = guardBits + epsilon - 1;\n\n // In the first resolution level, copyCoefficients will fill the\n // whole array with coefficients. In the succeeding passes,\n // copyCoefficients will consecutively fill in the values that belong\n // to the interleaved positions of the HL, LH, and HH coefficients.\n // The LL coefficients will then be interleaved in Transform.iterate().\n copyCoefficients(\n coefficients,\n width,\n height,\n subband,\n delta,\n mb,\n reversible,\n segmentationSymbolUsed,\n resetContextProbabilities\n );\n }\n subbandCoefficients.push({\n width,\n height,\n items: coefficients,\n });\n }\n\n const result = transform.calculate(\n subbandCoefficients,\n component.tcx0,\n component.tcy0\n );\n return {\n left: component.tcx0,\n top: component.tcy0,\n width: result.width,\n height: result.height,\n items: result.items,\n };\n}\nfunction transformComponents(context) {\n const siz = context.SIZ;\n const components = context.components;\n const componentsCount = siz.Csiz;\n const resultImages = [];\n for (let i = 0, ii = context.tiles.length; i < ii; i++) {\n const tile = context.tiles[i];\n const transformedTiles = [];\n for (let c = 0; c < componentsCount; c++) {\n transformedTiles[c] = transformTile(context, tile, c);\n }\n const tile0 = transformedTiles[0];\n const out = new Uint8ClampedArray(tile0.items.length * componentsCount);\n const result = {\n left: tile0.left,\n top: tile0.top,\n width: tile0.width,\n height: tile0.height,\n items: out,\n };\n\n // Section G.2.2 Inverse multi component transform\n let shift, offset;\n let pos = 0,\n j,\n jj,\n y0,\n y1,\n y2;\n if (tile.codingStyleDefaultParameters.multipleComponentTransform) {\n const fourComponents = componentsCount === 4;\n const y0items = transformedTiles[0].items;\n const y1items = transformedTiles[1].items;\n const y2items = transformedTiles[2].items;\n const y3items = fourComponents ? transformedTiles[3].items : null;\n\n // HACK: The multiple component transform formulas below assume that\n // all components have the same precision. With this in mind, we\n // compute shift and offset only once.\n shift = components[0].precision - 8;\n offset = (128 << shift) + 0.5;\n\n const component0 = tile.components[0];\n const alpha01 = componentsCount - 3;\n jj = y0items.length;\n if (!component0.codingStyleParameters.reversibleTransformation) {\n // inverse irreversible multiple component transform\n for (j = 0; j < jj; j++, pos += alpha01) {\n y0 = y0items[j] + offset;\n y1 = y1items[j];\n y2 = y2items[j];\n out[pos++] = (y0 + 1.402 * y2) >> shift;\n out[pos++] = (y0 - 0.34413 * y1 - 0.71414 * y2) >> shift;\n out[pos++] = (y0 + 1.772 * y1) >> shift;\n }\n } else {\n // inverse reversible multiple component transform\n for (j = 0; j < jj; j++, pos += alpha01) {\n y0 = y0items[j] + offset;\n y1 = y1items[j];\n y2 = y2items[j];\n const g = y0 - ((y2 + y1) >> 2);\n\n out[pos++] = (g + y2) >> shift;\n out[pos++] = g >> shift;\n out[pos++] = (g + y1) >> shift;\n }\n }\n if (fourComponents) {\n for (j = 0, pos = 3; j < jj; j++, pos += 4) {\n out[pos] = (y3items[j] + offset) >> shift;\n }\n }\n } else {\n // no multi-component transform\n for (let c = 0; c < componentsCount; c++) {\n const items = transformedTiles[c].items;\n shift = components[c].precision - 8;\n offset = (128 << shift) + 0.5;\n for (pos = c, j = 0, jj = items.length; j < jj; j++) {\n out[pos] = (items[j] + offset) >> shift;\n pos += componentsCount;\n }\n }\n }\n resultImages.push(result);\n }\n return resultImages;\n}\nfunction initializeTile(context, tileIndex) {\n const siz = context.SIZ;\n const componentsCount = siz.Csiz;\n const tile = context.tiles[tileIndex];\n for (let c = 0; c < componentsCount; c++) {\n const component = tile.components[c];\n const qcdOrQcc =\n context.currentTile.QCC[c] !== undefined\n ? context.currentTile.QCC[c]\n : context.currentTile.QCD;\n component.quantizationParameters = qcdOrQcc;\n const codOrCoc =\n context.currentTile.COC[c] !== undefined\n ? context.currentTile.COC[c]\n : context.currentTile.COD;\n component.codingStyleParameters = codOrCoc;\n }\n tile.codingStyleDefaultParameters = context.currentTile.COD;\n}\n\n// Section B.10.2 Tag trees\nclass TagTree {\n constructor(width, height) {\n const levelsLength = log2(Math.max(width, height)) + 1;\n this.levels = [];\n for (let i = 0; i < levelsLength; i++) {\n const level = {\n width,\n height,\n items: [],\n };\n this.levels.push(level);\n width = Math.ceil(width / 2);\n height = Math.ceil(height / 2);\n }\n }\n\n reset(i, j) {\n let currentLevel = 0,\n value = 0,\n level;\n while (currentLevel < this.levels.length) {\n level = this.levels[currentLevel];\n const index = i + j * level.width;\n if (level.items[index] !== undefined) {\n value = level.items[index];\n break;\n }\n level.index = index;\n i >>= 1;\n j >>= 1;\n currentLevel++;\n }\n currentLevel--;\n level = this.levels[currentLevel];\n level.items[level.index] = value;\n this.currentLevel = currentLevel;\n delete this.value;\n }\n\n incrementValue() {\n const level = this.levels[this.currentLevel];\n level.items[level.index]++;\n }\n\n nextLevel() {\n let currentLevel = this.currentLevel;\n let level = this.levels[currentLevel];\n const value = level.items[level.index];\n currentLevel--;\n if (currentLevel < 0) {\n this.value = value;\n return false;\n }\n\n this.currentLevel = currentLevel;\n level = this.levels[currentLevel];\n level.items[level.index] = value;\n return true;\n }\n}\n\nclass InclusionTree {\n constructor(width, height, defaultValue) {\n const levelsLength = log2(Math.max(width, height)) + 1;\n this.levels = [];\n for (let i = 0; i < levelsLength; i++) {\n const items = new Uint8Array(width * height);\n for (let j = 0, jj = items.length; j < jj; j++) {\n items[j] = defaultValue;\n }\n\n const level = {\n width,\n height,\n items,\n };\n this.levels.push(level);\n\n width = Math.ceil(width / 2);\n height = Math.ceil(height / 2);\n }\n }\n\n reset(i, j, stopValue) {\n let currentLevel = 0;\n while (currentLevel < this.levels.length) {\n const level = this.levels[currentLevel];\n const index = i + j * level.width;\n level.index = index;\n const value = level.items[index];\n\n if (value === 0xff) {\n break;\n }\n\n if (value > stopValue) {\n this.currentLevel = currentLevel;\n // already know about this one, propagating the value to top levels\n this.propagateValues();\n return false;\n }\n\n i >>= 1;\n j >>= 1;\n currentLevel++;\n }\n this.currentLevel = currentLevel - 1;\n return true;\n }\n\n incrementValue(stopValue) {\n const level = this.levels[this.currentLevel];\n level.items[level.index] = stopValue + 1;\n this.propagateValues();\n }\n\n propagateValues() {\n let levelIndex = this.currentLevel;\n let level = this.levels[levelIndex];\n const currentValue = level.items[level.index];\n while (--levelIndex >= 0) {\n level = this.levels[levelIndex];\n level.items[level.index] = currentValue;\n }\n }\n\n nextLevel() {\n let currentLevel = this.currentLevel;\n let level = this.levels[currentLevel];\n const value = level.items[level.index];\n level.items[level.index] = 0xff;\n currentLevel--;\n if (currentLevel < 0) {\n return false;\n }\n\n this.currentLevel = currentLevel;\n level = this.levels[currentLevel];\n level.items[level.index] = value;\n return true;\n }\n}\n\n// Section D. Coefficient bit modeling\nclass BitModel {\n static UNIFORM_CONTEXT = 17;\n\n static RUNLENGTH_CONTEXT = 18;\n\n // Table D-1\n // The index is binary presentation: 0dddvvhh, ddd - sum of Di (0..4),\n // vv - sum of Vi (0..2), and hh - sum of Hi (0..2)\n static LLAndLHContextsLabel = new Uint8Array([\n 0, 5, 8, 0, 3, 7, 8, 0, 4, 7, 8, 0, 0, 0, 0, 0, 1, 6, 8, 0, 3, 7, 8, 0, 4,\n 7, 8, 0, 0, 0, 0, 0, 2, 6, 8, 0, 3, 7, 8, 0, 4, 7, 8, 0, 0, 0, 0, 0, 2, 6,\n 8, 0, 3, 7, 8, 0, 4, 7, 8, 0, 0, 0, 0, 0, 2, 6, 8, 0, 3, 7, 8, 0, 4, 7, 8,\n ]);\n\n static HLContextLabel = new Uint8Array([\n 0, 3, 4, 0, 5, 7, 7, 0, 8, 8, 8, 0, 0, 0, 0, 0, 1, 3, 4, 0, 6, 7, 7, 0, 8,\n 8, 8, 0, 0, 0, 0, 0, 2, 3, 4, 0, 6, 7, 7, 0, 8, 8, 8, 0, 0, 0, 0, 0, 2, 3,\n 4, 0, 6, 7, 7, 0, 8, 8, 8, 0, 0, 0, 0, 0, 2, 3, 4, 0, 6, 7, 7, 0, 8, 8, 8,\n ]);\n\n static HHContextLabel = new Uint8Array([\n 0, 1, 2, 0, 1, 2, 2, 0, 2, 2, 2, 0, 0, 0, 0, 0, 3, 4, 5, 0, 4, 5, 5, 0, 5,\n 5, 5, 0, 0, 0, 0, 0, 6, 7, 7, 0, 7, 7, 7, 0, 7, 7, 7, 0, 0, 0, 0, 0, 8, 8,\n 8, 0, 8, 8, 8, 0, 8, 8, 8, 0, 0, 0, 0, 0, 8, 8, 8, 0, 8, 8, 8, 0, 8, 8, 8,\n ]);\n\n constructor(width, height, subband, zeroBitPlanes, mb) {\n this.width = width;\n this.height = height;\n\n let contextLabelTable;\n if (subband === \"HH\") {\n contextLabelTable = BitModel.HHContextLabel;\n } else if (subband === \"HL\") {\n contextLabelTable = BitModel.HLContextLabel;\n } else {\n contextLabelTable = BitModel.LLAndLHContextsLabel;\n }\n this.contextLabelTable = contextLabelTable;\n\n const coefficientCount = width * height;\n\n // coefficients outside the encoding region treated as insignificant\n // add border state cells for significanceState\n this.neighborsSignificance = new Uint8Array(coefficientCount);\n this.coefficentsSign = new Uint8Array(coefficientCount);\n let coefficentsMagnitude;\n if (mb > 14) {\n coefficentsMagnitude = new Uint32Array(coefficientCount);\n } else if (mb > 6) {\n coefficentsMagnitude = new Uint16Array(coefficientCount);\n } else {\n coefficentsMagnitude = new Uint8Array(coefficientCount);\n }\n this.coefficentsMagnitude = coefficentsMagnitude;\n this.processingFlags = new Uint8Array(coefficientCount);\n\n const bitsDecoded = new Uint8Array(coefficientCount);\n if (zeroBitPlanes !== 0) {\n for (let i = 0; i < coefficientCount; i++) {\n bitsDecoded[i] = zeroBitPlanes;\n }\n }\n this.bitsDecoded = bitsDecoded;\n\n this.reset();\n }\n\n setDecoder(decoder) {\n this.decoder = decoder;\n }\n\n reset() {\n // We have 17 contexts that are accessed via context labels,\n // plus the uniform and runlength context.\n this.contexts = new Int8Array(19);\n\n // Contexts are packed into 1 byte:\n // highest 7 bits carry the index, lowest bit carries mps\n this.contexts[0] = (4 << 1) | 0;\n this.contexts[BitModel.UNIFORM_CONTEXT] = (46 << 1) | 0;\n this.contexts[BitModel.RUNLENGTH_CONTEXT] = (3 << 1) | 0;\n }\n\n setNeighborsSignificance(row, column, index) {\n const neighborsSignificance = this.neighborsSignificance;\n const width = this.width,\n height = this.height;\n const left = column > 0;\n const right = column + 1 < width;\n let i;\n\n if (row > 0) {\n i = index - width;\n if (left) {\n neighborsSignificance[i - 1] += 0x10;\n }\n if (right) {\n neighborsSignificance[i + 1] += 0x10;\n }\n neighborsSignificance[i] += 0x04;\n }\n\n if (row + 1 < height) {\n i = index + width;\n if (left) {\n neighborsSignificance[i - 1] += 0x10;\n }\n if (right) {\n neighborsSignificance[i + 1] += 0x10;\n }\n neighborsSignificance[i] += 0x04;\n }\n\n if (left) {\n neighborsSignificance[index - 1] += 0x01;\n }\n if (right) {\n neighborsSignificance[index + 1] += 0x01;\n }\n neighborsSignificance[index] |= 0x80;\n }\n\n runSignificancePropagationPass() {\n const decoder = this.decoder;\n const width = this.width,\n height = this.height;\n const coefficentsMagnitude = this.coefficentsMagnitude;\n const coefficentsSign = this.coefficentsSign;\n const neighborsSignificance = this.neighborsSignificance;\n const processingFlags = this.processingFlags;\n const contexts = this.contexts;\n const labels = this.contextLabelTable;\n const bitsDecoded = this.bitsDecoded;\n const processedInverseMask = ~1;\n const processedMask = 1;\n const firstMagnitudeBitMask = 2;\n\n for (let i0 = 0; i0 < height; i0 += 4) {\n for (let j = 0; j < width; j++) {\n let index = i0 * width + j;\n for (let i1 = 0; i1 < 4; i1++, index += width) {\n const i = i0 + i1;\n if (i >= height) {\n break;\n }\n // clear processed flag first\n processingFlags[index] &= processedInverseMask;\n\n if (coefficentsMagnitude[index] || !neighborsSignificance[index]) {\n continue;\n }\n\n const contextLabel = labels[neighborsSignificance[index]];\n const decision = decoder.readBit(contexts, contextLabel);\n if (decision) {\n const sign = this.decodeSignBit(i, j, index);\n coefficentsSign[index] = sign;\n coefficentsMagnitude[index] = 1;\n this.setNeighborsSignificance(i, j, index);\n processingFlags[index] |= firstMagnitudeBitMask;\n }\n bitsDecoded[index]++;\n processingFlags[index] |= processedMask;\n }\n }\n }\n }\n\n decodeSignBit(row, column, index) {\n const width = this.width,\n height = this.height;\n const coefficentsMagnitude = this.coefficentsMagnitude;\n const coefficentsSign = this.coefficentsSign;\n let contribution, sign0, sign1, significance1;\n let contextLabel, decoded;\n\n // calculate horizontal contribution\n significance1 = column > 0 && coefficentsMagnitude[index - 1] !== 0;\n if (column + 1 < width && coefficentsMagnitude[index + 1] !== 0) {\n sign1 = coefficentsSign[index + 1];\n if (significance1) {\n sign0 = coefficentsSign[index - 1];\n contribution = 1 - sign1 - sign0;\n } else {\n contribution = 1 - sign1 - sign1;\n }\n } else if (significance1) {\n sign0 = coefficentsSign[index - 1];\n contribution = 1 - sign0 - sign0;\n } else {\n contribution = 0;\n }\n const horizontalContribution = 3 * contribution;\n\n // calculate vertical contribution and combine with the horizontal\n significance1 = row > 0 && coefficentsMagnitude[index - width] !== 0;\n if (row + 1 < height && coefficentsMagnitude[index + width] !== 0) {\n sign1 = coefficentsSign[index + width];\n if (significance1) {\n sign0 = coefficentsSign[index - width];\n contribution = 1 - sign1 - sign0 + horizontalContribution;\n } else {\n contribution = 1 - sign1 - sign1 + horizontalContribution;\n }\n } else if (significance1) {\n sign0 = coefficentsSign[index - width];\n contribution = 1 - sign0 - sign0 + horizontalContribution;\n } else {\n contribution = horizontalContribution;\n }\n\n if (contribution >= 0) {\n contextLabel = 9 + contribution;\n decoded = this.decoder.readBit(this.contexts, contextLabel);\n } else {\n contextLabel = 9 - contribution;\n decoded = this.decoder.readBit(this.contexts, contextLabel) ^ 1;\n }\n return decoded;\n }\n\n runMagnitudeRefinementPass() {\n const decoder = this.decoder;\n const width = this.width,\n height = this.height;\n const coefficentsMagnitude = this.coefficentsMagnitude;\n const neighborsSignificance = this.neighborsSignificance;\n const contexts = this.contexts;\n const bitsDecoded = this.bitsDecoded;\n const processingFlags = this.processingFlags;\n const processedMask = 1;\n const firstMagnitudeBitMask = 2;\n const length = width * height;\n const width4 = width * 4;\n\n for (let index0 = 0, indexNext; index0 < length; index0 = indexNext) {\n indexNext = Math.min(length, index0 + width4);\n for (let j = 0; j < width; j++) {\n for (let index = index0 + j; index < indexNext; index += width) {\n // significant but not those that have just become\n if (\n !coefficentsMagnitude[index] ||\n (processingFlags[index] & processedMask) !== 0\n ) {\n continue;\n }\n\n let contextLabel = 16;\n if ((processingFlags[index] & firstMagnitudeBitMask) !== 0) {\n processingFlags[index] ^= firstMagnitudeBitMask;\n // first refinement\n const significance = neighborsSignificance[index] & 127;\n contextLabel = significance === 0 ? 15 : 14;\n }\n\n const bit = decoder.readBit(contexts, contextLabel);\n coefficentsMagnitude[index] =\n (coefficentsMagnitude[index] << 1) | bit;\n bitsDecoded[index]++;\n processingFlags[index] |= processedMask;\n }\n }\n }\n }\n\n runCleanupPass() {\n const decoder = this.decoder;\n const width = this.width,\n height = this.height;\n const neighborsSignificance = this.neighborsSignificance;\n const coefficentsMagnitude = this.coefficentsMagnitude;\n const coefficentsSign = this.coefficentsSign;\n const contexts = this.contexts;\n const labels = this.contextLabelTable;\n const bitsDecoded = this.bitsDecoded;\n const processingFlags = this.processingFlags;\n const processedMask = 1;\n const firstMagnitudeBitMask = 2;\n const oneRowDown = width;\n const twoRowsDown = width * 2;\n const threeRowsDown = width * 3;\n let iNext;\n for (let i0 = 0; i0 < height; i0 = iNext) {\n iNext = Math.min(i0 + 4, height);\n const indexBase = i0 * width;\n const checkAllEmpty = i0 + 3 < height;\n for (let j = 0; j < width; j++) {\n const index0 = indexBase + j;\n // using the property: labels[neighborsSignificance[index]] === 0\n // when neighborsSignificance[index] === 0\n const allEmpty =\n checkAllEmpty &&\n processingFlags[index0] === 0 &&\n processingFlags[index0 + oneRowDown] === 0 &&\n processingFlags[index0 + twoRowsDown] === 0 &&\n processingFlags[index0 + threeRowsDown] === 0 &&\n neighborsSignificance[index0] === 0 &&\n neighborsSignificance[index0 + oneRowDown] === 0 &&\n neighborsSignificance[index0 + twoRowsDown] === 0 &&\n neighborsSignificance[index0 + threeRowsDown] === 0;\n let i1 = 0,\n index = index0;\n let i = i0,\n sign;\n if (allEmpty) {\n const hasSignificantCoefficent = decoder.readBit(\n contexts,\n BitModel.RUNLENGTH_CONTEXT\n );\n if (!hasSignificantCoefficent) {\n bitsDecoded[index0]++;\n bitsDecoded[index0 + oneRowDown]++;\n bitsDecoded[index0 + twoRowsDown]++;\n bitsDecoded[index0 + threeRowsDown]++;\n continue; // next column\n }\n i1 =\n (decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT) << 1) |\n decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT);\n if (i1 !== 0) {\n i = i0 + i1;\n index += i1 * width;\n }\n\n sign = this.decodeSignBit(i, j, index);\n coefficentsSign[index] = sign;\n coefficentsMagnitude[index] = 1;\n this.setNeighborsSignificance(i, j, index);\n processingFlags[index] |= firstMagnitudeBitMask;\n\n index = index0;\n for (let i2 = i0; i2 <= i; i2++, index += width) {\n bitsDecoded[index]++;\n }\n\n i1++;\n }\n for (i = i0 + i1; i < iNext; i++, index += width) {\n if (\n coefficentsMagnitude[index] ||\n (processingFlags[index] & processedMask) !== 0\n ) {\n continue;\n }\n\n const contextLabel = labels[neighborsSignificance[index]];\n const decision = decoder.readBit(contexts, contextLabel);\n if (decision === 1) {\n sign = this.decodeSignBit(i, j, index);\n coefficentsSign[index] = sign;\n coefficentsMagnitude[index] = 1;\n this.setNeighborsSignificance(i, j, index);\n processingFlags[index] |= firstMagnitudeBitMask;\n }\n bitsDecoded[index]++;\n }\n }\n }\n }\n\n checkSegmentationSymbol() {\n const decoder = this.decoder;\n const contexts = this.contexts;\n const symbol =\n (decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT) << 3) |\n (decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT) << 2) |\n (decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT) << 1) |\n decoder.readBit(contexts, BitModel.UNIFORM_CONTEXT);\n if (symbol !== 0xa) {\n throw new JpxError(\"Invalid segmentation symbol\");\n }\n }\n}\n\n// Section F, Discrete wavelet transformation\nclass Transform {\n constructor() {\n if (this.constructor === Transform) {\n unreachable(\"Cannot initialize Transform.\");\n }\n }\n\n calculate(subbands, u0, v0) {\n let ll = subbands[0];\n for (let i = 1, ii = subbands.length; i < ii; i++) {\n ll = this.iterate(ll, subbands[i], u0, v0);\n }\n return ll;\n }\n\n extend(buffer, offset, size) {\n // Section F.3.7 extending... using max extension of 4\n let i1 = offset - 1,\n j1 = offset + 1;\n let i2 = offset + size - 2,\n j2 = offset + size;\n buffer[i1--] = buffer[j1++];\n buffer[j2++] = buffer[i2--];\n buffer[i1--] = buffer[j1++];\n buffer[j2++] = buffer[i2--];\n buffer[i1--] = buffer[j1++];\n buffer[j2++] = buffer[i2--];\n buffer[i1] = buffer[j1];\n buffer[j2] = buffer[i2];\n }\n\n filter(x, offset, length) {\n unreachable(\"Abstract method `filter` called\");\n }\n\n iterate(ll, hl_lh_hh, u0, v0) {\n const llWidth = ll.width,\n llHeight = ll.height;\n let llItems = ll.items;\n const width = hl_lh_hh.width;\n const height = hl_lh_hh.height;\n const items = hl_lh_hh.items;\n let i, j, k, l, u, v;\n\n // Interleave LL according to Section F.3.3\n for (k = 0, i = 0; i < llHeight; i++) {\n l = i * 2 * width;\n for (j = 0; j < llWidth; j++, k++, l += 2) {\n items[l] = llItems[k];\n }\n }\n // The LL band is not needed anymore.\n llItems = ll.items = null;\n\n const bufferPadding = 4;\n const rowBuffer = new Float32Array(width + 2 * bufferPadding);\n\n // Section F.3.4 HOR_SR\n if (width === 1) {\n // if width = 1, when u0 even keep items as is, when odd divide by 2\n if ((u0 & 1) !== 0) {\n for (v = 0, k = 0; v < height; v++, k += width) {\n items[k] *= 0.5;\n }\n }\n } else {\n for (v = 0, k = 0; v < height; v++, k += width) {\n rowBuffer.set(items.subarray(k, k + width), bufferPadding);\n\n this.extend(rowBuffer, bufferPadding, width);\n this.filter(rowBuffer, bufferPadding, width);\n\n items.set(rowBuffer.subarray(bufferPadding, bufferPadding + width), k);\n }\n }\n\n // Accesses to the items array can take long, because it may not fit into\n // CPU cache and has to be fetched from main memory. Since subsequent\n // accesses to the items array are not local when reading columns, we\n // have a cache miss every time. To reduce cache misses, get up to\n // 'numBuffers' items at a time and store them into the individual\n // buffers. The colBuffers should be small enough to fit into CPU cache.\n let numBuffers = 16;\n const colBuffers = [];\n for (i = 0; i < numBuffers; i++) {\n colBuffers.push(new Float32Array(height + 2 * bufferPadding));\n }\n let b,\n currentBuffer = 0;\n ll = bufferPadding + height;\n\n // Section F.3.5 VER_SR\n if (height === 1) {\n // if height = 1, when v0 even keep items as is, when odd divide by 2\n if ((v0 & 1) !== 0) {\n for (u = 0; u < width; u++) {\n items[u] *= 0.5;\n }\n }\n } else {\n for (u = 0; u < width; u++) {\n // if we ran out of buffers, copy several image columns at once\n if (currentBuffer === 0) {\n numBuffers = Math.min(width - u, numBuffers);\n for (k = u, l = bufferPadding; l < ll; k += width, l++) {\n for (b = 0; b < numBuffers; b++) {\n colBuffers[b][l] = items[k + b];\n }\n }\n currentBuffer = numBuffers;\n }\n\n currentBuffer--;\n const buffer = colBuffers[currentBuffer];\n this.extend(buffer, bufferPadding, height);\n this.filter(buffer, bufferPadding, height);\n\n // If this is last buffer in this group of buffers, flush all buffers.\n if (currentBuffer === 0) {\n k = u - numBuffers + 1;\n for (l = bufferPadding; l < ll; k += width, l++) {\n for (b = 0; b < numBuffers; b++) {\n items[k + b] = colBuffers[b][l];\n }\n }\n }\n }\n }\n\n return { width, height, items };\n }\n}\n\n// Section 3.8.2 Irreversible 9-7 filter\nclass IrreversibleTransform extends Transform {\n filter(x, offset, length) {\n const len = length >> 1;\n offset |= 0;\n let j, n, current, next;\n\n const alpha = -1.586134342059924;\n const beta = -0.052980118572961;\n const gamma = 0.882911075530934;\n const delta = 0.443506852043971;\n const K = 1.230174104914001;\n const K_ = 1 / K;\n\n // step 1 is combined with step 3\n\n // step 2\n j = offset - 3;\n for (n = len + 4; n--; j += 2) {\n x[j] *= K_;\n }\n\n // step 1 & 3\n j = offset - 2;\n current = delta * x[j - 1];\n for (n = len + 3; n--; j += 2) {\n next = delta * x[j + 1];\n x[j] = K * x[j] - current - next;\n if (n--) {\n j += 2;\n current = delta * x[j + 1];\n x[j] = K * x[j] - current - next;\n } else {\n break;\n }\n }\n\n // step 4\n j = offset - 1;\n current = gamma * x[j - 1];\n for (n = len + 2; n--; j += 2) {\n next = gamma * x[j + 1];\n x[j] -= current + next;\n if (n--) {\n j += 2;\n current = gamma * x[j + 1];\n x[j] -= current + next;\n } else {\n break;\n }\n }\n\n // step 5\n j = offset;\n current = beta * x[j - 1];\n for (n = len + 1; n--; j += 2) {\n next = beta * x[j + 1];\n x[j] -= current + next;\n if (n--) {\n j += 2;\n current = beta * x[j + 1];\n x[j] -= current + next;\n } else {\n break;\n }\n }\n\n // step 6\n if (len !== 0) {\n j = offset + 1;\n current = alpha * x[j - 1];\n for (n = len; n--; j += 2) {\n next = alpha * x[j + 1];\n x[j] -= current + next;\n if (n--) {\n j += 2;\n current = alpha * x[j + 1];\n x[j] -= current + next;\n } else {\n break;\n }\n }\n }\n }\n}\n\n// Section 3.8.1 Reversible 5-3 filter\nclass ReversibleTransform extends Transform {\n filter(x, offset, length) {\n const len = length >> 1;\n offset |= 0;\n let j, n;\n\n for (j = offset, n = len + 1; n--; j += 2) {\n x[j] -= (x[j - 1] + x[j + 1] + 2) >> 2;\n }\n\n for (j = offset + 1, n = len; n--; j += 2) {\n x[j] += (x[j - 1] + x[j + 1]) >> 1;\n }\n }\n}\n\nexport { JpxImage };\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __w_pdfjs_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __w_pdfjs_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","/* Copyright 2018 Mozilla Foundation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { getVerbosityLevel, setVerbosityLevel } from \"./shared/util.js\";\nimport { Jbig2Image } from \"./core/jbig2.js\";\nimport { JpegImage } from \"./core/jpg.js\";\nimport { JpxImage } from \"./core/jpx.js\";\n\n/* eslint-disable-next-line no-unused-vars */\nconst pdfjsVersion =\n typeof PDFJSDev !== \"undefined\" ? PDFJSDev.eval(\"BUNDLE_VERSION\") : void 0;\n/* eslint-disable-next-line no-unused-vars */\nconst pdfjsBuild =\n typeof PDFJSDev !== \"undefined\" ? PDFJSDev.eval(\"BUNDLE_BUILD\") : void 0;\n\nexport {\n getVerbosityLevel,\n Jbig2Image,\n JpegImage,\n JpxImage,\n setVerbosityLevel,\n};\n"],"names":["isNodeJS","process","versions","nw","electron","type","exports","IDENTITY_MATRIX","FONT_IDENTITY_MATRIX","MAX_IMAGE_SIZE_TO_CACHE","LINE_FACTOR","LINE_DESCENT_FACTOR","BASELINE_FACTOR","RenderingIntentFlag","ANY","DISPLAY","PRINT","SAVE","ANNOTATIONS_FORMS","ANNOTATIONS_STORAGE","ANNOTATIONS_DISABLE","OPLIST","AnnotationMode","DISABLE","ENABLE","ENABLE_FORMS","ENABLE_STORAGE","AnnotationEditorPrefix","AnnotationEditorType","NONE","FREETEXT","STAMP","INK","AnnotationEditorParamsType","RESIZE","CREATE","FREETEXT_SIZE","FREETEXT_COLOR","FREETEXT_OPACITY","INK_COLOR","INK_THICKNESS","INK_OPACITY","PermissionFlag","MODIFY_CONTENTS","COPY","MODIFY_ANNOTATIONS","FILL_INTERACTIVE_FORMS","COPY_FOR_ACCESSIBILITY","ASSEMBLE","PRINT_HIGH_QUALITY","TextRenderingMode","FILL","STROKE","FILL_STROKE","INVISIBLE","FILL_ADD_TO_PATH","STROKE_ADD_TO_PATH","FILL_STROKE_ADD_TO_PATH","ADD_TO_PATH","FILL_STROKE_MASK","ADD_TO_PATH_FLAG","ImageKind","GRAYSCALE_1BPP","RGB_24BPP","RGBA_32BPP","AnnotationType","TEXT","LINK","LINE","SQUARE","CIRCLE","POLYGON","POLYLINE","HIGHLIGHT","UNDERLINE","SQUIGGLY","STRIKEOUT","CARET","POPUP","FILEATTACHMENT","SOUND","MOVIE","WIDGET","SCREEN","PRINTERMARK","TRAPNET","WATERMARK","THREED","REDACT","AnnotationReplyType","GROUP","REPLY","AnnotationFlag","HIDDEN","NOZOOM","NOROTATE","NOVIEW","READONLY","LOCKED","TOGGLENOVIEW","LOCKEDCONTENTS","AnnotationFieldFlag","REQUIRED","NOEXPORT","MULTILINE","PASSWORD","NOTOGGLETOOFF","RADIO","PUSHBUTTON","COMBO","EDIT","SORT","FILESELECT","MULTISELECT","DONOTSPELLCHECK","DONOTSCROLL","COMB","RICHTEXT","RADIOSINUNISON","COMMITONSELCHANGE","AnnotationBorderStyleType","SOLID","DASHED","BEVELED","INSET","AnnotationActionEventType","E","X","D","U","Fo","Bl","PO","PC","PV","PI","K","F","V","C","DocumentActionEventType","WC","WS","DS","WP","DP","PageActionEventType","O","VerbosityLevel","ERRORS","WARNINGS","INFOS","CMapCompressionType","BINARY","OPS","dependency","setLineWidth","setLineCap","setLineJoin","setMiterLimit","setDash","setRenderingIntent","setFlatness","setGState","save","restore","transform","moveTo","lineTo","curveTo","curveTo2","curveTo3","closePath","rectangle","stroke","closeStroke","fill","eoFill","fillStroke","eoFillStroke","closeFillStroke","closeEOFillStroke","endPath","clip","eoClip","beginText","endText","setCharSpacing","setWordSpacing","setHScale","setLeading","setFont","setTextRenderingMode","setTextRise","moveText","setLeadingMoveText","setTextMatrix","nextLine","showText","showSpacedText","nextLineShowText","nextLineSetSpacingShowText","setCharWidth","setCharWidthAndBounds","setStrokeColorSpace","setFillColorSpace","setStrokeColor","setStrokeColorN","setFillColor","setFillColorN","setStrokeGray","setFillGray","setStrokeRGBColor","setFillRGBColor","setStrokeCMYKColor","setFillCMYKColor","shadingFill","beginInlineImage","beginImageData","endInlineImage","paintXObject","markPoint","markPointProps","beginMarkedContent","beginMarkedContentProps","endMarkedContent","beginCompat","endCompat","paintFormXObjectBegin","paintFormXObjectEnd","beginGroup","endGroup","beginAnnotation","endAnnotation","paintImageMaskXObject","paintImageMaskXObjectGroup","paintImageXObject","paintInlineImageXObject","paintInlineImageXObjectGroup","paintImageXObjectRepeat","paintImageMaskXObjectRepeat","paintSolidColorImageMask","constructPath","PasswordResponses","NEED_PASSWORD","INCORRECT_PASSWORD","verbosity","setVerbosityLevel","level","Number","isInteger","getVerbosityLevel","info","msg","console","log","warn","unreachable","Error","assert","cond","_isValidProtocol","url","protocol","createValidAbsoluteUrl","baseUrl","options","addDefaultProtocol","startsWith","dots","match","length","tryConvertEncoding","stringToUTF8String","absoluteUrl","URL","shadow","obj","prop","value","nonSerializable","Object","defineProperty","enumerable","configurable","writable","BaseException","BaseExceptionClosure","message","name","constructor","prototype","PasswordException","code","UnknownErrorException","details","InvalidPDFException","MissingPDFException","UnexpectedResponseException","status","FormatError","AbortException","bytesToString","bytes","undefined","MAX_ARGUMENT_COUNT","String","fromCharCode","apply","strBuf","i","chunkEnd","Math","min","chunk","subarray","push","join","stringToBytes","str","Uint8Array","charCodeAt","string32","objectSize","keys","objectFromMap","map","create","key","isLittleEndian","buffer8","view32","Uint32Array","buffer","isEvalSupported","Function","FeatureTest","isOffscreenCanvasSupported","OffscreenCanvas","platform","navigator","isWin","isMac","includes","isCSSRoundSupported","globalThis","CSS","supports","hexNumbers","Array","n","toString","padStart","Util","makeHexColor","r","g","b","scaleMinMax","minMax","temp","m1","m2","applyTransform","p","m","xt","yt","applyInverseTransform","d","getAxialAlignedBoundingBox","p1","p2","slice","p3","p4","max","inverseTransform","singularValueDecompose2dScale","transpose","a","c","first","second","sqrt","sx","sy","normalizeRect","rect","intersect","rect1","rect2","xLow","xHigh","yLow","yHigh","bezierBoundingBox","x0","y0","x1","y1","x2","y2","x3","y3","tvalues","bounds","t","t1","t2","b2ac","sqrtb2ac","abs","j","mt","jlen","PDFStringTranslateTable","stringToPDFString","encoding","decoder","TextDecoder","fatal","decode","ex","ii","charAt","decodeURIComponent","escape","utf8StringToString","unescape","encodeURIComponent","isArrayBuffer","v","byteLength","isArrayEqual","arr1","arr2","getModificationDate","date","Date","getUTCFullYear","getUTCMonth","getUTCDate","getUTCHours","getUTCMinutes","getUTCSeconds","PromiseCapability","settled","promise","Promise","resolve","reject","data","reason","NormalizeRegex","NormalizationMap","normalizeUnicode","Map","replaceAll","_","normalize","get","getUuid","crypto","randomUUID","buf","getRandomValues","floor","random","AnnotationPrefix","_util","require","_core_utils","_arithmetic_decoder","_ccitt","Jbig2Error","ContextCache","getContexts","id","Int8Array","DecodingContext","start","end","ArithmeticDecoder","contextCache","cache","MAX_INT_32","MIN_INT_32","decodeInteger","procedure","contexts","prev","readBits","bit","readBit","sign","signedValue","decodeIAID","codeLength","SegmentTypes","CodingTemplates","x","y","RefinementTemplates","coding","reference","ReusedContexts","RefinementReusedContexts","decodeBitmapTemplate0","width","height","decodingContext","bitmap","contextLabel","pixel","row","row1","row2","OLD_PIXEL_MASK","decodeBitmap","mmr","templateIndex","prediction","skip","at","input","Reader","decodeMMRBitmap","useskip","template","concat","sort","templateLength","templateX","templateY","changingTemplateEntries","reuseMask","minX","maxX","minY","k","changingEntriesLength","changingTemplateX","changingTemplateY","changingTemplateBit","Uint16Array","sbb_left","sbb_top","sbb_right","pseudoPixelContext","ltp","i0","j0","shift","sltp","decodeRefinement","referenceBitmap","offsetX","offsetY","codingTemplate","codingTemplateLength","codingTemplateX","Int32Array","codingTemplateY","referenceTemplate","referenceTemplateLength","referenceTemplateX","referenceTemplateY","referenceWidth","referenceHeight","decodeSymbolDictionary","huffman","refinement","symbols","numberOfNewSymbols","numberOfExportedSymbols","huffmanTables","refinementTemplateIndex","refinementAt","huffmanInput","newSymbols","currentHeight","symbolCodeLength","log2","tableB1","symbolWidths","getStandardTable","deltaHeight","tableDeltaHeight","currentWidth","totalWidth","firstSymbol","deltaWidth","tableDeltaWidth","numberOfInstances","decodeTextRegion","symbolId","rdx","rdy","symbol","bitmapSize","tableBitmapSize","byteAlign","collectiveBitmap","readUncompressedBitmap","originalEnd","bitmapEnd","position","numberOfSymbolsDecoded","xMin","xMax","bitmapWidth","symbolBitmap","exportedSymbols","flags","currentFlag","totalSymbolsLength","runLength","defaultPixelValue","numberOfSymbolInstances","stripSize","inputSymbols","transposed","dsOffset","referenceCorner","combinationOperator","logStripSize","stripT","tableDeltaT","firstS","deltaT","deltaFirstS","tableFirstS","currentS","currentT","symbolIDTable","applyRefinement","symbolWidth","symbolHeight","rdw","rdh","offsetT","offsetS","s2","symbolRow","maxWidth","deltaS","tableDeltaS","decodePatternDictionary","patternWidth","patternHeight","maxPatternIndex","collectiveWidth","patterns","patternBitmap","decodeHalftoneRegion","regionWidth","regionHeight","enableSkip","gridWidth","gridHeight","gridOffsetX","gridOffsetY","gridVectorX","gridVectorY","regionBitmap","numberOfPatterns","pattern0","bitsPerValue","grayScaleBitPlanes","mmrInput","mg","ng","patternIndex","patternRow","regionRow","regionX","regionY","readSegmentHeader","segmentHeader","number","readUint32","segmentType","typeName","deferredNonRetain","pageAssociationFieldSize","referredFlags","referredToCount","retainBits","referredToSegmentNumberSize","referredTo","readUint16","pageAssociation","genericRegionInfo","readRegionSegmentInformation","genericRegionSegmentFlags","RegionSegmentInformationFieldLength","genericRegionMmr","searchPatternLength","searchPattern","headerEnd","readSegments","header","segments","segment","randomAccess","processSegment","visitor","args","atLength","dictionary","dictionaryFlags","huffmanDHSelector","huffmanDWSelector","bitmapSizeSelector","aggregationInstancesSelector","bitmapCodingContextUsed","bitmapCodingContextRetained","refinementTemplate","readInt8","textRegion","textRegionSegmentFlags","textRegionHuffmanFlags","huffmanFS","huffmanDS","huffmanDT","huffmanRefinementDW","huffmanRefinementDH","huffmanRefinementDX","huffmanRefinementDY","huffmanRefinementSizeSelector","patternDictionary","patternDictionaryFlags","halftoneRegion","halftoneRegionFlags","genericRegion","pageInfo","resolutionX","resolutionY","pageSegmentFlags","lossless","requiresBuffer","combinationOperatorOverride","callbackName","processSegments","parseJbig2Chunks","chunks","SimpleSegmentVisitor","parseJbig2","numberOfPages","currentPageInfo","bitPacked","imgData","Uint8ClampedArray","q","mask","onPageInformation","rowSize","drawBitmap","regionInfo","mask0","offset0","offset","onImmediateGenericRegion","region","onImmediateLosslessGenericRegion","arguments","onSymbolDictionary","currentSegment","referredSegments","getSymbolDictionaryHuffmanTables","customTables","referredSegment","referredSymbols","onImmediateTextRegion","getTextRegionHuffmanTables","onImmediateLosslessTextRegion","onPatternDictionary","onImmediateHalftoneRegion","onImmediateLosslessHalftoneRegion","onTables","decodeTablesSegment","HuffmanLine","lineData","isOOB","rangeLow","prefixLength","rangeLength","prefixCode","isLowerRange","HuffmanTreeNode","line","children","isLeaf","buildTree","node","decodeNode","reader","htOffset","HuffmanTable","lines","prefixCodesDone","assignPrefixCodes","rootNode","linesLength","prefixLengthMax","histogram","currentLength","firstCode","currentCode","currentTemp","lowestValue","highestValue","prefixSizeBits","rangeSizeBits","currentRangeLow","standardTablesCache","table","currentByte","numBits","result","next","getCustomHuffmanTable","index","currentIndex","numberOfSymbols","codes","runCodesTable","repeatedLength","numberOfRepeats","customIndex","tableAggregateInstances","endOfBlock","params","Columns","Rows","BlackIs1","EndOfBlock","CCITTFaxDecoder","eof","readNextChar","lookForEOFLimit","Jbig2Image","parseChunks","parse","_primitives","_base_stream","PDF_VERSION_REGEXP","getLookupTableFactory","initializer","lookup","MissingDataException","begin","ParserEOFException","XRefEntryException","XRefParseException","arrayBuffersToBytes","arr","dataLength","pos","item","set","getInheritableProperty","dict","getArray","stopWhenFound","values","visited","RefSet","Dict","objId","has","put","ROMAN_NUMBER_MAP","toRomanNumerals","lowerCase","romanBuf","romanStr","toLowerCase","ceil","isWhiteSpace","ch","parseXFAPath","path","positionPattern","split","component","parseInt","escapePDFName","char","substring","escapeString","_collectJS","entry","xref","list","parents","parent","Ref","fetch","isArray","element","isName","js","BaseStream","getString","getRaw","remove","collectActions","eventType","actions","additionalActionsDicts","additionalActions","getKeys","action","actionDict","Action","XMLEntities","encodeToXmlString","codePointAt","entity","toUpperCase","validateFontName","fontFamily","mustWarn","exec","re","RegExp","test","ident","validateCSSFont","cssFontInfo","DEFAULT_CSS_FONT_OBLIQUE","DEFAULT_CSS_FONT_WEIGHT","CSS_FONT_WEIGHT_VALUES","Set","fontWeight","italicAngle","weight","angle","parseFloat","isNaN","recoverJsURL","URL_OPEN_METHODS","regex","jsUrl","newWindow","numberToString","roundedValue","round","toFixed","getNewAnnotationsMap","annotationStorage","newAnnotationsByPage","annotations","pageIndex","size","isAscii","stringToUTF16HexString","stringToUTF16String","bigEndian","getRotationMatrix","rotation","CIRCULAR_REF","Symbol","EOF","CmdCache","NameCache","RefCache","clearPrimitiveCaches","Name","Cmd","cmd","nonSerializableClosure","_map","suppressEncryption","__nonSerializable__","assignXref","newXref","key1","key2","key3","getAsync","fetchAsync","getRawValues","forEach","callback","empty","emptyDict","merge","dictArray","mergeSubDicts","mergedDict","properties","entries","property","subDict","clear","clone","num","gen","fromString","ref","_set","add","delete","iterator","RefSetCache","putAlias","aliasRef","isCmd","isDict","isRefsEqual","v1","v2","isEmpty","isDataLoaded","getByte","getBytes","peekByte","peekedByte","peekBytes","getUint16","b0","b1","getInt32","b2","b3","getByteRange","reset","moveStart","makeSubStream","getBaseStreams","QeTable","qe","nmps","nlps","switchFlag","bp","dataEnd","chigh","clow","byteIn","ct","cx_index","cx_mps","qeTableIcx","qeIcx","ccittEOL","ccittEOF","twoDimPass","twoDimHoriz","twoDimVert0","twoDimVertR1","twoDimVertL1","twoDimVertR2","twoDimVertL2","twoDimVertR3","twoDimVertL3","twoDimTable","whiteTable1","whiteTable2","blackTable1","blackTable2","blackTable3","source","eoline","EndOfLine","EncodedByteAlign","columns","rows","eoblock","black","codingLine","refLine","codingPos","nextLine2D","inputBits","inputBuf","outputBits","rowsDone","code1","_lookBits","_eatBits","refPos","blackPixels","bits","err","code2","code3","_getTwoDimCode","_addPixels","_getBlackCode","_getWhiteCode","_addPixelsNeg","gotEOL","a1","_findTableCode","limit","limitValue","_image_utils","JpegError","DNLMarkerError","scanLines","EOIMarkerError","dctZigZag","dctCos1","dctSin1","dctCos3","dctSin3","dctCos6","dctSin6","dctSqrt2","dctSqrt1d2","buildHuffmanTable","codeLengths","pop","getBlockBufferOffset","col","blocksPerLine","decodeScan","frame","components","resetInterval","spectralStart","spectralEnd","successivePrev","successive","parseDNLMarker","mcusPerLine","progressive","startOffset","bitsData","bitsCount","nextByte","maybeScanLines","blockRow","precision","decodeHuffman","tree","receive","receiveAndExtend","decodeBaseline","blockOffset","huffmanTableDC","diff","blockData","pred","rs","huffmanTableAC","s","z","decodeDCFirst","decodeDCSuccessive","eobrun","decodeACFirst","e","successiveACState","successiveACNextValue","decodeACSuccessive","offsetZ","decodeMcu","mcu","mcuRow","mcuCol","blockCol","h","decodeBlock","componentsLength","decodeFn","fileMarker","mcuExpected","blocksPerColumn","mcusPerColumn","mcuToRead","findNextFileMarker","invalid","partialMsg","marker","quantizeAndInverse","blockBufferOffset","qt","quantizationTable","v0","v3","v4","v5","v6","v7","p0","p5","p6","p7","buildComponentData","computationBuffer","Int16Array","currentPos","startPos","maxPos","newPos","currentMarker","newMarker","JpegImage","decodeTransform","colorTransform","_decodeTransform","_colorTransform","dnlScanLines","readDataBlock","endOffset","array","prepareComponents","samplesPerLine","maxH","maxV","blocksPerLineForMcu","blocksPerColumnForMcu","blocksBufferSize","jfif","adobe","numSOSMarkers","quantizationTables","huffmanTablesAC","huffmanTablesDC","markerLoop","l","appData","version","major","minor","densityUnits","xDensity","yDensity","thumbWidth","thumbHeight","thumbData","flags0","flags1","transformCode","quantizationTablesLength","quantizationTablesEnd","quantizationTableSpec","tableData","extended","sofScanLines","componentIds","componentsCount","componentId","qId","quantizationId","huffmanLength","huffmanTableSpec","codeLengthSum","huffmanValues","selectorsCount","componentIndex","tableSpec","successiveApproximation","processed","nextFileMarker","output","scaleX","scaleY","numComponents","_getLinearizedBlockData","isSourcePDF","componentScaleX","componentScaleY","blocksPerScanline","xScaleBlockOffset","mask3LSB","lastComponentScaleX","_isColorConversionNeeded","_convertYccToRgb","Y","Cb","Cr","_convertYccToRgba","out","_convertYcckToRgb","_convertYcckToRgba","_convertYcckToCmyk","_convertCmykToRgb","_convertCmykToRgba","getData","forceRGBA","forceRGB","len","rgbaData","grayToRGBA","grayColor","convertToRGBA","kind","convertBlackAndWhiteToRGBA","convertRGBToRGBA","src","srcPos","dest","nonBlackColor","inverseDecode","zeroMapping","oneMapping","widthInSource","widthRemainder","srcLength","destPos","elem","len32","src32","s1","s3","jj","JpxError","SubbandsGainLog2","LL","LH","HL","HH","JpxImage","failOnCorruptedImage","head","parseCodestream","headerSize","lbox","tbox","jumpDataLength","method","colorspace","headerType","parseImageProperties","stream","newByte","oldByte","Xsiz","Ysiz","XOsiz","YOsiz","Csiz","bitsPerComponent","context","doNotRecover","sqcd","spqcds","spqcdSize","scalarExpounded","tile","mainHeader","siz","XTsiz","YTsiz","XTOsiz","YTOsiz","isSigned","XRsiz","YRsiz","calculateComponentDimensions","SIZ","calculateTileGrids","QCC","COC","qcd","noQuantization","guardBits","spqcd","epsilon","mu","SPqcds","QCD","currentTile","qcc","cqcc","cod","scod","entropyCoderWithCustomPrecincts","sopMarkerUsed","ephMarkerUsed","progressionOrder","layersCount","multipleComponentTransform","decompositionLevelsCount","xcb","ycb","blockStyle","selectiveArithmeticCodingBypass","resetContextProbabilities","terminationOnEachCodingPass","verticallyStripe","predictableTermination","segmentationSymbolUsed","reversibleTransformation","precinctsSizes","precinctsSize","PPx","PPy","unsupported","COD","partIndex","partsCount","initializeTile","buildPackets","parseTilePackets","tiles","transformComponents","numXtiles","numYtiles","tx0","ty0","tx1","ty1","tileComponent","tcx0","tcy0","tcx1","tcy1","getBlocksDimensions","codOrCoc","codingStyleParameters","xcb_","ycb_","buildPrecincts","resolution","dimensions","precinctWidth","precinctHeight","isZeroRes","resLevel","precinctWidthInSubband","precinctHeightInSubband","numprecinctswide","trx1","trx0","numprecinctshigh","try1","try0","numprecincts","precinctParameters","buildCodeblocks","subband","codeblockWidth","codeblockHeight","cbx0","tbx0","cby0","tby0","cbx1","tbx1","cby1","tby1","codeblocks","precincts","codeblock","precinctNumber","cbx","cby","tbx0_","tby0_","tbx1_","tby1_","pi","pj","subbandType","Lblock","precinct","cbxMin","cbxMax","cbyMin","cbyMax","codeblockParameters","numcodeblockwide","numcodeblockhigh","createPacket","layerNumber","precinctCodeblocks","subbands","LayerResolutionComponentPositionIterator","tileIndex","codingStyleDefaultParameters","maxDecompositionLevelsCount","nextPacket","JpxImage_nextPacket","resolutions","packet","ResolutionLayerComponentPositionIterator","ResolutionPositionComponentLayerIterator","maxNumPrecinctsInLevel","maxNumPrecincts","PositionComponentResolutionLayerIterator","getPrecinctSizesInImageScale","precinctsIterationSizes","px","py","maxNumHigh","maxNumWide","sizeInImageScale","getPrecinctIndexIfExist","ComponentPositionResolutionLayerIterator","pxIndex","pyIndex","precinctIterationSizes","posX","minWidth","posY","minHeight","startPrecinctRowIndex","MAX_VALUE","sizePerComponent","sizePerResolution","minWidthCurrentComponent","minHeightCurrentComponent","maxNumWideCurrentComponent","maxNumHighCurrentComponent","scale","widthCurrentResolution","heightCurrentResolution","blocksDimensions","bscale","resolutionSubbands","packetsIterator","bufferSize","skipNextBit","count","skipMarkerIfEqual","skipBytes","alignToByte","readCodingpasses","queue","codeblockColumn","codeblockRow","codeblockIncluded","firstTimeInclusion","valueReady","zeroBitPlanesTree","included","inclusionTree","InclusionTree","TagTree","nextLevel","incrementValue","zeroBitPlanes","codingpasses","codingpassesLog2","codedDataLength","packetItem","copyCoefficients","coefficients","levelWidth","levelHeight","delta","mb","reversible","right","bottom","blockWidth","blockHeight","bitModel","BitModel","currentCodingpassType","totalLength","dataItem","encodedData","setDecoder","runSignificancePropagationPass","runMagnitudeRefinementPass","runCleanupPass","checkSegmentationSymbol","coefficentsSign","magnitude","coefficentsMagnitude","bitsDecoded","magnitudeCorrection","nb","interleave","levelOffset","transformTile","quantizationParameters","ReversibleTransform","IrreversibleTransform","subbandCoefficients","Float32Array","gainLog2","items","calculate","left","top","resultImages","transformedTiles","tile0","fourComponents","y0items","y1items","y2items","y3items","component0","alpha01","qcdOrQcc","levelsLength","levels","currentLevel","defaultValue","stopValue","propagateValues","levelIndex","currentValue","UNIFORM_CONTEXT","RUNLENGTH_CONTEXT","LLAndLHContextsLabel","HLContextLabel","HHContextLabel","contextLabelTable","coefficientCount","neighborsSignificance","processingFlags","setNeighborsSignificance","column","labels","processedInverseMask","processedMask","firstMagnitudeBitMask","i1","decision","decodeSignBit","contribution","sign0","sign1","significance1","decoded","horizontalContribution","width4","index0","indexNext","significance","oneRowDown","twoRowsDown","threeRowsDown","iNext","indexBase","checkAllEmpty","allEmpty","hasSignificantCoefficent","i2","Transform","u0","ll","iterate","extend","j1","j2","filter","hl_lh_hh","llWidth","llHeight","llItems","u","bufferPadding","rowBuffer","numBuffers","colBuffers","currentBuffer","current","alpha","beta","gamma","K_","_jbig","_jpg","_jpx","pdfjsVersion","pdfjsBuild"],"sourceRoot":""} |