Home > General > Audio effects - copy one channel to both channels

Audio effects - copy one channel to both channels

Sample code to copy left channel (0) to both (0, 1).

Delphi / ActiveX

MediaPlayer1.Audio_Effects_Clear(-1);
MediaPlayer1.Audio_Effects_Enabled = true;
MediaPlayer1.Audio_Effects_Add(-1, VFAudioEffectType.ChannelOrder, true);
MediaPlayer1.Audio_Effects_SetCurrentChannel(-1, 0, 0);
MediaPlayer1.Audio_Effects_ChannelOrder(-1, 0, 0);
MediaPlayer1.Audio_Effects_SetCurrentChannel(-1, 0, 1);
MediaPlayer1.Audio_Effects_ChannelOrder(-1, 0, 0);

.Net

MediaPlayer1.Audio_Effects_Enabled = true;
MediaPlayer1.Audio_Effects_Clear(-1);
MediaPlayer1.Audio_Effects_Add(-1, VFAudioEffectType.ChannelOrder, true, -1, -1);
byte[,] channels = { { 0, 0 }, { 1, 0 } };
MediaPlayer1.Audio_Effects_ChannelOrderEx(-1, 0, channels);