# Passthrough Camera API

**URL:** <https://forums.unrealengine.com/t/passthrough-camera-api/2655374>\
**Category:** XR Development\
**Tags:** image, android-device, unreal-engine, oculus-vr\
**Created:** [September 10, 2025, 12:06pm UTC](https://forums.unrealengine.com/t/passthrough-camera-api/2655374 "2025-09-10T12:06:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![FonseCode1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@FonseCode1](https://forums.unrealengine.com/u/FonseCode1)\
**Post date:** [September 10, 2025, 12:06pm UTC](https://forums.unrealengine.com/t/passthrough-camera-api/2655374/1 "2025-09-10T12:06:08Z")

</div>

# **Android Camera2 API for Unreal Engine (UE 5.6)**

High-performance Android Camera2 capture for Unreal Engine 5.6 (Vulkan-only), with sample apps for QR detection (quirc) and luma-based (same as grayscale image) edge detection.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/1/7/9172fa901df7790b6fcc735f93006b9701304076.jpeg)

## **✨ “AndroidCamera2” Plugin**

- **Video Campture** via Android **Camera2** in **YUV I420** format.

- **Basic 3A controls** (device-dependent support): autofocus modes, auto-exposure and antibanding modes, auto-white-balance modes.

- **Device enumeration & control** : list cameras, initialize camera, pause/resume video capturing, stop video capturing. This simple funcionalities can be used with `UAndroidCamera2BlueprintLibrary`.

- **GPU-friendly outputs** : three `UTextureRenderTarget2D` targets for I420 planes: **Y (Luma)**, **U (Chroma blue-difference)**, **V (Chroma red-difference)**. You can assign your own `UTextureRenderTarget2D` in  
**Project Settings → Plugins → Android Camera2 → Render and Buffering Settings**

- Fast YUV-RGB: material example using `/Plugin/AndroidCamera2/Private/YUVUtils.ush`.  
See sample material at:  
`/AndroidCamera2/Materials/MaterialsSamples/M_AndroidCamera2RGB_SampleUI`

- **Raw access API (BP/C++)**: `UAndroidCamera2BlueprintLibrary` and `UAndroidCamera2Subsystem` to consume Y/U/V buffers directly for custom processing.  
You can see an example of use in the sample Camera UI at : `/AndroidCamera2/UISample/CameraUI`.

## **🔒 Permissions (Meta Quest 3 – optional)**

To access Meta Quest 3 passthrough cameras you must request `horizonos.permission.HEADSET_CAMERA` pemisson.

Enable in:  
**Project Settings → Plugins → Android Camera2 → Permissions Meta Quest**

- ✅ Request Headset Camera Permission  
See [Meta documentation](https://developers.meta.com/horizon/documentation/spatial-sdk/spatial-sdk-pca-overview/).

By default the plugin will require `android.permission.CAMERA` permisson.

> On the headset: enable **Headset camera** permission for your app:  
> **Privacy & safety \> App permissions \> Headset cameras**

A ready-to-run configuration lives in branch [Passthorugh\_Quest3](https://github.com/yesidfonseca/Camera2AndroidApi/tree/Passthrough_Quest3).
