You can use this event to compress or encrypt audio data.
property OnEncodeAudio: TRVAudioEvent;
AStream contains raw audio data. Only initial ADataSize bytes in this stream are used. Parameters of these data are specified in ASamplesPerSec, ABitsPerSample and AChannels.
ADuration is an audio length, in milliseconds.
You can encode audio in another format and write it back to AStream. Update ADataSize as well.
You can also modify values of ASamplesPerSec, ABitsPerSample, AChannels that will be sent to the network. If your modifications changed the sound duration, modify ADuration as well.