# TFSettings

`#include <tuningfork.h>`

Initialization settings Zero any values that are not being used.

## Summary

| ### Public attributes ||
|---|---|
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a88e9ace6b6d25dfdf6ee281f1840ace3` | `const char *` A null-terminated string containing the endpoint that Tuning Fork will connect to for parameter, upload and debug requests. |
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a89cd30d7f2359b54c20ac53aca6aa629` | `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/group/tuningfork#group__tuningfork_1gaf780faded2692da73f8d7ee37499d171` Callback If set, this is called with the fidelity parameters that are downloaded. |
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a25e55876c9296aaec34b4dbb8772ceba` | `const https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-cache#struct_t_f_cache *` Cache object to be used for upload data persistence. |
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a3ca27ab14efce1c40d4b70f8e567da33` | `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/group/tuningfork#group__tuningfork_1ga43b1819af457676a72f228c08068fed4` The address of the Swappy_injectTracers function. |
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a5c2d98b44ddf8084bc7ef9eff516d451` | `uint32_t` The version of Swappy that swappy_tracer_fn comes from. |
| `https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/t-f-settings#struct_t_f_settings_1a3ab649a2ec035694d4b035b742d56dd9` | `const https://developer.android.com/games/sdk/reference/performance-tuner/custom-engine/struct/c-protobuf-serialization#struct_c_protobuf_serialization *` A serialized protobuf containing the fidelity parameters to be uploaded for training. |

## Public attributes

### endpoint_uri_override

```gdscript
const char * TFSettings::endpoint_uri_override
```
A null-terminated string containing the endpoint that Tuning Fork will connect to for parameter, upload and debug requests.

This overrides the value in base_uri in the settings proto and is intended for debugging purposes only.

### fidelity_params_callback

```scdoc
ProtoCallback TFSettings::fidelity_params_callback
```
Callback If set, this is called with the fidelity parameters that are downloaded.

If unset, you need to call TuningFork_getFidelityParameters yourself.

### persistent_cache

```gdscript
const TFCache * TFSettings::persistent_cache
```
Cache object to be used for upload data persistence.

If unset, data is persisted to /data/local/tmp/tuningfork

### swappy_tracer_fn

```scdoc
SwappyTracerFn TFSettings::swappy_tracer_fn
```
The address of the Swappy_injectTracers function.

If this is unset, you need to call TuningFork_tick yourself. If it is set, telemetry for 4 instrument keys is automatically recorded.

### swappy_version

```scdoc
uint32_t TFSettings::swappy_version
```
The version of Swappy that swappy_tracer_fn comes from.

### training_fidelity_params

```gdscript
const CProtobufSerialization * TFSettings::training_fidelity_params
```
A serialized protobuf containing the fidelity parameters to be uploaded for training.

Set this to nullptr if you are not using training mode. Note that these are used instead of the default parameters loaded from the APK, if they are present and there are neither a successful download nor saved parameters.