Start a new topic
Solved

Unity Plugin does not work

When I compile the Client Recognition - Simple application in the Unity and I run it on iPad Air 2 over Xcode I get white screen only. The camera does not work.

I added wikituted native sdk framework to the embedded library, enable bytoce -no, always embed swift standard library - yes and I added camera usage description.


The next problem is that the Unity Editor is not supported...Why? ... It is not effective to deploy every change to the device.


But I am doing something wrong maybe.


Thank you 


Hi, 

this was the problem.

Thank you

Hi,


Are you using Metal for rendering in Unity? If so, please switch to OpenGLES2, as Metal is currently not supported by the SDK.


Best regards,

Alexandru

Hi,


Are there any error log messages printed to the console? Does this happen in the other samples as well, or just in Client Recognition - Simple? Are you building the example project provided, or is this happening after importing the package into your own project?


We are aware that not supporting the editor is a considerable drawback for Unity developers and it is something we want to address. In the mean time, some basic prototyping can still be done in the editor. When pressing play, the recognition triggers are automatically sent, to allow you to inspect your augmentations. Additionally, the recognition events can be triggered manually, since they are just Unity Events, which allows you to simulate some of the aspects of the SDK in the editor.


Best regards,

Alexandru

Hi,

I tested on my own simple project and then I opened the Client Recognition - Simple scene and I tested it too. The same result for both.

This is the log:

2017-02-02 13:47:14.608145 wikitudetest[4170:1683473] [DYMTLInitPlatform] platform initialization successful


2017-02-02 13:47:14.873017 wikitudetest[4170:1683356] -> registered mono modules 0x100d4f7e0

2017-02-02 13:47:14.986326 wikitudetest[4170:1683356] You've implemented -[<UIApplicationDelegate> application:didReceiveRemoteNotification:fetchCompletionHandler:], but you still need to add "remote-notification" to the list of your supported UIBackgroundModes in your Info.plist.

-> applicationDidFinishLaunching()

2017-02-02 13:47:15.034781 wikitudetest[4170:1683356] Metal GPU Frame Capture Enabled

2017-02-02 13:47:15.035095 wikitudetest[4170:1683356] Metal API Validation Disabled

-> applicationDidBecomeActive()

GfxDevice: creating device client; threaded=1

Init: screen size 2048x1536

Initializing Metal device caps: Apple A8X GPU

Initialize engine version: 5.5.0f3 (38b4efef76f0)

UnloadTime: 1.291750 ms

Application name not licensed.

Application name: cz.foxon.ar.wikitudetest

Licensed name(s): com.wikitude.SDKExamples

 com.wikitude.phonegapsamples

 com.wikitude.titaniumsample

 com.wikitude.xamarinexample

 com.wikitude.Native-Examples

 com.wikitude.unityexample

Before Native Call

Wikitude.iOSBridge:Wikitude.IPlatformBridge.GetCameraInfo(Int32, Int32, Int32)

Wikitude.WikitudeCamera:UpdateRenderTexture(Int32, Int32, Int32)

Wikitude.WikitudeCamera:set_DevicePosition(CaptureDevicePosition)

Wikitude.WikitudeCamera:Awake()

 

(Filename: /Users/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)


2017-02-02 13:47:18.294763 wikitudetest[4170:1683356] [MC] System group container for systemgroup.com.apple.configurationprofiles path is /private/var/containers/Shared/SystemGroup/systemgroup.com.apple.configurationprofiles

2017-02-02 13:47:18.295469 wikitudetest[4170:1683356] [MC] Reading from public effective user settings.

After Native Call

Wikitude.iOSBridge:Wikitude.IPlatformBridge.GetCameraInfo(Int32, Int32, Int32)

Wikitude.WikitudeCamera:UpdateRenderTexture(Int32, Int32, Int32)

Wikitude.WikitudeCamera:set_DevicePosition(CaptureDevicePosition)

Wikitude.WikitudeCamera:Awake()

 

(Filename: /Users/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)


width: 1920 height: 1080 framerate: 30

Wikitude.iOSBridge:Wikitude.IPlatformBridge.GetCameraInfo(Int32, Int32, Int32)

Wikitude.WikitudeCamera:UpdateRenderTexture(Int32, Int32, Int32)

