# How can I create a multiple-camera/multiple-monitor Setup?

**URL:** <https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201>\
**Category:** C++\
**Tags:** multiple-monitors, unreal-engine, question, CPP\
**Created:** [July 14, 2014, 3:52pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201 "2014-07-14T15:52:48Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_2eecf72c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2eecf72c](https://forums.unrealengine.com/u/anonymous_user_2eecf72c)\
**Post date:** [July 14, 2014, 3:52pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/1 "2014-07-14T15:52:48Z")

</div>

Hi guys,

So I am currently looking into a feature that’s required for a project, specifically, I have three separate cameras setup in my Player blueprint, and I need all three of them to render to separate views. Each of these views will be fit on a separate monitor, or projected by three separate projectors, based off client requirements.

I have been able to setup my character with three cameras (which honestly is the easiest part of the deal), but where I’m getting stuck is creating three different viewports for these three separate cameras. I tried looking into a previous thread and tried to make some sense of it, but honestly, I find it slightly cryptic:

[https://answers.unrealengine.com/questions/30918/does-ue4-support-multiple-monitors.html](https://answers.unrealengine.com/questions/30918/does-ue4-support-multiple-monitors.html)

More specifically, I am alluding to the section where Mike is talking about the UGameEngine::Init() and the CreateGameWindow and CreateGameViewport methods.

Hunting around a bit more, I found the wiki page for how to override the UGameEngine module:

[https://wiki.unrealengine.com/Create\_Custom\_engine\_classes\_for\_your\_game\_module#Extending\_the\_editor\_engine](https://wiki.unrealengine.com/Create_Custom_engine_classes_for_your_game_module#Extending_the_editor_engine)

Following the methods described here, I have been able to successfully subclass the UGameEngine class into my own class called CTGameEngine. And that’s about all that I’ve been able to do.

I tried setting up my own viewport, but I always end up with an exception. Here’s the offending code:

```
void UCTGameEngine::Init(IEngineLoop * InEngineLoop)
{
	DECLARE_SCOPE_CYCLE_COUNTER(TEXT("UGameEngine Init"), STAT_GameEngineStartup, STATGROUP_LoadTime);

	// Call base.
	UGameEngine::Init(InEngineLoop);
	// Creates the initial world context. For GameEngine, this should be the only WorldContext that ever gets created.
	FWorldContext &InitialWorldContext = CreateNewWorldContext(EWorldType::Game);
	
	// Initialize the viewport client.
	UGameViewportClient* ViewportClient2 = NULL;
	if (GIsClient)
	{
		ViewportClient2 = ConstructObject<UGameViewportClient>(GameViewportClientClass, this);
		ViewportClient2->SetReferenceToWorldContext(InitialWorldContext);
		GameViewport = ViewportClient2;
		InitialWorldContext.GameViewport = ViewportClient2;

		SecondaryViewportClients.Add(ViewportClient2);
	}
	
	if (ViewportClient2)
	{
		ViewportClient2->AddToRoot();
		ViewportClient2->LayoutPlayers();
		//ViewportClient2->SetViewport();
		CreateGameViewport(ViewportClient2);
	}
	bIsInitialized = true;

}

```

This is almost a straight lift from the UGameEngine::Init() documentation.

When I tried to debug it, I found that my ViewportClient2 was a NULL pointer, even though it was actually going through all the steps of creating the ConstructObject, etc.

So, any pointers (pun not intended) on what I may be doing wrong here? And what I should be trying to do instead (other than asking someone else to look into coding this thing, that is not an option)?

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2eecf72c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2eecf72c](https://forums.unrealengine.com/u/anonymous_user_2eecf72c)\
**Post date:** [July 15, 2014, 11:44am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/2 "2014-07-15T11:44:15Z")

</div>

So does anyone have any insights?

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2eecf72c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2eecf72c](https://forums.unrealengine.com/u/anonymous_user_2eecf72c)\
**Post date:** [July 16, 2014, 8:36am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/3 "2014-07-16T08:36:48Z")

</div>

Bumping this up…

---

<div class="post-metadata">

**Author:** ![TheBabelFish](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TheBabelFish](https://forums.unrealengine.com/u/TheBabelFish)\
**Post date:** [August 23, 2014, 12:35am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/4 "2014-08-23T00:35:45Z")

</div>

UGameEngine::Init() calls

```
FString Error;
if(!ViewportClient->Init(Error))
{
	UE_LOG(LogEngine, Fatal,TEXT("%s"),*Error);
}

```

You seem to be missing the Init call to your new ViewportClient

---

<div class="post-metadata">

**Author:** ![CrashAngel](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/crashangel/32/467279_2.png) [@CrashAngel](https://forums.unrealengine.com/u/CrashAngel)\
**Post date:** [May 12, 2015, 7:32pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/5 "2015-05-12T19:32:40Z")

</div>

Hi, Were you able to configure more than one Portview on their monitors?

There is the possibility of posting as was your code? need to do the same for 2 monitors …

---

<div class="post-metadata">

**Author:** ![CrashAngel](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/crashangel/32/467279_2.png) [@CrashAngel](https://forums.unrealengine.com/u/CrashAngel)\
**Post date:** [May 12, 2015, 7:33pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/6 "2015-05-12T19:33:49Z")

</div>

Hi, Were you able to configure more than one Portview on their monitors?

There is the possibility of posting as was your code? need to do the same for 2 monitors …

---

<div class="post-metadata">

**Author:** ![CrashAngel](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/crashangel/32/467279_2.png) [@CrashAngel](https://forums.unrealengine.com/u/CrashAngel)\
**Post date:** [March 13, 2016, 6:53pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/7 "2016-03-13T18:53:43Z")

</div>

Hello friend, I need to do the same thing as you … How did you solve this problem … you could post your code here …

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_5d8c2ae0](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_5d8c2ae0](https://forums.unrealengine.com/u/anonymous_user_5d8c2ae0)\
**Post date:** [April 29, 2016, 11:50am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/8 "2016-04-29T11:50:07Z")

</div>

Have you solved this issue with the information of TheBabelFish? Because i need somethin similiar too.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_5d8c2ae0](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_5d8c2ae0](https://forums.unrealengine.com/u/anonymous_user_5d8c2ae0)\
**Post date:** [July 27, 2016, 1:23pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/9 "2016-07-27T13:23:29Z")

</div>

if this is still a question to you , you should might have a look into here :

> **[Multiple active cameras for 1 player](https://forums.unrealengine.com/showthread.php?50144-Multiple-active-cameras-for-1-player)**
>
> I’m starting a project soon will require different views of the scene to be displayed by different physical monitors, sometimes with asymmetrical split screens per physical monitor (e.g. 3 camera views in one monitor). I’ve searched around and found...

---

<div class="post-metadata">

**Author:** ![MissCaligari](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MissCaligari](https://forums.unrealengine.com/u/MissCaligari)\
**Post date:** [August 25, 2016, 12:26pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/10 "2016-08-25T12:26:36Z")

</div>

This link goes to a “maintenance mode” screen…

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_5d8c2ae0](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_5d8c2ae0](https://forums.unrealengine.com/u/anonymous_user_5d8c2ae0)\
**Post date:** [August 25, 2016, 1:14pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/11 "2016-08-25T13:14:12Z")

</div>

Thats not my fault the whole unreal engine forum is down due to maintenance since yesterday. Be a little patient or just ask me a more detailed question.

I will try to help you solve your problem

Best Regards

---

<div class="post-metadata">

**Author:** ![MissCaligari](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MissCaligari](https://forums.unrealengine.com/u/MissCaligari)\
**Post date:** [August 26, 2016, 3:40pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/12 "2016-08-26T15:40:19Z")

</div>

Thank you for your quick response,

I would like to have your advice.

I’m doing a video mapping project and need to take out each in-game camera to each projector.

I found this for rendering two windows : [GitHub - chaosgrid/ExtraCamWindow: A simple Unreal Engine 4 plugin that allows to have extra game windows with their own camera viewpoints.](https://github.com/chaosgrid/ExtraCamWindow)  
I’ve tried it, it has some glitches but I can see how it’s done.

There is also this tread that explains how to chose the default monitor : [https://www.reddit.com/r/unrealengine/comments/3j7bo4/is\_it\_possible\_to\_choose\_the\_default\_screen\_in\_a/](https://www.reddit.com/r/unrealengine/comments/3j7bo4/is_it_possible_to_choose_the_default_screen_in_a/)  
It may be a best solution but I was wondering if you have access to in-game cameras in the engine class…

Other solution would be using split screen and extend (easiest method).

I’m wandering if it wouldn’t be a best solution to use an external video-mapping software because the screen is not flat so I would need to do some wrapping, one camera renders the 3D scene that is put onto the uv of the wrapped plane to fit with the screen (I would have to do a tool like this : [Projection Mapping Tutorial - Resolume Arena 4 - YouTube](https://youtu.be/SauJLNhnWNQ?t=3m8s)). This plane is rendered by two other cameras that represent each real projector.  
In this case I would have to find a way to send unreal game output to the mapping software, I guess it’s possible.

What would be your advice ?

---

<div class="post-metadata">

**Author:** ![MissCaligari](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MissCaligari](https://forums.unrealengine.com/u/MissCaligari)\
**Post date:** [August 26, 2016, 4:36pm UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/13 "2016-08-26T16:36:24Z")

</div>

Finally I’m going to use a video-mapping soft. I found how to link UE4 and Resolume with Spout plugin and it looks very easy.

Thank you for your time !

---

<div class="post-metadata">

**Author:** ![Rizzu\_R](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Rizzu\_R](https://forums.unrealengine.com/u/Rizzu_R)\
**Post date:** [November 25, 2017, 7:43am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/14 "2017-11-25T07:43:28Z")

</div>

Did you complete?

---

<div class="post-metadata">

**Author:** ![HashemShepard](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/hashemshepard/32/1201564_2.png) [@HashemShepard](https://forums.unrealengine.com/u/HashemShepard)\
**Post date:** [June 28, 2026, 10:52am UTC](https://forums.unrealengine.com/t/how-can-i-create-a-multiple-camera-multiple-monitor-setup/288201/15 "2026-06-28T10:52:52Z")

</div>

like this [Multi-Monitor Display Controller | Fab](https://www.fab.com/listings/8cc2b168-3642-4e24-9aa8-750c0bc49771) ?
