private void GetFormat(IBaseFilter filter) { var config = (IAMStreamConfig)GetOutputPin(filter); AMMediaType media; var hr = config.GetFormat(out media); DsError.ThrowExceptionForHR(hr); if (currentFormat != null) { DsUtils.FreeAMMediaType(currentFormat); } currentFormat = media; var resolutionInfo = ResolutionInfo.Create(currentFormat); Settings.Default.Width = resolutionInfo.Width; Settings.Default.Height = resolutionInfo.Height; Settings.Default.Bpp = resolutionInfo.Bpp; Settings.Default.Save(); OnFormatChanged(resolutionInfo); }
private void OnFormatChanged(ResolutionInfo resolutionInfo) { FormatChanged(this, new EventArgs<string>(resolutionInfo.ToString())); }
private void OnFormatChanged(ResolutionInfo resolutionInfo) { FormatChanged(this, new EventArgs <string>(resolutionInfo.ToString())); }