01.7. Touch Input Setup for Mobile
Set up Pixel Streaming in your own project - Core Settings
Last updated
Set up Pixel Streaming in your own project - Core Settings
Last updated
Unreal Engine Setup
Set up Pixel Streaming in your own projectUsing the Arcware Pixel Streaming Template ProjectCommon Unreal Engine QuestionsArcware Features
Screenshot FunctionalityCopyright 2024 - Arcware GmbH
In order to have functional Touch input when interacting with the Pixel Stream on a touch enabled device, you will need to enable the following touch related settings.
Select Edit > Project Settings > Engine > Input, and tick 'Enable Gesture Recognizer’.
Note: 'Enable Gesture Recognizer’ will allow your application to react to common touch functions such as 'Pinch to zoom' or 'Swipe'. Previously the 'BP_Arcware_Pawn' from the Arcware Pixel Streaming Template Project required this setting to allow the 'Pinch' (to zoom) gesture to work correctly. However the 'Pinch' gesture does not trigger on IOS, so we build a custom Pinch function that doesn't rely on the dedicated 'Pinch' gesture.
Now open your 'Player Controller' blueprint and in the Details panel tick 'Enable Touch Events'
Once you have enabled those touch settings, you can now add the blueprint functionality reponsible for controlling the touch input events. We recommend downloading the 'BP_Arcware_Pawn' from the Arcware Pixel Streaming Template Project. In the Pawn there are existing blueprint functions for 'Camera Rotation With Touch' or 'Zooming with the Touch Pinch Gesture'. The touch blueprint functions could be copied to your own Player Pawn blueprint or you can instantly use the 'BP_Arcware_Pawn' in your project with little setup required.
Warning: Please be aware... if you have set up Touch Events in your Unreal Engine project you also need to enable 'Touch capability' for the uploaded application in the CloudRT user portal (see screenshot below).
Another touch related project setting to be aware of is 'Use Mouse for Touch' in... Edit > Project Settings > Engine > Input This is just a handy feature for debugging touch inputs if you don't have a touch device available to you, all it does is simulate your Touch Events being triggered via the mouse instead, so you can check if your touch logic is working without having to connect a touch device. For production, we recommend to avoid using this setting and instead building dedicated Touch events. 'Use Mouse for Touch' is ok for testing things, but it only takes input from one finger, meaning functionality like 'zooming' is not possible with this feature because it requires two fingers.