feat: Add customizable Video Bit Rate (videoBitRate) (#1882)

* feat: Add `videoBitRate` option to `RecordVideoOptions`

* feat: Implement `videoBitRate` on iOS

* feat: Implement `videoBitRate` on Android

* chore: Format

* docs: Separate recording and photo docs

* docs: Fix links

* docs: Add docs about bitrate and quality

* docs: Add blob

* fix: Don't use inline style for CI

* fix: Correctly log default bitRate

* fix: Fix typo

* fix: Calculate default bit-rate on Android depending on resolution

* Update RecordingSession.kt
This commit is contained in:
Marc Rousavy
2023-09-29 15:27:09 +02:00
committed by GitHub
parent 1c8c081e11
commit 902dc634a4
14 changed files with 294 additions and 64 deletions

View File

@@ -24,6 +24,17 @@ export interface RecordVideoOptions {
* - `h265`: The HEVC (High-Efficient-Video-Codec) for higher efficient video recordings.
*/
videoCodec?: 'h264' | 'h265'
/**
* The bit-rate for encoding the video into a file, in Mbps (Megabits per second).
*
* Bit-rate is dependant on various factors such as resolution, FPS, pixel format (whether it's 10 bit HDR or not), and codec.
*
* By default, it will be calculated using those factors.
* For example, at 1080p, 30 FPS, H.264 codec, without HDR it will result to 10 Mbps.
*
* @default 'normal'
*/
videoBitRate?: 'low' | 'normal' | 'high' | number
}
/**