- Home /
Force/Maintain aspect ratio of game/ add black bars on edges/ SOLUTION
Canvas - canvas scaler - UI scale mode - scale with screen size
Canvas - canvas scaler - UI scale mode - screen match mode - expand
Panel - add component - aspect ratio filter - aspect mode - fit in prent
panel - aspect ratio filter - aspect ratio - whatever aspect ratio you want 16/9 or 9/16 or anything
it worked for me. I made game in 9:16 aspect ratio, and when I open in 9:18 and 2:3 aspect ratio display, it does add black bars on edges.
let me know if you have any other method to make it work.
thank you so much personally the fit in parent didnt do what i wanted but changing it to height controlls width made it work perfectly thank you so much!
Your answer
Follow this Question
Related Questions
Keeping the health bar at the same length 2 Answers
"loading image or a bar" in between scene switching 2 Answers
Shooting Cooldown Bar 2 Answers
My game loads, but the game screen stays black. 1 Answer
How to make screen turn black? 1 Answer