Releases: fredemmott/StreamDeck-CPPSDK
v3.0.3: improved platform compatibility
- Support building on more recent versions of MacoS - thanks to @timothyschoen (#23)
v3.0.2: increased platform compatibility
- supports MSVC 17.5 (February update to Visual Studio 2022)
- consistently uses
std::filesystem
forESD::filesystem
on Windows; it is also used on projects targeting MacOS v10.15 and above, andghc::filesystem
is used on v10.11-v10.14
v3.0.1: Compatibility with MacOS 10.11
This release is compatible with builds targeting MacOS 10.11.
This release adds ESD::filesystem
which is an alias for std::filesystem
where available, and an alias for https://github.com/gulrak/filesystem on MacOS 10.11-10.14.
Thanks to @quentinmit
v3.0: use new C++ features, CMake changes, and deprecations
This release:
- targets C++20; this means that MacOS plugins must target MacOS 10.15 or above
- Removes the
kESDSDKVersion
constant - Adds
ESD::format()
- this is an alias forstd::format
if it is available, otherwise it is an alias forfmt::format
. This adds support for compile-time verification of wchar-based format strings when building with MSVC 2022 - fmtlib is no longer included if
std::format
is available - Changes
ESDUtilities::GetPluginExecutablePath()
andESDUtilities::GetPluginDirectoryPath()
to return anstd::filesystem::path
instead of anstd::string
- Removed
ESDDebugf()
andESDLogf()
; use thestd::format
-basedESDDebug()
andESDLog()
functions instead - changes the provided
StreamDeckSDK.cmake
to useFetchContent
instead ofExternalProject
; this makes it easier to use your projects' build/link flags, e.g. macos architectures - Marks
ESDUtilities::DoSleep()
as[[deprecated]]
in favor ofstd::this_thread::sleep_for()
- Marks the path-manipulating functions in
ESDUtilities
as[[deprecated]]
in favor ofstd::filesystem::path
Windows note
StreamDeck-CPPSDK must build in C++20, including /await:strict
instead of /await
; older versions of the Windows SDK may raise errors saying that /await
is needed - in this case, a newer Windows SDK must be used.
If you use GitHub Actions, one way to do this is to specify CMAKE_SYSTEM_VERSION=10.0.22621.0
ESDUtilities::GetParentDirectoryPath()to
std::filesystem::path::parent_path()` migration note
GetParentDirectoryPath()
will automatically remove trailing slashes, however std::filesystem::path
will not; for example, GetParentDirectoryPath("/foo/bar/")
is /foo
, but std::filesystem::path("/foo/bar/").parent_path()
is "/foo/bar"
v2.0.3: add `kESDSDKDeviceType_StreamDeckPedal`
- add
kESDSDKDeviceType_StreamDeckPedal
- fix default
STREAMDECK_PLUGIN_DIR
on MacOS
v2.0.2: Adds set_default_install_dir_to_streamdeck_plugin_dir CMake function
This function should be called before any other targets are defined.
v2.0.1: exit cleanly if asio context is re-used by plugin
When the streamdeck software is exiting, it closes the websocket connections to plugins; this usually stops the asio event loop, but if there are pending events (which is possible if a plugin uses GetAsioContext()
), it will not exit cleanly, and eventually be killed by the StreamDeck software.
This release explicitly shuts down the event loop when the websocket connection is closed.
v2.0.0: Update to Elgato 4.8 SDK, add ESDAction and ESDPlugin classes
This release:
- adds new features from the 4.4 to 4.8 SDK updates
- adds corsair gkeys device type
- adds SystemDidWakeUp() event
- adds optional
state
parameter toSetTitle
andSetImage
- requires C++17 or C++20 (tested with Visual Studio 2019, latest XCode)
- adds a minimal example
- supports building for arm64 (M1) macs via
CMAKE_OSX_ARCHITECTURES
- adds
ESDPlugin
andESDAction
: instead of directly subclassingESDBasePlugin
, consider putting most of your code intoESDAction
subclasses (one for each supported action), and having a minimalESDPlugin
subclass that merely managesESDAction
instances. For example, "StreamDeckAudioMutePlugin" is anESDPlugin
, and "Toggle Mute", "Mute Off", "Mute On" are allESDAction
subclasses that are created and tracked by theStreamDeckAudioMutePlugin
- includes libfmt (C++20-style format string support on C++17 compilers), and updates the included versions of asio and websocketpp
- moves
ESDDebug()
andESDLog()
from sprintf-style (ESDDebug("Foo %s", "bar")
) to C++20-style (ESDDebug("Foo {}")
); the old forms are available asESDDebugf()
andESDLogf()
for find-replace. These functions replaceDebugPrint()
in Elgato's C++ examples. ESDDebug()
andESDLog()
now support wide-strings on Windows, e.g.ESDDebug(L"Foo {}", L"bar)
.- Removes
ESDLogger::SetWin32DebugPrefix()
: the executable name is automatically detected on macos and added to debug messages viewable withdbgview
,windbg
, Visual Studio, orConsole.app
on MacOS - Supports static linking on windows via CMAKE_MSVC_RUNTIME_LIBRARY
- Adds
ESDUtilities::GetPluginExecutablePath()
; renamesGetFolderPath()
toGetParentDirectoryPath()
andGetPluginPath()
toGetPluginDirectoryPath()
- Adds
ESDConnectionManager::GetAsioContext()
exposing the asio context used by websocketpp; this allows adding additional async connections (sockets, websockets, named pipes) or timers without needing additional threads. For example, this is used by StreamDeck-AudioMute for timers, and StreamDeck-Discord to manage the communication with Discord. - Adds a
STREAMDECK_PLUGIN_DIR
cmake variable that can be used to set a defaultCMAKE_INSTALLATION_PREFIX
to simplify local testing
v2.0-rc13: SDK 4.8 support
This release adds:
- a STREAMDECK_PLUGIN_DIR cmake variable
- a small, standalone example
- ESDAction::KeyDown()
- ESDPlugin::SystemDidWakeUp()
- Corsair GKeys device type
- optional
state
parameter toSetTitle
andSetImage
v2.0-rc12: add ESDAction::GetAction(), make ESDAction::GetContext() public
This is useful when a plugin wants to directly interface with ESDCommunicationManager to perform the same action for all actions it manages, e.g. to indicate a plugin-wide error