01-21-2013 10:28 AM
I'm creating an app which has a mapview in it.
With that in mind, I've copied in example code from the custommapview sample on GitHub.
After a little head scratching I found that I needed to update my the LIBS setting in my .PRO file, so the app would build.
I now have an app which has a map on a TAB which I can switch too when i need to look things up on the map.
The problem is that 90% of the time I activate the tab which has the map on, it doesn't work.
I get a black area shown for less than half a second and then I get an off-white area displayed in its place.
In the 10% of times, the off-white area gets filled in with map tiles. When it errors, I get this...
NBRE_GLTexture::Create2DTexture: glGenTextures failed! texture name=InternalTexture, nbmID=T_BR7_2_PNG_23_63_39, offset=0, memory addr=9786d48 glError = 0
eglSwapBuffers: an EGLSurface argument does not name a valid surface configured for rendering
... x100 or more.
Has anyone else seen this and is there a solution available?
01-21-2013 10:41 AM
take a look at this thread
I gave samoe tips
01-23-2013 09:30 AM
I think I've got a solution to my problem.
I've observed that the mapview doesn't like being re-rendered in quick succession.
This can happen if you have the mapview misplaced in your container heirarchy and it gets resized for some reason.
Especially if you add a TextField control to the same page, to do some geocoding for example.
The act of displaying the keyboard (scrolling in from the bottom) can cause the mapview to be resized.
To workaround this, I've had to put a minHeight value that matches the preferredHeight to stop the mapview shrinking as the keyboard grabs screen real estate.