// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.240405.15 #pragma once #ifndef WINRT_Windows_Media_H #define WINRT_Windows_Media_H #include "winrt/base.h" static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.240405.15"), "Mismatched C++/WinRT headers."); #define CPPWINRT_VERSION "2.0.240405.15" #include "winrt/impl/Windows.ApplicationModel.AppService.2.h" #include "winrt/impl/Windows.Foundation.2.h" #include "winrt/impl/Windows.Foundation.Collections.2.h" #include "winrt/impl/Windows.Graphics.DirectX.2.h" #include "winrt/impl/Windows.Graphics.DirectX.Direct3D11.2.h" #include "winrt/impl/Windows.Graphics.Imaging.2.h" #include "winrt/impl/Windows.Storage.2.h" #include "winrt/impl/Windows.Storage.Streams.2.h" #include "winrt/impl/Windows.Media.2.h" namespace winrt::impl { template auto consume_Windows_Media_IAudioBuffer::Capacity() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAudioBuffer)->get_Capacity(&value)); return value; } template auto consume_Windows_Media_IAudioBuffer::Length() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAudioBuffer)->get_Length(&value)); return value; } template auto consume_Windows_Media_IAudioBuffer::Length(uint32_t value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAudioBuffer)->put_Length(value)); } template auto consume_Windows_Media_IAudioFrame::LockBuffer(winrt::Windows::Media::AudioBufferAccessMode const& mode) const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAudioFrame)->LockBuffer(static_cast(mode), &value)); return winrt::Windows::Media::AudioBuffer{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IAudioFrameFactory::Create(uint32_t capacity) const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAudioFrameFactory)->Create(capacity, &value)); return winrt::Windows::Media::AudioFrame{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IAutoRepeatModeChangeRequestedEventArgs::RequestedAutoRepeatMode() const { winrt::Windows::Media::MediaPlaybackAutoRepeatMode value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IAutoRepeatModeChangeRequestedEventArgs)->get_RequestedAutoRepeatMode(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_IImageDisplayProperties::Title() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IImageDisplayProperties)->get_Title(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IImageDisplayProperties::Title(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IImageDisplayProperties)->put_Title(*(void**)(&value))); } template auto consume_Windows_Media_IImageDisplayProperties::Subtitle() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IImageDisplayProperties)->get_Subtitle(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IImageDisplayProperties::Subtitle(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IImageDisplayProperties)->put_Subtitle(*(void**)(&value))); } template auto consume_Windows_Media_IMediaControl::SoundLevelChanged(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_SoundLevelChanged(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::SoundLevelChanged(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, SoundLevelChanged(handler)); } template auto consume_Windows_Media_IMediaControl::SoundLevelChanged(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_SoundLevelChanged(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::PlayPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_PlayPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::PlayPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, PlayPressed(handler)); } template auto consume_Windows_Media_IMediaControl::PlayPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_PlayPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::PausePressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_PausePressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::PausePressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, PausePressed(handler)); } template auto consume_Windows_Media_IMediaControl::PausePressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_PausePressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::StopPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_StopPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::StopPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, StopPressed(handler)); } template auto consume_Windows_Media_IMediaControl::StopPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_StopPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::PlayPauseTogglePressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_PlayPauseTogglePressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::PlayPauseTogglePressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, PlayPauseTogglePressed(handler)); } template auto consume_Windows_Media_IMediaControl::PlayPauseTogglePressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_PlayPauseTogglePressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::RecordPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_RecordPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::RecordPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, RecordPressed(handler)); } template auto consume_Windows_Media_IMediaControl::RecordPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_RecordPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::NextTrackPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_NextTrackPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::NextTrackPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, NextTrackPressed(handler)); } template auto consume_Windows_Media_IMediaControl::NextTrackPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_NextTrackPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::PreviousTrackPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_PreviousTrackPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::PreviousTrackPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, PreviousTrackPressed(handler)); } template auto consume_Windows_Media_IMediaControl::PreviousTrackPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_PreviousTrackPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::FastForwardPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_FastForwardPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::FastForwardPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, FastForwardPressed(handler)); } template auto consume_Windows_Media_IMediaControl::FastForwardPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_FastForwardPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::RewindPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_RewindPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::RewindPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, RewindPressed(handler)); } template auto consume_Windows_Media_IMediaControl::RewindPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_RewindPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::ChannelUpPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_ChannelUpPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::ChannelUpPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, ChannelUpPressed(handler)); } template auto consume_Windows_Media_IMediaControl::ChannelUpPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_ChannelUpPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::ChannelDownPressed(winrt::Windows::Foundation::EventHandler const& handler) const { winrt::event_token cookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->add_ChannelDownPressed(*(void**)(&handler), put_abi(cookie))); return cookie; } template auto consume_Windows_Media_IMediaControl::ChannelDownPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) const { return impl::make_event_revoker(this, ChannelDownPressed(handler)); } template auto consume_Windows_Media_IMediaControl::ChannelDownPressed(winrt::event_token const& cookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->remove_ChannelDownPressed(impl::bind_in(cookie)); } template auto consume_Windows_Media_IMediaControl::SoundLevel() const { winrt::Windows::Media::SoundLevel value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->get_SoundLevel(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_IMediaControl::TrackName(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->put_TrackName(*(void**)(&value))); } template auto consume_Windows_Media_IMediaControl::TrackName() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->get_TrackName(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaControl::ArtistName(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->put_ArtistName(*(void**)(&value))); } template auto consume_Windows_Media_IMediaControl::ArtistName() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->get_ArtistName(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaControl::IsPlaying(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->put_IsPlaying(value)); } template auto consume_Windows_Media_IMediaControl::IsPlaying() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->get_IsPlaying(&value)); return value; } template auto consume_Windows_Media_IMediaControl::AlbumArt(winrt::Windows::Foundation::Uri const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->put_AlbumArt(*(void**)(&value))); } template auto consume_Windows_Media_IMediaControl::AlbumArt() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaControl)->get_AlbumArt(&value)); return winrt::Windows::Foundation::Uri{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaExtension::SetProperties(winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtension)->SetProperties(*(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterSchemeHandler(param::hstring const& activatableClassId, param::hstring const& scheme) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterSchemeHandler(*(void**)(&activatableClassId), *(void**)(&scheme))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterSchemeHandler(param::hstring const& activatableClassId, param::hstring const& scheme, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterSchemeHandlerWithSettings(*(void**)(&activatableClassId), *(void**)(&scheme), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterByteStreamHandler(param::hstring const& activatableClassId, param::hstring const& fileExtension, param::hstring const& mimeType) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterByteStreamHandler(*(void**)(&activatableClassId), *(void**)(&fileExtension), *(void**)(&mimeType))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterByteStreamHandler(param::hstring const& activatableClassId, param::hstring const& fileExtension, param::hstring const& mimeType, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterByteStreamHandlerWithSettings(*(void**)(&activatableClassId), *(void**)(&fileExtension), *(void**)(&mimeType), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterAudioDecoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterAudioDecoder(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterAudioDecoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterAudioDecoderWithSettings(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterAudioEncoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterAudioEncoder(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterAudioEncoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterAudioEncoderWithSettings(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterVideoDecoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterVideoDecoder(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterVideoDecoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterVideoDecoderWithSettings(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterVideoEncoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterVideoEncoder(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype))); } template auto consume_Windows_Media_IMediaExtensionManager::RegisterVideoEncoder(param::hstring const& activatableClassId, winrt::guid const& inputSubtype, winrt::guid const& outputSubtype, winrt::Windows::Foundation::Collections::IPropertySet const& configuration) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager)->RegisterVideoEncoderWithSettings(*(void**)(&activatableClassId), impl::bind_in(inputSubtype), impl::bind_in(outputSubtype), *(void**)(&configuration))); } template auto consume_Windows_Media_IMediaExtensionManager2::RegisterMediaExtensionForAppService(winrt::Windows::Media::IMediaExtension const& extension, winrt::Windows::ApplicationModel::AppService::AppServiceConnection const& connection) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaExtensionManager2)->RegisterMediaExtensionForAppService(*(void**)(&extension), *(void**)(&connection))); } template auto consume_Windows_Media_IMediaFrame::Type() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_Type(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaFrame::IsReadOnly() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_IsReadOnly(&value)); return value; } template auto consume_Windows_Media_IMediaFrame::RelativeTime(winrt::Windows::Foundation::IReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->put_RelativeTime(*(void**)(&value))); } template auto consume_Windows_Media_IMediaFrame::RelativeTime() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_RelativeTime(&value)); return winrt::Windows::Foundation::IReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaFrame::SystemRelativeTime(winrt::Windows::Foundation::IReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->put_SystemRelativeTime(*(void**)(&value))); } template auto consume_Windows_Media_IMediaFrame::SystemRelativeTime() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_SystemRelativeTime(&value)); return winrt::Windows::Foundation::IReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaFrame::Duration(winrt::Windows::Foundation::IReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->put_Duration(*(void**)(&value))); } template auto consume_Windows_Media_IMediaFrame::Duration() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_Duration(&value)); return winrt::Windows::Foundation::IReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaFrame::IsDiscontinuous(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->put_IsDiscontinuous(value)); } template auto consume_Windows_Media_IMediaFrame::IsDiscontinuous() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_IsDiscontinuous(&value)); return value; } template auto consume_Windows_Media_IMediaFrame::ExtendedProperties() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaFrame)->get_ExtendedProperties(&value)); return winrt::Windows::Foundation::Collections::IPropertySet{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaMarker::Time() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaMarker)->get_Time(put_abi(value))); return value; } template auto consume_Windows_Media_IMediaMarker::MediaMarkerType() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaMarker)->get_MediaMarkerType(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaMarker::Text() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaMarker)->get_Text(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaMarkerTypesStatics::Bookmark() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaMarkerTypesStatics)->get_Bookmark(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaMarkers::Markers() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaMarkers)->get_Markers(&value)); return winrt::Windows::Foundation::Collections::IVectorView{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaProcessingTriggerDetails::Arguments() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaProcessingTriggerDetails)->get_Arguments(&value)); return winrt::Windows::Foundation::Collections::ValueSet{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaTimelineController::Start() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->Start()); } template auto consume_Windows_Media_IMediaTimelineController::Resume() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->Resume()); } template auto consume_Windows_Media_IMediaTimelineController::Pause() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->Pause()); } template auto consume_Windows_Media_IMediaTimelineController::Position() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->get_Position(put_abi(value))); return value; } template auto consume_Windows_Media_IMediaTimelineController::Position(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->put_Position(impl::bind_in(value))); } template auto consume_Windows_Media_IMediaTimelineController::ClockRate() const { double value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->get_ClockRate(&value)); return value; } template auto consume_Windows_Media_IMediaTimelineController::ClockRate(double value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->put_ClockRate(value)); } template auto consume_Windows_Media_IMediaTimelineController::State() const { winrt::Windows::Media::MediaTimelineControllerState value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->get_State(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_IMediaTimelineController::PositionChanged(winrt::Windows::Foundation::TypedEventHandler const& positionChangedEventHandler) const { winrt::event_token eventCookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->add_PositionChanged(*(void**)(&positionChangedEventHandler), put_abi(eventCookie))); return eventCookie; } template auto consume_Windows_Media_IMediaTimelineController::PositionChanged(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& positionChangedEventHandler) const { return impl::make_event_revoker(this, PositionChanged(positionChangedEventHandler)); } template auto consume_Windows_Media_IMediaTimelineController::PositionChanged(winrt::event_token const& eventCookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->remove_PositionChanged(impl::bind_in(eventCookie)); } template auto consume_Windows_Media_IMediaTimelineController::StateChanged(winrt::Windows::Foundation::TypedEventHandler const& stateChangedEventHandler) const { winrt::event_token eventCookie{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->add_StateChanged(*(void**)(&stateChangedEventHandler), put_abi(eventCookie))); return eventCookie; } template auto consume_Windows_Media_IMediaTimelineController::StateChanged(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& stateChangedEventHandler) const { return impl::make_event_revoker(this, StateChanged(stateChangedEventHandler)); } template auto consume_Windows_Media_IMediaTimelineController::StateChanged(winrt::event_token const& eventCookie) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController)->remove_StateChanged(impl::bind_in(eventCookie)); } template auto consume_Windows_Media_IMediaTimelineController2::Duration() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->get_Duration(&value)); return winrt::Windows::Foundation::IReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMediaTimelineController2::Duration(winrt::Windows::Foundation::IReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->put_Duration(*(void**)(&value))); } template auto consume_Windows_Media_IMediaTimelineController2::IsLoopingEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->get_IsLoopingEnabled(&value)); return value; } template auto consume_Windows_Media_IMediaTimelineController2::IsLoopingEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->put_IsLoopingEnabled(value)); } template auto consume_Windows_Media_IMediaTimelineController2::Failed(winrt::Windows::Foundation::TypedEventHandler const& eventHandler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->add_Failed(*(void**)(&eventHandler), put_abi(token))); return token; } template auto consume_Windows_Media_IMediaTimelineController2::Failed(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& eventHandler) const { return impl::make_event_revoker(this, Failed(eventHandler)); } template auto consume_Windows_Media_IMediaTimelineController2::Failed(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->remove_Failed(impl::bind_in(token)); } template auto consume_Windows_Media_IMediaTimelineController2::Ended(winrt::Windows::Foundation::TypedEventHandler const& eventHandler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->add_Ended(*(void**)(&eventHandler), put_abi(token))); return token; } template auto consume_Windows_Media_IMediaTimelineController2::Ended(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& eventHandler) const { return impl::make_event_revoker(this, Ended(eventHandler)); } template auto consume_Windows_Media_IMediaTimelineController2::Ended(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineController2)->remove_Ended(impl::bind_in(token)); } template auto consume_Windows_Media_IMediaTimelineControllerFailedEventArgs::ExtendedError() const { winrt::hresult value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMediaTimelineControllerFailedEventArgs)->get_ExtendedError(put_abi(value))); return value; } template auto consume_Windows_Media_IMusicDisplayProperties::Title() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->get_Title(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMusicDisplayProperties::Title(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->put_Title(*(void**)(&value))); } template auto consume_Windows_Media_IMusicDisplayProperties::AlbumArtist() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->get_AlbumArtist(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMusicDisplayProperties::AlbumArtist(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->put_AlbumArtist(*(void**)(&value))); } template auto consume_Windows_Media_IMusicDisplayProperties::Artist() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->get_Artist(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMusicDisplayProperties::Artist(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties)->put_Artist(*(void**)(&value))); } template auto consume_Windows_Media_IMusicDisplayProperties2::AlbumTitle() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties2)->get_AlbumTitle(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMusicDisplayProperties2::AlbumTitle(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties2)->put_AlbumTitle(*(void**)(&value))); } template auto consume_Windows_Media_IMusicDisplayProperties2::TrackNumber() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties2)->get_TrackNumber(&value)); return value; } template auto consume_Windows_Media_IMusicDisplayProperties2::TrackNumber(uint32_t value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties2)->put_TrackNumber(value)); } template auto consume_Windows_Media_IMusicDisplayProperties2::Genres() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties2)->get_Genres(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IMusicDisplayProperties3::AlbumTrackCount() const { uint32_t value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties3)->get_AlbumTrackCount(&value)); return value; } template auto consume_Windows_Media_IMusicDisplayProperties3::AlbumTrackCount(uint32_t value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IMusicDisplayProperties3)->put_AlbumTrackCount(value)); } template auto consume_Windows_Media_IPlaybackPositionChangeRequestedEventArgs::RequestedPlaybackPosition() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IPlaybackPositionChangeRequestedEventArgs)->get_RequestedPlaybackPosition(put_abi(value))); return value; } template auto consume_Windows_Media_IPlaybackRateChangeRequestedEventArgs::RequestedPlaybackRate() const { double value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IPlaybackRateChangeRequestedEventArgs)->get_RequestedPlaybackRate(&value)); return value; } template auto consume_Windows_Media_IShuffleEnabledChangeRequestedEventArgs::RequestedShuffleEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IShuffleEnabledChangeRequestedEventArgs)->get_RequestedShuffleEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::PlaybackStatus() const { winrt::Windows::Media::MediaPlaybackStatus value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_PlaybackStatus(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::PlaybackStatus(winrt::Windows::Media::MediaPlaybackStatus const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_PlaybackStatus(static_cast(value))); } template auto consume_Windows_Media_ISystemMediaTransportControls::DisplayUpdater() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_DisplayUpdater(&value)); return winrt::Windows::Media::SystemMediaTransportControlsDisplayUpdater{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControls::SoundLevel() const { winrt::Windows::Media::SoundLevel value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_SoundLevel(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPlayEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsPlayEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPlayEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsPlayEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsStopEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsStopEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsStopEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsStopEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPauseEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsPauseEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPauseEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsPauseEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsRecordEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsRecordEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsRecordEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsRecordEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsFastForwardEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsFastForwardEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsFastForwardEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsFastForwardEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsRewindEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsRewindEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsRewindEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsRewindEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPreviousEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsPreviousEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsPreviousEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsPreviousEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsNextEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsNextEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsNextEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsNextEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsChannelUpEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsChannelUpEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsChannelUpEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsChannelUpEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::IsChannelDownEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->get_IsChannelDownEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls::IsChannelDownEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->put_IsChannelDownEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls::ButtonPressed(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->add_ButtonPressed(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls::ButtonPressed(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, ButtonPressed(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls::ButtonPressed(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->remove_ButtonPressed(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControls::PropertyChanged(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->add_PropertyChanged(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls::PropertyChanged(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, PropertyChanged(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls::PropertyChanged(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls)->remove_PropertyChanged(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::AutoRepeatMode() const { winrt::Windows::Media::MediaPlaybackAutoRepeatMode value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->get_AutoRepeatMode(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls2::AutoRepeatMode(winrt::Windows::Media::MediaPlaybackAutoRepeatMode const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->put_AutoRepeatMode(static_cast(value))); } template auto consume_Windows_Media_ISystemMediaTransportControls2::ShuffleEnabled() const { bool value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->get_ShuffleEnabled(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls2::ShuffleEnabled(bool value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->put_ShuffleEnabled(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackRate() const { double value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->get_PlaybackRate(&value)); return value; } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackRate(double value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->put_PlaybackRate(value)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::UpdateTimelineProperties(winrt::Windows::Media::SystemMediaTransportControlsTimelineProperties const& timelineProperties) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->UpdateTimelineProperties(*(void**)(&timelineProperties))); } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackPositionChangeRequested(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->add_PlaybackPositionChangeRequested(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackPositionChangeRequested(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, PlaybackPositionChangeRequested(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackPositionChangeRequested(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->remove_PlaybackPositionChangeRequested(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackRateChangeRequested(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->add_PlaybackRateChangeRequested(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackRateChangeRequested(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, PlaybackRateChangeRequested(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::PlaybackRateChangeRequested(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->remove_PlaybackRateChangeRequested(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::ShuffleEnabledChangeRequested(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->add_ShuffleEnabledChangeRequested(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls2::ShuffleEnabledChangeRequested(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, ShuffleEnabledChangeRequested(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::ShuffleEnabledChangeRequested(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->remove_ShuffleEnabledChangeRequested(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::AutoRepeatModeChangeRequested(winrt::Windows::Foundation::TypedEventHandler const& handler) const { winrt::event_token token{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->add_AutoRepeatModeChangeRequested(*(void**)(&handler), put_abi(token))); return token; } template auto consume_Windows_Media_ISystemMediaTransportControls2::AutoRepeatModeChangeRequested(auto_revoke_t, winrt::Windows::Foundation::TypedEventHandler const& handler) const { return impl::make_event_revoker(this, AutoRepeatModeChangeRequested(handler)); } template auto consume_Windows_Media_ISystemMediaTransportControls2::AutoRepeatModeChangeRequested(winrt::event_token const& token) const noexcept { WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControls2)->remove_AutoRepeatModeChangeRequested(impl::bind_in(token)); } template auto consume_Windows_Media_ISystemMediaTransportControlsButtonPressedEventArgs::Button() const { winrt::Windows::Media::SystemMediaTransportControlsButton value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsButtonPressedEventArgs)->get_Button(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::Type() const { winrt::Windows::Media::MediaPlaybackType value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_Type(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::Type(winrt::Windows::Media::MediaPlaybackType const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->put_Type(static_cast(value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::AppMediaId() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_AppMediaId(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::AppMediaId(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->put_AppMediaId(*(void**)(&value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::Thumbnail() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_Thumbnail(&value)); return winrt::Windows::Storage::Streams::RandomAccessStreamReference{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::Thumbnail(winrt::Windows::Storage::Streams::RandomAccessStreamReference const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->put_Thumbnail(*(void**)(&value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::MusicProperties() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_MusicProperties(&value)); return winrt::Windows::Media::MusicDisplayProperties{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::VideoProperties() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_VideoProperties(&value)); return winrt::Windows::Media::VideoDisplayProperties{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::ImageProperties() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->get_ImageProperties(&value)); return winrt::Windows::Media::ImageDisplayProperties{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::CopyFromFileAsync(winrt::Windows::Media::MediaPlaybackType const& type, winrt::Windows::Storage::StorageFile const& source) const { void* operation{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->CopyFromFileAsync(static_cast(type), *(void**)(&source), &operation)); return winrt::Windows::Foundation::IAsyncOperation{ operation, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::ClearAll() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->ClearAll()); } template auto consume_Windows_Media_ISystemMediaTransportControlsDisplayUpdater::Update() const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsDisplayUpdater)->Update()); } template auto consume_Windows_Media_ISystemMediaTransportControlsPropertyChangedEventArgs::Property() const { winrt::Windows::Media::SystemMediaTransportControlsProperty value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsPropertyChangedEventArgs)->get_Property(reinterpret_cast(&value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsStatics::GetForCurrentView() const { void* mediaControl{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsStatics)->GetForCurrentView(&mediaControl)); return winrt::Windows::Media::SystemMediaTransportControls{ mediaControl, take_ownership_from_abi }; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::StartTime() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->get_StartTime(put_abi(value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::StartTime(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->put_StartTime(impl::bind_in(value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::EndTime() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->get_EndTime(put_abi(value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::EndTime(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->put_EndTime(impl::bind_in(value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::MinSeekTime() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->get_MinSeekTime(put_abi(value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::MinSeekTime(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->put_MinSeekTime(impl::bind_in(value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::MaxSeekTime() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->get_MaxSeekTime(put_abi(value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::MaxSeekTime(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->put_MaxSeekTime(impl::bind_in(value))); } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::Position() const { winrt::Windows::Foundation::TimeSpan value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->get_Position(put_abi(value))); return value; } template auto consume_Windows_Media_ISystemMediaTransportControlsTimelineProperties::Position(winrt::Windows::Foundation::TimeSpan const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::ISystemMediaTransportControlsTimelineProperties)->put_Position(impl::bind_in(value))); } template auto consume_Windows_Media_IVideoDisplayProperties::Title() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoDisplayProperties)->get_Title(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoDisplayProperties::Title(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoDisplayProperties)->put_Title(*(void**)(&value))); } template auto consume_Windows_Media_IVideoDisplayProperties::Subtitle() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoDisplayProperties)->get_Subtitle(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoDisplayProperties::Subtitle(param::hstring const& value) const { check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoDisplayProperties)->put_Subtitle(*(void**)(&value))); } template auto consume_Windows_Media_IVideoDisplayProperties2::Genres() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoDisplayProperties2)->get_Genres(&value)); return winrt::Windows::Foundation::Collections::IVector{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoEffectsStatics::VideoStabilization() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoEffectsStatics)->get_VideoStabilization(&value)); return hstring{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrame::SoftwareBitmap() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrame)->get_SoftwareBitmap(&value)); return winrt::Windows::Graphics::Imaging::SoftwareBitmap{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrame::CopyToAsync(winrt::Windows::Media::VideoFrame const& frame) const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrame)->CopyToAsync(*(void**)(&frame), &value)); return winrt::Windows::Foundation::IAsyncAction{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrame::Direct3DSurface() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrame)->get_Direct3DSurface(&value)); return winrt::Windows::Graphics::DirectX::Direct3D11::IDirect3DSurface{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrame2::CopyToAsync(winrt::Windows::Media::VideoFrame const& frame, winrt::Windows::Foundation::IReference const& sourceBounds, winrt::Windows::Foundation::IReference const& destinationBounds) const { void* operation{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrame2)->CopyToWithBoundsAsync(*(void**)(&frame), *(void**)(&sourceBounds), *(void**)(&destinationBounds), &operation)); return winrt::Windows::Foundation::IAsyncAction{ operation, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameFactory::Create(winrt::Windows::Graphics::Imaging::BitmapPixelFormat const& format, int32_t width, int32_t height) const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameFactory)->Create(static_cast(format), width, height, &value)); return winrt::Windows::Media::VideoFrame{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameFactory::CreateWithAlpha(winrt::Windows::Graphics::Imaging::BitmapPixelFormat const& format, int32_t width, int32_t height, winrt::Windows::Graphics::Imaging::BitmapAlphaMode const& alpha) const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameFactory)->CreateWithAlpha(static_cast(format), width, height, static_cast(alpha), &value)); return winrt::Windows::Media::VideoFrame{ value, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameStatics::CreateAsDirect3D11SurfaceBacked(winrt::Windows::Graphics::DirectX::DirectXPixelFormat const& format, int32_t width, int32_t height) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameStatics)->CreateAsDirect3D11SurfaceBacked(static_cast(format), width, height, &result)); return winrt::Windows::Media::VideoFrame{ result, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameStatics::CreateAsDirect3D11SurfaceBacked(winrt::Windows::Graphics::DirectX::DirectXPixelFormat const& format, int32_t width, int32_t height, winrt::Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice const& device) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameStatics)->CreateAsDirect3D11SurfaceBackedWithDevice(static_cast(format), width, height, *(void**)(&device), &result)); return winrt::Windows::Media::VideoFrame{ result, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameStatics::CreateWithSoftwareBitmap(winrt::Windows::Graphics::Imaging::SoftwareBitmap const& bitmap) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameStatics)->CreateWithSoftwareBitmap(*(void**)(&bitmap), &result)); return winrt::Windows::Media::VideoFrame{ result, take_ownership_from_abi }; } template auto consume_Windows_Media_IVideoFrameStatics::CreateWithDirect3D11Surface(winrt::Windows::Graphics::DirectX::Direct3D11::IDirect3DSurface const& surface) const { void* result{}; check_hresult(WINRT_IMPL_SHIM(winrt::Windows::Media::IVideoFrameStatics)->CreateWithDirect3D11Surface(*(void**)(&surface), &result)); return winrt::Windows::Media::VideoFrame{ result, take_ownership_from_abi }; } #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Capacity(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Capacity()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Length(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Length()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Length(uint32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Length(value); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall LockBuffer(int32_t mode, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().LockBuffer(*reinterpret_cast(&mode))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(uint32_t capacity, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(capacity)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_RequestedAutoRepeatMode(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestedAutoRepeatMode()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Title(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Title()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Title(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Title(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Subtitle(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Subtitle()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Subtitle(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Subtitle(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall add_SoundLevelChanged(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().SoundLevelChanged(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_SoundLevelChanged(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().SoundLevelChanged(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_PlayPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().PlayPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PlayPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PlayPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_PausePressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().PausePressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PausePressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PausePressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_StopPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().StopPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_StopPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().StopPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_PlayPauseTogglePressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().PlayPauseTogglePressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PlayPauseTogglePressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PlayPauseTogglePressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_RecordPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().RecordPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_RecordPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().RecordPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_NextTrackPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().NextTrackPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_NextTrackPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().NextTrackPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_PreviousTrackPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().PreviousTrackPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PreviousTrackPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PreviousTrackPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_FastForwardPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().FastForwardPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_FastForwardPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().FastForwardPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_RewindPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().RewindPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_RewindPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().RewindPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_ChannelUpPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().ChannelUpPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_ChannelUpPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().ChannelUpPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall add_ChannelDownPressed(void* handler, winrt::event_token* cookie) noexcept final try { zero_abi(cookie); typename D::abi_guard guard(this->shim()); *cookie = detach_from(this->shim().ChannelDownPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_ChannelDownPressed(winrt::event_token cookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().ChannelDownPressed(*reinterpret_cast(&cookie)); return 0; } int32_t __stdcall get_SoundLevel(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SoundLevel()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_TrackName(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().TrackName(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_TrackName(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().TrackName()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ArtistName(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ArtistName(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ArtistName(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ArtistName()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsPlaying(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsPlaying(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsPlaying(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsPlaying()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AlbumArt(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AlbumArt(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AlbumArt(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AlbumArt()); return 0; } catch (...) { return to_hresult(); } }; #endif template struct produce : produce_base { int32_t __stdcall SetProperties(void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().SetProperties(*reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } }; #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall RegisterSchemeHandler(void* activatableClassId, void* scheme) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterSchemeHandler(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&scheme)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterSchemeHandlerWithSettings(void* activatableClassId, void* scheme, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterSchemeHandler(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&scheme), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterByteStreamHandler(void* activatableClassId, void* fileExtension, void* mimeType) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterByteStreamHandler(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&fileExtension), *reinterpret_cast(&mimeType)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterByteStreamHandlerWithSettings(void* activatableClassId, void* fileExtension, void* mimeType, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterByteStreamHandler(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&fileExtension), *reinterpret_cast(&mimeType), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterAudioDecoder(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterAudioDecoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterAudioDecoderWithSettings(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterAudioDecoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterAudioEncoder(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterAudioEncoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterAudioEncoderWithSettings(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterAudioEncoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterVideoDecoder(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterVideoDecoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterVideoDecoderWithSettings(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterVideoDecoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterVideoEncoder(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterVideoEncoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall RegisterVideoEncoderWithSettings(void* activatableClassId, winrt::guid inputSubtype, winrt::guid outputSubtype, void* configuration) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterVideoEncoder(*reinterpret_cast(&activatableClassId), *reinterpret_cast(&inputSubtype), *reinterpret_cast(&outputSubtype), *reinterpret_cast(&configuration)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall RegisterMediaExtensionForAppService(void* extension, void* connection) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RegisterMediaExtensionForAppService(*reinterpret_cast(&extension), *reinterpret_cast(&connection)); return 0; } catch (...) { return to_hresult(); } }; #endif template struct produce : produce_base { int32_t __stdcall get_Type(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Type()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsReadOnly(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsReadOnly()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_RelativeTime(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().RelativeTime(*reinterpret_cast const*>(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_RelativeTime(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().RelativeTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_SystemRelativeTime(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().SystemRelativeTime(*reinterpret_cast const*>(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SystemRelativeTime(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().SystemRelativeTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Duration(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Duration(*reinterpret_cast const*>(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Duration(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Duration()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsDiscontinuous(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsDiscontinuous(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsDiscontinuous(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsDiscontinuous()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ExtendedProperties(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedProperties()); return 0; } catch (...) { return to_hresult(); } }; template struct produce : produce_base { int32_t __stdcall get_Time(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Time()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_MediaMarkerType(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().MediaMarkerType()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Text(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Text()); return 0; } catch (...) { return to_hresult(); } }; #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Bookmark(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Bookmark()); return 0; } catch (...) { return to_hresult(); } }; #endif template struct produce : produce_base { int32_t __stdcall get_Markers(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Markers()); return 0; } catch (...) { return to_hresult(); } }; #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Arguments(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Arguments()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Start() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Start(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall Resume() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Resume(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall Pause() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Pause(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Position(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Position()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Position(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Position(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ClockRate(double* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ClockRate()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ClockRate(double value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ClockRate(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_State(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().State()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_PositionChanged(void* positionChangedEventHandler, winrt::event_token* eventCookie) noexcept final try { zero_abi(eventCookie); typename D::abi_guard guard(this->shim()); *eventCookie = detach_from(this->shim().PositionChanged(*reinterpret_cast const*>(&positionChangedEventHandler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PositionChanged(winrt::event_token eventCookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PositionChanged(*reinterpret_cast(&eventCookie)); return 0; } int32_t __stdcall add_StateChanged(void* stateChangedEventHandler, winrt::event_token* eventCookie) noexcept final try { zero_abi(eventCookie); typename D::abi_guard guard(this->shim()); *eventCookie = detach_from(this->shim().StateChanged(*reinterpret_cast const*>(&stateChangedEventHandler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_StateChanged(winrt::event_token eventCookie) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().StateChanged(*reinterpret_cast(&eventCookie)); return 0; } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Duration(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Duration()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Duration(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Duration(*reinterpret_cast const*>(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsLoopingEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsLoopingEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsLoopingEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsLoopingEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_Failed(void* eventHandler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().Failed(*reinterpret_cast const*>(&eventHandler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_Failed(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().Failed(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_Ended(void* eventHandler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().Ended(*reinterpret_cast const*>(&eventHandler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_Ended(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().Ended(*reinterpret_cast(&token)); return 0; } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_ExtendedError(winrt::hresult* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ExtendedError()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Title(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Title()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Title(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Title(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AlbumArtist(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AlbumArtist()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AlbumArtist(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AlbumArtist(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Artist(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Artist()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Artist(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Artist(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_AlbumTitle(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AlbumTitle()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AlbumTitle(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AlbumTitle(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_TrackNumber(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().TrackNumber()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_TrackNumber(uint32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().TrackNumber(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Genres(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Genres()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_AlbumTrackCount(uint32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AlbumTrackCount()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AlbumTrackCount(uint32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AlbumTrackCount(value); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_RequestedPlaybackPosition(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestedPlaybackPosition()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_RequestedPlaybackRate(double* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestedPlaybackRate()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_RequestedShuffleEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().RequestedShuffleEnabled()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_PlaybackStatus(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().PlaybackStatus()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_PlaybackStatus(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().PlaybackStatus(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_DisplayUpdater(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().DisplayUpdater()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_SoundLevel(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SoundLevel()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsPlayEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsPlayEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsPlayEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsPlayEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsStopEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsStopEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsStopEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsStopEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsPauseEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsPauseEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsPauseEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsPauseEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsRecordEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsRecordEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsRecordEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsRecordEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsFastForwardEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsFastForwardEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsFastForwardEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsFastForwardEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsRewindEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsRewindEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsRewindEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsRewindEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsPreviousEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsPreviousEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsPreviousEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsPreviousEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsNextEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsNextEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsNextEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsNextEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsChannelUpEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsChannelUpEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsChannelUpEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsChannelUpEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_IsChannelDownEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().IsChannelDownEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_IsChannelDownEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().IsChannelDownEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_ButtonPressed(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().ButtonPressed(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_ButtonPressed(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().ButtonPressed(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_PropertyChanged(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().PropertyChanged(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PropertyChanged(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PropertyChanged(*reinterpret_cast(&token)); return 0; } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_AutoRepeatMode(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AutoRepeatMode()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AutoRepeatMode(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AutoRepeatMode(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ShuffleEnabled(bool* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ShuffleEnabled()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_ShuffleEnabled(bool value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ShuffleEnabled(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_PlaybackRate(double* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().PlaybackRate()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_PlaybackRate(double value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().PlaybackRate(value); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall UpdateTimelineProperties(void* timelineProperties) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().UpdateTimelineProperties(*reinterpret_cast(&timelineProperties)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall add_PlaybackPositionChangeRequested(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().PlaybackPositionChangeRequested(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PlaybackPositionChangeRequested(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PlaybackPositionChangeRequested(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_PlaybackRateChangeRequested(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().PlaybackRateChangeRequested(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_PlaybackRateChangeRequested(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().PlaybackRateChangeRequested(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_ShuffleEnabledChangeRequested(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().ShuffleEnabledChangeRequested(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_ShuffleEnabledChangeRequested(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().ShuffleEnabledChangeRequested(*reinterpret_cast(&token)); return 0; } int32_t __stdcall add_AutoRepeatModeChangeRequested(void* handler, winrt::event_token* token) noexcept final try { zero_abi(token); typename D::abi_guard guard(this->shim()); *token = detach_from(this->shim().AutoRepeatModeChangeRequested(*reinterpret_cast const*>(&handler))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall remove_AutoRepeatModeChangeRequested(winrt::event_token token) noexcept final { typename D::abi_guard guard(this->shim()); this->shim().AutoRepeatModeChangeRequested(*reinterpret_cast(&token)); return 0; } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Button(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Button()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Type(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Type()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Type(int32_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Type(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_AppMediaId(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().AppMediaId()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_AppMediaId(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().AppMediaId(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Thumbnail(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Thumbnail()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Thumbnail(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Thumbnail(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_MusicProperties(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().MusicProperties()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_VideoProperties(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().VideoProperties()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_ImageProperties(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().ImageProperties()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CopyFromFileAsync(int32_t type, void* source, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from>(this->shim().CopyFromFileAsync(*reinterpret_cast(&type), *reinterpret_cast(&source))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ClearAll() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ClearAll(); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall Update() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Update(); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Property(int32_t* value) noexcept final try { typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Property()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall GetForCurrentView(void** mediaControl) noexcept final try { clear_abi(mediaControl); typename D::abi_guard guard(this->shim()); *mediaControl = detach_from(this->shim().GetForCurrentView()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_StartTime(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().StartTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_StartTime(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().StartTime(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_EndTime(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().EndTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_EndTime(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().EndTime(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_MinSeekTime(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().MinSeekTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_MinSeekTime(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().MinSeekTime(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_MaxSeekTime(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().MaxSeekTime()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_MaxSeekTime(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().MaxSeekTime(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Position(int64_t* value) noexcept final try { zero_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Position()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Position(int64_t value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Position(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Title(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Title()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Title(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Title(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Subtitle(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Subtitle()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall put_Subtitle(void* value) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().Subtitle(*reinterpret_cast(&value)); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Genres(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from>(this->shim().Genres()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_VideoStabilization(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().VideoStabilization()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_SoftwareBitmap(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().SoftwareBitmap()); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CopyToAsync(void* frame, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CopyToAsync(*reinterpret_cast(&frame))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall get_Direct3DSurface(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Direct3DSurface()); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CopyToWithBoundsAsync(void* frame, void* sourceBounds, void* destinationBounds, void** operation) noexcept final try { clear_abi(operation); typename D::abi_guard guard(this->shim()); *operation = detach_from(this->shim().CopyToAsync(*reinterpret_cast(&frame), *reinterpret_cast const*>(&sourceBounds), *reinterpret_cast const*>(&destinationBounds))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall Create(int32_t format, int32_t width, int32_t height, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Create(*reinterpret_cast(&format), width, height)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateWithAlpha(int32_t format, int32_t width, int32_t height, int32_t alpha, void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().CreateWithAlpha(*reinterpret_cast(&format), width, height, *reinterpret_cast(&alpha))); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall CreateAsDirect3D11SurfaceBacked(int32_t format, int32_t width, int32_t height, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().CreateAsDirect3D11SurfaceBacked(*reinterpret_cast(&format), width, height)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateAsDirect3D11SurfaceBackedWithDevice(int32_t format, int32_t width, int32_t height, void* device, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().CreateAsDirect3D11SurfaceBacked(*reinterpret_cast(&format), width, height, *reinterpret_cast(&device))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateWithSoftwareBitmap(void* bitmap, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().CreateWithSoftwareBitmap(*reinterpret_cast(&bitmap))); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall CreateWithDirect3D11Surface(void* surface, void** result) noexcept final try { clear_abi(result); typename D::abi_guard guard(this->shim()); *result = detach_from(this->shim().CreateWithDirect3D11Surface(*reinterpret_cast(&surface))); return 0; } catch (...) { return to_hresult(); } }; #endif } WINRT_EXPORT namespace winrt::Windows::Media { inline AudioFrame::AudioFrame(uint32_t capacity) : AudioFrame(impl::call_factory([&](IAudioFrameFactory const& f) { return f.Create(capacity); })) { } inline auto MediaControl::SoundLevelChanged(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.SoundLevelChanged(handler); }); } inline auto MediaControl::SoundLevelChanged(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::SoundLevelChanged_revoker{ f, f.SoundLevelChanged(handler) }; } inline auto MediaControl::SoundLevelChanged(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.SoundLevelChanged(cookie); }); } inline auto MediaControl::PlayPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.PlayPressed(handler); }); } inline auto MediaControl::PlayPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::PlayPressed_revoker{ f, f.PlayPressed(handler) }; } inline auto MediaControl::PlayPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.PlayPressed(cookie); }); } inline auto MediaControl::PausePressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.PausePressed(handler); }); } inline auto MediaControl::PausePressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::PausePressed_revoker{ f, f.PausePressed(handler) }; } inline auto MediaControl::PausePressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.PausePressed(cookie); }); } inline auto MediaControl::StopPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.StopPressed(handler); }); } inline auto MediaControl::StopPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::StopPressed_revoker{ f, f.StopPressed(handler) }; } inline auto MediaControl::StopPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.StopPressed(cookie); }); } inline auto MediaControl::PlayPauseTogglePressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.PlayPauseTogglePressed(handler); }); } inline auto MediaControl::PlayPauseTogglePressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::PlayPauseTogglePressed_revoker{ f, f.PlayPauseTogglePressed(handler) }; } inline auto MediaControl::PlayPauseTogglePressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.PlayPauseTogglePressed(cookie); }); } inline auto MediaControl::RecordPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.RecordPressed(handler); }); } inline auto MediaControl::RecordPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::RecordPressed_revoker{ f, f.RecordPressed(handler) }; } inline auto MediaControl::RecordPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.RecordPressed(cookie); }); } inline auto MediaControl::NextTrackPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.NextTrackPressed(handler); }); } inline auto MediaControl::NextTrackPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::NextTrackPressed_revoker{ f, f.NextTrackPressed(handler) }; } inline auto MediaControl::NextTrackPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.NextTrackPressed(cookie); }); } inline auto MediaControl::PreviousTrackPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.PreviousTrackPressed(handler); }); } inline auto MediaControl::PreviousTrackPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::PreviousTrackPressed_revoker{ f, f.PreviousTrackPressed(handler) }; } inline auto MediaControl::PreviousTrackPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.PreviousTrackPressed(cookie); }); } inline auto MediaControl::FastForwardPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.FastForwardPressed(handler); }); } inline auto MediaControl::FastForwardPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::FastForwardPressed_revoker{ f, f.FastForwardPressed(handler) }; } inline auto MediaControl::FastForwardPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.FastForwardPressed(cookie); }); } inline auto MediaControl::RewindPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.RewindPressed(handler); }); } inline auto MediaControl::RewindPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::RewindPressed_revoker{ f, f.RewindPressed(handler) }; } inline auto MediaControl::RewindPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.RewindPressed(cookie); }); } inline auto MediaControl::ChannelUpPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.ChannelUpPressed(handler); }); } inline auto MediaControl::ChannelUpPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::ChannelUpPressed_revoker{ f, f.ChannelUpPressed(handler) }; } inline auto MediaControl::ChannelUpPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.ChannelUpPressed(cookie); }); } inline auto MediaControl::ChannelDownPressed(winrt::Windows::Foundation::EventHandler const& handler) { return impl::call_factory([&](IMediaControl const& f) { return f.ChannelDownPressed(handler); }); } inline auto MediaControl::ChannelDownPressed(auto_revoke_t, winrt::Windows::Foundation::EventHandler const& handler) { auto f = get_activation_factory(); return MediaControl::ChannelDownPressed_revoker{ f, f.ChannelDownPressed(handler) }; } inline auto MediaControl::ChannelDownPressed(winrt::event_token const& cookie) { impl::call_factory([&](IMediaControl const& f) { return f.ChannelDownPressed(cookie); }); } inline auto MediaControl::SoundLevel() { return impl::call_factory_cast([](IMediaControl const& f) { return f.SoundLevel(); }); } inline auto MediaControl::TrackName(param::hstring const& value) { impl::call_factory([&](IMediaControl const& f) { return f.TrackName(value); }); } inline auto MediaControl::TrackName() { return impl::call_factory_cast([](IMediaControl const& f) { return f.TrackName(); }); } inline auto MediaControl::ArtistName(param::hstring const& value) { impl::call_factory([&](IMediaControl const& f) { return f.ArtistName(value); }); } inline auto MediaControl::ArtistName() { return impl::call_factory_cast([](IMediaControl const& f) { return f.ArtistName(); }); } inline auto MediaControl::IsPlaying(bool value) { impl::call_factory([&](IMediaControl const& f) { return f.IsPlaying(value); }); } inline auto MediaControl::IsPlaying() { return impl::call_factory_cast([](IMediaControl const& f) { return f.IsPlaying(); }); } inline auto MediaControl::AlbumArt(winrt::Windows::Foundation::Uri const& value) { impl::call_factory([&](IMediaControl const& f) { return f.AlbumArt(value); }); } inline auto MediaControl::AlbumArt() { return impl::call_factory_cast([](IMediaControl const& f) { return f.AlbumArt(); }); } inline MediaExtensionManager::MediaExtensionManager() : MediaExtensionManager(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline auto MediaMarkerTypes::Bookmark() { return impl::call_factory_cast([](IMediaMarkerTypesStatics const& f) { return f.Bookmark(); }); } inline MediaTimelineController::MediaTimelineController() : MediaTimelineController(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline auto SystemMediaTransportControls::GetForCurrentView() { return impl::call_factory_cast([](ISystemMediaTransportControlsStatics const& f) { return f.GetForCurrentView(); }); } inline SystemMediaTransportControlsTimelineProperties::SystemMediaTransportControlsTimelineProperties() : SystemMediaTransportControlsTimelineProperties(impl::call_factory_cast([](winrt::Windows::Foundation::IActivationFactory const& f) { return f.template ActivateInstance(); })) { } inline auto VideoEffects::VideoStabilization() { return impl::call_factory_cast([](IVideoEffectsStatics const& f) { return f.VideoStabilization(); }); } inline VideoFrame::VideoFrame(winrt::Windows::Graphics::Imaging::BitmapPixelFormat const& format, int32_t width, int32_t height) : VideoFrame(impl::call_factory([&](IVideoFrameFactory const& f) { return f.Create(format, width, height); })) { } inline VideoFrame::VideoFrame(winrt::Windows::Graphics::Imaging::BitmapPixelFormat const& format, int32_t width, int32_t height, winrt::Windows::Graphics::Imaging::BitmapAlphaMode const& alpha) : VideoFrame(impl::call_factory([&](IVideoFrameFactory const& f) { return f.CreateWithAlpha(format, width, height, alpha); })) { } inline auto VideoFrame::CreateAsDirect3D11SurfaceBacked(winrt::Windows::Graphics::DirectX::DirectXPixelFormat const& format, int32_t width, int32_t height) { return impl::call_factory([&](IVideoFrameStatics const& f) { return f.CreateAsDirect3D11SurfaceBacked(format, width, height); }); } inline auto VideoFrame::CreateAsDirect3D11SurfaceBacked(winrt::Windows::Graphics::DirectX::DirectXPixelFormat const& format, int32_t width, int32_t height, winrt::Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice const& device) { return impl::call_factory([&](IVideoFrameStatics const& f) { return f.CreateAsDirect3D11SurfaceBacked(format, width, height, device); }); } inline auto VideoFrame::CreateWithSoftwareBitmap(winrt::Windows::Graphics::Imaging::SoftwareBitmap const& bitmap) { return impl::call_factory([&](IVideoFrameStatics const& f) { return f.CreateWithSoftwareBitmap(bitmap); }); } inline auto VideoFrame::CreateWithDirect3D11Surface(winrt::Windows::Graphics::DirectX::Direct3D11::IDirect3DSurface const& surface) { return impl::call_factory([&](IVideoFrameStatics const& f) { return f.CreateWithDirect3D11Surface(surface); }); } } namespace std { #ifndef WINRT_LEAN_AND_MEAN template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; #endif #ifdef __cpp_lib_format #endif } #endif