# SceneCaptureComponent2d gap issue

**URL:** <https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197>\
**Category:** Rendering\
**Tags:** portal, scenecapture2d, Scene-Capture, unreal-engine, render-target, Rendering, question\
**Created:** [February 3, 2021, 3:37pm UTC](https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197 "2021-02-03T15:37:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vernyvoda](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Vernyvoda](https://forums.unrealengine.com/u/Vernyvoda)\
**Post date:** [February 3, 2021, 3:37pm UTC](https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197/1 "2021-02-03T15:37:50Z")

</div>

Hi everyone.

I wanted to ask for help because I have a problem with USceneCaptureComponent2D. I used it to create a portal. And everything looks good, but if I move the camera quickly there is a gap.  
This is how I calculate scene component camera location and rotation:

> **[monosnap.com](https://monosnap.com/file/0glzgCwgACXbIUWeTRNmeChO7ELUnn)**
>
> Monosnap screenshot tool for Mac and PC with own cloud storage. Take screenshots, record videos and upload files directly to the cloud. Just in one click.

And projectile matrix:

> **[monosnap.com](https://monosnap.com/file/sPWLlO4umm75NtB3IA5nc2ezmJnc7T)**
>
> Monosnap screenshot tool for Mac and PC with own cloud storage. Take screenshots, record videos and upload files directly to the cloud. Just in one click.

Maybe someone has encountered this and can give a hint.

The problem can be seen in the video. [Monosnap](https://monosnap.com/file/DvFovzyuPRqEJkULEiq6EfbIPG0COM)

Thanks.

---

<div class="post-metadata">

**Author:** ![Krxtopher](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Krxtopher](https://forums.unrealengine.com/u/Krxtopher)\
**Post date:** [February 5, 2021, 4:50am UTC](https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197/2 "2021-02-05T04:50:50Z")

</div>

I believe what you are seeing is caused by the fact that the SceneCapture2D’s output is always going to lag 1 frame behind the game’s current render frame. I think you would need to somehow force the SceneCapture2D to do its render _before_ the player camera does its render. However, I don’t know enough about how to hijack UE’s render loop to suggest a fix, but maybe knowing this root cause will help in your search for a workaround?

---

<div class="post-metadata">

**Author:** ![Vernyvoda](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Vernyvoda](https://forums.unrealengine.com/u/Vernyvoda)\
**Post date:** [February 5, 2021, 1:53pm UTC](https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197/3 "2021-02-05T13:53:25Z")

</div>

The problem was in frame synchronization. I used  
PrimaryActorTick.TickGroup = ETickingGroup::TG\_PostUpdateWork  
and it solved the problem.  
Thanks!

---

<div class="post-metadata">

**Author:** ![Vernyvoda](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Vernyvoda](https://forums.unrealengine.com/u/Vernyvoda)\
**Post date:** [February 12, 2021, 12:07am UTC](https://forums.unrealengine.com/t/scenecapturecomponent2d-gap-issue/478197/4 "2021-02-12T00:07:54Z")

</div>

The problem was in frame synchronization. I used PrimaryActorTick.TickGroup = ETickingGroup::TG\_PostUpdateWork and it solved the problem. Thanks!
