0

Since the Google IO I waited for the presented drift correction update (look at my last question). Now after the Qianru update this function is finally available at the Java API. But when trying to use it, the example I try with always crashes (Java Floorplan Example). I just added one line (KEY_ENABLE_DRIFT_CORRECTION). Can anyone help me?

Code:

        // Use default configuration for Tango Service, plus low latency
    // IMU integration and area learning.
    TangoConfig config = mTango.getConfig(TangoConfig.CONFIG_TYPE_DEFAULT);
    // NOTE: Low latency integration is necessary to achieve a precise alignment of virtual
    // objects with the RBG image and produce a good AR effect.
    config.putBoolean(TangoConfig.KEY_BOOLEAN_LOWLATENCYIMUINTEGRATION, true);
    config.putBoolean(TangoConfig.KEY_BOOLEAN_DEPTH, true);
    config.putBoolean(TangoConfig.KEY_BOOLEAN_DRIFT_CORRECTION, true);
    // NOTE: Area learning is necessary to achieve better precision is pose estimation
    config.putBoolean(TangoConfig.KEY_BOOLEAN_LEARNINGMODE, true);
    config.putBoolean(TangoConfig.KEY_BOOLEAN_COLORCAMERA, true);
    mTango.connect(config);

Error: enter image description here

Community
  • 1
  • 1
Konsti
  • 83
  • 8
  • 1
    LEARNINGMODE and loading AREADESCRIPTION cannot be used if drift correction is enabled. (Java API Doc) – Konsti Jul 13 '16 at 15:38
  • Looks like you found the answer yourself :), and yes, you can't use drift correction and learning mode together – xuguo Jul 26 '16 at 22:00
  • But do you know why? Because the drift correction function recognizes known areas to replace the AR-objects. An this is pretty similiar to area learning. – Konsti Jul 29 '16 at 09:57
  • It's just not a feature that implemented in Tango, if I remember correctly, there's check when you call connect to Tango, it will throw an exception if both things are enabled. – xuguo Jul 29 '16 at 23:46

0 Answers0