Example #1
0
        private async Task CameraComponentSetCurrentFormat(MessageContainer data)
        {
            await Task.CompletedTask;
            uint width  = uint.Parse(data.ResolveParameter("Width", 0));
            uint height = uint.Parse(data.ResolveParameter("Height", 1));
            VideoEncodingProperties mediaFormat = VideoEncodingProperties.CreateMpeg2();

            mediaFormat.Width  = width;
            mediaFormat.Height = height;
            await SetCurrentFormat(mediaFormat).ConfigureAwait(false);
        }