protected override string RunInBackground(params string[] paths) { string filePath = null !; try { //This bellow is just a temporary solution to test that method call works var b = bool.Parse(paths[0]); if (b) { filePath = SiliCompressor.With(MContext).CompressVideo(paths[1], paths[2]); } else { Android.Net.Uri videoContentUri = Android.Net.Uri.Parse(paths[1]); // Example using the bitrate and video size parameters = >> filePath = SiliCompressor.with(mContext).compressVideo(videoContentUri, paths[2], 1280,720,1500000);*/ filePath = SiliCompressor.With(MContext).CompressVideo(videoContentUri?.ToString(), paths[2]); } } catch (URISyntaxException e) { Methods.DisplayReportResultTrack(e); } catch (Exception e) { Methods.DisplayReportResultTrack(e); } return(filePath); }
protected override string RunInBackground(params string[] paths) { string filePath = SiliCompressor.With(mContext).Compress(paths[0], new File(paths[1])); return(filePath); }