Google.Android.PerformanceTuner

Summary

Enumerations

ErrorCode{
  Ok = 0,
  NoSettings = 1,
  NoSwappy = 2,
  InvalidDefaultFidelityParams = 3,
  NoFidelityParams = 4,
  TuningforkNotInitialized = 5,
  InvalidAnnotation = 6,
  InvalidInstrumentKey = 7,
  InvalidTraceHandle = 8,
  Timeout = 9,
  BadParameter = 10,
  B64EncodeFailed = 11,
  JniBadVersion = 12,
  JniBadThread = 13,
  JniBadEnv = 14,
  JniException = 15,
  JniBadJvm = 16,
  NoClearcut = 17,
  NoFidelityParamsInApk = 18,
  CouldntSaveOrDeleteFps = 19,
  PreviousUploadPending = 20,
  UploadTooFrequent = 21,
  NoSuchKey = 22,
  BadFileOperation = 23,
  BadSettings = 24,
  AlreadyInitialized = 25,
  NoSettingsAnnotationEnumSizes = 26,
  DownloadThreadAlreadyStarted = 27,
  GenerateTuningParametersError = 29,
  GenerateTuningParametersResponseNotSuccess = 30,
  NoMoreSpaceForLoadingTimeData = 31,
  NoMoreSpaceForFrameData = 32,
  InvalidLoadingHandle = 33,
  DuplicateStartLoadingEvent = 34,
  MeteredConnectionDisallowed = 35,
  PlatformNotSupported = 100,
  InvalidFidelity = 101,
  InvalidMode = 102
}
enum
All the error codes that can be returned by Tuning Fork functions.
InstrumentationKeys{
  RawFrameTime = 64000,
  PacedFrameTime = 64001,
  CpuTime = 64002,
  GpuTime = 64003
}
enum
Instrument keys indicating time periods within a frame.
LifecycleState enum
The set of states that the ReportLifecycleEvent method accepts.

Classes

Google.Android.PerformanceTuner.AndroidPerformanceTuner< TFidelity, TAnnotation >

The main class to instantiate to set up and run the Android Performance Tuner.

Google.Android.PerformanceTuner.LoadingTimeMetadata

Metadata recorded with a loading time event.

Google.Android.PerformanceTuner.Result< T >

Represents a value returned by an operation, with the associated error code.

Structs

Google.Android.PerformanceTuner.MetricLimits

Limits on the number of metrics of each type.

Enumerations

ErrorCode

 ErrorCode

All the error codes that can be returned by Tuning Fork functions.

Properties
AlreadyInitialized

TuningFork_init was called more than once.

B64EncodeFailed

Could not encode a protobuf.

BadFileOperation

General file error.

BadParameter

Generic bad parameter.

BadSettings

Invalid tuningfork_settings.bin file.

CouldntSaveOrDeleteFps

Error calling TuningFork_saveOrDeleteFidelityParamsFile.

DownloadThreadAlreadyStarted

TuningFork_startFidelityParamDownloadThread was called more than once, or called when TuningFork_init has already started download.

DuplicateStartLoadingEvent

TuningFork_startRecordingLoadingTime was called with the same parameters twice without a stop function inbetween.

GenerateTuningParametersError

An error occurred parsing the response to generateTuningParameters.

GenerateTuningParametersResponseNotSuccess

The response from generateTuningParameters was not a success code.

InvalidAnnotation

Invalid parameter to TuningFork_setCurrentAnnotation.

InvalidDefaultFidelityParams

fpDefaultFileNum is out of range.

InvalidFidelity

Fidelity message is invalid.

InvalidInstrumentKey

Invalid instrument key passed to a tick function.

InvalidLoadingHandle

Invalid handle passed to TuningFork_startRecordingLoadingTime.

InvalidMode

Using incorrect API for default/custom modes.

InvalidTraceHandle

Invalid handle passed to TuningFork_endTrace.

JniBadEnv

Jni error - obsolete

JniBadJvm

Jni error - obsolete

JniBadThread

Jni error - obsolete

JniBadVersion

Jni error - obsolete

JniException

Jni error - an exception was thrown.

See logcat output.

MeteredConnectionDisallowed

An HTTP request could not be made because there is no unmetered connection available.

NoClearcut

Obsolete

NoFidelityParams

No fidelity parameters found at initialization.

NoFidelityParamsInApk

No dev_tuningfork_fidelityparams_#.bin found in assets/tuningfork.

NoMoreSpaceForFrameData

Not enough space for metric data was allocated at start-up: increase Settings.max_num_metrics.frame_time or check max_num_instrument_keys

NoMoreSpaceForLoadingTimeData

Not enough space for metric data was allocated at start-up: increase Settings.max_num_metrics.loading_time

NoSettings

No tuningfork_settings.bin found in assets/tuningfork.

NoSettingsAnnotationEnumSizes

Missing part of tuningfork_settings.bin.

NoSuchKey

No such key when accessing file cache.

NoSwappy

Not able to find the required Swappy functions.

Ok

No error.

PlatformNotSupported

The game or app is run on a platform not supporting Tuning fork.

PreviousUploadPending

Can't upload since another request is pending.

Timeout

Timeout in request for fidelity parameters.

TuningforkNotInitialized

A call was made before Tuning Fork was initialized.

UploadTooFrequent

Too frequent calls to TuningFork_flush.

InstrumentationKeys

 InstrumentationKeys

Instrument keys indicating time periods within a frame.

Keys 64000-65535 are reserved

Properties
CpuTime

The time between frame start and the call to Swappy_swap.

GpuTime

The time between buffer swap and GPU fence triggering.

PacedFrameTime

Frame time between ends of eglSwapBuffers calls or Vulkan queue present.

RawFrameTime

If GPU time is available, this is MAX(CpuTime, GpuTime).

If not, this is the same as PacedFrameTime

LifecycleState

 LifecycleState

The set of states that the ReportLifecycleEvent method accepts.