I've found that if I take the SDK sample, and comment out line 43 of GLRenderer (mWikitudeRenderExtension.onDrawFrame(unused);) the CustomCameraActivity will quit after ~4 minutes or running. This does not occur with the line uncommented.
Any idea why?
Seems that I have to answer quite a lot of questions here. Let's see if we can clarify some of them:
First, the Wikitude Native SDK should fulfil all your needs in regards to rendering flexibility. If you have your own custom rendering, you only need to call the WikitudeRenderExtensions update and draw methods. `Update` triggers internal Wikitude SDK calculations and `draw` updates the given OpenGL texture with the current camera image (in case you didn't setup your own input plugin). I'm not sure if you also want your own camera access implementation or if the standard Wikitude implementation is enough. In case you want your own camera implementation, you don't need to call `draw` (I created a internal ticket to investigate the crash after ~4 minutes).
If you're fine with the default Wikitude camera and you want the camera image rendered into a OpenGL texture, make sure that you set the texture id like you mentioned before (getCameraManager().setTextureId) and that you call the render extension `draw` method before you do any other rendering.
Did you had a look at our example application? They also do some custom rendering (rendering of the augmentations) after the camera image is rendered.
I guess we will write some more messages back and forth, so don't hesitate to ask any further question you have ;)
Hi, attempting to use a custom renderer with Wikitude on Android and I'm having trouble accessing the camera data in an OpenGL shader. I've tried several approaches to accomplish this: