4

ARToolkitPlusBenchmarkを使用してAR Tag Markerをスキャンしています。すべての4096 BCH マーカーを簡単に検出できます。しかし、私の問題は、各BCH マーカー IDを検出する方法がわからないことです。

ここからコードを見つけました ARToolkitPlusBenchmark

Markerinfo.javaでマーカーを検出しようとしました

class DetectMarkerWorker extends Thread {
private byte[] curFrame;
public DetectMarkerWorker() {
 setPriority(MAX_PRIORITY);
 start();
}
@Override
public synchronized void run() {
  try {
wait();
 } catch (InterruptedException e) {
 }
 while (true) {
  if(!CurrentConfig.ONLY_CAMERA_PREVIEW){
 long tick = System.currentTimeMillis();
 if (CurrentConfig.USE_ARTOOLKITPLUS) {

  timeNativeMarkerDetection = artoolkitPlus_detectmarkers(curFrame, transMatMonitor);      
  nativeMarkerDetectionHistory.add(timeNativeMarkerDetection);
  if(nativeMarkerDetectionHistory.size()>20){
   nativeMarkerDetectionHistory.remove(0);
  }
  for(int i = 0;i<nativeMarkerDetectionHistory.size();i++){
   sumNativeMarkerDetection += nativeMarkerDetectionHistory.elementAt(i);
  }
  avgNativeMarkerDetection = sumNativeMarkerDetection/nativeMarkerDetectionHistory.size();
  sumNativeMarkerDetection = 0;
 } else {
  artoolkit_detectmarkers(curFrame, transMatMonitor);
 }
 timeJavaMarkerDetection = System.currentTimeMillis() - tick;
 javaMarkerDetectionHistory.add(timeJavaMarkerDetection);
 if(javaMarkerDetectionHistory.size()>20){
  javaMarkerDetectionHistory.remove(0);
 }
 for(int i = 0;i<javaMarkerDetectionHistory.size();i++){
  sumJavaMarkerDetection += javaMarkerDetectionHistory.elementAt(i);
 }
 avgJavaMarkerDetection = sumJavaMarkerDetection/javaMarkerDetectionHistory.size();
 sumJavaMarkerDetection = 0;
}  
DebugFps.updateFPS();
try {
 wait();
  } catch (InterruptedException e) {
  }
 }
}

iOS iOSでは、 VRToolkitを 使用して各マーカーの ID を検索しています。このアプリは、ARToolKit plus を使用してビデオ フレームのマーカーを検出します。

対応するプロパティを YES に設定し、各マーカー ID を取得すると、すべての4096 BCH マーカーとシン ベースのマーカーをスキャンできます。

Android では、問題に直面しています。

この問題を理解するためにさらに情報が必要な場合はお知らせください。不足しているヘルプやガイダンスに感謝します。

4

1 に答える 1

3

ARToolkitPlusBenchmarkこれを達成するために使用している理由は何ですか? 見てみましたかhttp://code.google.com/p/andar/

Andar も ARToolkit を使用しており、 ARObjectクラスが表示されている場合は、このオブジェクトに属するマーカーの ID を取得できます。

于 2013-11-25T10:33:17.963 に答える