From 9b1dd099f60ae1b49d226e5298cc61c21c0f23f0 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 16:47:09 -0600 Subject: [PATCH 1/8] feat: Add IPresenterTrack and ISpeakerTrack interfaces Introduced two new interfaces, `IPresenterTrack` and `ISpeakerTrack`, in the `PepperDash.Essentials.Devices.Common.Codec.Cisco` namespace. These interfaces provide properties and methods for managing presenter and speaker tracking functionalities in Cisco codecs, including availability, status feedback, and control methods. --- .../Codec/Cisco/IPresenterTrack.cs | 32 +++++++++++++++++++ .../Codec/Cisco/ISpeakerTrack.cs | 25 +++++++++++++++ 2 files changed, 57 insertions(+) create mode 100644 src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs create mode 100644 src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs new file mode 100644 index 00000000..538a5adf --- /dev/null +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs @@ -0,0 +1,32 @@ +using PepperDash.Core; +using PepperDash.Essentials.Core; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace PepperDash.Essentials.Devices.Common.Codec.Cisco +{ + /// + /// Describes the Presenter Track controls for a Cisco codec. + /// + public interface IPresenterTrack : IKeyed + { + bool PresenterTrackAvailability { get; } + + BoolFeedback PresenterTrackAvailableFeedback { get; } + + BoolFeedback PresenterTrackStatusOffFeedback { get; } + BoolFeedback PresenterTrackStatusFollowFeedback { get; } + BoolFeedback PresenterTrackStatusBackgroundFeedback { get; } + BoolFeedback PresenterTrackStatusPersistentFeedback { get; } + + bool PresenterTrackStatus { get; } + + void PresenterTrackOff(); + void PresenterTrackFollow(); + void PresenterTrackBackground(); + void PresenterTrackPersistent(); + } +} diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs new file mode 100644 index 00000000..4e72dcf6 --- /dev/null +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs @@ -0,0 +1,25 @@ +using PepperDash.Core; +using PepperDash.Essentials.Core; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace PepperDash.Essentials.Devices.Common.Codec.Cisco +{ + /// + /// Describes the available tracking modes for a Cisco codec + /// + public interface ISpeakerTrack : IKeyed + { + bool SpeakerTrackAvailability { get; } + + BoolFeedback SpeakerTrackAvailableFeedback { get; } + + bool SpeakerTrackStatus { get; } + + void SpeakerTrackOff(); + void SpeakerTrackOn(); + } +} From 0a6896910d3d0971d06606819480819f56a1ff22 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 18:35:36 -0600 Subject: [PATCH 2/8] feat: Add screen/layout management and codec tracking features Introduced new interfaces and classes for screen and layout management, including `IHasScreensWithLayouts`, `ScreenInfo`, and `LayoutInfo`. Enhanced `IPresenterTrack` and `ISpeakerTrack` interfaces with additional properties and methods for managing presenter and speaker tracking. Added `IHasCodecRoomPresets` interface for room preset management and updated `CodecRoomPreset` class with a new constructor. --- .../IHasScreensWithLayouts.cs | 70 +++++++++++++++++++ .../Codec/Cisco/IPresenterTrack.cs | 39 +++++++++++ .../Codec/Cisco/ISpeakerTrack.cs | 15 ++++ .../VideoCodec/CiscoCodec/RoomPresets.cs | 34 ++++++++- 4 files changed, 157 insertions(+), 1 deletion(-) create mode 100644 src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs diff --git a/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs new file mode 100644 index 00000000..ccae1e11 --- /dev/null +++ b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs @@ -0,0 +1,70 @@ +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace PepperDash.Essentials.Core.DeviceTypeInterfaces +{ + /// + /// This defines a device that has screens with layouts + /// Simply decorative + /// + public interface IHasScreensWithLayouts + { + /// + /// A dictionary of screens, keyed by screen ID, that contains information about each screen and its layouts. + /// + Dictionary Screens { get; } + } + + /// + /// Represents information about a screen and its layouts. + /// + public class ScreenInfo + { + + /// + /// Indicates whether the screen is enabled or not. + /// + [JsonProperty("enabled")] + public bool Enabled { get; set; } + + /// + /// The name of the screen. + /// + [JsonProperty("name")] + public string Name { get; set; } + + /// + /// The index of the screen. + /// + [JsonProperty("screenIndex")] + public int ScreenIndex { get; set; } + + /// + /// A dictionary of layout information for the screen, keyed by layout ID. + /// + [JsonProperty("layouts")] + public Dictionary Layouts { get; set; } + } + + /// + /// Represents information about a layout on a screen. + /// + public class LayoutInfo + { + /// + /// The display name for the layout + /// + [JsonProperty("layoutName")] + public string LayoutName { get; set; } + + /// + /// The index of the layout. + /// + [JsonProperty("layoutIndex")] + public int LayoutIndex { get; set; } + } +} diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs index 538a5adf..b38225fe 100644 --- a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs @@ -13,20 +13,59 @@ namespace PepperDash.Essentials.Devices.Common.Codec.Cisco /// public interface IPresenterTrack : IKeyed { + /// + /// + /// bool PresenterTrackAvailability { get; } + /// + /// Feedback indicating whether Presenter Track is available. + /// BoolFeedback PresenterTrackAvailableFeedback { get; } + /// + /// Feedback indicateing the current status of Presenter Track is off + /// BoolFeedback PresenterTrackStatusOffFeedback { get; } + + /// + /// Feedback indicating the current status of Presenter Track is follow + /// BoolFeedback PresenterTrackStatusFollowFeedback { get; } + + /// + /// Feedback indicating the current status of Presenter Track is background + /// BoolFeedback PresenterTrackStatusBackgroundFeedback { get; } + + /// + /// Feedback indicating the current status of Presenter Track is persistent + /// BoolFeedback PresenterTrackStatusPersistentFeedback { get; } + /// + /// Indicates the current status of Presenter Track. + /// bool PresenterTrackStatus { get; } + /// + /// Turns off Presenter Track. + /// void PresenterTrackOff(); + + /// + /// Turns on Presenter Track in follow mode. + /// void PresenterTrackFollow(); + + /// + /// Turns on Presenter Track in background mode. + /// void PresenterTrackBackground(); + + /// + /// Turns on Presenter Track in persistent mode. + /// void PresenterTrackPersistent(); } } diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs index 4e72dcf6..83735183 100644 --- a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/ISpeakerTrack.cs @@ -13,13 +13,28 @@ namespace PepperDash.Essentials.Devices.Common.Codec.Cisco /// public interface ISpeakerTrack : IKeyed { + /// + /// Indicates whether Speaker Track is available on the codec. + /// bool SpeakerTrackAvailability { get; } + /// + /// + /// BoolFeedback SpeakerTrackAvailableFeedback { get; } + /// + /// Feedback indicating the current status of Speaker Track is off + /// bool SpeakerTrackStatus { get; } + /// + /// Turns Speaker Track off + /// void SpeakerTrackOff(); + /// + /// Turns Speaker Track on + /// void SpeakerTrackOn(); } } diff --git a/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs b/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs index 8fc8a1d0..0adf40a2 100644 --- a/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs +++ b/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs @@ -12,20 +12,45 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec /// public interface IHasCodecRoomPresets { + /// + /// Event that is raised when the list of room presets has changed. + /// event EventHandler CodecRoomPresetsListHasChanged; + /// + /// List of near end presets that can be recalled. + /// List NearEndPresets { get; } + /// + /// List of far end presets that can be recalled. + /// List FarEndRoomPresets { get; } + /// + /// Selects a near end preset by its ID. + /// + /// void CodecRoomPresetSelect(int preset); + /// + /// Stores a near end preset with the given ID and description. + /// + /// + /// void CodecRoomPresetStore(int preset, string description); + /// + /// Selects a far end preset by its ID. This is typically used to recall a preset that has been defined on the far end codec. + /// + /// void SelectFarEndPreset(int preset); } - public static class RoomPresets + /// + /// Static class for converting non-generic RoomPresets to generic CameraPresets. + /// + public static class RoomPresets { /// /// Converts non-generic RoomPresets to generic CameraPresets @@ -47,6 +72,13 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec /// public class CodecRoomPreset : PresetBase { + /// + /// + /// + /// + /// + /// + /// public CodecRoomPreset(int id, string description, bool def, bool isDef) : base(id, description, def, isDef) { From af98a92f8c53e5bb802eaaed64c2974ce3bdacc2 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 19:01:13 -0600 Subject: [PATCH 3/8] (force-patch): generate new build to test updated workflow nuget push issues --- .../VideoCodec/CiscoCodec/RoomPresets.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs b/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs index 0adf40a2..a6531a40 100644 --- a/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs +++ b/src/PepperDash.Essentials.Devices.Common/VideoCodec/CiscoCodec/RoomPresets.cs @@ -38,7 +38,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec /// /// /// - void CodecRoomPresetStore(int preset, string description); + void CodecRoomPresetStore(int preset, string description); /// /// Selects a far end preset by its ID. This is typically used to recall a preset that has been defined on the far end codec. From 7178d8e284cfd3722f0a6982d78e03438584a518 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 19:17:34 -0600 Subject: [PATCH 4/8] featr: Add PresenterTrackMode enum to IPresenterTrack.cs Introduces a new enumeration `PresenterTrackMode` that defines four tracking modes for the Cisco codec's Presenter Track feature: `Off`, `Follow`, `Background`, and `Persistent`. Each mode includes a summary comment for clarity. --- .../Codec/Cisco/IPresenterTrack.cs | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs index b38225fe..15b378f8 100644 --- a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs @@ -8,6 +8,30 @@ using System.Threading.Tasks; namespace PepperDash.Essentials.Devices.Common.Codec.Cisco { + /// + /// Describes the available tracking modes for a Cisco codec's Presenter Track feature. + /// + public enum PresenterTrackMode + { + /// + /// Presenter Track is turned off. + /// + Off, + /// + /// Presenter Track follows the speaker's movements. + /// + Follow, + /// + /// Presenter Track is set to background mode, where it tracks the speaker but does not actively follow. + /// + Background, + /// + /// Presenter Track is set to persistent mode, where it maintains a fixed position or focus on the speaker. + /// + Persistent + } + + /// /// Describes the Presenter Track controls for a Cisco codec. /// From 2c5cae9f4119e562cff3c1f82dfdfc74e9efedcd Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 19:18:30 -0600 Subject: [PATCH 5/8] fix: Rename PresenterTrackMode to ePresenterTrackMode Updated the enum name to reflect new naming conventions and potentially broader categorization within the codebase. --- .../Codec/Cisco/IPresenterTrack.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs index 15b378f8..a03dfddb 100644 --- a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs @@ -11,7 +11,7 @@ namespace PepperDash.Essentials.Devices.Common.Codec.Cisco /// /// Describes the available tracking modes for a Cisco codec's Presenter Track feature. /// - public enum PresenterTrackMode + public enum ePresenterTrackMode { /// /// Presenter Track is turned off. From f3159738ce4e333c40eecd95d9cf0517ef1916b1 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Tue, 17 Jun 2025 20:33:25 -0600 Subject: [PATCH 6/8] feat: Enhance layout and window configuration classes Added `LayoutType` and `Windows` properties to the `LayoutInfo` class. Introduced a new `WindowConfig` class with `Label` and `Input` properties to represent window configurations within a layout. --- .../IHasScreensWithLayouts.cs | 32 ++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs index ccae1e11..dec9c0b3 100644 --- a/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs +++ b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs @@ -56,7 +56,7 @@ namespace PepperDash.Essentials.Core.DeviceTypeInterfaces public class LayoutInfo { /// - /// The display name for the layout + /// The name of the layout. /// [JsonProperty("layoutName")] public string LayoutName { get; set; } @@ -66,5 +66,35 @@ namespace PepperDash.Essentials.Core.DeviceTypeInterfaces /// [JsonProperty("layoutIndex")] public int LayoutIndex { get; set; } + + /// + /// The type of the layout, which can be "single", "double", "triple", or "quad". + /// + [JsonProperty("layoutType")] + public string LayoutType { get; set; } + + /// + /// A dictionary of window configurations for the layout, keyed by window ID. + /// + [JsonProperty("windows")] + public Dictionary Windows { get; set; } + } + + /// + /// Represents the configuration of a window within a layout on a screen. + /// + public class WindowConfig + { + /// + /// The display label for the window + /// + [JsonProperty("label")] + public string Label { get; set; } + + /// + /// The input for the window + /// + [JsonProperty("input")] + public string Input { get; set; } } } From 183879f1c435490eafb0b3eda4fe7f34dafe0aad Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Wed, 18 Jun 2025 11:11:12 -0600 Subject: [PATCH 7/8] feat: Add ApplyLayout method to IHasScreensWithLayouts Introduced a new method `ApplyLayout` in the `IHasScreensWithLayouts` interface. This method enables the application of a specific layout to a screen using the provided screen ID and layout index. XML documentation has been added to clarify its purpose and parameters. --- .../DeviceTypeInterfaces/IHasScreensWithLayouts.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs index dec9c0b3..439462c6 100644 --- a/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs +++ b/src/PepperDash.Essentials.Core/DeviceTypeInterfaces/IHasScreensWithLayouts.cs @@ -17,6 +17,13 @@ namespace PepperDash.Essentials.Core.DeviceTypeInterfaces /// A dictionary of screens, keyed by screen ID, that contains information about each screen and its layouts. /// Dictionary Screens { get; } + + /// + /// Applies a specific layout to a screen based on the provided screen ID and layout index. + /// + /// + /// + void ApplyLayout(uint screenId, uint layoutIndex); } /// From 9c94806e4f0e55c71cfd228d09176bd379e7b2f0 Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Wed, 18 Jun 2025 13:21:32 -0600 Subject: [PATCH 8/8] Update src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .../Codec/Cisco/IPresenterTrack.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs index a03dfddb..f3f164bd 100644 --- a/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs +++ b/src/PepperDash.Essentials.Devices.Common/Codec/Cisco/IPresenterTrack.cs @@ -48,7 +48,7 @@ namespace PepperDash.Essentials.Devices.Common.Codec.Cisco BoolFeedback PresenterTrackAvailableFeedback { get; } /// - /// Feedback indicateing the current status of Presenter Track is off + /// Feedback indicating the current status of Presenter Track is off /// BoolFeedback PresenterTrackStatusOffFeedback { get; }