# Utilities & platform

General-purpose helpers under `Public/Utilities/`. None expose positional values, so no cm ↔ m conversion applies here.

## EPlatformTypes

<Badge tone="type">UENUM</Badge> <Badge tone="warn">⚠️ unverified</Badge>

The runtime/XR platform a client advertises (also `AAR51SDK.Platform`). `UENUM` without `BlueprintType` — reflected and C++-usable; ⚠️ whether it appears in Blueprint dropdowns without `BlueprintType` is unconfirmed.

| Value | Name | | Value | Name |
|---|---|---|---|---|
| 0 | `PC` | | 7 | `HtcVive` |
| 1 | `HoloLens` | | 8 | `OpenXrTethered` |
| 2 | `HoloLens2` | | 9 | `OpenXrMobile` |
| 3 | `Android` | | 10 | `PicoNeo3Pro` |
| 4 | `MagicLeap` | | 11 | `OvrTethered` |
| 5 | `OculusRift` | | 12 | `HtcFocus3` |
| 6 | `OculusQuest` | | | |

<ApiMember name="IsPlatformVr" kind="method" tags="static, C++ only" id="isplatformvr">

```cpp
static bool IsPlatformVr(EPlatformTypes platform);
```

<Returns type="bool">`true` for VR/MR headsets (HoloLens, HoloLens2, HtcVive, OculusQuest, OculusRift, OpenXrTethered, OpenXrMobile, PicoNeo3Pro, OvrTethered, HtcFocus3); `false` for `PC`, `Android`, `MagicLeap`</Returns>

Header-inline free function (not a `UFUNCTION`). Useful to branch desktop vs VR behavior.

</ApiMember>

## UNetworkUtils

Moved to [`UNetworkUtils`](/docs/sdk-api/unreal-api/classes/unetworkutils).

## Logging — the `AR51SDK` category

<Badge tone="type">log category + macro</Badge>

`Public/Utilities/Debug.h` declares the SDK's UE log category and a convenience macro:

- `DECLARE_LOG_CATEGORY_EXTERN(AR51SDK, Log, All)` — reference the `AR51SDK` category to filter SDK output (`Log AR51SDK ...` in the console / Output Log).
- `#define LOG(Format, ...)` — wraps `UE_LOG(AR51SDK, Log, ...)` and auto-prefixes `__FUNCTION__` + `__LINE__`. For SDK/plugin C++ code; not Blueprint-relevant.

## UnrealThread

Moved to [`UnrealThread`](/docs/sdk-api/unreal-api/classes/unrealthread).

## ISingleton&#60;T&#62;

<Badge tone="type">template class</Badge> <Badge>C++ only</Badge>

A CRTP base providing a GC-aware singleton via `TWeakObjectPtr<T>` (`Public/Utilities/ISingleton.h`). The protected constructor registers the instance automatically when a `T` is created.

```cpp
static T* Instance();   // the live singleton, or nullptr if none/GC'd (logs a notice)
```

A game dev integrating against SDK-provided singletons calls `T::Instance()` (surfaced per component as each `Get…Singleton()` accessor).

:::note[Internal — not documented]
`UEvent<TSender,TArgs>` (use UE's native delegates instead), `TaskBase` / `Task<T>` internals, `AutoResetEvent`, `Filters/*` (`KalmanFilter1D`, `MovingAverage`, `MovingMedian`), `Heaps/*`, `EnableGrpcIncludes` / `DisableGrpcIncludes`, and `TTransform` internals are excluded.
:::
