Exemple #1
0
 public DisplayConfigPathInfo(DisplayConfigPathSourceInfo sourceInfo, DisplayConfigPathTargetInfo targetInfo,
                              DisplayConfigPathInfoFlags flags)
 {
     SourceInfo = sourceInfo;
     TargetInfo = targetInfo;
     Flags      = flags;
 }
        internal PathTargetInfo(DisplayConfigPathInfoFlags pathFlags,
                                DisplayConfigPathTargetInfo targetInfo,
                                DisplayConfigTargetMode?targetMode,
                                DisplayConfigDesktopImageInfo?desktopImageMode)
        {
            IsPathActive = pathFlags.HasFlag(DisplayConfigPathInfoFlags.Active);
            IsVirtualModeSupportedByPath = pathFlags.HasFlag(DisplayConfigPathInfoFlags.SupportVirtualMode);

            DisplayTarget = new PathDisplayTarget(new PathDisplayAdapter(targetInfo.AdapterId), targetInfo.TargetId,
                                                  targetInfo.TargetAvailable);

            OutputTechnology         = targetInfo.OutputTechnology;
            Rotation                 = targetInfo.Rotation;
            Scaling                  = targetInfo.Scaling;
            ScanLineOrdering         = targetInfo.ScanLineOrdering;
            FrequencyInMillihertz    = targetInfo.RefreshRate.ToValue(1000);
            ForcedBootAvailability   = targetInfo.StatusFlags.HasFlag(DisplayConfigPathTargetInfoFlags.AvailabilityBoot);
            ForcedPathAvailability   = targetInfo.StatusFlags.HasFlag(DisplayConfigPathTargetInfoFlags.AvailabilityPath);
            ForcedSystemAvailability =
                targetInfo.StatusFlags.HasFlag(DisplayConfigPathTargetInfoFlags.AvailabilitySystem);
            IsCurrentlyInUse = targetInfo.StatusFlags.HasFlag(DisplayConfigPathTargetInfoFlags.InUse);
            IsForcible       = targetInfo.StatusFlags.HasFlag(DisplayConfigPathTargetInfoFlags.Forcible);

            IsSignalInformationAvailable = targetMode.HasValue;
            if (targetMode.HasValue)
            {
                _signalInfo = new PathTargetSignalInfo(targetMode.Value.TargetVideoSignalInfo);
            }

            IsDesktopImageInformationAvailable = desktopImageMode.HasValue;
            if (desktopImageMode.HasValue)
            {
                _desktopImage = new PathTargetDesktopImage(desktopImageMode.Value);
            }
        }
Exemple #3
0
 public DisplayConfigPathInfo(
     DisplayConfigPathSourceInfo sourceInfo,
     DisplayConfigPathTargetInfo targetInfo,
     DisplayConfigPathInfoFlags flags)
 {
     this.SourceInfo = sourceInfo;
     this.TargetInfo = targetInfo;
     this.Flags      = flags;
 }