Basic Shape Drawer
This example uses the BasicShapeDrawer class to render a 2D overlay directly on top of the map. As the user browses the map, the app looks up which country lies under the map centre and draws a panel listing that country's speed limits - one row per coverage type (within town, outside town, express road, motorway) - each shown as a red speed sign next to a road-type icon. The panel is redrawn every frame, so it updates live as the map is panned across borders.
Creating the canvas and shape drawer
A BasicShapeDrawer draws onto a Canvas, which is bound to the map's rendering surface. Once the GL surface is created, the example produces a full-screen Canvas (a normalized RectF from 0,0 to 1,1) and a BasicShapeDrawer on top of it.
Drawing on every frame
The overlay is painted through onDrawFrameCustom, a hook invoked for each rendered map frame. It transforms the map-view centre to WGS coordinates and asks MapDetails for the country code there. To avoid recomputing on every frame, the country name and its speed limits are only refreshed when the centre crosses into a new country. While a country is known, the speed-limit panel is drawn.
Drawing the panel background and title
drawSpeedLimitsPanel measures the country name with getTextWidth / getTextAscent, sizes the panel to fit either the title or two sign columns, and draws a semi-transparent white background with drawRectangle before placing the country title with drawText. It then iterates the speed limits and, based on each limit's coverage, draws a row with the matching road-type texture.
Drawing a speed-limit sign
Each row is a speed sign followed by a road-type icon. The sign is built from two filled circles drawn with drawCircle - a red ring with a smaller white circle inside it - the limit value is centred on top with drawText, and the road-type icon is placed to the right with drawTextureRectangle.
Loading the road-type icon textures
The road-type icons are PNG assets that must be uploaded to the shape drawer as textures before they can be drawn. createFlagTexture reads each asset into a DataBuffer, wraps it in an Image, and registers it with shapeDrawer.createTexture, returning a texture id used later by drawTexturedRectangle.

