Package com.mapbox.mapboxsdk.maps.renderer

Contains the Mapbox Maps Android Renderer API classes.

Types

Name Summary
MapRenderer
abstract class MapRenderer : MapRendererScheduler
The MapRenderer encapsulates the GL thread.
MapRendererRunnable
open class MapRendererRunnable : Runnable
Peer class for Runnables to be scheduled on the MapRenderer thread.
MapRendererScheduler
interface MapRendererScheduler
Can be used to schedule work on the map renderer thread or request a render.

MapRenderer

abstract class MapRenderer : MapRendererScheduler

The MapRenderer encapsulates the GL thread.

Performs actions on the GL thread to manage the GL resources and render on the one end and acts as a scheduler to request work to be performed on the GL thread on the other.

Constructors

Name Summary
MapRenderer open fun MapRenderer(context: Context, localIdeographFontFamily: String)

Functions

Name Summary
onDestroy
open fun onDestroy()
onPause
open fun onPause()
onResume
open fun onResume()
onStart
open fun onStart()
onStop
open fun onStop()
queueEvent
@CallSuper()
open fun queueEvent(runnable: MapRendererRunnable)
May be called from any thread.
abstract fun queueEvent(runnable: Runnable)
requestRender
abstract fun requestRender()
setMaximumFps
open fun setMaximumFps(maximumFps: Int)
The max frame rate at which this render is rendered,but it can’t excess the ability of device hardware.

Properties

Name Summary
onFpsChangedListener private open var onFpsChangedListener: MapboxMap.OnFpsChangedListener

Inheritors

Name
GLSurfaceViewMapRenderer
TextureViewMapRenderer

onDestroy

open fun onDestroy()

onFpsChangedListener

private open var onFpsChangedListener: MapboxMap.OnFpsChangedListener

onPause

open fun onPause()

onResume

open fun onResume()

onStart

open fun onStart()

onStop

open fun onStop()

queueEvent

@CallSuper()

open fun queueEvent(runnable: MapRendererRunnable)

May be called from any thread.

Called from the native peer to schedule work on the GLthread. Explicit override for easier to read jni code.

See also

Name Summary
com.mapbox.mapboxsdk.maps.renderer.MapRendererRunnable  
   
Parameters
Name Summary
runnable
the runnable to execute
   
   

setMaximumFps

open fun setMaximumFps(maximumFps: Int)

The max frame rate at which this render is rendered,but it can’t excess the ability of device hardware.

Parameters
Name Summary
maximumFps
Can be set to arbitrary integer values.
   
   

MapRendererRunnable

open class MapRendererRunnable : Runnable

Peer class for Runnables to be scheduled on the MapRenderer thread. The actual work is performed in the native peer.

Constructors

Name Summary
MapRendererRunnable open fun MapRendererRunnable(nativePtr: Long)Constructed from the native peer constructor

Functions

Name Summary
run
open fun run()
abstract fun run()

run

open fun run()

MapRendererScheduler

interface MapRendererScheduler

Can be used to schedule work on the map renderer thread or request a render.

Functions

Name Summary
queueEvent
abstract fun queueEvent(runnable: Runnable)
requestRender
abstract fun requestRender()

Inheritors

Name
MapRenderer

queueEvent

abstract fun queueEvent(runnable: Runnable)

requestRender

abstract fun requestRender()