chillerlan-QRCode-Detector-FinderPattern.html 51 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Documentation</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <base href="../">
  8. <link rel="icon" href="images/favicon.ico"/>
  9. <link rel="stylesheet" href="css/normalize.css">
  10. <link rel="stylesheet" href="css/base.css">
  11. <link rel="preconnect" href="https://fonts.gstatic.com">
  12. <link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  13. <link href="https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;600;700&display=swap" rel="stylesheet">
  14. <link rel="stylesheet" href="css/template.css">
  15. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.0/css/all.min.css" integrity="sha256-ybRkN9dBjhcS2qrW1z+hfCxq+1aBdwyQM5wlQoQVt/0=" crossorigin="anonymous" />
  16. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/themes/prism-okaidia.css">
  17. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.css">
  18. <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.css">
  19. <script src="https://cdn.jsdelivr.net/npm/fuse.js@3.4.6"></script>
  20. <script src="https://cdn.jsdelivr.net/npm/css-vars-ponyfill@2"></script>
  21. <script src="js/search.js"></script>
  22. <script defer src="js/searchIndex.js"></script>
  23. </head>
  24. <body id="top">
  25. <header class="phpdocumentor-header phpdocumentor-section">
  26. <h1 class="phpdocumentor-title"><a href="" class="phpdocumentor-title__link">Documentation</a></h1>
  27. <input class="phpdocumentor-header__menu-button" type="checkbox" id="menu-button" name="menu-button" />
  28. <label class="phpdocumentor-header__menu-icon" for="menu-button">
  29. <i class="fas fa-bars"></i>
  30. </label>
  31. <section data-search-form class="phpdocumentor-search">
  32. <label>
  33. <span class="visually-hidden">Search for</span>
  34. <svg class="phpdocumentor-search__icon" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
  35. <circle cx="7.5" cy="7.5" r="6.5" stroke="currentColor" stroke-width="2"/>
  36. <line x1="12.4892" y1="12.2727" x2="19.1559" y2="18.9393" stroke="currentColor" stroke-width="3"/>
  37. </svg>
  38. <input type="search" class="phpdocumentor-field phpdocumentor-search__field" placeholder="Loading .." disabled />
  39. </label>
  40. </section>
  41. <nav class="phpdocumentor-topnav">
  42. <ul class="phpdocumentor-topnav__menu">
  43. <li class="phpdocumentor-topnav__menu-item -menu">
  44. <a href="https://php-qrcode.readthedocs.io">
  45. <span>
  46. User Manual
  47. </span>
  48. </a>
  49. </li>
  50. <li class="phpdocumentor-topnav__menu-item -social">
  51. <a href="https://github.com/chillerlan/php-qrcode">
  52. <span>
  53. <i class="fab fa-github"></i>
  54. </span>
  55. </a>
  56. </li>
  57. </ul>
  58. </nav>
  59. </header>
  60. <main class="phpdocumentor">
  61. <div class="phpdocumentor-section">
  62. <input class="phpdocumentor-sidebar__menu-button" type="checkbox" id="sidebar-button" name="sidebar-button" />
  63. <label class="phpdocumentor-sidebar__menu-icon" for="sidebar-button">
  64. Menu
  65. </label>
  66. <aside class="phpdocumentor-column -four phpdocumentor-sidebar">
  67. <section class="phpdocumentor-sidebar__category">
  68. <h2 class="phpdocumentor-sidebar__category-header">Namespaces</h2>
  69. <h4 class="phpdocumentor-sidebar__root-namespace">
  70. <a href="namespaces/chillerlan.html" class="">chillerlan</a>
  71. </h4>
  72. <ul class="phpdocumentor-list">
  73. <li>
  74. <a href="namespaces/chillerlan-qrcode.html" class="">QRCode</a>
  75. </li>
  76. <li>
  77. <a href="namespaces/chillerlan-qrcodetest.html" class="">QRCodeTest</a>
  78. </li>
  79. </ul>
  80. </section>
  81. <section class="phpdocumentor-sidebar__category">
  82. <h2 class="phpdocumentor-sidebar__category-header">Packages</h2>
  83. <h4 class="phpdocumentor-sidebar__root-namespace">
  84. <a href="packages/Application.html" class="">Application</a>
  85. </h4>
  86. </section>
  87. <section class="phpdocumentor-sidebar__category">
  88. <h2 class="phpdocumentor-sidebar__category-header">Reports</h2>
  89. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/deprecated.html">Deprecated</a></h3>
  90. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/errors.html">Errors</a></h3>
  91. <h3 class="phpdocumentor-sidebar__root-package"><a href="reports/markers.html">Markers</a></h3>
  92. </section>
  93. <section class="phpdocumentor-sidebar__category">
  94. <h2 class="phpdocumentor-sidebar__category-header">Indices</h2>
  95. <h3 class="phpdocumentor-sidebar__root-package"><a href="indices/files.html">Files</a></h3>
  96. </section>
  97. </aside>
  98. <div class="phpdocumentor-column -eight phpdocumentor-content">
  99. <ul class="phpdocumentor-breadcrumbs">
  100. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan.html">chillerlan</a></li>
  101. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode.html">QRCode</a></li>
  102. <li class="phpdocumentor-breadcrumb"><a href="namespaces/chillerlan-qrcode-detector.html">Detector</a></li>
  103. </ul>
  104. <article class="phpdocumentor-element -class">
  105. <h2 class="phpdocumentor-content__title">
  106. FinderPattern
  107. <span class="phpdocumentor-element__extends">
  108. extends <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html"><abbr title="\chillerlan\QRCode\Detector\ResultPoint">ResultPoint</abbr></a>
  109. </span>
  110. <div class="phpdocumentor-element__package">
  111. in package
  112. <ul class="phpdocumentor-breadcrumbs">
  113. <li class="phpdocumentor-breadcrumb"><a href="packages/Application.html">Application</a></li>
  114. </ul>
  115. </div>
  116. </h2>
  117. <aside class="phpdocumentor-element-found-in">
  118. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  119. :
  120. <span class="phpdocumentor-element-found-in__line">23</span>
  121. </aside>
  122. <p class="phpdocumentor-summary">Encapsulates a finder pattern, which are the three square patterns found in
  123. the corners of QR Codes. It also encapsulates a count of similar finder patterns,
  124. as a convenience to the finder&#039;s bookkeeping.</p>
  125. <h5 class="phpdocumentor-tag-list__heading" id="tags">
  126. Tags
  127. <a href="#tags" class="headerlink"><i class="fas fa-link"></i></a>
  128. </h5>
  129. <dl class="phpdocumentor-tag-list">
  130. <dt class="phpdocumentor-tag-list__entry">
  131. <span class="phpdocumentor-tag__name">author</span>
  132. </dt>
  133. <dd class="phpdocumentor-tag-list__definition">
  134. <section class="phpdocumentor-description"><p>Sean Owen</p>
  135. </section>
  136. </dd>
  137. </dl>
  138. <h3 id="toc">
  139. Table of Contents
  140. <a href="#toc" class="headerlink"><i class="fas fa-link"></i></a>
  141. </h3>
  142. <dl class="phpdocumentor-table-of-contents">
  143. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  144. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_estimatedModuleSize">$estimatedModuleSize</a>
  145. <span>
  146. &nbsp;: float </span>
  147. </dt>
  148. <dd></dd>
  149. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  150. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_x">$x</a>
  151. <span>
  152. &nbsp;: float </span>
  153. </dt>
  154. <dd></dd>
  155. <dt class="phpdocumentor-table-of-contents__entry -property -protected">
  156. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_y">$y</a>
  157. <span>
  158. &nbsp;: float </span>
  159. </dt>
  160. <dd></dd>
  161. <dt class="phpdocumentor-table-of-contents__entry -property -private">
  162. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#property_count">$count</a>
  163. <span>
  164. &nbsp;: int </span>
  165. </dt>
  166. <dd></dd>
  167. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  168. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method___construct">__construct()</a>
  169. <span>
  170. &nbsp;: mixed </span>
  171. </dt>
  172. <dd></dd>
  173. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  174. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_aboutEquals">aboutEquals()</a>
  175. <span>
  176. &nbsp;: bool </span>
  177. </dt>
  178. <dd>Determines if this finder pattern &quot;about equals&quot; a finder pattern at the stated
  179. position and size -- meaning, it is at nearly the same center with nearly the same size.</dd>
  180. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  181. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_combineEstimate">combineEstimate()</a>
  182. <span>
  183. &nbsp;: self </span>
  184. </dt>
  185. <dd>Combines this object&#039;s current estimate of a finder pattern position and module size
  186. with a new estimate. It returns a new FinderPattern containing a weighted average
  187. based on count.</dd>
  188. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  189. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_distance">distance()</a>
  190. <span>
  191. &nbsp;: float </span>
  192. </dt>
  193. <dd></dd>
  194. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  195. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getCount">getCount()</a>
  196. <span>
  197. &nbsp;: int </span>
  198. </dt>
  199. <dd></dd>
  200. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  201. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getDistance">getDistance()</a>
  202. <span>
  203. &nbsp;: float </span>
  204. </dt>
  205. <dd></dd>
  206. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  207. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getEstimatedModuleSize">getEstimatedModuleSize()</a>
  208. <span>
  209. &nbsp;: float </span>
  210. </dt>
  211. <dd></dd>
  212. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  213. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getSquaredDistance">getSquaredDistance()</a>
  214. <span>
  215. &nbsp;: float </span>
  216. </dt>
  217. <dd>Get square of distance between a and b.</dd>
  218. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  219. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getX">getX()</a>
  220. <span>
  221. &nbsp;: float </span>
  222. </dt>
  223. <dd></dd>
  224. <dt class="phpdocumentor-table-of-contents__entry -method -public">
  225. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getY">getY()</a>
  226. <span>
  227. &nbsp;: float </span>
  228. </dt>
  229. <dd></dd>
  230. <dt class="phpdocumentor-table-of-contents__entry -method -private">
  231. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_squaredDistance">squaredDistance()</a>
  232. <span>
  233. &nbsp;: float </span>
  234. </dt>
  235. <dd></dd>
  236. </dl>
  237. <section class="phpdocumentor-properties">
  238. <h3 class="phpdocumentor-elements__header" id="properties">
  239. Properties
  240. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
  241. </h3>
  242. <article
  243. class="
  244. phpdocumentor-element
  245. -property
  246. -protected
  247. "
  248. >
  249. <h4 class="phpdocumentor-element__name" id="property_estimatedModuleSize">
  250. $estimatedModuleSize
  251. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_estimatedModuleSize" class="headerlink"><i class="fas fa-link"></i></a>
  252. <span class="phpdocumentor-element__modifiers">
  253. </span>
  254. </h4>
  255. <aside class="phpdocumentor-element-found-in">
  256. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  257. :
  258. <span class="phpdocumentor-element-found-in__line">26</span>
  259. </aside>
  260. <code class="phpdocumentor-code phpdocumentor-signature ">
  261. <span class="phpdocumentor-signature__visibility">protected</span>
  262. <span class="phpdocumentor-signature__type">float</span>
  263. <span class="phpdocumentor-signature__name">$estimatedModuleSize</span>
  264. </code>
  265. <section class="phpdocumentor-description"></section>
  266. <section class="phpdocumentor-description"></section>
  267. </article>
  268. <article
  269. class="
  270. phpdocumentor-element
  271. -property
  272. -protected
  273. "
  274. >
  275. <h4 class="phpdocumentor-element__name" id="property_x">
  276. $x
  277. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_x" class="headerlink"><i class="fas fa-link"></i></a>
  278. <span class="phpdocumentor-element__modifiers">
  279. </span>
  280. </h4>
  281. <aside class="phpdocumentor-element-found-in">
  282. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  283. :
  284. <span class="phpdocumentor-element-found-in__line">24</span>
  285. </aside>
  286. <code class="phpdocumentor-code phpdocumentor-signature ">
  287. <span class="phpdocumentor-signature__visibility">protected</span>
  288. <span class="phpdocumentor-signature__type">float</span>
  289. <span class="phpdocumentor-signature__name">$x</span>
  290. </code>
  291. <section class="phpdocumentor-description"></section>
  292. <section class="phpdocumentor-description"></section>
  293. </article>
  294. <article
  295. class="
  296. phpdocumentor-element
  297. -property
  298. -protected
  299. "
  300. >
  301. <h4 class="phpdocumentor-element__name" id="property_y">
  302. $y
  303. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#property_y" class="headerlink"><i class="fas fa-link"></i></a>
  304. <span class="phpdocumentor-element__modifiers">
  305. </span>
  306. </h4>
  307. <aside class="phpdocumentor-element-found-in">
  308. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  309. :
  310. <span class="phpdocumentor-element-found-in__line">25</span>
  311. </aside>
  312. <code class="phpdocumentor-code phpdocumentor-signature ">
  313. <span class="phpdocumentor-signature__visibility">protected</span>
  314. <span class="phpdocumentor-signature__type">float</span>
  315. <span class="phpdocumentor-signature__name">$y</span>
  316. </code>
  317. <section class="phpdocumentor-description"></section>
  318. <section class="phpdocumentor-description"></section>
  319. </article>
  320. <article
  321. class="
  322. phpdocumentor-element
  323. -property
  324. -private
  325. "
  326. >
  327. <h4 class="phpdocumentor-element__name" id="property_count">
  328. $count
  329. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#property_count" class="headerlink"><i class="fas fa-link"></i></a>
  330. <span class="phpdocumentor-element__modifiers">
  331. </span>
  332. </h4>
  333. <aside class="phpdocumentor-element-found-in">
  334. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  335. :
  336. <span class="phpdocumentor-element-found-in__line">25</span>
  337. </aside>
  338. <code class="phpdocumentor-code phpdocumentor-signature ">
  339. <span class="phpdocumentor-signature__visibility">private</span>
  340. <span class="phpdocumentor-signature__type">int</span>
  341. <span class="phpdocumentor-signature__name">$count</span>
  342. </code>
  343. <section class="phpdocumentor-description"></section>
  344. <section class="phpdocumentor-description"></section>
  345. </article>
  346. </section>
  347. <section class="phpdocumentor-methods">
  348. <h3 class="phpdocumentor-elements__header" id="methods">
  349. Methods
  350. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
  351. </h3>
  352. <article
  353. class="phpdocumentor-element
  354. -method
  355. -public
  356. "
  357. >
  358. <h4 class="phpdocumentor-element__name" id="method___construct">
  359. __construct()
  360. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method___construct" class="headerlink"><i class="fas fa-link"></i></a>
  361. </h4>
  362. <aside class="phpdocumentor-element-found-in">
  363. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  364. :
  365. <span class="phpdocumentor-element-found-in__line">30</span>
  366. </aside>
  367. <code class="phpdocumentor-code phpdocumentor-signature ">
  368. <span class="phpdocumentor-signature__visibility">public</span>
  369. <span class="phpdocumentor-signature__name">__construct</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$posX</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$posY</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$estimatedModuleSize</span></span><span class="phpdocumentor-signature__argument"><span>[</span><span>, </span><span class="phpdocumentor-signature__argument__return-type">int&nbsp;</span><span class="phpdocumentor-signature__argument__name">$count</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">null</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
  370. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  371. <dl class="phpdocumentor-argument-list">
  372. <dt class="phpdocumentor-argument-list__entry">
  373. <span class="phpdocumentor-signature__argument__name">$posX</span>
  374. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  375. </dt>
  376. <dd class="phpdocumentor-argument-list__definition">
  377. <section class="phpdocumentor-description"></section>
  378. </dd>
  379. <dt class="phpdocumentor-argument-list__entry">
  380. <span class="phpdocumentor-signature__argument__name">$posY</span>
  381. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  382. </dt>
  383. <dd class="phpdocumentor-argument-list__definition">
  384. <section class="phpdocumentor-description"></section>
  385. </dd>
  386. <dt class="phpdocumentor-argument-list__entry">
  387. <span class="phpdocumentor-signature__argument__name">$estimatedModuleSize</span>
  388. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  389. </dt>
  390. <dd class="phpdocumentor-argument-list__definition">
  391. <section class="phpdocumentor-description"></section>
  392. </dd>
  393. <dt class="phpdocumentor-argument-list__entry">
  394. <span class="phpdocumentor-signature__argument__name">$count</span>
  395. : <span class="phpdocumentor-signature__argument__return-type">int</span>
  396. = <span class="phpdocumentor-signature__argument__default-value">null</span> </dt>
  397. <dd class="phpdocumentor-argument-list__definition">
  398. <section class="phpdocumentor-description"></section>
  399. </dd>
  400. </dl>
  401. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  402. <span class="phpdocumentor-signature__response_type">mixed</span>
  403. &mdash;
  404. </article>
  405. <article
  406. class="phpdocumentor-element
  407. -method
  408. -public
  409. "
  410. >
  411. <h4 class="phpdocumentor-element__name" id="method_aboutEquals">
  412. aboutEquals()
  413. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_aboutEquals" class="headerlink"><i class="fas fa-link"></i></a>
  414. </h4>
  415. <aside class="phpdocumentor-element-found-in">
  416. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  417. :
  418. <span class="phpdocumentor-element-found-in__line">62</span>
  419. </aside>
  420. <p class="phpdocumentor-summary">Determines if this finder pattern &quot;about equals&quot; a finder pattern at the stated
  421. position and size -- meaning, it is at nearly the same center with nearly the same size.</p>
  422. <code class="phpdocumentor-code phpdocumentor-signature ">
  423. <span class="phpdocumentor-signature__visibility">public</span>
  424. <span class="phpdocumentor-signature__name">aboutEquals</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$moduleSize</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$i</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$j</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
  425. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  426. <dl class="phpdocumentor-argument-list">
  427. <dt class="phpdocumentor-argument-list__entry">
  428. <span class="phpdocumentor-signature__argument__name">$moduleSize</span>
  429. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  430. </dt>
  431. <dd class="phpdocumentor-argument-list__definition">
  432. <section class="phpdocumentor-description"></section>
  433. </dd>
  434. <dt class="phpdocumentor-argument-list__entry">
  435. <span class="phpdocumentor-signature__argument__name">$i</span>
  436. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  437. </dt>
  438. <dd class="phpdocumentor-argument-list__definition">
  439. <section class="phpdocumentor-description"></section>
  440. </dd>
  441. <dt class="phpdocumentor-argument-list__entry">
  442. <span class="phpdocumentor-signature__argument__name">$j</span>
  443. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  444. </dt>
  445. <dd class="phpdocumentor-argument-list__definition">
  446. <section class="phpdocumentor-description"></section>
  447. </dd>
  448. </dl>
  449. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  450. <span class="phpdocumentor-signature__response_type">bool</span>
  451. &mdash;
  452. </article>
  453. <article
  454. class="phpdocumentor-element
  455. -method
  456. -public
  457. "
  458. >
  459. <h4 class="phpdocumentor-element__name" id="method_combineEstimate">
  460. combineEstimate()
  461. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_combineEstimate" class="headerlink"><i class="fas fa-link"></i></a>
  462. </h4>
  463. <aside class="phpdocumentor-element-found-in">
  464. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  465. :
  466. <span class="phpdocumentor-element-found-in__line">64</span>
  467. </aside>
  468. <p class="phpdocumentor-summary">Combines this object&#039;s current estimate of a finder pattern position and module size
  469. with a new estimate. It returns a new FinderPattern containing a weighted average
  470. based on count.</p>
  471. <code class="phpdocumentor-code phpdocumentor-signature ">
  472. <span class="phpdocumentor-signature__visibility">public</span>
  473. <span class="phpdocumentor-signature__name">combineEstimate</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$i</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$j</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$newModuleSize</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">self</span></code>
  474. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  475. <dl class="phpdocumentor-argument-list">
  476. <dt class="phpdocumentor-argument-list__entry">
  477. <span class="phpdocumentor-signature__argument__name">$i</span>
  478. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  479. </dt>
  480. <dd class="phpdocumentor-argument-list__definition">
  481. <section class="phpdocumentor-description"></section>
  482. </dd>
  483. <dt class="phpdocumentor-argument-list__entry">
  484. <span class="phpdocumentor-signature__argument__name">$j</span>
  485. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  486. </dt>
  487. <dd class="phpdocumentor-argument-list__definition">
  488. <section class="phpdocumentor-description"></section>
  489. </dd>
  490. <dt class="phpdocumentor-argument-list__entry">
  491. <span class="phpdocumentor-signature__argument__name">$newModuleSize</span>
  492. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  493. </dt>
  494. <dd class="phpdocumentor-argument-list__definition">
  495. <section class="phpdocumentor-description"></section>
  496. </dd>
  497. </dl>
  498. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  499. <span class="phpdocumentor-signature__response_type">self</span>
  500. &mdash;
  501. </article>
  502. <article
  503. class="phpdocumentor-element
  504. -method
  505. -public
  506. -static "
  507. >
  508. <h4 class="phpdocumentor-element__name" id="method_distance">
  509. distance()
  510. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_distance" class="headerlink"><i class="fas fa-link"></i></a>
  511. </h4>
  512. <aside class="phpdocumentor-element-found-in">
  513. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  514. :
  515. <span class="phpdocumentor-element-found-in__line">88</span>
  516. </aside>
  517. <code class="phpdocumentor-code phpdocumentor-signature ">
  518. <span class="phpdocumentor-signature__visibility">public</span>
  519. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">distance</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$aX</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$aY</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bX</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bY</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  520. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  521. <dl class="phpdocumentor-argument-list">
  522. <dt class="phpdocumentor-argument-list__entry">
  523. <span class="phpdocumentor-signature__argument__name">$aX</span>
  524. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  525. </dt>
  526. <dd class="phpdocumentor-argument-list__definition">
  527. <section class="phpdocumentor-description"></section>
  528. </dd>
  529. <dt class="phpdocumentor-argument-list__entry">
  530. <span class="phpdocumentor-signature__argument__name">$aY</span>
  531. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  532. </dt>
  533. <dd class="phpdocumentor-argument-list__definition">
  534. <section class="phpdocumentor-description"></section>
  535. </dd>
  536. <dt class="phpdocumentor-argument-list__entry">
  537. <span class="phpdocumentor-signature__argument__name">$bX</span>
  538. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  539. </dt>
  540. <dd class="phpdocumentor-argument-list__definition">
  541. <section class="phpdocumentor-description"></section>
  542. </dd>
  543. <dt class="phpdocumentor-argument-list__entry">
  544. <span class="phpdocumentor-signature__argument__name">$bY</span>
  545. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  546. </dt>
  547. <dd class="phpdocumentor-argument-list__definition">
  548. <section class="phpdocumentor-description"></section>
  549. </dd>
  550. </dl>
  551. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  552. <span class="phpdocumentor-signature__response_type">float</span>
  553. &mdash;
  554. </article>
  555. <article
  556. class="phpdocumentor-element
  557. -method
  558. -public
  559. "
  560. >
  561. <h4 class="phpdocumentor-element__name" id="method_getCount">
  562. getCount()
  563. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getCount" class="headerlink"><i class="fas fa-link"></i></a>
  564. </h4>
  565. <aside class="phpdocumentor-element-found-in">
  566. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  567. :
  568. <span class="phpdocumentor-element-found-in__line">39</span>
  569. </aside>
  570. <code class="phpdocumentor-code phpdocumentor-signature ">
  571. <span class="phpdocumentor-signature__visibility">public</span>
  572. <span class="phpdocumentor-signature__name">getCount</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
  573. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  574. <span class="phpdocumentor-signature__response_type">int</span>
  575. &mdash;
  576. </article>
  577. <article
  578. class="phpdocumentor-element
  579. -method
  580. -public
  581. "
  582. >
  583. <h4 class="phpdocumentor-element__name" id="method_getDistance">
  584. getDistance()
  585. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getDistance" class="headerlink"><i class="fas fa-link"></i></a>
  586. </h4>
  587. <aside class="phpdocumentor-element-found-in">
  588. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  589. :
  590. <span class="phpdocumentor-element-found-in__line">48</span>
  591. </aside>
  592. <code class="phpdocumentor-code phpdocumentor-signature ">
  593. <span class="phpdocumentor-signature__visibility">public</span>
  594. <span class="phpdocumentor-signature__name">getDistance</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Detector-FinderPattern.html"><abbr title="\chillerlan\QRCode\Detector\FinderPattern">FinderPattern</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$b</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  595. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  596. <dl class="phpdocumentor-argument-list">
  597. <dt class="phpdocumentor-argument-list__entry">
  598. <span class="phpdocumentor-signature__argument__name">$b</span>
  599. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Detector-FinderPattern.html"><abbr title="\chillerlan\QRCode\Detector\FinderPattern">FinderPattern</abbr></a></span>
  600. </dt>
  601. <dd class="phpdocumentor-argument-list__definition">
  602. <section class="phpdocumentor-description"><p>second pattern</p>
  603. </section>
  604. </dd>
  605. </dl>
  606. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  607. <span class="phpdocumentor-signature__response_type">float</span>
  608. &mdash;
  609. <section class="phpdocumentor-description"><p>distance between two points</p>
  610. </section>
  611. </article>
  612. <article
  613. class="phpdocumentor-element
  614. -method
  615. -public
  616. "
  617. >
  618. <h4 class="phpdocumentor-element__name" id="method_getEstimatedModuleSize">
  619. getEstimatedModuleSize()
  620. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getEstimatedModuleSize" class="headerlink"><i class="fas fa-link"></i></a>
  621. </h4>
  622. <aside class="phpdocumentor-element-found-in">
  623. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  624. :
  625. <span class="phpdocumentor-element-found-in__line">54</span>
  626. </aside>
  627. <code class="phpdocumentor-code phpdocumentor-signature ">
  628. <span class="phpdocumentor-signature__visibility">public</span>
  629. <span class="phpdocumentor-signature__name">getEstimatedModuleSize</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  630. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  631. <span class="phpdocumentor-signature__response_type">float</span>
  632. &mdash;
  633. </article>
  634. <article
  635. class="phpdocumentor-element
  636. -method
  637. -public
  638. "
  639. >
  640. <h4 class="phpdocumentor-element__name" id="method_getSquaredDistance">
  641. getSquaredDistance()
  642. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_getSquaredDistance" class="headerlink"><i class="fas fa-link"></i></a>
  643. </h4>
  644. <aside class="phpdocumentor-element-found-in">
  645. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  646. :
  647. <span class="phpdocumentor-element-found-in__line">55</span>
  648. </aside>
  649. <p class="phpdocumentor-summary">Get square of distance between a and b.</p>
  650. <code class="phpdocumentor-code phpdocumentor-signature ">
  651. <span class="phpdocumentor-signature__visibility">public</span>
  652. <span class="phpdocumentor-signature__name">getSquaredDistance</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Detector-FinderPattern.html"><abbr title="\chillerlan\QRCode\Detector\FinderPattern">FinderPattern</abbr></a>&nbsp;</span><span class="phpdocumentor-signature__argument__name">$b</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  653. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  654. <dl class="phpdocumentor-argument-list">
  655. <dt class="phpdocumentor-argument-list__entry">
  656. <span class="phpdocumentor-signature__argument__name">$b</span>
  657. : <span class="phpdocumentor-signature__argument__return-type"><a href="classes/chillerlan-QRCode-Detector-FinderPattern.html"><abbr title="\chillerlan\QRCode\Detector\FinderPattern">FinderPattern</abbr></a></span>
  658. </dt>
  659. <dd class="phpdocumentor-argument-list__definition">
  660. <section class="phpdocumentor-description"></section>
  661. </dd>
  662. </dl>
  663. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  664. <span class="phpdocumentor-signature__response_type">float</span>
  665. &mdash;
  666. </article>
  667. <article
  668. class="phpdocumentor-element
  669. -method
  670. -public
  671. "
  672. >
  673. <h4 class="phpdocumentor-element__name" id="method_getX">
  674. getX()
  675. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getX" class="headerlink"><i class="fas fa-link"></i></a>
  676. </h4>
  677. <aside class="phpdocumentor-element-found-in">
  678. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  679. :
  680. <span class="phpdocumentor-element-found-in__line">40</span>
  681. </aside>
  682. <code class="phpdocumentor-code phpdocumentor-signature ">
  683. <span class="phpdocumentor-signature__visibility">public</span>
  684. <span class="phpdocumentor-signature__name">getX</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  685. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  686. <span class="phpdocumentor-signature__response_type">float</span>
  687. &mdash;
  688. </article>
  689. <article
  690. class="phpdocumentor-element
  691. -method
  692. -public
  693. "
  694. >
  695. <h4 class="phpdocumentor-element__name" id="method_getY">
  696. getY()
  697. <a href="classes/chillerlan-QRCode-Detector-ResultPoint.html#method_getY" class="headerlink"><i class="fas fa-link"></i></a>
  698. </h4>
  699. <aside class="phpdocumentor-element-found-in">
  700. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/ResultPoint.php"><a href="files/src-detector-resultpoint.html"><abbr title="src/Detector/ResultPoint.php">ResultPoint.php</abbr></a></abbr>
  701. :
  702. <span class="phpdocumentor-element-found-in__line">47</span>
  703. </aside>
  704. <code class="phpdocumentor-code phpdocumentor-signature ">
  705. <span class="phpdocumentor-signature__visibility">public</span>
  706. <span class="phpdocumentor-signature__name">getY</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  707. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  708. <span class="phpdocumentor-signature__response_type">float</span>
  709. &mdash;
  710. </article>
  711. <article
  712. class="phpdocumentor-element
  713. -method
  714. -private
  715. -static "
  716. >
  717. <h4 class="phpdocumentor-element__name" id="method_squaredDistance">
  718. squaredDistance()
  719. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#method_squaredDistance" class="headerlink"><i class="fas fa-link"></i></a>
  720. </h4>
  721. <aside class="phpdocumentor-element-found-in">
  722. <abbr class="phpdocumentor-element-found-in__file" title="src/Detector/FinderPattern.php"><a href="files/src-detector-finderpattern.html"><abbr title="src/Detector/FinderPattern.php">FinderPattern.php</abbr></a></abbr>
  723. :
  724. <span class="phpdocumentor-element-found-in__line">78</span>
  725. </aside>
  726. <code class="phpdocumentor-code phpdocumentor-signature ">
  727. <span class="phpdocumentor-signature__visibility">private</span>
  728. <span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">squaredDistance</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$aX</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$aY</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bX</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type">float&nbsp;</span><span class="phpdocumentor-signature__argument__name">$bY</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">float</span></code>
  729. <h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
  730. <dl class="phpdocumentor-argument-list">
  731. <dt class="phpdocumentor-argument-list__entry">
  732. <span class="phpdocumentor-signature__argument__name">$aX</span>
  733. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  734. </dt>
  735. <dd class="phpdocumentor-argument-list__definition">
  736. <section class="phpdocumentor-description"></section>
  737. </dd>
  738. <dt class="phpdocumentor-argument-list__entry">
  739. <span class="phpdocumentor-signature__argument__name">$aY</span>
  740. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  741. </dt>
  742. <dd class="phpdocumentor-argument-list__definition">
  743. <section class="phpdocumentor-description"></section>
  744. </dd>
  745. <dt class="phpdocumentor-argument-list__entry">
  746. <span class="phpdocumentor-signature__argument__name">$bX</span>
  747. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  748. </dt>
  749. <dd class="phpdocumentor-argument-list__definition">
  750. <section class="phpdocumentor-description"></section>
  751. </dd>
  752. <dt class="phpdocumentor-argument-list__entry">
  753. <span class="phpdocumentor-signature__argument__name">$bY</span>
  754. : <span class="phpdocumentor-signature__argument__return-type">float</span>
  755. </dt>
  756. <dd class="phpdocumentor-argument-list__definition">
  757. <section class="phpdocumentor-description"></section>
  758. </dd>
  759. </dl>
  760. <h5 class="phpdocumentor-return-value__heading">Return values</h5>
  761. <span class="phpdocumentor-signature__response_type">float</span>
  762. &mdash;
  763. </article>
  764. </section>
  765. <script type="text/javascript">
  766. function loadExternalCodeSnippets(line) {
  767. Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach((pre) => {
  768. var src = pre.getAttribute('data-src').replace( /\\/g, '/');
  769. var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
  770. var language = 'php';
  771. var code = document.createElement('code');
  772. code.className = 'language-' + language;
  773. pre.textContent = '';
  774. pre.setAttribute('data-line', line)
  775. code.textContent = 'Loading…';
  776. pre.appendChild(code);
  777. var xhr = new XMLHttpRequest();
  778. xhr.open('GET', src, true);
  779. xhr.onreadystatechange = function () {
  780. if (xhr.readyState == 4) {
  781. if (xhr.status < 400 && xhr.responseText) {
  782. code.textContent = xhr.responseText;
  783. Prism.highlightElement(code);
  784. }
  785. else if (xhr.status >= 400) {
  786. code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
  787. }
  788. else {
  789. code.textContent = '✖ Error: File does not exist, is empty or trying to view from localhost';
  790. }
  791. }
  792. };
  793. xhr.send(null);
  794. });
  795. }
  796. var modals = document.querySelectorAll("[data-modal]");
  797. modals.forEach(function (trigger) {
  798. trigger.addEventListener("click", function (event) {
  799. //event.preventDefault();
  800. const modal = document.getElementById(trigger.dataset.modal);
  801. modal.classList.add("phpdocumentor-modal__open");
  802. loadExternalCodeSnippets(trigger.dataset.line)
  803. const exits = modal.querySelectorAll("[data-exit-button]");
  804. exits.forEach(function (exit) {
  805. exit.addEventListener("click", function (event) {
  806. event.preventDefault();
  807. modal.classList.remove("phpdocumentor-modal__open");
  808. });
  809. });
  810. });
  811. });
  812. </script>
  813. </article>
  814. <section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
  815. <section class="phpdocumentor-search-results__dialog">
  816. <header class="phpdocumentor-search-results__header">
  817. <h2 class="phpdocumentor-search-results__title">Search results</h2>
  818. <button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
  819. </header>
  820. <section class="phpdocumentor-search-results__body">
  821. <ul class="phpdocumentor-search-results__entries"></ul>
  822. </section>
  823. </section>
  824. </section>
  825. </div>
  826. </div>
  827. <a href="classes/chillerlan-QRCode-Detector-FinderPattern.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
  828. </main>
  829. <script>
  830. cssVars({});
  831. </script>
  832. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
  833. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
  834. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
  835. <script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
  836. </body>
  837. </html>