Wikitude.WikitudeCamera:set_DevicePosition(CaptureDevicePosition)

Wikitude.WikitudeCamera:Awake()

 

(Filename: /Users/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)


2017-02-02 13:47:18.462355 wikitudetest[4170:1683356] extendedTargets is valid.

2017-02-02 13:47:18.462462 wikitudetest[4170:1683356] raw extended targets NSString:

Setting up 1 worker threads for Enlighten.

  Thread -> id: 16fa5f000 -> priority: 1 

-> applicationWillResignActive()

2017-02-02 13:47:18.792184 wikitudetest[4170:1683356] [Common] _BSMachError: port 9d03; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

2017-02-02 13:47:18.792831 wikitudetest[4170:1683356] [Common] _BSMachError: port 9d03; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

2017-02-02 13:47:18.810696 wikitudetest[4170:1683356] [Common] _BSMachError: port 9d03; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

-> applicationDidBecomeActive()

2017-02-02 13:47:18.867626 wikitudetest[4170:1683356] [Common] _BSMachError: port e103; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

2017-02-02 13:47:18.870103 wikitudetest[4170:1683356] [Common] _BSMachError: port e903; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

2017-02-02 13:47:18.870406 wikitudetest[4170:1683356] [Common] _BSMachError: port e903; (os/kern) invalid capability (0x14) "Unable to insert COPY_SEND"

-> applicationWillResignActive()

-> applicationDidBecomeActive()

2017-02-02 13:47:20.266652 wikitudetest[4170:1683455] *** Assertion failure in -[WTCaptureDataOutputHandlerOpenGLES setupDataOutputTextureCache], /Users/emperor/Development/Tools/Jenkins/Master/Instance/jobs/native_sdk_builder/workspace/repositories/ios_core_services/src/Camera/FrameCapturing/CaptureDataOutputHandler/WTCaptureDataOutputHandlerOpenGLES.m:51

2017-02-02 13:47:20.277420 wikitudetest[4170:1683455] Uncaught exception: NSInternalInconsistencyException: Invalid parameter not satisfying: _eaglCameraContext

(

0   CoreFoundation                      0x000000019460e1d8 <redacted> + 148

1   libobjc.A.dylib                     0x000000019304855c objc_exception_throw + 56

2   CoreFoundation                      0x000000019460e094 <redacted> + 0

3   Foundation                          0x000000019509b79c <redacted> + 112

4   WikitudeNativeSDK                   0x00000001029e1430 -[WTCaptureDataOutputHandlerOpenGLES setupDataOutputTextureCache] + 380

5   WikitudeNativeSDK                   0x00000001029cb4e4 -[WTVideoCamera captureManagerWillStart:] + 64

6   WikitudeNativeSDK                   0x00000001029df704 __87-[WTCaptureManager startCaptureSessionWithCaptureDevice:andIntermediateStartupHandler:]_block_invoke + 144

7   libdispatch.dylib                   0x0000000102ebd25c _dispatch_call_block_and_release + 24

8   libdispatch.dylib                   0x0000000102ebd21c _dispatch_client_callout + 16

9   libdispatch.dylib                   0x0000000102ecab54 _dispatch_queue_serial_drain + 1136

10  libdispatch.dylib                   0x0000000102ec0ce4 _dispatch_queue_invoke + 672

11  libdispatch.dylib                   0x0000000102ecce6c _dispatch_root_queue_drain + 584

12  libdispatch.dylib                   0x0000000102eccbb8 _dispatch_worker_thread3 + 140

13  libsystem_pthread.dylib             0x00000001936a22b8 _pthread_wqthread + 1288

14  libsystem_pthread.dylib             0x00000001936a1da4 start_wqthread + 4

)

2017-02-02 13:47:20.277809 wikitudetest[4170:1683455] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid parameter not satisfying: _eaglCameraContext'

*** First throw call stack:

(0x19460e1c0 0x19304855c 0x19460e094 0x19509b79c 0x1029e1430 0x1029cb4e4 0x1029df704 0x102ebd25c 0x102ebd21c 0x102ecab54 0x102ec0ce4 0x102ecce6c 0x102eccbb8 0x1936a22b8 0x1936a1da4)

libc++abi.dylib: terminating with uncaught exception of type NSException

(lldb)

Login or Signup to post a comment