I am working on an Android application that requires a two-dimensional graphical representation with a large set of objects. Here is what I basically need to display:

In my case, there may be hundreds of spatially distributed objects. This view will behave like a map, so the user can scroll horizontally and vertically, zoom in and out. It also requires click event handling, so the user can click on any triangle, and then I have to display some advanced information related to that particular triangle.
I mainly worry about 3 things:
- If I re-draw all the objects in my
onDraw() handler, it will be very slow. In addition, there are cases when I donโt even need to draw all these objects, since some of them are invisible depending on the zoom level and scroll position. This requires the use of quad trees, which I do not want to do manually. - All these objects are defined as (x, y, rotation, type), so if the client decides that we need the "show all" button, I will have to implement a function to calculate the bounding fields.
- I need to be able to handle click events and (possibly) drag and drop for all of these shapes.
Is there a library that can help me with these tasks? I just do not want to spend 3 days on things that, I think, have already been implemented.
source share