Christopher N. Hesse | 757ac41 | 2017-01-28 14:42:48 +0100 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2013 The Android Open Source Project |
| 3 | * Copyright (C) 2017 Christopher N. Hesse <raymanfx@gmail.com> |
| 4 | * |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | * |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | * |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
| 17 | |
| 18 | #ifndef COMPRESS_OFFLOAD_H |
| 19 | #define COMPRESS_OFFLOAD_H |
| 20 | |
| 21 | void stop_compressed_output_l(struct stream_out *out); |
| 22 | |
| 23 | int create_offload_callback_thread(struct stream_out *out); |
| 24 | |
| 25 | int destroy_offload_callback_thread(struct stream_out *out); |
| 26 | |
| 27 | int parse_compress_metadata(struct stream_out *out, struct str_parms *parms); |
| 28 | |
| 29 | int stop_output_offload_stream(struct stream_out *out, bool *disable); |
| 30 | |
| 31 | int out_set_offload_parameters(struct audio_device *adev, struct audio_usecase *uc_info); |
| 32 | |
| 33 | ssize_t out_write_offload(struct audio_stream_out *stream, const void *buffer, |
| 34 | size_t bytes); |
| 35 | |
| 36 | int out_get_render_offload_position(struct stream_out *out, |
| 37 | uint32_t *dsp_frames); |
| 38 | |
| 39 | int out_get_presentation_offload_position(struct stream_out *out, uint64_t *frames, |
| 40 | struct timespec *timestamp); |
| 41 | |
| 42 | int out_pause_offload(struct stream_out *out); |
| 43 | |
| 44 | int out_resume_offload(struct stream_out *out); |
| 45 | |
| 46 | int out_drain_offload(struct stream_out *out, audio_drain_type_t type); |
| 47 | |
| 48 | int out_flush_offload(struct stream_out *out); |
| 49 | |
| 50 | int out_set_offload_volume(float left, float right); |
| 51 | |
| 52 | #endif // COMPRESS_OFFLOAD_H |