A modern Android application for viewing and managing GLB/GLTF 3D models with authentication and role-based access control.
- Overview
- Features
- Tech Stack
- Architecture
- Screenshots
- Getting Started
- Installation
- Project Structure
- Dependencies
- Usage
- Contributing
- License
- Contact
GLB 3D Viewer App is a powerful Android application built with Jetpack Compose and Google Filament that allows users to visualize, manage, and interact with 3D models in GLB/GLTF format. The app features a robust authentication system with role-based access control, making it perfect for teams collaborating on 3D content.
- User registration and login
- Role-based access control (Admin/User)
- Secure password storage with encryption
- Persistent authentication state
- High-quality GLB/GLTF model rendering using Google Filament
- Interactive 3D viewport with touch controls
- Adjustable lighting intensity
- Real-time model manipulation (rotation, zoom, pan)
- Smooth animations and transitions
- Add new 3D models from device storage
- Grid view of all models with thumbnails
- Edit model information
- Delete models (with role-based permissions)
- Local database storage for model metadata
- Material Design 3 (Material You)
- Beautiful glassmorphism effects using Haze library
- Dark/Light theme support
- Responsive layouts
- Bottom sheet controls
- Smooth animations
- Encrypted data storage
- Role-based access control
- Secure user authentication
- Language: Kotlin
- UI Framework: Jetpack Compose
- Minimum SDK: API 33 (Android 13)
- Target SDK: API 36
- Build System: Gradle (Kotlin DSL)
- Google Filament (v1.68.2) - High-performance 3D rendering engine
- GLTF I/O - GLB/GLTF model loading and parsing
- Filament Utils - Utility functions for Filament
- Jetpack Compose - Modern declarative UI
- Material 3 - Material Design components
- Haze (v0.7.2) - Glassmorphism blur effects
- Coil (v2.5.0) - Image loading library
- Room Database (v2.8.4) - Local data persistence
- Kotlin Coroutines - Asynchronous programming
- DataStore - Key-value storage
- ViewModel - UI state management
- Lifecycle Components - Lifecycle-aware components
- KSP (Kotlin Symbol Processing) - Annotation processing
The app follows MVVM (Model-View-ViewModel) architecture pattern with clean architecture principles:
βββββββββββββββββββββββββββββββββββββββββββ
β UI Layer β
β (Jetpack Compose + Material 3) β
ββββββββββββββββ¬βββββββββββββββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββββββββββββββ
β ViewModel Layer β
β (State Management + Business Logic) β
ββββββββββββββββ¬βββββββββββββββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββββββββββββββ
β Repository Layer β
β (Data Source Abstraction) β
ββββββββββββββββ¬βββββββββββββββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββββββββββββββ
β Data Layer β
β (Room Database + File System + 3D) β
βββββββββββββββββββββββββββββββββββββββββββ
- MainActivity: Entry point and composition root
- MainViewModel: Manages app state and business logic
- GLBModelViewer: Handles 3D model rendering with Filament
- AppRepo: Repository for data operations
- Database Layer: Room database with DAO interfaces
- UI Components: Reusable Compose screens and components
Add your app screenshots here to showcase the UI and features
βββββββββββββββ βββββββββββββββ βββββββββββββββ
β Login β β 3D View β β Gallery β
β Screen β β Screen β β Screen β
βββββββββββββββ βββββββββββββββ βββββββββββββββ
Before you begin, ensure you have the following installed:
- Android Studio (Ladybug | 2024.2.1 or later)
- JDK 11 or higher
- Android SDK with API 33+
- Git
- OS: Windows, macOS, or Linux
- RAM: 8GB minimum (16GB recommended)
- Storage: 4GB free space
git clone https://github.com/yourusername/GLB3DViewerApp.git
cd GLB3DViewerApp- Launch Android Studio
- Select "Open an Existing Project"
- Navigate to the cloned repository
- Wait for Gradle sync to complete
Update local.properties with your Android SDK path:
sdk.dir=/path/to/your/android/sdk./gradlew buildOr use Android Studio's Build > Make Project (Ctrl+F9)
- Connect an Android device or start an emulator (API 33+)
- Click the Run button (Shift+F10) or run:
./gradlew installDebugGLB3DViewerApp/
βββ app/
β βββ src/
β β βββ main/
β β β βββ java/com/samrudha/glb3dviewerapp/
β β β β βββ Database/
β β β β β βββ AppDatabase.kt
β β β β β βββ DAO.kt
β β β β β βββ Entity.kt
β β β β βββ Design/
β β β β β βββ Login.kt
β β β β β βββ MainUI.kt
β β β β β βββ UI_Constant.kt
β β β β βββ MainViewModel/
β β β β β βββ AuthState.kt
β β β β β βββ CryptoManager.kt
β β β β β βββ MainViewModel.kt
β β β β β βββ Roles.kt
β β β β βββ ui/theme/
β β β β β βββ Theme files
β β β β βββ MainActivity.kt
β β β βββ res/
β β β β βββ drawable/
β β β β βββ mipmap/
β β β β βββ values/
β β β β βββ xml/
β β β βββ AndroidManifest.xml
β β βββ androidTest/
β β βββ test/
β βββ build.gradle.kts
β βββ proguard-rules.pro
βββ gradle/
β βββ libs.versions.toml
β βββ wrapper/
βββ build.gradle.kts
βββ settings.gradle.kts
βββ gradlew
βββ gradlew.bat
βββ README.md
androidx.core:core-ktx
androidx.lifecycle:lifecycle-runtime-ktx
androidx.activity:activity-composeandroidx.compose:compose-bom
androidx.compose.ui:ui
androidx.compose.ui:ui-graphics
androidx.compose.ui:ui-tooling-preview
androidx.compose.material3:material3
androidx.compose.material:material-icons-extendedcom.google.android.filament:filament-android:1.68.2
com.google.android.filament:gltfio-android:1.68.2
com.google.android.filament:filament-utils-android:1.68.2androidx.room:room-runtime:2.8.4
androidx.room:room-compiler:2.8.4 // KSPdev.chrisbanes.haze:haze:0.7.2
dev.chrisbanes.haze:haze-materials:0.7.2
io.coil-kt:coil-compose:2.5.0androidx.datastore:datastore-core-
Launch the App
-
Register an Account
- Choose your role (User/Admin)
- Enter email and password
- Click "Register"
-
Login
- Enter your credentials
- Access the main dashboard
- Click the "Add Model" button
- Select a GLB/GLTF file from your device
- The model will be added to your library with a thumbnail
- Tap on any model thumbnail in the gallery
- The 3D viewer will open
- Use touch gestures to interact:
- Rotate: Drag with one finger
- Zoom: Pinch gesture
- Pan: Drag with two fingers
- Adjust lighting using the slider
- Edit: Click the edit icon to modify model details
- Delete: Admin users can delete models (requires admin role)
- User: Can view and add models
- Admin: Full access including delete permissions
Contributions are welcome! Here's how you can help:
- Fork the repository
- Create a feature branch
git checkout -b feature/AmazingFeature
- Commit your changes
git commit -m 'Add some AmazingFeature' - Push to the branch
git push origin feature/AmazingFeature
- Open a Pull Request
- Follow Kotlin coding conventions
- Use meaningful variable and function names
- Add comments for complex logic
- Write unit tests for new features
Found a bug or have a suggestion? Please open an issue with:
- Clear description
- Steps to reproduce (for bugs)
- Expected vs actual behavior
- Screenshots (if applicable)
This project is licensed under the MIT License - see the LICENSE file for details.
MIT License
Copyright (c) 2026 Samrudha
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Samrudha
- GitHub: @samrudha01codespace
- LinkedIn: Samrudha Kshirsagar
- Email: samrudhakshirsagar@gmail.com
- Google Filament Team - For the amazing 3D rendering engine
- Android Jetpack Team - For Compose and modern Android libraries
- Chris Banes - For the Haze library
- Open Source Community - For inspiration and resources
- Cloud storage integration
- Model animation playback
- AR (Augmented Reality) mode
- Model sharing between users
- Export rendered images
- Material editor
- Multiple light sources
- Model statistics and info
- Search and filter functionality
- Batch model import
- Language: Kotlin
- Build Tool: Gradle
- UI Framework: Jetpack Compose
- Architecture: MVVM
- Min Android Version: Android 13 (API 33)
- None reported yet
- Initial release
- Basic 3D model viewing
- User authentication
- Role-based access control
- Model management (add, edit, delete)
- Local database storage
If you have any questions or need help, feel free to:
- Open an issue on GitHub
- Contact via email
- Join our community discussions
If you find this project useful, please consider giving it a star! β
Made with β€οΈ and Kotlin