rename 'length' parameters in the API to 'bytes', to make their unit clear

git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1999 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
Lennart Poettering 2007-10-30 14:17:41 +00:00
parent b84489d8b3
commit b03b5741ea
2 changed files with 7 additions and 7 deletions

View file

@ -130,13 +130,13 @@ pa_simple* pa_simple_new(
void pa_simple_free(pa_simple *s); void pa_simple_free(pa_simple *s);
/** Write some data to the server */ /** Write some data to the server */
int pa_simple_write(pa_simple *s, const void*data, size_t length, int *error); int pa_simple_write(pa_simple *s, const void*data, size_t bytes, int *error);
/** Wait until all data already written is played by the daemon */ /** Wait until all data already written is played by the daemon */
int pa_simple_drain(pa_simple *s, int *error); int pa_simple_drain(pa_simple *s, int *error);
/** Read some data from the server */ /** Read some data from the server */
int pa_simple_read(pa_simple *s, void*data, size_t length, int *error); int pa_simple_read(pa_simple *s, void*data, size_t bytes, int *error);
/** Return the playback latency. \since 0.5 */ /** Return the playback latency. \since 0.5 */
pa_usec_t pa_simple_get_latency(pa_simple *s, int *error); pa_usec_t pa_simple_get_latency(pa_simple *s, int *error);

View file

@ -271,7 +271,7 @@ typedef struct pa_stream pa_stream;
typedef void (*pa_stream_success_cb_t) (pa_stream*s, int success, void *userdata); typedef void (*pa_stream_success_cb_t) (pa_stream*s, int success, void *userdata);
/** A generic request callback */ /** A generic request callback */
typedef void (*pa_stream_request_cb_t)(pa_stream *p, size_t length, void *userdata); typedef void (*pa_stream_request_cb_t)(pa_stream *p, size_t bytes, void *userdata);
/** A generic notification callback */ /** A generic notification callback */
typedef void (*pa_stream_notify_cb_t)(pa_stream *p, void *userdata); typedef void (*pa_stream_notify_cb_t)(pa_stream *p, void *userdata);
@ -327,7 +327,7 @@ int pa_stream_disconnect(pa_stream *s);
int pa_stream_write( int pa_stream_write(
pa_stream *p /**< The stream to use */, pa_stream *p /**< The stream to use */,
const void *data /**< The data to write */, const void *data /**< The data to write */,
size_t length /**< The length of the data to write */, size_t bytes /**< The length of the data to write in bytes*/,
pa_free_cb_t free_cb /**< A cleanup routine for the data or NULL to request an internal copy */, pa_free_cb_t free_cb /**< A cleanup routine for the data or NULL to request an internal copy */,
int64_t offset, /**< Offset for seeking, must be 0 for upload streams */ int64_t offset, /**< Offset for seeking, must be 0 for upload streams */
pa_seek_mode_t seek /**< Seek mode, must be PA_SEEK_RELATIVE for upload streams */); pa_seek_mode_t seek /**< Seek mode, must be PA_SEEK_RELATIVE for upload streams */);
@ -340,16 +340,16 @@ int pa_stream_write(
int pa_stream_peek( int pa_stream_peek(
pa_stream *p /**< The stream to use */, pa_stream *p /**< The stream to use */,
const void **data /**< Pointer to pointer that will point to data */, const void **data /**< Pointer to pointer that will point to data */,
size_t *length /**< The length of the data read */); size_t *bytes /**< The length of the data read in bytes */);
/** Remove the current fragment on record streams. It is invalid to do this without first /** Remove the current fragment on record streams. It is invalid to do this without first
* calling pa_stream_peek(). \since 0.8 */ * calling pa_stream_peek(). \since 0.8 */
int pa_stream_drop(pa_stream *p); int pa_stream_drop(pa_stream *p);
/** Return the nember of bytes that may be written using pa_stream_write() */ /** Return the nember of bytes that may be written using pa_stream_write(), in bytes */
size_t pa_stream_writable_size(pa_stream *p); size_t pa_stream_writable_size(pa_stream *p);
/** Return the number of bytes that may be read using pa_stream_read() \since 0.8 */ /** Return the number of bytes that may be read using pa_stream_read(), in bytes \since 0.8 */
size_t pa_stream_readable_size(pa_stream *p); size_t pa_stream_readable_size(pa_stream *p);
/** Drain a playback stream. Use this for notification when the buffer is empty */ /** Drain a playback stream. Use this for notification when the buffer is empty */