NyARToolkit for Processing 3.0.2

[Japanese] [Spanish(Emiliusvgs)]

NyARToolkit for Processing 3.0.2 is released.

n5psg3

New library can handle Neture Feature Tracking easily.

https://github.com/nyatla/NyARToolkit-for-Processing

NFT Sample Sketch

NFT sketch is very simple.

// examples/Simplenft.pde
import processing.video.*;
import jp.nyatla.nyar4psg.*;

Capture cam;
MultiNft nya;

void setup() {
  size(640,480,P3D);
  colorMode(RGB, 100);
  println(MultiMarker.VERSION);
  cam=new Capture(this,640,480);
  nya=new MultiNft(this,width,height,"camera_para5.dat",NyAR4PsgConfig.CONFIG_PSG);
  nya.addNftTarget("infinitycat",160);//id=0
  cam.start();
}

void draw()
{
  if (cam.available() !=true) {
      return;
  }
  cam.read();
  nya.detect(cam);
  background(0);
  nya.drawBackground(cam);//frustumを考慮した背景描画
    if(!nya.isExist(0)){
      return;
    }
    nya.beginTransform(0);
    fill(255,0,0);
    translate(-80,55,20);
    box(40);
    nya.endTransform(); 
}

The program sequence are same as marker sketch.
The only difference is that are using the MultiNft instead of MultiMarker.

How to change NFT target

In order to make the NFT target fileset to use the nftFilesGen sketch.
Sketch will launch the file generator.

 

NyARToolkit for Java 5.0.0

NyARToolkit for Java 5.0.0 has been released.
https://github.com/nyatla/NyARToolkit

NyARToolkit 5.0.0 supports the natural features tracking which is same as implemented on ARToolKit5 (NFT) .

The development of NyARToolKit5 has received the funding and technical assistance by DAQRI LLC.
I’m grateful to DAQRI LLC and ARToolKit team.

How to running NFT sample

  1. Checkout NyARToolKit from Github.
  2. Import NyARToolkit projects to Eclipse. Make sure that there are no errors in the project shown in .
    p1
  3. Print NFT image  to paper. If you do not have a printer, display the pdf file into the screen.
    infinitycat.pdf
  4. Connect your webcam to computer.
  5. Run NftSimpleLite.java in NyARToolkit.sample.jogl package.
    p2
  6. It takes a few seconds to startup. When you take a picture with the camera, The color cube will display on image.
    Ce7VUtqUIAAvu0o

NFT Programming

NFT programming with NyARToolkit is simply.
It requires only a few dozen lines of code.

NftSimpleLite.java is a template of NFT application. You can create the unique application by modify the template.

public class NftSimpleLite extends GlSketch
{
  String nftdataset="d:\\infinitycat";
  String cparam="../../Data/testcase/camera_para5.dat";
  private Webcam camera;
  private NyARGlNftSystem nyar;
  private NyARGlRender render;
  private NyARSensor sensor;
  public void setup(GL gl)throws Exception
  {
    this.size(640,480);
    NyARNftSystemConfig config = new NyARNftSystemConfig(new FileInputStream(cparam),640,480);
    this.camera=Webcam.getDefault();
    this.camera.setViewSize(new Dimension(640,480));
    this.nyar=new NyARGlNftSystem(config);   //create MarkerSystem
    this.render=new NyARGlRender(this.nyar);
    this.sensor=new NyARSensor(config.getScreenSize());
    //
    this.id=this.nyar.addNftTarget(nftdataset,160);
    gl.glEnable(GL.GL_DEPTH_TEST);
    this.camera.open();
  }
  private int id;
  public void draw(GL gl)throws Exception
  {
    synchronized(this.camera){
      try {
        this.sensor.update(new NyARBufferedImageRaster(this.camera.getImage()));        
        this.render.drawBackground(gl,this.sensor.getSourceImage());
        this.render.loadARProjectionMatrix(gl);
        this.nyar.update(this.sensor);
        if(this.nyar.isExistTarget(this.id)){
          this.nyar.loadTransformMatrix(gl,this.id);
          this.render.colorCube(gl,40,80,60,20);
        }
        Thread.sleep(1);
      } catch (Exception e) {
        e.printStackTrace();
      }
    }
  }  
  public static void main(String[] args)
  {
    new NftSimpleLite().run();
    return;
  }
}
  • How to change the tracking image file?
    →Change nftdataset value. In NFT, it need to place 3 files(.iset, .fset, .fset3) onto same path.
    For example: If you specify “d \\ example”, “c:\\ example.iset”, “c:\\ example.fset”, “c:\\example.fset3” will be used as a tracking image.
  • How to change the tracking image size?
    →Set the paper image width in mm to the second parameter of addNftTarget function.
  • How to make the tracking image set file?
    →NftFileGenerator.jar is a fileset generator.
    Download NyARToolkit.utility.zip from the following URL.
    https://github.com/nyatla/NyARToolkit/releases

For compatibility with ARToolKit5

Calculation algorithm of NyARToolKit is identical to the ARToolKit5 but there is a slight difference.
The cause of the difference are the accuracy of floating-point calculations, and the simplification of  the math functions.

