Initial
This commit is contained in:
95
sample/InCaps.hpp
Normal file
95
sample/InCaps.hpp
Normal file
@@ -0,0 +1,95 @@
|
||||
#ifndef _SAMPLE_WAVEINCAPS_HPP_
|
||||
#define _SAMPLE_WAVEINCAPS_HPP_
|
||||
#ifndef _COMMON_WINDOWS_HPP_
|
||||
#include <common/windows.hpp>
|
||||
#endif
|
||||
#ifndef _COMMON_STRING_HPP_
|
||||
#include <common/string.hpp>
|
||||
#endif
|
||||
#ifndef _COMMON_MMSYSTEM_HPP_
|
||||
#include <common/mmsystem.hpp>
|
||||
#endif
|
||||
|
||||
class WaveInCaps : private WAVEINCAPS
|
||||
{
|
||||
public:
|
||||
WaveInCaps(const WaveInCaps &someWaveInCaps);
|
||||
WaveInCaps(void);
|
||||
~WaveInCaps();
|
||||
WaveInCaps &operator=(const WaveInCaps &someWaveInCaps);
|
||||
operator WAVEINCAPS &(void);
|
||||
UINT manufacturerID(void)const;
|
||||
UINT productID(void)const;
|
||||
WORD driverVersion(void)const;
|
||||
String productName(void)const;
|
||||
DWORD supportedFormats(void)const;
|
||||
UINT channels(void)const;
|
||||
private:
|
||||
};
|
||||
|
||||
inline
|
||||
WaveInCaps::WaveInCaps(const WaveInCaps &someWaveInCaps)
|
||||
{
|
||||
*this=someWaveInCaps;
|
||||
}
|
||||
|
||||
inline
|
||||
WaveInCaps::WaveInCaps(void)
|
||||
{
|
||||
::memset(this,0,sizeof(*this));
|
||||
}
|
||||
|
||||
inline
|
||||
WaveInCaps::~WaveInCaps()
|
||||
{
|
||||
}
|
||||
|
||||
inline
|
||||
UINT WaveInCaps::manufacturerID(void)const
|
||||
{
|
||||
return WAVEINCAPS::wMid;
|
||||
}
|
||||
|
||||
inline
|
||||
UINT WaveInCaps::productID(void)const
|
||||
{
|
||||
return WAVEINCAPS::wPid;
|
||||
}
|
||||
|
||||
inline
|
||||
WORD WaveInCaps::driverVersion(void)const
|
||||
{
|
||||
return WAVEINCAPS::vDriverVersion;
|
||||
}
|
||||
|
||||
inline
|
||||
String WaveInCaps::productName(void)const
|
||||
{
|
||||
return String(WAVEINCAPS::szPname);
|
||||
}
|
||||
|
||||
inline
|
||||
DWORD WaveInCaps::supportedFormats(void)const
|
||||
{
|
||||
return WAVEINCAPS::dwFormats;
|
||||
}
|
||||
|
||||
inline
|
||||
UINT WaveInCaps::channels(void)const
|
||||
{
|
||||
return WAVEINCAPS::wChannels;
|
||||
}
|
||||
|
||||
inline
|
||||
WaveInCaps::operator WAVEINCAPS &(void)
|
||||
{
|
||||
return *((WAVEINCAPS*)this);
|
||||
}
|
||||
|
||||
inline
|
||||
WaveInCaps &WaveInCaps::operator=(const WaveInCaps &someWaveInCaps)
|
||||
{
|
||||
::memcpy(this,&someWaveInCaps,sizeof(*this));
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
Reference in New Issue
Block a user