get low quality camcorder, if high quality isnt available
This commit is contained in:
parent
4359f0f3ed
commit
3295e58306
|
@ -609,7 +609,12 @@ class Preview : ViewGroup, SurfaceHolder.Callback, MediaScannerConnection.OnScan
|
||||||
}
|
}
|
||||||
|
|
||||||
val resolution = getSelectedResolution()
|
val resolution = getSelectedResolution()
|
||||||
CamcorderProfile.get(CamcorderProfile.QUALITY_HIGH).apply {
|
val profile = if (CamcorderProfile.hasProfile(CamcorderProfile.QUALITY_HIGH)) {
|
||||||
|
CamcorderProfile.get(CamcorderProfile.QUALITY_HIGH)
|
||||||
|
} else {
|
||||||
|
CamcorderProfile.get(CamcorderProfile.QUALITY_LOW)
|
||||||
|
}
|
||||||
|
profile.apply {
|
||||||
videoFrameWidth = resolution.width
|
videoFrameWidth = resolution.width
|
||||||
videoFrameHeight = resolution.height
|
videoFrameHeight = resolution.height
|
||||||
mRecorder!!.setProfile(this)
|
mRecorder!!.setProfile(this)
|
||||||
|
|
Loading…
Reference in New Issue