I'm developing a game with vertical screen orientation. Default of Libgdx screen is horizontal orientation. So I don't know should I rotate the background (texture/sprite) or I rotate camera 90 degrees, which solution is easy to develop later?
Asked
Active
Viewed 183 times
0
-
2If the whole game should be in vertical ("portrait") orientation for android, you should change the orientation in the manifest file (http://stackoverflow.com/questions/23402717/how-to-set-portrait-mode-with-libgdx). If you want a game with portrait-orientation on desktop, you should probably rotate the camera, but i don't guess thats what you want. If you instead only want to rotate the background, rotate the background `Texture` only. – Robert P Jan 13 '15 at 12:33
-
thanks so much, manifest file is OK – Dark Light Jan 13 '15 at 13:18
1 Answers
3
Don't rotate anything. Go to the Android subproject, open the AndroidManifest.xml file and change (or add) the "android:screenOrientation" attribute of the "activity" XML tag to "portrait".
Rotating the content would cause problem in many cases (default text direction, virtual keyboard appearence...).
Rada

Rada
- 52
- 5