Intel 05-1832-002 IP Phone User Manual


 
330 Voice API for Windows Operating Systems Library Reference — November 2003
dx_PutStreamData( ) — place data into a circular stream buffer
dx_PutStreamData( )
place data into a circular stream buffer
!
!!
! Description
The dx_PutStreamData( ) function puts data into the specified circular stream buffer. If there is
not enough room in the buffer (an overrun condition), an error of -1 is returned and none of the data
will be placed in the stream buffer. Writing 0 bytes of data to the buffer is not considered an error.
The flag field is used to indicate that this is the last block of data. Set this flag to STREAM_CONT
(0) for all buffers except the last one, which should be set to STREAM_EOD (1). This function can
be called at any time between the opening and closing of the stream buffer.
!
!!
! Cautions
None.
!
!!
! Errors
If there is not enough room in the buffer (an overrun condition), this function returns an error of -1.
Name: int dx_PutStreamData(hBuffer, pNewData, BuffSize, flag)
Inputs: int hBuffer
stream buffer handle
char* pNewData
pointer to user buffer of data to place in the stream buffer
int BuffSize
number of bytes in the user buffer
int flag
flag indicating last block of data
Returns: 0 if successful
-1 if failure
Includes: srllib.h
dxxxlib.h
Category: streaming to board
Mode: synchronous
Platform: DM3
Parameter Description
hBuffer specifies the circular stream buffer handle obtained from
dx_OpenStreamBuffer( )
pNewData a pointer to the user buffer containing data to be placed in the circular
stream buffer
BuffSize specifies the number of bytes in the user buffer
flag a flag indicating whether this is the last block of data in the user buffer.
Valid values are:
STREAM_CONT – for all buffers except the last one
STREAM_EOD – for the last buffer