asrc_abuffer.h 3.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /*
  2. * This file is part of FFmpeg.
  3. *
  4. * FFmpeg is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU Lesser General Public
  6. * License as published by the Free Software Foundation; either
  7. * version 2.1 of the License, or (at your option) any later version.
  8. *
  9. * FFmpeg is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  12. * Lesser General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU Lesser General Public
  15. * License along with FFmpeg; if not, write to the Free Software
  16. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  17. */
  18. #ifndef AVFILTER_ASRC_ABUFFER_H
  19. #define AVFILTER_ASRC_ABUFFER_H
  20. #include "avfilter.h"
  21. /**
  22. * @file
  23. * memory buffer source for audio
  24. *
  25. * @deprecated use buffersrc.h instead.
  26. */
  27. /**
  28. * Queue an audio buffer to the audio buffer source.
  29. *
  30. * @param abuffersrc audio source buffer context
  31. * @param data pointers to the samples planes
  32. * @param linesize linesizes of each audio buffer plane
  33. * @param nb_samples number of samples per channel
  34. * @param sample_fmt sample format of the audio data
  35. * @param ch_layout channel layout of the audio data
  36. * @param planar flag to indicate if audio data is planar or packed
  37. * @param pts presentation timestamp of the audio buffer
  38. * @param flags unused
  39. *
  40. * @deprecated use av_buffersrc_add_ref() instead.
  41. */
  42. attribute_deprecated
  43. int av_asrc_buffer_add_samples(AVFilterContext *abuffersrc,
  44. uint8_t *data[8], int linesize[8],
  45. int nb_samples, int sample_rate,
  46. int sample_fmt, int64_t ch_layout, int planar,
  47. int64_t pts, int av_unused flags);
  48. /**
  49. * Queue an audio buffer to the audio buffer source.
  50. *
  51. * This is similar to av_asrc_buffer_add_samples(), but the samples
  52. * are stored in a buffer with known size.
  53. *
  54. * @param abuffersrc audio source buffer context
  55. * @param buf pointer to the samples data, packed is assumed
  56. * @param size the size in bytes of the buffer, it must contain an
  57. * integer number of samples
  58. * @param sample_fmt sample format of the audio data
  59. * @param ch_layout channel layout of the audio data
  60. * @param pts presentation timestamp of the audio buffer
  61. * @param flags unused
  62. *
  63. * @deprecated use av_buffersrc_add_ref() instead.
  64. */
  65. attribute_deprecated
  66. int av_asrc_buffer_add_buffer(AVFilterContext *abuffersrc,
  67. uint8_t *buf, int buf_size,
  68. int sample_rate,
  69. int sample_fmt, int64_t ch_layout, int planar,
  70. int64_t pts, int av_unused flags);
  71. /**
  72. * Queue an audio buffer to the audio buffer source.
  73. *
  74. * @param abuffersrc audio source buffer context
  75. * @param samplesref buffer ref to queue
  76. * @param flags unused
  77. *
  78. * @deprecated use av_buffersrc_add_ref() instead.
  79. */
  80. attribute_deprecated
  81. int av_asrc_buffer_add_audio_buffer_ref(AVFilterContext *abuffersrc,
  82. AVFilterBufferRef *samplesref,
  83. int av_unused flags);
  84. #endif /* AVFILTER_ASRC_ABUFFER_H */