The NyARToolKit and ARToolKit data files(iset fset fset3) are compatible.
These files can be used with each other.

 

NyARToolKit for Android licence has been updated

NyARToolkit for Android licence was updated to LGPLv3.

Source code header and bundled licence text were updated in NyARTK4.nyatla branch.

https://osdn.jp/projects/nyartoolkit-and/scm/git/NyARTK4.nyatla/

Source code header and bundled licence text has been updated in NyARTK4.nyatla branch.
Other branches are not updated.
These branch will probably available on LGPLv3. However,should contact to commiter if you require completeness.

 

NyARToolkitAS3/4.1.1 and FLARToolKit/4.1.1 Released.

NyARToolkitAS3及びFLARToolKitのバージョン4.1.1をリリースします。
変更点は、NyARToolkit/4.1.1APIへの対応です。

ダウンロード

NyARToolkitAS3

http://sourceforge.jp/projects/nyartoolkit/releases/

FLARToolKit

http://www.libspark.org/svn/as3/FLARToolKit/branches/nyatla/v4/tags/4.1.1/
(subversion repository)

本年もNyARToolkitシリーズをご利用いただきまして、有難うございました。また来年も、どうぞ宜しくお願いいたします。

English

NyARToolkitAS3 and FLARToolKit version4 are released.
This is patches for NyARToolkit/4.1.1 API.

Download

NyARToolkitAS3

http://sourceforge.jp/projects/nyartoolkit/releases/

FLARToolKit

http://www.libspark.org/svn/as3/FLARToolKit/branches/nyatla/v4/tags/4.1.1/
(subversion repository)

Thank you for using NyARToolkit and FLARToolkit. Happy Holidays!

NyARToolkit 4.1.0

NyARToolkit 4.1.0(Java/C#/Unity3D)をリリースします。
http://sourceforge.jp/projects/nyartoolkit/releases/

更新内容は以下の通りです。

新機能

共通

  • ARToolkit Professional Version4のカメラパラメータが使用できるようになります
  • OpenCVスタイルのカメラパラメータを使用できるようになります。
  • MarkerSystemでARプレイカードを使用できるようになります。

Java

  • スケッチシステムに、J2se版を追加しました。
  • NyARBufferedImageIoにNyARRgbRasterをラップするcreateWrappedBufferedImage関数を追加しました。

Unity

  • WebPlayerに対応しました。また、サンプルを追加しました。
  • サンプルの設定ファイルをResourceから読み込むように修正

バグ修正

共通

  • MarkerSystemで複数のARマーカ取り扱い時に検出ミスが発生する不具合の修正しました。(#29287)
  • NyARPointerStack#removeが正常に動作しない不具合を修正しました。(#29917)
  • MarkerSystemが10個以上のマーカを同時に認識できない問題を修正しました。(#30173)
  • その他の不具合修正( #29763 , #28851)

変更

共通

  • NyARParamのコンストラクタを変更しました。初期値設定やファイルから値をロードするときは、static関数をコールします。
  • NyARCodeのコンストラクタを変更しました。初期値設定やファイルから値をロードするときは、static関数をコールします。
  • NyARParam#changeSizeが、x,y独立してスケールするようになりました。
  • NyARTransMatの仕様を変更しました。NyARTransmatResultを廃止し、NyARTransmatResultParamとNyARDoubleMatrix44へ返却するようになりました。
  • NyARMath/NyARDoubleMatrix44/NyARDoubleMatrix33に関数を追加しました。
  • サンプルを変更にあわせて修正しました。

Java

  • GlSketchの起動方法を変更しました。new Sketch().run();のようにコールする必要があります。

C#

  • D3dSketchの起動方法を変更しました。new Sketch().run();のようにコールする必要があります。

 

English

NyARToolkit version 4.1.0 (Java/C#/Unity) released.
http://sourceforge.jp/projects/nyartoolkit/releases/

New function

All

  • NyARParam supports ARToolkit Professional Version4 format.
  • NyARParam supports OpenCV style Matrix.
  • NyARMarkerSystem supports PS AR play card format.

Java

  • Added the J2se version to a sketch system.
  • Added the createWrappedBufferedImage function which wraps NyARRgbRaster to NyARBufferedImageIo.

Unity

  • Supported WebPlayer. And added it’s sample.
  • The configuration files loader was changed. Files are loaded from Resource.

BugFix

  • #29287,#29917,#30173,#29763, #28851

Changes

All

  • The constructor of NyARParam was changed. Call a new static function for loading.
  • The constructor of NyARCode was changed. Call a new static function for loading.
  • NyARParam#changeSize function parameter is changed. it can set scales independently x and y.
  • The specification of NyARTransMat function is changed. it became to  return 2 parameters – NyARTransmatResultParam and NyARDoubleMatrix44.  NyARTransmatResult is removed.
  • The function is added to NyARMath/NyARDoubleMatrix44/NyARDoubleMatrix33.
  • All samples are changed to follow changes.

Java

  • The starting method of GlSketch is changed.  It is necessary to call like “new Sketch().run();” .

C#

  • The starting method of D3dSketch is changed. It is necessary to call like “new Sketch().run();”.