OxiGDAL Mobile Enhanced
Advanced mobile platform optimizations for iOS and Android geospatial applications.
Overview
oxigdal-mobile-enhanced provides comprehensive performance optimizations and mobile-specific features for geospatial applications on iOS and Android platforms. This crate complements oxigdal-mobile by adding platform-specific performance tuning, battery-aware processing, network optimization, and intelligent resource management.
Features
Battery-Aware Processing
- Real-time battery level monitoring
- Adaptive processing modes (High Performance, Balanced, Power Saver)
- Automatic quality adjustment based on battery state
- Charging state detection
- Background processing throttling
Network Optimization
- Network type detection (WiFi, Cellular, Ethernet)
- Adaptive compression based on network conditions
- Data usage tracking and reporting
- Cellular data usage minimization
- Smart prefetching strategies
Background Task Management
- Priority-based task scheduling
- Platform-aware execution limits
- Battery-aware task throttling
- Automatic task suspension/resumption
- Progress tracking and monitoring
Mobile Storage Optimization
- LRU/LFU/TTL caching strategies
- Size-based cache eviction
- Storage compression (Zstd, Deflate)
- Adaptive compression selection
- Automatic cleanup and maintenance
iOS-Specific Features
- Metal GPU acceleration hints
- Core Image integration support
- iOS memory pressure handling
- Background execution management
- Hardware accelerated image decoding
- Texture compression
Android-Specific Features
- RenderScript acceleration hints (legacy)
- Vulkan/OpenGL GPU acceleration
- ART runtime optimizations
- Lifecycle-aware processing
- Low Memory Killer awareness
- Hardware bitmap support
- Dalvik/ART heap monitoring
Installation
Add this to your Cargo.toml:
[]
= "0.1.3"
Feature Flags
std(default): Standard library supportios: Enable iOS-specific optimizationsandroid: Enable Android-specific optimizationsbattery-aware: Enable battery monitoring (requiressysinfo)network-optimization: Enable network optimization featuresgesture-support: Enable gesture-based interaction supportbackground-tasks: Enable background task management (requirestokio)
Usage Examples
Battery-Aware Processing
use ;
// Create battery monitor
let monitor = new?;
// Check current battery level
let level = monitor.current_level?;
println!;
// Get recommended processing mode
let mode = monitor.recommended_processing_mode;
match mode
Network Optimization
use ;
let optimizer = new;
// Check network type
let network_type = optimizer.detect_network_type?;
match network_type
// Compress data for transfer
let data = vec!;
let compressed = optimizer.compress_for_transfer?;
println!;
Background Task Scheduling
use ;
let scheduler = new;
// Schedule a background task
let task_id = scheduler.schedule_task.await?;
// Check task status
let status = scheduler.task_status?;
println!;
iOS Performance Optimization
use ;
Android Performance Optimization
use ;
Mobile Caching
use ;
// Create LRU cache with size limit
let cache = new;
// Insert data
cache.insert?;
// Retrieve data
if let Some = cache.get
Performance Characteristics
Battery Impact
- High Performance Mode: ~15-20% battery usage
- Balanced Mode: ~8-12% battery usage
- Power Saver Mode: ~3-5% battery usage
Network Efficiency
- WiFi: 3x compression ratio (typical)
- Cellular: 9x compression ratio (maximum)
- Data savings: 60-70% on cellular
Cache Performance
- LRU eviction: O(1)
- Cache hit ratio: 85-95% (typical)
- Memory overhead: <5%
Platform Support
iOS
- Minimum: iOS 13.0
- Targets:
aarch64-apple-ios,x86_64-apple-ios(simulator) - Features: Metal, Core Image, Memory Pressure Handling
Android
- Minimum: API 24 (Android 7.0)
- Targets:
aarch64-linux-android,armv7-linux-androideabi,x86_64-linux-android - Features: Vulkan, OpenGL, ART Optimizations
COOLJAPAN Policies
This crate adheres to all COOLJAPAN ecosystem policies:
- ✅ Pure Rust: 100% Pure Rust implementation, no C/C++ dependencies
- ✅ No Unwrap: All error cases explicitly handled with
Result - ✅ Workspace: Version management via workspace
- ✅ Latest Crates: Uses latest stable dependencies from crates.io
- ✅ No Warnings: Code compiles without warnings
- ✅ File Size: All files under 2000 lines
Testing
Run tests:
Run tests with all features:
Run iOS-specific tests:
Run Android-specific tests:
Benchmarks
Run benchmarks:
Documentation
Generate documentation:
License
Licensed under Apache-2.0
Authors
COOLJAPAN OU (Team Kitasan)
Contributing
This is part of the COOLJAPAN ecosystem. Contributions welcome!