Forum Xamarin.Android

How do I use 3rd party graphics stack with Xamarin

demogalliumdemogallium USMember, University

I'm using Prism and Unity, and their corresponding HelloWorld sample code. I'm totally new to Android/Xamarin/Prism/Unity and I'm trying to use a 3rd party graphics stack, which is based on openGL and provided as a jar, to draw some simple graphics (lines and text) and hopefully a map underneath the "Hello World" string. I have created a jar binding dll for the jar using visual studio and I'm able to reference it following the article from the link.
I added code to create a "viewport" object (through the binding) in the OnCreate() of MainActivity.cs and added the drawing code in the OnResume() method. When I deploy and run the apk, I get "call to OpenGL ES API with no current context" when the OnResume() is called. How do I pass the context to the graphics stack (say through the viewport constructor or through other means)? Any help is much appreciated.


Sign In or Register to comment.