# Framerate much lower in packaged build on Oculus than in editor or on Vive

**URL:** <https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654>\
**Category:** Debugging, Optimization, & Profiling\
**Tags:** oculus-vr, unreal-engine, Performance, packaged-game, question\
**Created:** [May 22, 2018, 3:16am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654 "2018-05-22T03:16:43Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kmack](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/kmack/32/706181_2.png) [@Kmack](https://forums.unrealengine.com/u/Kmack)\
**Post date:** [May 22, 2018, 3:16am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/1 "2018-05-22T03:16:43Z")

</div>

I’m running into an issue whereby a packaged shipping build is performing much more slowly on Oculus Rift CV1 than it does in editor, but the same packaged executable runs fine on HTC Vive.

Has anybody else encountered something like this? Are there settings or details I should be aware of that differ between the two platforms?

Thanks!

---

<div class="post-metadata">

**Author:** ![Thomas\_Low](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Thomas\_Low](https://forums.unrealengine.com/u/Thomas_Low)\
**Post date:** [October 30, 2018, 7:25pm UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/2 "2018-10-30T19:25:01Z")

</div>

I am having similar issues, but haven’t tried my Vive yet… I need to get it working in the Oculus! from 90 FPS in editor to 14 FPS packaged!!! I’ve tried Instanced Stereo, Dynamic Resolution Reduction, I’ve unchecked the smoothed framerate option, and I’m only rendering a small window on the monitor in addition to the Oculus.

Did you ever find a smoking gun, and if so, how did you solve this?

---

<div class="post-metadata">

**Author:** ![Thomas\_Low](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Thomas\_Low](https://forums.unrealengine.com/u/Thomas_Low)\
**Post date:** [October 31, 2018, 1:39am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/3 "2018-10-31T01:39:03Z")

</div>

The issue appears related to use of rendertarget2d. I’ve tried various render target formats. no improvement so far unless I disable this in my application.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_e1d5ba97](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_e1d5ba97](https://forums.unrealengine.com/u/anonymous_user_e1d5ba97)\
**Post date:** [January 7, 2019, 10:33am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/4 "2019-01-07T10:33:51Z")

</div>

I have the same problem. Works fine in the editor, but the packaged version gives me ~3 fps when using the Oculus Rift.

Even if reduce the scene complexity to an almost empty scene with default floor (but leaving the spectator camera which use rendertarget2d) I can never get more than 45 fps.

The HTC Vive works perfectly fine in both editor and packaged version.

I am using UE 4.20.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_e1d5ba97](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_e1d5ba97](https://forums.unrealengine.com/u/anonymous_user_e1d5ba97)\
**Post date:** [February 20, 2019, 10:26pm UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/5 "2019-02-20T22:26:39Z")

</div>

Confirmed bug by Epic  
Issue: UE-70352

> **[The Unreal Engine Issues and Bug Tracker](https://issues.unrealengine.com/issue/UE-70352)**
>
> Welcome to the Unreal Engine Issue and Bug Tracker. You can check the status of an issue and search for existing bugs. See latest bug fixes too.

---

<div class="post-metadata">

**Author:** ![XGibbousX](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@XGibbousX](https://forums.unrealengine.com/u/XGibbousX)\
**Post date:** [September 29, 2019, 8:56am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/6 "2019-09-29T08:56:33Z")

</div>

This issue is due to assigning a RenderTarget2D to a SceneCaptureComponent’s “Texture Target”.

This is solved by executing the console command “r.SceneRenderTargetResizeMethod 2” in your BeginPlay event that assigns the RenderTarget2D to the SceneCaptureComponent.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_e1d5ba97](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_e1d5ba97](https://forums.unrealengine.com/u/anonymous_user_e1d5ba97)\
**Post date:** [September 29, 2019, 9:59am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/7 "2019-09-29T09:59:50Z")

</div>

@XGibbousX Thanks for the suggestion. I have not tried your proposed solution yet, since I have all my HMDs at work. But could you elaborate a bit why this should work, i.e. what does that console command actually do? I tried googling the command but can’t find a good description of what actually happens.

Also since this behavior is exclusive to Oculus (Vive’s are unaffected), it should still IMHO be considered a issue.

---

<div class="post-metadata">

**Author:** ![XGibbousX](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@XGibbousX](https://forums.unrealengine.com/u/XGibbousX)\
**Post date:** [September 30, 2019, 12:12am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/8 "2019-09-30T00:12:26Z")

</div>

@anonymous_user_b677394b Thank you too. I can only guess as to why this works. I found the following on r.SceneRenderTargetResizeMethod though:

```
Control the scene render target resize method:
0: Resize to match requested render size (Default) (Least memory use, can cause stalls when size changes e.g. ScreenPercentage)
1: Fixed to screen resolution.
2: Expands to encompass the largest requested render dimension. (Most memory use, least prone to allocation stalls.)

```

It seems that there is some conflict between the Oculus and Unreal Engine resizing a scene capture onto a render target. It seems that option “2” is the least performant but highest reliability based on the description above.

I agree that this is a big issue and should be fixed by Epic. There’s even an official bug report that Epic claims is “Fixed” in Unreal Engine 4.23 but I tried it and it’s not fixed. Therefore, this is the only way right now and it works very well for me.

Please let me know if this worked out for you :]

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_e1d5ba97](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_e1d5ba97](https://forums.unrealengine.com/u/anonymous_user_e1d5ba97)\
**Post date:** [September 30, 2019, 6:52am UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/9 "2019-09-30T06:52:10Z")

</div>

@XGibbousX Just tried it and it works.

This is the level blueprint I ended up using:

 ![288809-unreal-oculus-spectator-hack.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/8/b/f8b5568bc2bb9ca53624142e208c53d47ddef87a.png)

The official bug report that you refer to is probably UE-70352, which I reported. I have contacted Epic again about this issue and they have been able to reproduce it with 4.23 as well. I have ongoing communications with them about this issue and I will report your workaround to them as well.

---

<div class="post-metadata">

**Author:** ![XGibbousX](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@XGibbousX](https://forums.unrealengine.com/u/XGibbousX)\
**Post date:** [September 30, 2019, 2:51pm UTC](https://forums.unrealengine.com/t/framerate-much-lower-in-packaged-build-on-oculus-than-in-editor-or-on-vive/425654/10 "2019-09-30T14:51:53Z")

</div>

@anonymous_user_b677394b Thank you for the update. I am very happy that it helped and that you are in communication with Epic about it.
