Hi Luke, Thx for your message. I had a look at our Android examples and internal implementation. The way it is on Android is not exactly what we want and we will update our Android SDK with one of the next releases to make it easier what you try to achieve.
For now, please try to setup your own 30 fps loop (does/should not rely on a view/render loop) and call the RenderExtension.onDrawFrame() method (don't forget about all the other lifecycle related methods from the RenderExtension interface) in this loop. This will still do some work in the background which you're not interested in, but it's the only way you have right now. Inside the onDrawFrame method we update our SDK logic and render new frames although it should only contain the render updates. Without a onDrawFrame the SDK will not update the CV results and call the registered Listeners, so you need to call this method in order to receive recognized target updates.
over 7 years ago
I am running the native SDK and have been modifying the example code. I need to be able to have the information given by the Wikitude tracking engine, i.e.. the RecognizedTarget object that it gives the ClientTrackerEventListener, but I need to not be showing the camera on screen. To test if this is happening I put a simple Log.v call in onTracking (Log spam, I know) to see if the ClientTracker is still running. This seems like a fairly simple use case, but the ClientTracker seems to be reliant on the SurfaceView and Renderer displaying on the screen. I have tried commenting out where the SurfaceView is add to the layout, but this causes the tracking to stop. The same happens when I comment out the call to RenderExtension.onDrawFrame in my Renderer's onDrawFrame. I am modifying the SimpleClientTrackingActivity in the given example code. I have changed the license over from the sample license to a trial license.
I would prefer if their is a way to allow the ClientTracker to run without an associated View in the activity. My next lines of attack are to try to the the view to be 1 pixel wide and tall in the corner or overlaid with another View. Any help with either of those would be appreciated. Thank you!