UNPKG

node-libpng

Version:

Unofficial bindings for node to libpng.

844 lines 111 kB
<!doctype html> <html class="default no-js"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>node-libpng</title> <meta name="description" content=""> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="assets/css/main.css"> </head> <body> <header> <div class="tsd-page-toolbar"> <div class="container"> <div class="table-wrap"> <div class="table-cell" id="tsd-search" data-index="assets/js/search.js" data-base="."> <div class="field"> <label for="tsd-search-field" class="tsd-widget search no-caption">Search</label> <input id="tsd-search-field" type="text" /> </div> <ul class="results"> <li class="state loading">Preparing search index...</li> <li class="state failure">The search index is not available</li> </ul> <a href="index.html" class="title">node-libpng</a> </div> <div class="table-cell" id="tsd-widgets"> <div id="tsd-filter"> <a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a> <div class="tsd-filter-group"> <div class="tsd-select" id="tsd-filter-visibility"> <span class="tsd-select-label">All</span> <ul class="tsd-select-list"> <li data-value="public">Public</li> <li data-value="protected">Public/Protected</li> <li data-value="private" class="selected">All</li> </ul> </div> <input type="checkbox" id="tsd-filter-inherited" checked /> <label class="tsd-widget" for="tsd-filter-inherited">Inherited</label> <input type="checkbox" id="tsd-filter-externals" checked /> <label class="tsd-widget" for="tsd-filter-externals">Externals</label> <input type="checkbox" id="tsd-filter-only-exported" /> <label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label> </div> </div> <a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a> </div> </div> </div> </div> <div class="tsd-page-title"> <div class="container"> <ul class="tsd-breadcrumb"> <li> <a href="globals.html">Globals</a> </li> </ul> <h1> node-libpng</h1> </div> </div> </header> <div class="container container-main"> <div class="row"> <div class="col-8 col-content"> <section class="tsd-panel-group tsd-index-group"> <h2>Index</h2> <section class="tsd-panel tsd-index-panel"> <div class="tsd-index-content"> <section class="tsd-index-section "> <h3>Enumerations</h3> <ul class="tsd-index-list"> <li class="tsd-kind-enum"><a href="enums/colortype.html" class="tsd-kind-icon">Color<wbr>Type</a></li> <li class="tsd-kind-enum"><a href="enums/interlacetype.html" class="tsd-kind-icon">Interlace<wbr>Type</a></li> </ul> </section> <section class="tsd-index-section "> <h3>Classes</h3> <ul class="tsd-index-list"> <li class="tsd-kind-class"><a href="classes/pngimage.html" class="tsd-kind-icon">Png<wbr>Image</a></li> </ul> </section> <section class="tsd-index-section "> <h3>Interfaces</h3> <ul class="tsd-index-list"> <li class="tsd-kind-interface"><a href="interfaces/encodeoptions.html" class="tsd-kind-icon">Encode<wbr>Options</a></li> <li class="tsd-kind-interface"><a href="interfaces/resizecanvasarguments.html" class="tsd-kind-icon">Resize<wbr>Canvas<wbr>Arguments</a></li> </ul> </section> <section class="tsd-index-section "> <h3>Type aliases</h3> <ul class="tsd-index-list"> <li class="tsd-kind-type-alias"><a href="globals.html#colorany" class="tsd-kind-icon">Color<wbr>Any</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colorgrayscale" class="tsd-kind-icon">Color<wbr>Gray<wbr>Scale</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colorgrayscalealpha" class="tsd-kind-icon">Color<wbr>Gray<wbr>Scale<wbr>Alpha</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colornoalpha" class="tsd-kind-icon">Color<wbr>NoAlpha</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colorpalette" class="tsd-kind-icon">Color<wbr>Palette</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colorrgb" class="tsd-kind-icon">ColorRGB</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#colorrgba" class="tsd-kind-icon">ColorRGBA</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#palette" class="tsd-kind-icon">Palette</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#readpngfilecallback" class="tsd-kind-icon">Read<wbr>Png<wbr>File<wbr>Callback</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#rect" class="tsd-kind-icon">Rect</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#writepngfilecallback" class="tsd-kind-icon">Write<wbr>Png<wbr>File<wbr>Callback</a></li> <li class="tsd-kind-type-alias"><a href="globals.html#xy" class="tsd-kind-icon">XY</a></li> </ul> </section> <section class="tsd-index-section "> <h3>Variables</h3> <ul class="tsd-index-list"> <li class="tsd-kind-variable"><a href="globals.html#__native_pngimage" class="tsd-kind-icon">__native_<wbr><wbr>Png<wbr>Image</a></li> <li class="tsd-kind-variable"><a href="globals.html#__native_copy" class="tsd-kind-icon">__native_<wbr>copy</a></li> <li class="tsd-kind-variable"><a href="globals.html#__native_encode" class="tsd-kind-icon">__native_<wbr>encode</a></li> <li class="tsd-kind-variable"><a href="globals.html#__native_fill" class="tsd-kind-icon">__native_<wbr>fill</a></li> <li class="tsd-kind-variable"><a href="globals.html#__native_ispng" class="tsd-kind-icon">__native_<wbr>is<wbr>Png</a></li> <li class="tsd-kind-variable"><a href="globals.html#__native_resize" class="tsd-kind-icon">__native_<wbr>resize</a></li> </ul> </section> <section class="tsd-index-section "> <h3>Functions</h3> <ul class="tsd-index-list"> <li class="tsd-kind-function"><a href="globals.html#colorgrayscale" class="tsd-kind-icon">color<wbr>Gray<wbr>Scale</a></li> <li class="tsd-kind-function"><a href="globals.html#colorgrayscalealpha" class="tsd-kind-icon">color<wbr>Gray<wbr>Scale<wbr>Alpha</a></li> <li class="tsd-kind-function"><a href="globals.html#colorpalette" class="tsd-kind-icon">color<wbr>Palette</a></li> <li class="tsd-kind-function"><a href="globals.html#colorrgb" class="tsd-kind-icon">colorRGB</a></li> <li class="tsd-kind-function"><a href="globals.html#colorrgba" class="tsd-kind-icon">colorRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#colortypetocolorchecker" class="tsd-kind-icon">color<wbr>Type<wbr>ToColor<wbr>Checker</a></li> <li class="tsd-kind-function"><a href="globals.html#convertgrayscalealphatorgba" class="tsd-kind-icon">convert<wbr>Gray<wbr>Scale<wbr>Alpha<wbr>ToRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#convertgrayscaletorgba" class="tsd-kind-icon">convert<wbr>Gray<wbr>Scale<wbr>ToRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#convertnativebackgroundcolor" class="tsd-kind-icon">convert<wbr>Native<wbr>Background<wbr>Color</a></li> <li class="tsd-kind-function tsd-is-not-exported"><a href="globals.html#convertnativepalette" class="tsd-kind-icon">convert<wbr>Native<wbr>Palette</a></li> <li class="tsd-kind-function"><a href="globals.html#convertnativetime" class="tsd-kind-icon">convert<wbr>Native<wbr>Time</a></li> <li class="tsd-kind-function"><a href="globals.html#convertpalettetorgba" class="tsd-kind-icon">convert<wbr>Palette<wbr>ToRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#convertrgbtorgba" class="tsd-kind-icon">convertRGBToRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#converttorgba" class="tsd-kind-icon">convert<wbr>ToRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#decode" class="tsd-kind-icon">decode</a></li> <li class="tsd-kind-function"><a href="globals.html#defaultbackgroundcolor" class="tsd-kind-icon">default<wbr>Background<wbr>Color</a></li> <li class="tsd-kind-function"><a href="globals.html#encode" class="tsd-kind-icon">encode</a></li> <li class="tsd-kind-function"><a href="globals.html#expecteverypixel" class="tsd-kind-icon">expect<wbr>Every<wbr>Pixel</a></li> <li class="tsd-kind-function"><a href="globals.html#expectredbluegradient" class="tsd-kind-icon">expect<wbr>Red<wbr>Blue<wbr>Gradient</a></li> <li class="tsd-kind-function"><a href="globals.html#iscolorgrayscale" class="tsd-kind-icon">is<wbr>Color<wbr>Gray<wbr>Scale</a></li> <li class="tsd-kind-function"><a href="globals.html#iscolorgrayscalealpha" class="tsd-kind-icon">is<wbr>Color<wbr>Gray<wbr>Scale<wbr>Alpha</a></li> <li class="tsd-kind-function"><a href="globals.html#iscolorpalette" class="tsd-kind-icon">is<wbr>Color<wbr>Palette</a></li> <li class="tsd-kind-function"><a href="globals.html#iscolorrgb" class="tsd-kind-icon">is<wbr>ColorRGB</a></li> <li class="tsd-kind-function"><a href="globals.html#iscolorrgba" class="tsd-kind-icon">is<wbr>ColorRGBA</a></li> <li class="tsd-kind-function"><a href="globals.html#ispng" class="tsd-kind-icon">is<wbr>Png</a></li> <li class="tsd-kind-function"><a href="globals.html#isrect" class="tsd-kind-icon">is<wbr>Rect</a></li> <li class="tsd-kind-function"><a href="globals.html#isxy" class="tsd-kind-icon">isXY</a></li> <li class="tsd-kind-function"><a href="globals.html#readpngfile" class="tsd-kind-icon">read<wbr>Png<wbr>File</a></li> <li class="tsd-kind-function"><a href="globals.html#readpngfilesync" class="tsd-kind-icon">read<wbr>Png<wbr>File<wbr>Sync</a></li> <li class="tsd-kind-function"><a href="globals.html#rect" class="tsd-kind-icon">rect</a></li> <li class="tsd-kind-function"><a href="globals.html#writepngfile" class="tsd-kind-icon">write<wbr>Png<wbr>File</a></li> <li class="tsd-kind-function"><a href="globals.html#writepngfilesync" class="tsd-kind-icon">write<wbr>Png<wbr>File<wbr>Sync</a></li> <li class="tsd-kind-function"><a href="globals.html#xy" class="tsd-kind-icon">xy</a></li> </ul> </section> </div> </section> </section> <section class="tsd-panel-group tsd-member-group "> <h2>Type aliases</h2> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorany" class="tsd-anchor"></a> <h3>Color<wbr>Any</h3> <div class="tsd-signature tsd-kind-icon">Color<wbr>Any<span class="tsd-signature-symbol">:</span> <a href="globals.html#colorrgb" class="tsd-signature-type">ColorRGB</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorgrayscalealpha" class="tsd-signature-type">ColorGrayScaleAlpha</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorpalette" class="tsd-signature-type">ColorPalette</a></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/index.ts#L15">colors/index.ts:15</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorgrayscale" class="tsd-anchor"></a> <h3>Color<wbr>Gray<wbr>Scale</h3> <div class="tsd-signature tsd-kind-icon">Color<wbr>Gray<wbr>Scale<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale.ts#L8">colors/gray-scale.ts:8</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Represents a color of color type <code>ColorType.GRAY_SCALE</code>.</p> </div> <dl class="tsd-comment-tags"> <dt>see</dt> <dd><p>ColorType</p> </dd> </dl> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorgrayscalealpha" class="tsd-anchor"></a> <h3>Color<wbr>Gray<wbr>Scale<wbr>Alpha</h3> <div class="tsd-signature tsd-kind-icon">Color<wbr>Gray<wbr>Scale<wbr>Alpha<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale-alpha.ts#L8">colors/gray-scale-alpha.ts:8</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Represents a color of color type <code>ColorType.GRAY_SCALE_A</code>.</p> </div> <dl class="tsd-comment-tags"> <dt>see</dt> <dd><p>ColorType</p> </dd> </dl> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colornoalpha" class="tsd-anchor"></a> <h3>Color<wbr>NoAlpha</h3> <div class="tsd-signature tsd-kind-icon">Color<wbr>NoAlpha<span class="tsd-signature-symbol">:</span> <a href="globals.html#colorrgb" class="tsd-signature-type">ColorRGB</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#colorpalette" class="tsd-signature-type">ColorPalette</a></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/index.ts#L16">colors/index.ts:16</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorpalette" class="tsd-anchor"></a> <h3>Color<wbr>Palette</h3> <div class="tsd-signature tsd-kind-icon">Color<wbr>Palette<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/palette.ts#L14">colors/palette.ts:14</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Represents a color of color type <code>ColorType.PALETTE</code>.</p> </div> <dl class="tsd-comment-tags"> <dt>see</dt> <dd><p>ColorType</p> </dd> </dl> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorrgb" class="tsd-anchor"></a> <h3>ColorRGB</h3> <div class="tsd-signature tsd-kind-icon">ColorRGB<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/__tests__/utils.ts#L1">__tests__/utils.ts:1</a></li> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/rgb.ts#L8">colors/rgb.ts:8</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Represents a color of color type <code>ColorType.RGB</code>.</p> </div> <dl class="tsd-comment-tags"> <dt>see</dt> <dd><p>ColorType</p> </dd> </dl> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="colorrgba" class="tsd-anchor"></a> <h3>ColorRGBA</h3> <div class="tsd-signature tsd-kind-icon">ColorRGBA<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/__tests__/utils.ts#L2">__tests__/utils.ts:2</a></li> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/rgba.ts#L11">colors/rgba.ts:11</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Represents a color of color type <code>ColorType.RGBA</code>.</p> </div> <dl class="tsd-comment-tags"> <dt>see</dt> <dd><p>ColorType</p> </dd> </dl> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="palette" class="tsd-anchor"></a> <h3>Palette</h3> <div class="tsd-signature tsd-kind-icon">Palette<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Map</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><a href="globals.html#colorrgb" class="tsd-signature-type">ColorRGB</a><span class="tsd-signature-symbol">&gt;</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/palette.ts#L7">colors/palette.ts:7</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>A palette used by libpng to lookup colors in.</p> </div> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="readpngfilecallback" class="tsd-anchor"></a> <h3>Read<wbr>Png<wbr>File<wbr>Callback</h3> <div class="tsd-signature tsd-kind-icon">Read<wbr>Png<wbr>File<wbr>Callback<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">function</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/decode.ts#L15">decode.ts:15</a></li> </ul> </aside> <div class="tsd-type-declaration"> <h4>Type declaration</h4> <ul class="tsd-parameters"> <li class="tsd-parameter-siganture"> <ul class="tsd-signatures tsd-kind-type-literal tsd-parent-kind-type-alias tsd-is-not-exported"> <li class="tsd-signature tsd-kind-icon"><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Error</span>, pngImage<span class="tsd-signature-symbol">?: </span><a href="classes/pngimage.html" class="tsd-signature-type">PngImage</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>error: <span class="tsd-signature-type">Error</span></h5> </li> <li> <h5><span class="tsd-flag ts-flagOptional">Optional</span> pngImage: <a href="classes/pngimage.html" class="tsd-signature-type">PngImage</a></h5> </li> </ul> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4> </li> </ul> </li> </ul> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="rect" class="tsd-anchor"></a> <h3>Rect</h3> <div class="tsd-signature tsd-kind-icon">Rect<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/rect.ts#L3">rect.ts:3</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="writepngfilecallback" class="tsd-anchor"></a> <h3>Write<wbr>Png<wbr>File<wbr>Callback</h3> <div class="tsd-signature tsd-kind-icon">Write<wbr>Png<wbr>File<wbr>Callback<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">function</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/encode.ts#L51">encode.ts:51</a></li> </ul> </aside> <div class="tsd-type-declaration"> <h4>Type declaration</h4> <ul class="tsd-parameters"> <li class="tsd-parameter-siganture"> <ul class="tsd-signatures tsd-kind-type-literal tsd-parent-kind-type-alias tsd-is-not-exported"> <li class="tsd-signature tsd-kind-icon"><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Error</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>error: <span class="tsd-signature-type">Error</span></h5> </li> </ul> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4> </li> </ul> </li> </ul> </div> </section> <section class="tsd-panel tsd-member tsd-kind-type-alias"> <a name="xy" class="tsd-anchor"></a> <h3>XY</h3> <div class="tsd-signature tsd-kind-icon">XY<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol"> &amp; </span><span class="tsd-signature-type">object</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/xy.ts#L1">xy.ts:1</a></li> </ul> </aside> </section> </section> <section class="tsd-panel-group tsd-member-group "> <h2>Variables</h2> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_pngimage" class="tsd-anchor"></a> <h3>__native_<wbr><wbr>Png<wbr>Image</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr><wbr>Png<wbr>Image<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L12">native.ts:12</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_copy" class="tsd-anchor"></a> <h3>__native_<wbr>copy</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr>copy<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L16">native.ts:16</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_encode" class="tsd-anchor"></a> <h3>__native_<wbr>encode</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr>encode<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L13">native.ts:13</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_fill" class="tsd-anchor"></a> <h3>__native_<wbr>fill</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr>fill<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L17">native.ts:17</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_ispng" class="tsd-anchor"></a> <h3>__native_<wbr>is<wbr>Png</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr>is<wbr>Png<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L14">native.ts:14</a></li> </ul> </aside> </section> <section class="tsd-panel tsd-member tsd-kind-variable"> <a name="__native_resize" class="tsd-anchor"></a> <h3>__native_<wbr>resize</h3> <div class="tsd-signature tsd-kind-icon">__native_<wbr>resize<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/native.ts#L15">native.ts:15</a></li> </ul> </aside> </section> </section> <section class="tsd-panel-group tsd-member-group "> <h2>Functions</h2> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colorgrayscale" class="tsd-anchor"></a> <h3>color<wbr>Gray<wbr>Scale</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">color<wbr>Gray<wbr>Scale<span class="tsd-signature-symbol">(</span>gray<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale.ts#L17">colors/gray-scale.ts:17</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Create a new color of type <code>ColorGrayScale</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>gray: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>gray</code> part of the color.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a></h4> <p>The color in gray scale representation.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colorgrayscalealpha" class="tsd-anchor"></a> <h3>color<wbr>Gray<wbr>Scale<wbr>Alpha</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">color<wbr>Gray<wbr>Scale<wbr>Alpha<span class="tsd-signature-symbol">(</span>gray<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, a<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorgrayscalealpha" class="tsd-signature-type">ColorGrayScaleAlpha</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale-alpha.ts#L18">colors/gray-scale-alpha.ts:18</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Create a new color of type <code>gray scale</code> with alpha channel.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>gray: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>gray</code> part of the color.</p> </div> </li> <li> <h5>a: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the alpha channel part of the color.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorgrayscalealpha" class="tsd-signature-type">ColorGrayScaleAlpha</a></h4> <p>The color in gray scale with alpha channel representation.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colorpalette" class="tsd-anchor"></a> <h3>color<wbr>Palette</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">color<wbr>Palette<span class="tsd-signature-symbol">(</span>index<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorpalette" class="tsd-signature-type">ColorPalette</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/palette.ts#L23">colors/palette.ts:23</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Create a new color of type <code>ColorPalette</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>index: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the index on the palette.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorpalette" class="tsd-signature-type">ColorPalette</a></h4> <p>The color in palette representation.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colorrgb" class="tsd-anchor"></a> <h3>colorRGB</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">colorRGB<span class="tsd-signature-symbol">(</span>r<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, g<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, b<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorrgb" class="tsd-signature-type">ColorRGB</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/rgb.ts#L19">colors/rgb.ts:19</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Create a new color of type <code>number</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>r: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>red</code> part of the color.</p> </div> </li> <li> <h5>g: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>green</code> part of the color.</p> </div> </li> <li> <h5>b: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>blue</code> part of the color.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorrgb" class="tsd-signature-type">ColorRGB</a></h4> <p>The color in rgb representation.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colorrgba" class="tsd-anchor"></a> <h3>colorRGBA</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">colorRGBA<span class="tsd-signature-symbol">(</span>r<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, g<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, b<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, a<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/rgba.ts#L23">colors/rgba.ts:23</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Create a new color of type <code>number</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>r: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>red</code> part of the color.</p> </div> </li> <li> <h5>g: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>green</code> part of the color.</p> </div> </li> <li> <h5>b: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the <code>blue</code> part of the color.</p> </div> </li> <li> <h5>a: <span class="tsd-signature-type">number</span></h5> <div class="tsd-comment tsd-typography"> <p>The value for the alpha channel part of the color.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></h4> <p>The color in rgba representation.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="colortypetocolorchecker" class="tsd-anchor"></a> <h3>color<wbr>Type<wbr>ToColor<wbr>Checker</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">color<wbr>Type<wbr>ToColor<wbr>Checker<span class="tsd-signature-symbol">(</span>colorType<span class="tsd-signature-symbol">: </span><a href="enums/colortype.html" class="tsd-signature-type">ColorType</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#iscolorgrayscale" class="tsd-signature-type">isColorGrayScale</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#iscolorgrayscalealpha" class="tsd-signature-type">isColorGrayScaleAlpha</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#iscolorpalette" class="tsd-signature-type">isColorPalette</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#iscolorrgb" class="tsd-signature-type">isColorRGB</a><span class="tsd-signature-symbol"> | </span><a href="globals.html#iscolorrgba" class="tsd-signature-type">isColorRGBA</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/index.ts#L18">colors/index.ts:18</a></li> </ul> </aside> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>colorType: <a href="enums/colortype.html" class="tsd-signature-type">ColorType</a></h5> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#iscolorgrayscale" class="tsd-signature-type">isColorGrayScale</a> <span class="tsd-signature-symbol"> | </span> <a href="globals.html#iscolorgrayscalealpha" class="tsd-signature-type">isColorGrayScaleAlpha</a> <span class="tsd-signature-symbol"> | </span> <a href="globals.html#iscolorpalette" class="tsd-signature-type">isColorPalette</a> <span class="tsd-signature-symbol"> | </span> <a href="globals.html#iscolorrgb" class="tsd-signature-type">isColorRGB</a> <span class="tsd-signature-symbol"> | </span> <a href="globals.html#iscolorrgba" class="tsd-signature-type">isColorRGBA</a> </h4> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="convertgrayscalealphatorgba" class="tsd-anchor"></a> <h3>convert<wbr>Gray<wbr>Scale<wbr>Alpha<wbr>ToRGBA</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Gray<wbr>Scale<wbr>Alpha<wbr>ToRGBA<span class="tsd-signature-symbol">(</span>grayScaleAlpha<span class="tsd-signature-symbol">: </span><a href="globals.html#colorgrayscalealpha" class="tsd-signature-type">ColorGrayScaleAlpha</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale-alpha.ts#L47">colors/gray-scale-alpha.ts:47</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Converts a color of type <code>ColorGrayScaleAlpha</code> to <code>ColorRGBA</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>grayScaleAlpha: <a href="globals.html#colorgrayscalealpha" class="tsd-signature-type">ColorGrayScaleAlpha</a></h5> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></h4> <p>The converted color in rgba format.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="convertgrayscaletorgba" class="tsd-anchor"></a> <h3>convert<wbr>Gray<wbr>Scale<wbr>ToRGBA</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Gray<wbr>Scale<wbr>ToRGBA<span class="tsd-signature-symbol">(</span>grayScaleAlpha<span class="tsd-signature-symbol">: </span><a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/colors/gray-scale.ts#L44">colors/gray-scale.ts:44</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Converts a color of type <code>ColorGrayScale</code> to <code>ColorRGBA</code>.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>grayScaleAlpha: <a href="globals.html#colorgrayscale" class="tsd-signature-type">ColorGrayScale</a></h5> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colorrgba" class="tsd-signature-type">ColorRGBA</a></h4> <p>The converted color in rgba format.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="convertnativebackgroundcolor" class="tsd-anchor"></a> <h3>convert<wbr>Native<wbr>Background<wbr>Color</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Native<wbr>Background<wbr>Color<span class="tsd-signature-symbol">(</span>nativeBackgroundColor<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span>, colorType<span class="tsd-signature-symbol">: </span><a href="enums/colortype.html" class="tsd-signature-type">ColorType</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colornoalpha" class="tsd-signature-type">ColorNoAlpha</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/png-image.ts#L92">png-image.ts:92</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Converts the background color from the libpng bindings into a color.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>nativeBackgroundColor: <span class="tsd-signature-type">any</span></h5> <div class="tsd-comment tsd-typography"> <p>The background color as returned by the native bindings.</p> </div> </li> <li> <h5>colorType: <a href="enums/colortype.html" class="tsd-signature-type">ColorType</a></h5> <div class="tsd-comment tsd-typography"> <p>The color type of the image of which the background color should be converted.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#colornoalpha" class="tsd-signature-type">ColorNoAlpha</a></h4> <p>The converted background color in <code>ColorRGB</code>, <code>ColorPalette</code> or <code>ColorGrayScale</code> format or undefined if the background color was not set in the PNG.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function tsd-is-not-exported"> <a name="convertnativepalette" class="tsd-anchor"></a> <h3>convert<wbr>Native<wbr>Palette</h3> <ul class="tsd-signatures tsd-kind-function tsd-is-not-exported"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Native<wbr>Palette<span class="tsd-signature-symbol">(</span>nativePalette<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#palette" class="tsd-signature-type">Palette</a></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/png-image.ts#L120">png-image.ts:120</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Converts a native palette as returned by the bindings into a Map.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>nativePalette: <span class="tsd-signature-type">any</span></h5> <div class="tsd-comment tsd-typography"> <p>The native palette which should be converted.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <a href="globals.html#palette" class="tsd-signature-type">Palette</a></h4> <p>The palette as a <code>Palette</code> (Javascript Map with the key being the palette index and the value being a color.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="convertnativetime" class="tsd-anchor"></a> <h3>convert<wbr>Native<wbr>Time</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Native<wbr>Time<span class="tsd-signature-symbol">(</span>nativeTime<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Date</span></li> </ul> <ul class="tsd-descriptions"> <li class="tsd-description"> <aside class="tsd-sources"> <ul> <li>Defined in <a href="https://github.com/Prior99/node-libpng/blob/9e3e190/src/png-image.ts#L77">png-image.ts:77</a></li> </ul> </aside> <div class="tsd-comment tsd-typography"> <div class="lead"> <p>Converts the native time from the libpng bindings into a javascript <code>Date</code> object.</p> </div> </div> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameters"> <li> <h5>nativeTime: <span class="tsd-signature-type">any</span></h5> <div class="tsd-comment tsd-typography"> <p>The time as returned by the bindings.</p> </div> </li> </ul> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Date</span></h4> <p>The time converted to a javascript <code>Date</code> object or <code>undefined</code> if the time was not set in the PNG&#39;s header.</p> </li> </ul> </section> <section class="tsd-panel tsd-member tsd-kind-function"> <a name="convertpalettetorgba" class="tsd-anchor"></a> <h3>convert<wbr>Palette<wbr>ToRGBA</h3> <ul class="tsd-signatures tsd-kind-function"> <li class="tsd-signature tsd-kind-icon">convert<wbr>Palette<wbr>ToRGBA<span class="tsd-signature-symbol">(</span>color<span class="tsd-signature-symbol">: </span><a href="globals.html#colorpalette" class="tsd-signature-type">ColorPalette</a>, palette<span class="tsd-signature-symbol">: </span><a href="globals.html#palette" class="tsd-signature-type">Palette</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="globals.html#colorrgba" class="tsd-signature-