void ShowVideo() { try { var MediaPlaybackItem = new MediaPlaybackItem(MediaSource.CreateFromStorageFile(FileToUpload)); //FileToUpload ME.SetPlaybackSource(MediaPlaybackItem); ME.RemoveAllEffects(); var transform = new VideoTransformEffectDefinition { Rotation = MediaRotation.None, OutputSize = new Size(BitmapDecoder.PixelWidth, BitmapDecoder.PixelHeight), Mirror = MediaMirroringOptions.None, CropRectangle = CurrentCroppedRectForVideo }; ME.AddVideoEffect(transform.ActivatableClassId, true, transform.Properties); } catch { } }
void ShowVideo() { try { var MediaPlaybackItem = new MediaPlaybackItem(MediaSource.CreateFromStorageFile(FileToUpload)); //FileToUpload ME.SetPlaybackSource(MediaPlaybackItem); ME.RemoveAllEffects(); var transform = new VideoTransformEffectDefinition { Rotation = MediaRotation.None, OutputSize = Editor.ScaledSize, Mirror = MediaMirroringOptions.None, CropRectangle = Editor.ScaledCropRect }; ME.AddVideoEffect(transform.ActivatableClassId, true, transform.Properties); } catch { } }