Author: Cristian Vrabie

Reading text files is damn slow on Android!

In a Android application I wanted to use Scanner class to read a list of floats from a text file (it’s a list of vertex coordinates for OpenGL). Exact code is: Scanner in = new Scanner(new BufferedInputStream(getAssets().open(""))); final float[] vertexes = new float[nrVertexes]; for(int i=0;i vertexes[i] = in.nextFloat(); } It […]

Proper way to add/remove OverlayItems

Some time ago I contributed to an app for Android which had to manage a lot of Google map OverlayItems. The Google API support and performance for overlay items is satisfactory while you have a manageable amount of items but gets messy if you have lots and lots of items. […]