终于完成TCnVolumeCtrl
CnPack.org的邮件系统是否出来问题了?怎么发不了呢?
周兄,经过多天的调试终于完成TCnVolumeCtrl。
由于原来的单元无法适应多设备的要求,的已经全部重新编写了。
附件内包含Demo程序。
现在提供以下功能:(由于时间关系,没写使用说明。其实也很简单)
//获取参数
function GetDevCaption(uDev: UINT): string;
{* 获取设备名称}
function GetDevLines(uDev: UINT): DWORD;
{* 获取设备线路总数}
function GetLineCaption(uDev, uLine: UINT): string;
{* 获取线路名称}
function GetLineChannels(uDev, uLine: UINT): DWORD;
{* 获取线路通道总数}
function GetLineHaveBalance(uDev, uLine: UINT): Boolean;
{* 获取线路是否存在左右平行}
function GetLineVolume(uDev, uLine: UINT): TCnVolume;
{* 获取线路音量}
function GetLineBalance(uDev, uLine: UINT): TCnBalance;
{* 获取线路静音状态}
function GetLineMute(uDev, uLine: UINT): Boolean;
{* 获取线路静音状态}
//设置参数
function SetLineVolume(uDev, uLine: UINT; Volume: TCnVolume): Boolean;
{* 获取线路音量}
function SetLineBalance(uDev, uLine: UINT; iBalance: TCnBalance): Boolean;
{* 获取线路左右平行}
function SetLineMute(uDev, uLine: UINT; bMute: Boolean): Boolean;
{* 获取线路通道总数}
//属性
property Devs: UINT read GetDevs;
{* 获取设备总数}
property CurDev: UINT read FDevice write SetDev;
{* 设置/获取当前设备}
property CurDevCaption: string read GetDevCap;
{* 获取当前设备名称}
property Lines: UINT read GetLines;
{* 获取当前设备的线路总数}
property CurLine: UINT read FLine write SetLine;
{* 设置/获取当前线路}
property CurLineCaption: string read GetLineCap;
{* 获取当前线路名称}
property CurLineChannels: DWORD read GetChannels;
{* 获取当前线路通道总数}
property Volume: TCnVolume read GetVolume write SetVolume;
{* 设置/获取当前线路音量}
property Balance: TCnBalance read GetBalance write SetBalance;
{* 设置/获取当前线路左右平行}
property IsMute: Boolean read GetIsMute write SetIsMute;
{* 设置/获取当前线路静音状态}
property OnVolumeChange: TCnMixVolumeEvent read FOnVolumeChange write FOnVolumeChange;
property OnMuteChange: TCnMixMuteEvent read FOnMuteChange write FOnMuteChange;
Attachment:
VolumeCtrl.rar (2005-9-24 10:33, 186.43 K)
Download count 624
|