// Copyright (c) 2012-2017 VideoStitch SAS // Copyright (c) 2018 stitchEm #pragma once #include "libvideostitch/inputFactory.hpp" #include "libvideostitch/plugin.hpp" #include namespace VideoStitch { namespace Plugin { class PortAudioDiscovery : public VSDiscoveryPlugin { public: static PortAudioDiscovery* create(); virtual ~PortAudioDiscovery() {} std::string name() const override; std::string readableName() const override; std::vector inputDevices() override; std::vector outputDevices() override; std::vector cards() const override; void registerAutoDetectionCallback(AutoDetection&) override; std::vector supportedDisplayModes(const Plugin::DiscoveryDevice&) override; DisplayMode currentDisplayMode(const Plugin::DiscoveryDevice&) override; std::vector supportedPixelFormat(const Plugin::DiscoveryDevice&) override; std::vector supportedNbChannels(const Plugin::DiscoveryDevice& device) override; std::vector supportedSamplingRates(const Plugin::DiscoveryDevice& device) override; std::vector supportedSampleFormats(const Plugin::DiscoveryDevice& device) override; private: PortAudioDiscovery(); void filterWindowsDevices(); void removeDevice(size_t index); std::vector _devNames; std::map _devMaxInputsChannel; std::map _devMaxOutputsChannel; std::map> _devChannelCounts; std::map> _devSampleRates; std::map> _devSampleDepths; }; } // namespace Plugin } // namespace VideoStitch