/// <summary> /// Gets the available video modes. /// </summary> /// <returns></returns> public static List <TV_MODEFORMAT> GetAvailableVideoModes() { var modes = new List <TV_MODEFORMAT>(); var deviceInfo = new TVDeviceInfo(); for (int i = 0; i < deviceInfo.GetDisplayModeCount(); i++) { TV_MODEFORMAT mode = deviceInfo.GetDisplayMode(i); if (mode.Format == 32 && !modes.Any(m => m.Width == mode.Width && m.Height == mode.Height)) { modes.Add(mode); } } modes.Sort((a, b) => ((b.Width - a.Width) << 16) + b.Height - a.Height); return(modes); }