media/libcubeb/src/cubeb-internal.h

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 /*
     2  * Copyright © 2013 Mozilla Foundation
     3  *
     4  * This program is made available under an ISC-style license.  See the
     5  * accompanying file LICENSE for details.
     6  */
     7 #if !defined(CUBEB_INTERNAL_0eb56756_4e20_4404_a76d_42bf88cd15a5)
     8 #define CUBEB_INTERNAL_0eb56756_4e20_4404_a76d_42bf88cd15a5
    10 #include "cubeb/cubeb.h"
    12 struct cubeb_ops {
    13   int (* init)(cubeb ** context, char const * context_name);
    14   char const * (* get_backend_id)(cubeb * context);
    15   int (* get_max_channel_count)(cubeb * context, uint32_t * max_channels);
    16   int (* get_min_latency)(cubeb * context,
    17                           cubeb_stream_params params,
    18                           uint32_t * latency_ms);
    19   int (* get_preferred_sample_rate)(cubeb * context, uint32_t * rate);
    20   void (* destroy)(cubeb * context);
    21   int (* stream_init)(cubeb * context, cubeb_stream ** stream, char const * stream_name,
    22                       cubeb_stream_params stream_params, unsigned int latency,
    23                       cubeb_data_callback data_callback,
    24                       cubeb_state_callback state_callback,
    25                       void * user_ptr);
    26   void (* stream_destroy)(cubeb_stream * stream);
    27   int (* stream_start)(cubeb_stream * stream);
    28   int (* stream_stop)(cubeb_stream * stream);
    29   int (* stream_get_position)(cubeb_stream * stream, uint64_t * position);
    30   int (* stream_get_latency)(cubeb_stream * stream, uint32_t * latency);
    31 };
    33 #endif /* CUBEB_INTERNAL_0eb56756_4e20_4404_a76d_42bf88cd15a5 */

mercurial