Recently, Apple has introduced Dolby Vision HDR Screen Recording with their latest IOS update. So I wanted to try making an for android if possible. The result? due to many restrictions the virtual display rendered by the phone is always in 8 bit sRGB even if you phone has Wide gamut support. So I made this app which tone maps on the fly to give you very high fidelty video. Until android makes it an option and if OEMs allow it to be possible, we are stuck with this method. Other than that, this app aims to provide maximum control even in post.
A powerful, feature-rich Android screen recording application with support for HDR (PQ/HLG) encoding, 10-bit color depth and advanced audio mixing. Built with Kotlin and modern Android APIs.
- Multiple Codecs: HEVC (H.265), AVC (H.264) | Only Hardware Encoders are supported
- HDR Support: Proper PQ (ST2084) and HLG (BT.2100) color profiles for High fidelity video | Tone Mapped because android does not allow true HDR capture yet.
- 10-Bit Encoding: HEVC Main 10 profile with full bit-depth support
- Flexible Resolution: 2160p(4k), 1440p, 1080p, 720p with custom orientation [Portrait/Landscape/Square (only in native resolution for max screen real estate)], Aspect Ratio of your phone is maintained across all resolutions
- High Frame Rates: Upto 120 FPS (Modern devices use variable FPS)
- Constant Quality Mode (CQ): Adaptive bitrate based on quality settings (fallback to CBR)
- Dual Audio Input: Simultaneously capture device audio + microphone
- Multiple Codecs: AAC (MP4A), Opus, FLAC, PCM (Raw)
- Multi-Channel Mixing: Mix device and mic audio for 3 Channel or 6 Channel audio for good voice and device audio separation (aac and pcm only)
- SurfaceProcessor: GPU-based OpenGL pipeline for color space conversions
- Rec.709 (SDR) passthrough
- Rec.709 β Rec.2020 (HDR primaries) with gamut mapping
- Proper tonemapping for PQ and HLG HDR standards
- 10-Bit to 10-Bit Processing: Maintains color fidelity end-to-end
- EGL Configuration Detection: Automatically finds 10-bit or FP16 display configs (with fallbacks)
- Granular Settings UI: Control every aspect of recording
- Device Capability Probing: Automatically detects supported codecs, HDR profiles, and color modes
- Video Quality Slider: Intuitive quality vs. file size tradeoff
- Recording Orientation: Choose portrait, landscape, or square capture *sqaure aspect ratio uses max dimension of your device native resolution (Eg: 2340x1080 -> 2340x2340) so that no scaling occurs when you switch orientation from portrait to landscape while recording. you capture full resolution of your screen
- Organized Playback: Browse and manage recorded videos (Play, Rename, Share, etc)
- Metadata: Shows detailed information of the recordings
- Debug Dashboard: View device codec capabilities, color profile support, and hardware specs to better understand your capabilites and limitations
- Open the app β Recording tab
- Configure Settings:
- Select video codec (HEVC recommended for best compression)
- Select Audio codec (non aac codecs are stored separately due to mediamuxer limitations)
- Choose resolution (FHD, 2K, 4K, etc.)
- Set frame rate (60 FPS standard)
- Enable/disable microphone or device audio
- Pick a color profile (Default for SDR, PQ/HLG for HDR)
- Tap Start β Tap to begin capturing
- Tap Stop β Recording saved to device storage
- Browse Files β View your recordings in the Files tab
Video Tab:
- Quality: 1β100 scale (higher = better quality, larger file)
- Codec: Switch between HEVC (better compression) or AVC (broader compatibility)
- Resolution: Auto or manual override
- Color Profile:
- Default β SDR (standard 8-bit color)
- PQ β HDR10 (luminance-preserving, cinema-grade) (Tone mapped)
- HLG β HLG HDR (hybrid log-gamma, broadcast standard) (Tone mapped)
Audio Tab:
- Device Audio: Enable to capture system sounds, music, etc.
- Microphone: Enable to record voice narration (Phone or external mics)
- Codec: AAC (universal), Opus (better quality), FLAC (lossless), PCM (Raw audio)
Advanced:
- Toggle 10-Bit SDR (for reduced video artifacts)
- View hardware capability details in Debug Dashboard
| Class | Purpose |
|---|---|
| EncoderManager | Configures MediaCodec, handles video encoding with CQ/CBR modes |
| SurfaceProcessor | OpenGL pipeline for color space conversion (SDR β HDR, 8-bit β 10-bit) |
| AudioTrackManager | Manages AudioRecord, audio mixing, and synchronization |
| MediaProjectionService | Foreground service managing screen capture lifecycle |
| RecordingSettings | Data class storing all user-configurable parameters |
| DeviceProbeUtils | Probes codec capabilities and color profile support |
This app implements full color-accurate video encoding:
- Standard 8-bit sRGB β bit-shifted to 10-bit (no color transformation)
- Direct passthrough to encoder
- Color Space: Rec.2020 primaries
- Transfer Function: ST2084 (Perceptual Quantizer)
- Tonemapping: Luminance-preserving Reinhard with gamut mapping
- Peak Brightness: Configurable (default 960 nits)
- Color Space: Rec.2020 primaries
- Transfer Function: Hybrid Log-Gamma (OETF)
- Characteristics: Backward compatible with SDR displays
Key libraries used:
- Jetpack Compose β Modern UI framework
- MediaCodec API β Hardware-accelerated encoding
- OpenGL ES 3.0 β GPU color processing
- Coroutines β Async/concurrent operations
- Kotlin Serialization β Settings persistence
- Check Permissions: Ensure microphone + screen recording permissions are granted
- Check Storage: Device must have >1 GB free space
- Logcat: Open Android Studio β Logcat tab, filter by
RecordingScreenorEncoderManager
- Blurry Output: Increase quality slider or lower resolution
- Codec Not Supported: Use Debug Dashboard to check device capabilities; fallback to AVC
- Low Frame Rate: Some devices can't sustain 60+ FPS; check Debug Dashboard for hardware limits
- Not all devices support HDR encoding. Use Device Debug Screen to verify:
- Is
KEY_COLOR_TRANSFERsupported? - Does the device have a 10-bit codec (HEVC Main 10)?
- Is
- If not supported, fall back to SDR (Rec.709)
Tips for Best Performance:
- Close background apps β Reduces system load
- Use AVC SDR 8bit β Better compatibilty across devices and reduced load
- Lower quality for longer recordings β Balances file size
- Avoid High resolutions/FPS values β Causes throttling on most devices
Tips for Best Quality:
- Use HEVC β Better compression
- Use 10bit SDR or HDR - Better Visual fidelity
- Higher Resolution/FPS β Negligible increase in quality on most apps but gives you better quality in general
- Use other audio codecs β Use Opus if you want compressed but Higher Quality and FLAC/PCM for the absolute best audio quality.
This project uses the Google Sans font family, licensed under the SIL Open Font License (OFL 1.1).
See OFL.txt for details. All source code is provided as-is for educational and professional use.
Found a bug? Have a feature request? Feel free to:
- Open an Issue β Describe the problem or feature
- Submit a PR β Fork, branch, code, and submit a pull request
For major changes, please open an issue first to discuss.
- MediaCodec API: Android Developers
- HDR Standards: ST2084 (PQ), BT.2100 (HLG) specifications
- OpenGL ES: Modern GPU rendering techniques
- Jetpack Compose: Declarative UI framework