Skip to content

RangeError when loading .mind marker files - Extra bytes found at buffer #576

@roossop24

Description

@roossop24

@hiukim , @jmswrnr
Description:
Encountering a consistent error when loading .mind marker files in A-Frame with MindAR. The error occurs during the marker loading process and prevents AR tracking from initializing.

Error:
Uncaught (in promise) RangeError: Extra 191801 of 191802 byte(s) found at buffer
at n.createExtraByteError (mindar-image-aframe.prod.js:20716)
at n.decode (mindar-image-aframe.prod.js:20716)
at L_ (mindar-image-aframe.prod.js:20716)
at importData (mindar-image-aframe.prod.js:20716)
at addImageTargetsFromBuffer (mindar-image-aframe.prod.js:20726)
at addImageTargets (mindar-image-aframe.prod.js:20726)
at _startAR (mindar-image-aframe.prod.js:20756)

Environment:

  • A-Frame Version: 1.4.0
  • THREE.js Version: ^0.147.0
  • MindAR A-Frame: mindar-image-aframe.prod.js
  • Browser: [Your browser version]
  • Platform: Web/Desktop

Steps to Reproduce:

  1. Generate .mind marker file using MindAR compiler
  2. Load marker file in A-Frame scene with MindAR component
  3. Initialize AR scene
  4. Error occurs during marker buffer parsing

Expected Behavior:
Marker file should load successfully and AR tracking should initialize without errors.

Additional Context:
The error suggests an issue with binary data parsing where the buffer contains extra bytes. This appears to be related to the marker file format or generation process. The error occurs consistently across different marker files (file size: 191802 bytes in this case).

Possible Investigation Areas:

  • Binary format specification for .mind files
  • Buffer parsing logic in addImageTargetsFromBuffer
  • Marker file generation process

and these are the logs from browser console

A-Frame Version: 1.4.0 (Date 2022-12-26, Commit #60a324a2)
index.js:96 THREE Version (https://github.com/supermedium/three.js): ^0.147.0
index.js:98 WebVR Polyfill Version: ^0.10.12
jeeva/:249 A-Frame scene loaded
mindar-image-aframe.prod.js:20716 Uncaught (in promise) RangeError: Extra 191801 of 191802 byte(s) found at buffer[1]
n.createExtraByteError @ mindar-image-aframe.prod.js:20716
n.decode @ mindar-image-aframe.prod.js:20716
L_ @ mindar-image-aframe.prod.js:20716
importData @ mindar-image-aframe.prod.js:20716
addImageTargetsFromBuffer @ mindar-image-aframe.prod.js:20726
(anonymous) @ mindar-image-aframe.prod.js:20726
await in (anonymous)
addImageTargets @ mindar-image-aframe.prod.js:20726
_startAR @ mindar-image-aframe.prod.js:20756
(anonymous) @ mindar-image-aframe.prod.js:20756

MY django project logs

System check identified no issues (0 silenced).
September 15, 2025 - 09:31:46
Django version 4.2.23, using settings 'arexperience.settings'
Starting development server at http://127.0.0.1:8000/
Quit the server with CTRL-BREAK.

[15/Sep/2025 09:32:38] "GET / HTTP/1.1" 200 1212
Not Found: /favicon.ico
[15/Sep/2025 09:32:39] "GET /favicon.ico HTTP/1.1" 404 4516
[15/Sep/2025 09:32:41] "GET /upload/ HTTP/1.1" 200 23210
[15/Sep/2025 09:32:46] "GET /media/markers/1_12_TmdFsin.png HTTP/1.1" 200 823057
[15/Sep/2025 09:32:46] "GET /media/qrcodes/akash.png HTTP/1.1" 200 1087
[15/Sep/2025 09:32:46] "GET /media/qrcodes/akash-1.png HTTP/1.1" 200 1063
[15/Sep/2025 09:32:46] "GET /media/qrcodes/ranjith.png HTTP/1.1" 200 1081
[15/Sep/2025 09:32:46] "GET /media/qrcodes/akash1.png HTTP/1.1" 200 1108
[15/Sep/2025 09:32:46] "GET /media/markers/1_13_24ovvbw.jpeg HTTP/1.1" 200 54763
[15/Sep/2025 09:32:46] "GET /media/markers/1_13.jpeg HTTP/1.1" 200 54763
[15/Sep/2025 09:32:46] "GET /media/qrcodes/akash4.png HTTP/1.1" 200 1082
[15/Sep/2025 09:32:46] "GET /media/markers/1_1_EJ8tPdn.jpg HTTP/1.1" 200 645449
[15/Sep/2025 09:32:46] "GET /media/qrcodes/roosso.png HTTP/1.1" 200 1036
[15/Sep/2025 09:32:46] "GET /media/qrcodes/godzilla.png HTTP/1.1" 200 770
[15/Sep/2025 09:32:46] "GET /media/qrcodes/hello.png HTTP/1.1" 200 856
[15/Sep/2025 09:32:46] "GET /media/markers/1_12.jpeg HTTP/1.1" 200 54763
[15/Sep/2025 09:32:46] "GET /media/qrcodes/nila.png HTTP/1.1" 200 880
[15/Sep/2025 09:32:46] "GET /media/qrcodes/mamu.png HTTP/1.1" 200 725
[15/Sep/2025 09:32:49] "GET /media/markers/1_176_ja7ZUo3.png HTTP/1.1" 200 2399379
[15/Sep/2025 09:32:49] "GET /media/markers/1_32_FHdxGiF.png HTTP/1.1" 200 2194517
[15/Sep/2025 09:32:49] "GET /media/markers/1_145_y3WMfXo.png HTTP/1.1" 200 2422327
[15/Sep/2025 09:33:06] "POST /upload/ HTTP/1.1" 302 0
[15/Sep/2025 09:33:06] "GET /upload/?new=jeeva HTTP/1.1" 200 24282
[15/Sep/2025 09:33:07] "GET /media/qrcodes/jeeva.png HTTP/1.1" 200 993
[15/Sep/2025 09:33:07] "GET /media/markers/1_13_7ceM1wx.jpeg HTTP/1.1" 200 54763
[15/Sep/2025 09:33:07] "GET /media/markers/1_156_z3HPHoA.png HTTP/1.1" 200 2390225
[15/Sep/2025 09:33:31] "GET /x/jeeva/ HTTP/1.1" 200 9749
[15/Sep/2025 09:33:35] "GET /media/videos/output-c83a5814_W13138L.mp4 HTTP/1.1" 200 3462732
[15/Sep/2025 09:33:40] "GET /media/markers/jeeva/jeeva.mind HTTP/1.1" 200 191802

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions