get static method

Future<CamcorderProfile> get(
  1. int cameraId,
  2. int quality
)

Returns the default camcorder profile for the given camera at the given quality level.

Quality levels qualityLow, qualityHigh are guaranteed to be supported, while other levels may or may not be supported. The supported levels can be checked using CamcorderProfile.hasProfile. qualityLow refers to the lowest quality available, while qualityHigh refers to the highest quality available. qualityLow/qualityHigh have to match one of qcif, cif, 480p, 720p, 1080p or 2160p. E.g. if the device supports 480p, 720p, 1080p and 2160p, then low is 480p and high is 2160p. The same is true for time lapse quality levels, i.e. qualityTimeLapseLow, qualityTimeLapseHigh are guaranteed to be supported and have to match one of qcif, cif, 480p, 720p, 1080p, or 2160p. For high speed quality levels, they may or may not be supported. If a subset of the levels are supported, qualityHighSpeedLow and qualityHighSpeedHigh are guaranteed to be supported and have to match one of 480p, 720p, or 1080p. A camcorder recording session with higher quality level usually has higher output bit rate, better video and/or audio recording quality, larger video frame resolution and higher audio sampling rate, etc, than those with lower quality level.

cameraId: id from CameraInfo from Camera.getAllCameraInfo.

Throws an PlatformException if quality is not one of the defined quality... const values.

Implementation

static Future<CamcorderProfile> get(int cameraId, int quality) async {
  return await _channel.$get(cameraId, quality) as CamcorderProfile;
}