AR.js: Barcode Markers (May Be) Broken

Awesome project!

Hiro markers in my AR.js app (based on the a-frame example) are working fine.

However, I want to use 3x3 barcode markers!

I am following this example: http://jeromeetienne.github.io/slides/artoolkit-aframe/#20

The slideshow has this section:

<a-scene artoolkit='detectionMode: mono_matrix; sourceType: webcam;'>  
        <!-- here, put the content of your scene -->
</a-scene>

But changed mono_matrix to mono_and_matrix since mono_matrix does not exist.

Even after that, however, this does not appear to work:

<a-marker type='barcode' value='20' >
        <!-- here put your content -->
</a-marker>

Though the code runs in the browser without error, it is never able to identify the marker. This seems to be the case even when matrixCodeType is in 3x3, 4x4, 3x3_HAMMING63, etc…

Any ideas? It’s possible this is related to an underlying bug: https://github.com/artoolkit/jsartoolkit5/issues/34

Can somebody sanity check this for me, please?

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 19 (5 by maintainers)

Most upvoted comments

Still not working for me, even when using the exact code from the example linked by @jeromeetienne .

There is also a strange effect where even when the hiro marker is not being used, the hiro marker shows the objects that were meant to be shown from the barcode.

Is it possible that the cause of this is that tracking backend is not being set to aruco?

Sorry for the delay, i spent time on this today. And fixed an issue. I wrote an aframe example which handle multiple independant markers, and there is barcode is working there.

See the example here

You change the scene configuration to specific you are looking for matrix marker too and their type e.g.

<a-scene embedded artoolkit='sourceType: webcam; detectionMode: mono_and_matrix; matrixCodeType: 3x3;'>
</a-scene>

You define the marker like this

<a-marker type='barcode' value='5'>
     <a-box></a-box>
</a-marker>

screen shot 2017-06-06 at 15 25 17

@reza21 Hey, I’m also a newbie, but in case you’re still looking for barcode (3x3), artoolkit has some pre-generated numbers (0 to 63) here: https://github.com/artoolkit/artoolkit5/tree/master/doc/patterns/Matrix code 3x3 (72dpi). I hope that helps!

I can confirm that this works! Thank you very much Jerome!