|
Media Monitoring
When a call is in the connected state, information can be transported over the call. A call's media mode
provides an indication of the type of information (for example, its data type, or
higher-level protocol) of this media stream. TAPI allows applications to be
provided with a notification about changes in a call's media mode. The notification
provides an indication of the call's new media mode. The service provider
decides how it wants to make this determination. For example, the service provider
could use signal processing of the media stream to determine the media mode, or
it could rely on distinctive ringing patterns assigned to different media
streams, or on information elements passed in an out-of-band signaling protocol.
Independent of how the media mode determination is achieved, the application is
simply informed about media mode changes on an existing call.
The media modes defined by TAPI include:
- Unknown. The media mode of the call is not currently known
the call is unclassified.
- Interactive voice. Voice energy was detected on the call, and the call is handled as an
interactive voice call with a person at the application's end.
- Automated voice. Voice energy was detected on the call, and the call is handled as a voice
call but with no person at the application's end, such as with an answering
machine application.
- Data modem. A modem session on the call. Current modem protocols require the called
station to initiate the handshake. For an inbound data modem call, the application
can typically make no positive detection. How the service provider makes this
determination is its choice. For example, a period of silence just after
answering an inbound call can be used as a heuristic to decide that this might be a
data modem call.
- G3 fax. A group 3 fax session on the call.
- G4 fax. A group 4 fax session on the call.
- TDD. The call's media stream uses the Telephony Devices for the Deaf protocol.
- Digital data. A digital data stream of unspecified format.
- Teletex, Videotex, Telex, Mixed. These correspond to the telematic services of the same names.
- ADSI. An Analog Display Services Interface session on the call. ADSI enhances
voice calls with alphanumeric information downloaded to the phone and the use of
soft buttons on the phone.
An application can enable or disable media monitoring on a specified call with lineMonitorMedia. The application specifies which media modes it is interested in monitoring,
and when media monitoring is enabled, the detection of a media mode change
causes the application to be notified with the LINE_MONITORMEDIA message. This message provides the call handle on which the media mode change
was detected as well as the new media mode.
There is a distinction between the media mode of a call as reported by lineGetCallInfo and the media mode event reports by LINE_MONITORMEDIA messages. A call's
media mode is determined exclusively by owner applications of the call and is not
automatically changed by media monitoring events. The one exception is the
initial media mode determination that can be performed by the TAPI dynamic-link
library to select the first owner of a call. One could argue that in this case, the
library is the owner of the call.
Default media mode monitoring is performed for the media modes for which the
line device has been opened. This allows an inbound call's media mode to be
determined before the call is handed to an application based on what the
application demands. The scope of the media monitoring of a call is bound by the lifetime
of the call. Media monitoring on a call ends as soon the call disconnects or goes idle.
An application can obtain device IDs for various device classes associated
with an opened line by calling lineGetID. This function takes a line handle, address, or call handle and a device
class description. It returns the device ID for the device of the given device
class that is associated with the open line device, address, or call. If the device
class is "tapi/line," then the device ID of the line device is returned. If
the device class is "mci/wave," then the device ID of an mci waveaudio device is
returned (if supported), which allows activities such as the recording or
playback of audio over the call on the line.
The application can use the returned device ID with the corresponding media
API to query the device's capabilities and subsequently open the media device.
For example, if your application needs to use the line as a waveform device, it
must first call waveInGetDevCaps and/or waveOutGetDevCaps to determine the waveform capabilities of the device. The typical waveform
data format supported by telephony in North America is 8-bit m-law at 8000
samples per second, although the wave device driver can convert this sample rate and
companding to other more common multimedia audio formats.
To subsequently open a line device for audio playback using the waveform API,
an application calls waveOutOpen. The implementation of waveOutOpen is device specific, and there are a variety of options for implementing this
function.
| Last news from Greatis Software |
 |
|
Nostalgia .Net |
|
.Net is powerful, but not all-powerful, so sometimes we need to use Win32 API for our .Net applications. It's simple enough with Platform Invoke if you have Win32 skill, but we do not always have time to dig the ancient documentation, declare the special types that are compatible with Win32, find the values of the Win32's constants and so on. Nostalgia .Net offers several simple-to-use classes, and components that will allow you to forget about the headache of Win32 and just use the power of Win32 in your application the same way as you use the native. Net classes. More » |
| Recommended software for developers |
 |
|
Ultimate Pack |
|
Component pack for Delphi and C++ Builder that contains runtime form designer, runtime object inspector, print suite and much more for the very special price. More » |
 |
|
Form Designer .Net |
|
Unique runtime form design solution that allows to edit any form in .Net WinForms application at runtime with full source codes for only 300 euro! More » |
 |
|
Print Suite .Net |
|
Print Suite .Net is a set of components for easy printing texts, images and grids from your WinForms applications. Full C# source codes are available More » |
 |
|
Gradient Controls .Net |
|
Gradient Controls .Net offers controls with gradient background feature. Labels, panels and so on... Full C# source codes are available More » |
 |
|
Greatis iGrid |
|
iGrid plots drawing grid right over your desktop, so you can use it everywhere, with any drawing application without any special plugins for different graphic editors. More » |
All the contacts and projectsDmitry Vasiliev (just.dmitry)
Related LinksSoftware for Visual Studio .NET developers Software for Delphi and C++ Builder developers Software for Visual Basic 6 developers Delphi Tips&Tricks MegaDetailed.NET More Online Helps Win32 Programmer's Reference Win32 Multimedia Programmer's Reference OLE Programmer's Reference Microsoft Windows Pen API Programmer's Reference Microsoft Windows Sockets 2 Reference Microsoft Windows Telephony API (TAPI) Programmer's Reference Unix Manual Pages
|