Search Unity

Introducing ARCore: An Android AR SDK for Unity

Discussion in 'ARCore' started by matthewpruitt, Aug 28, 2017.

  1. L_JS

    L_JS

    Joined:
    Feb 14, 2017
    Posts:
    3
    arcore sdk 1.9.0 / unity 2018.1f1
    build is not played.
    failure to initialize!
    your hardware dose not support this application, sorry!
    why, how to solve?
     
  2. pepe1234

    pepe1234

    Joined:
    Jul 12, 2017
    Posts:
    2
    hey guys really need your help, I had this app in arkit with some furniture, but after adding ar core and compiling to android de 3D models dont render correctly. Here are some pictures:

    Screenshot_20190620-141219.png Screenshot_20190620-141224.png Screenshot_20190620-141224.png
     
  3. amichai2

    amichai2

    Joined:
    Jul 30, 2018
    Posts:
    3
    Hi!

    I'm working to connect Unity with my Kotlin-based computer vision code for an Android application. To do this, I need to:
    1. Access and configure an
      ARCore.ARSession
      object in Unity
    2. Pass this same
      ARSession
      object to my Unity plugin (an
      aar
      written in Java/Kotlin).

    Question: how can I get
    ARCore.ARSession
    to share the reference between my C# code and my Kotlin code?

    Solutions I've considered or tried:
    1. Passing the address of an
      ARSession
      instance created in Kotlin over to Unity and overriding the
      nativePtr
      value in
      ARReferenceObject.cs
      . I have not had success with this approach. (I can post the seg-fault log if you're curious)
    2. Porting my whole Java/Kotlin code to C# - super painful and would impact performance
    3. One thought - For ARKit I was able to extend objective-c code in the ARKit Unity plugin (ARSessionNative.mm) with
      extern "C"
      functions that allow passing the Unity Session from the C# files to Objective-C in
      ARSessionNative.mm
      . Is there a way to do something similar using C code and the JNI?

    Any advice/tips/stories of either accessing
    ARCore.ARSession
    in Unity and/or passing an
    ARSession
    reference from Unity to Kotlin/Java would be MUCH appreciated :)

    @matthewpruitt @tdmowrer @jimmya
     
    Dalooshman likes this.