/// <summary> /// Creates a mew GridTopologyDisplay /// </summary> /// <param name="displayId">Corresponding display identification</param> /// <param name="overlap">The overlap values</param> /// <param name="rotation">The display rotation</param> /// <param name="cloneGroup">The display clone group</param> /// <param name="pixelShiftType">The display pixel shift type</param> public GridTopologyDisplay( uint displayId, Overlap overlap = default(Overlap), Rotate rotation = Rotate.Degree0, uint cloneGroup = 0, PixelShiftType pixelShiftType = PixelShiftType.NoPixelShift) : this(new DisplayDevice(displayId), overlap, rotation, cloneGroup, pixelShiftType) { }
/// <summary> /// Creates a new Topology /// </summary> /// <param name="resolution">Mosaic displays resolution</param> /// <param name="frequency">Mosaic displays frequency</param> /// <param name="topology">Topology arrangement</param> /// <param name="overlap">Mosaic overlap</param> public Topology(Resolution resolution, int frequency, Native.Mosaic.Topology topology, Overlap overlap) { Resolution = resolution; Frequency = frequency; FrequencyInMillihertz = (uint)(Frequency * 1000); TopologyMode = topology; Overlap = overlap; }
/// <summary> /// Creates a new Topology /// </summary> /// <param name="resolution">>Mosaic displays resolution</param> /// <param name="frequency">Mosaic frequency</param> /// <param name="frequencyInMillihertz">Mosaic frequency x 1000</param> /// <param name="topology">Topology arrangement</param> /// <param name="overlap">Mosaic overlap</param> public Topology( Resolution resolution, int frequency, uint frequencyInMillihertz, Native.Mosaic.Topology topology, Overlap overlap) : this(resolution, frequency, topology, overlap) { FrequencyInMillihertz = frequencyInMillihertz; }
/// <inheritdoc /> public override int GetHashCode() { unchecked { var hashCode = PhysicalGPU != null?PhysicalGPU.GetHashCode() : 0; hashCode = (hashCode * 397) ^ (Output != null ? Output.GetHashCode() : 0); hashCode = (hashCode * 397) ^ Overlap.GetHashCode(); return(hashCode); } }
/// <summary> /// Creates a mew GridTopologyDisplay /// </summary> /// <param name="display">Corresponding display device</param> /// <param name="overlap">The overlap values</param> /// <param name="rotation">The display rotation</param> /// <param name="cloneGroup">The display clone group</param> /// <param name="pixelShiftType">The display pixel shift type</param> public GridTopologyDisplay(DisplayDevice display, Overlap overlap = default(Overlap), Rotate rotation = Rotate.Degree0, uint cloneGroup = 0, PixelShiftType pixelShiftType = PixelShiftType.NoPixelShift) { DisplayDevice = display; Overlap = overlap; Rotation = rotation; CloneGroup = cloneGroup; PixelShiftType = pixelShiftType; }
/// <inheritdoc /> public override int GetHashCode() { unchecked { var hashCode = Resolution.GetHashCode(); hashCode = (hashCode * 397) ^ Frequency; hashCode = (hashCode * 397) ^ (int)FrequencyInMillihertz; hashCode = (hashCode * 397) ^ (int)TopologyMode; hashCode = (hashCode * 397) ^ Overlap.GetHashCode(); return(hashCode); } }
/// <inheritdoc /> public override int GetHashCode() { unchecked { var hashCode = DisplayDevice?.GetHashCode() ?? 0; hashCode = (hashCode * 397) ^ Overlap.GetHashCode(); hashCode = (hashCode * 397) ^ (int)Rotation; hashCode = (hashCode * 397) ^ (int)CloneGroup; hashCode = (hashCode * 397) ^ (int)PixelShiftType; return(hashCode); } }
/// <inheritdoc /> public bool Equals(Topology other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(Resolution.Equals(other.Resolution) && (Frequency == other.Frequency) && (FrequencyInMillihertz == other.FrequencyInMillihertz) && (TopologyMode == other.TopologyMode) && Overlap.Equals(other.Overlap)); }
/// <inheritdoc /> public bool Equals(GridTopologyDisplay other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(DisplayDevice.Equals(other.DisplayDevice) && Overlap.Equals(other.Overlap) && (Rotation == other.Rotation) && (CloneGroup == other.CloneGroup) && (PixelShiftType == other.PixelShiftType)); }
/// <inheritdoc /> public bool Equals(TopologyDisplay other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(PhysicalGPU.Equals(other.PhysicalGPU) && Output.Equals(other.Output) && Overlap.Equals(other.Overlap)); }
internal TopologyDisplay(Native.Mosaic.Structures.TopologyDetails.LayoutCell layoutCell) { PhysicalGPU = !layoutCell.PhysicalGPUHandle.IsNull ? new PhysicalGPU(layoutCell.PhysicalGPUHandle) : null; Output = new GPUOutput(layoutCell.DisplayOutputId, PhysicalGPU); Overlap = new Overlap(layoutCell.OverlapX, layoutCell.OverlapY); }
/// <summary> /// Checks to see if the overlap values fall in to the acceptable overlap ranges /// </summary> /// <param name="overlap">The overlap values</param> /// <returns>true if the values fall into the range, otherwise false</returns> public bool IsInRange(Overlap overlap) { return(IsInHorizontalRange(overlap.HorizontalOverlap) && IsInVerticalRange(overlap.VerticalOverlap)); }