setRenderFillMode method
Set the fill mode of the picture
Parameter:
mode
Picture fill mode V2TXLiveFillMode
- V2TXLiveFillMode.v2TXLiveFillModeFill Default: The image covers the screen without black bars, and if the aspect ratio of the image is different from the aspect ratio of the screen, part of the image content will be cropped
- V2TXLiveFillMode.v2TXLiveFillModeFit The image adapts to the screen and keeps the picture intact, but if the image aspect ratio is different from the screen aspect ratio, there will be black bars
- V2TXLiveFillMode.v2TXLiveFillModeScaleFill The screen is entirely covered by the image. The image will be stretched if screen and image have different aspect ratios
Return:
'0' success, more information please see V2TXLiveCode
Implementation
Future<V2TXLiveCode> setRenderFillMode(V2TXLiveFillMode mode) async {
var result = await _channel.invokeMethod('setRenderFillMode', {"mode": mode.index});
return _liveCodeWithResult(result);
}