Skip to content

haidrrrry/ArBarCodeProject

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

10 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ArBarCodeProject

ArBarCodeProject is a cutting-edge mobile application built with Kotlin Multiplatform Mobile (KMM) and Compose Multiplatform, designed to integrate Augmented Reality (AR) and Barcode scanning functionalities. This project aims to provide a seamless and robust solution for various use cases involving barcode recognition and interactive AR experiences across both Android and iOS platforms from a single codebase.

✨ Features

0624.1.online-video-cutter.com.mp4
  • Cross-Platform Compatibility: Developed with Kotlin Multiplatform Mobile, ensuring a native experience on both Android and iOS from a shared codebase.
  • Augmented Reality (AR) Integration: Explore interactive AR features, likely for overlaying digital information or experiences onto the real world.
  • Barcode Scanning: Efficiently scan and process various barcode types (e.g., QR codes, UPCs) for data retrieval or product information.
  • Modern UI: Utilizes Compose Multiplatform for a declarative, modern, and consistent user interface across all supported platforms.
  • Shared Business Logic: Centralized business logic and data models for easier maintenance and development.

πŸš€ Technologies Used

  • Kotlin Multiplatform Mobile (KMM): For sharing code between Android and iOS.
  • Compose Multiplatform: For building native UIs across Android and iOS.
  • Android Jetpack Compose: For Android-specific UI components.
  • SwiftUI: For iOS-specific entry points and potential platform-specific UI.
  • Kotlin: The primary programming language.

πŸ› οΈ Setup and Run Locally

To get a local copy up and running, follow these simple steps.

Prerequisites

  • Android Studio (with Kotlin Multiplatform Mobile plugin)
  • Xcode (for iOS development, macOS only)
  • JDK 11 or higher

Installation

  1. Clone the repository:
git clone https://github.com/haidrrrry/ArBarCodeProject.git
cd ArBarCodeProject
  1. Open in Android Studio: Open the ArBarCodeProject directory in Android Studio. Android Studio will automatically resolve the dependencies.

  2. Run on Android:

    • Select the androidApp run configuration.
    • Choose an emulator or a connected Android device.
    • Click the 'Run' button (green triangle) in Android Studio.
  3. Run on iOS:

    • Open the ArBarCodeProject directory in Android Studio.
    • Select the iosApp run configuration.
    • Choose an iOS simulator.
    • Click the 'Run' button (green triangle) in Android Studio. Android Studio will build and launch the app in Xcode.
    • Alternatively, you can open iosApp/iosApp.xcodeproj directly in Xcode and run from there.

πŸ“ Project Structure

The project follows a standard Kotlin Multiplatform Mobile structure:

  • /composeApp: This module contains the shared logic and UI code that is common across your Compose Multiplatform applications.
    • commonMain: Contains the core business logic, data models, and shared Compose Multiplatform UI components that are used by all targets (Android, iOS).
    • androidMain: Contains Android-specific implementations, dependencies, and the MainActivity for the Android application.
    • iosMain: Contains iOS-specific implementations, dependencies, and the entry point for the iOS application.
  • /iosApp: This directory contains the Xcode project for the iOS application. Even when sharing UI with Compose Multiplatform, this is where the iOS application's entry point resides, and where you might add SwiftUI code for platform-specific needs.

πŸ“± Platform-Specific Features

Android

  • ARCore Integration: Utilizes Google's ARCore for augmented reality experiences
  • CameraX: Advanced camera functionality for barcode scanning
  • ML Kit: Google's machine learning kit for barcode detection and recognition
  • Material Design 3: Modern Android design system implementation

iOS

  • ARKit Integration: Apple's augmented reality framework for immersive experiences
  • AVFoundation: Core camera and media framework for scanning functionality
  • Vision Framework: Apple's computer vision framework for barcode detection
  • SwiftUI: Native iOS UI components where needed

🎯 Use Cases

This application can be utilized in various scenarios:

  • Retail & E-commerce: Product scanning for price comparison and information retrieval
  • Inventory Management: Quick barcode scanning for stock tracking and management
  • Educational: Interactive AR experiences combined with QR code learning materials
  • Marketing: AR-enhanced promotional campaigns triggered by barcode scanning
  • Logistics: Package tracking and warehouse management solutions

πŸ”§ Configuration

Camera Permissions

Android - Add to AndroidManifest.xml:

<uses-permission android:name="android.permission.CAMERA" />
<uses-feature android:name="android.hardware.camera" android:required="true" />
<uses-feature android:name="android.hardware.camera.autofocus" />

iOS - Add to Info.plist:

<key>NSCameraUsageDescription</key>
<string>This app needs camera access to scan barcodes and provide AR experiences</string>

AR Requirements

Android - ARCore metadata in AndroidManifest.xml:

<meta-data android:name="com.google.ar.core" android:value="required" />

iOS - ARKit capability in Info.plist:

<key>NSCameraUsageDescription</key>
<string>This app uses AR to enhance barcode scanning experience</string>

πŸ§ͺ Testing

Running Tests

# Run all tests
./gradlew test

# Run Android tests
./gradlew testDebugUnitTest

# Run iOS tests
./gradlew iosSimulatorArm64Test

Test Coverage

The project includes:

  • Unit tests for shared business logic
  • Platform-specific tests for AR and camera functionality
  • UI tests for cross-platform components

🀝 Contributing

Contributions are welcome! If you have suggestions for improvements, new features, or bug fixes, please open an issue or submit a pull request.

Development Guidelines

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Follow Kotlin coding conventions
  4. Write tests for new functionality
  5. Update documentation as needed
  6. Commit your changes (git commit -m 'Add some amazing feature')
  7. Push to the branch (git push origin feature/amazing-feature)
  8. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ› Issues and Support

If you encounter any issues:

  1. Check the Issues page for existing problems
  2. Create a new issue with:
    • Device information (OS version, device model)
    • Steps to reproduce the issue
    • Expected vs actual behavior
    • Screenshots or logs if applicable

πŸ”— Useful Resources

πŸ“ˆ Project Status

This project is actively maintained and under development. Check the releases page for the latest updates and version history.


Note: If you appreciate this project, consider starring the repository! ⭐

Made with ❀️ using Kotlin Multiplatform Mobile

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors