In UE4, there is a setting called “constrain aspect ratio” for the camera, which makes it so that the aspect ratio (16x9, 4x3, etc) of your rendered viewport is preserved no matter what ratio the device is using. It will display black bars on either top/bottom or left/right if the device’s ratio and viewport ratio don’t match up. Here is a video showing how it works (video starts at 2:46):
I see the
fovMode on the camera has
FOVMODE_HORIZONTAL_FIXED, but I think it needs a third option,
If I use the vertical mode and width is smaller than height, then the left or right sides get cut off. If I use the horizontal mode and height is smaller than width, then the top or bottom will get cut off.
I’d like an option where no matter what width and height device the user may be playing on, the bounds of the game will always look the same.