ultralytics / yolo-flutter-app

A Flutter plugin for Ultralytics YOLO computer vision models
https://ultralytics.com
GNU Affero General Public License v3.0
36 stars 14 forks source link

Display in Landscape Mode #14

Closed FrankFeng-23 closed 1 month ago

FrankFeng-23 commented 2 months ago

Hi, I'm a Flutter newbie. Recently, I've been wanting to deploy my trained YOLOv8n on a mobile phone for real-time object detection. I'd like to change the app to display in landscape mode, but I'm not sure how to do it. Any ideas and suggestions would be appreciated!

pderrenger commented 2 months ago

Hello there! Glad to hear you're venturing into deploying your trained model on a mobile device. 🚀 For Flutter, you can set your app to landscape mode by adjusting your app's settings. In your main AndroidManifest.xml (for Android) located in android/app/src/main, and Info.plist (for iOS) located in ios/Runner, specify the orientation settings.

For Android, inside the <activity> tag, you can add:

android:screenOrientation="landscape"

For iOS, in Info.plist, add:

<key>UISupportedInterfaceOrientations</key>
<array>
    <string>UIInterfaceOrientationLandscapeLeft</string>
    <string>UIInterfaceOrientationLandscapeRight</string>
</array>

This should lock your app into landscape mode. Happy coding, and let the YOLO community know if you have more questions! 🌟

github-actions[bot] commented 1 month ago

👋 Hello there! We wanted to give you a friendly reminder that this issue has not had any recent activity and may be closed soon, but don't worry - you can always reopen it if needed. If you still have any questions or concerns, please feel free to let us know how we can help.

For additional resources and information, please see the links below:

Feel free to inform us of any other issues you discover or feature requests that come to mind in the future. Pull Requests (PRs) are also always welcomed!

Thank you for your contributions to YOLO 🚀 and Vision AI ⭐