# Reset Camera

### Introduction

If you're building a seated or standing experience, you can recenter Unity's world origin at the user's current position and orientation by calling the API `NRHMDPoseTracker.ResetWorldMatrix` . The **HelloMR-ResetCamera** sample scene demonstrates how to reset the camera with this API in an app.&#x20;

The main script is `CameraResetController.cs` which uses a boolean to support reset camera with pitch as well.

### Developer Guide

1. Create a new project in Unity with NRSDK. Refer to [Getting Started with NRSDK](../../nrsdk-fundamentals/quickstart-for-android) for more setting up instructions.
2. Create a canvas and a button;
3. Drag the script CameraSmoothFollow.cs to the inspector of canvas for sticking the menu in your view so you can click your reset button easily. You can adjust the speed of the button moving with your view with `Follow Speed`.                   ![](https://content.gitbook.com/content/yXoV7SMVFQhr75lOIoQv/blobs/60VSwvijbeEramJ7JPCn/image.png)
4. Drag the script CameraResetController.cs and CanvasRaycastTarget.cs to the inspector of canvas;
5. Set the OnClick() event of your button, drag the canvas to the event;![](https://content.gitbook.com/content/yXoV7SMVFQhr75lOIoQv/blobs/exoUzS73l8mY35OyFF43/image.png)
6. Choose the function `CameraResetController` -> `ResetCameraToOrigin(bool)`![](https://content.gitbook.com/content/yXoV7SMVFQhr75lOIoQv/blobs/fi0vFfgujSKGr68PDFGe/image.png)
7. That's it. You can build your app and test the recenter effect. If you want to reset the camera with pitch, just repeat the upper steps and choose the check box.  ![](https://content.gitbook.com/content/yXoV7SMVFQhr75lOIoQv/blobs/iPM2W1Oowzpq73foqUTg/image.png)





