Recreating UDK's UTPortals?
I recently started using Unreal Engine 4 and was disappointed to see the removal of the UTPortal actor. I've tried experimenting with SceneCapture2D and depth buffers to get a similar effect, but the resulting view, while three-dimensional, lacks any sort of perspective detection and the view remains stationary.
I essentially recreated the effect shown in this video https://www.youtube.com/watch?v=r5XAVy6wE-A
It's certainly better than just a flat real-time 2d texture, but it is a far cry from what the UTPortal actor could do. Does anybody have any ideas?
I have managed to recreate my UDK portal in UE4 (kind of). It is not in usable form and is not optimized. But if anyone is interested in creating portals, this might give you some ideas.
Here is the Scene setup and Gameplay demo
The blue print is shown below:
Problems: It uses a large Render Target (same as the screen resolution), which results in low FPS. I hardcoded several things like resolution, eye height, active camera into the settings and blueprints * I could not find an option to set a near clip plane, so the illusion fails if player is too far away (other stuff will block the portal)
If anyone is interested I will try to make more screenshots of other assetts as well.
answered May 31 '14 at 04:26 PM
Just an idea. Not sure how good it will work.
Setup a camera that points to the destination area. Positioned at the portal exit. Manipulate its properties (FOV, rotation..), based on the original player camaera - entry portal values. Ie if your original camera is at 45 degree angle with the entry portal plane, you adjust your secondary camera to be at 45 degrees with the exit portal plane. Then render the view given by the secondary camera onto a render target and use it to texture the entry portal surface.
I had tried the above method in UDK and got pretty good results. However it was simply a demo I did after playing portal and did not have anything to do with gameplay. SO I cannot say anything about how it will affect performance.
answered May 30 '14 at 03:06 AM
Don't ask me how it works, but I think it's what you're looking for. Scene Capture Components now have a Clip Plane Base and Clip Plane Normal attribute. Which is "useful for portals". I've tried using them, but couldn't get the values correct. Might be what you're looking for.
answered Apr 22 '17 at 04:13 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here