You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

103 lines
3.4KB

  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_AVCODEC_H
  19. #define AVFILTER_AVCODEC_H
  20. /**
  21. * @file
  22. * libavcodec/libavfilter gluing utilities
  23. *
  24. * This should be included in an application ONLY if the installed
  25. * libavfilter has been compiled with libavcodec support, otherwise
  26. * symbols defined below will not be available.
  27. */
  28. #include "avfilter.h"
  29. /**
  30. * Create and return a picref reference from the data and properties
  31. * contained in frame.
  32. *
  33. * @param perms permissions to assign to the new buffer reference
  34. */
  35. AVFilterBufferRef *avfilter_get_video_buffer_ref_from_frame(const AVFrame *frame, int perms);
  36. /**
  37. * Create and return a picref reference from the data and properties
  38. * contained in frame.
  39. *
  40. * @param perms permissions to assign to the new buffer reference
  41. */
  42. AVFilterBufferRef *avfilter_get_audio_buffer_ref_from_frame(const AVFrame *frame,
  43. int perms);
  44. /**
  45. * Create and return a buffer reference from the data and properties
  46. * contained in frame.
  47. *
  48. * @param perms permissions to assign to the new buffer reference
  49. */
  50. AVFilterBufferRef *avfilter_get_buffer_ref_from_frame(enum AVMediaType type,
  51. const AVFrame *frame,
  52. int perms);
  53. #if FF_API_FILL_FRAME
  54. /**
  55. * Fill an AVFrame with the information stored in samplesref.
  56. *
  57. * @param frame an already allocated AVFrame
  58. * @param samplesref an audio buffer reference
  59. * @return 0 in case of success, a negative AVERROR code in case of
  60. * failure
  61. * @deprecated Use avfilter_copy_buf_props() instead.
  62. */
  63. attribute_deprecated
  64. int avfilter_fill_frame_from_audio_buffer_ref(AVFrame *frame,
  65. const AVFilterBufferRef *samplesref);
  66. /**
  67. * Fill an AVFrame with the information stored in picref.
  68. *
  69. * @param frame an already allocated AVFrame
  70. * @param picref a video buffer reference
  71. * @return 0 in case of success, a negative AVERROR code in case of
  72. * failure
  73. * @deprecated Use avfilter_copy_buf_props() instead.
  74. */
  75. attribute_deprecated
  76. int avfilter_fill_frame_from_video_buffer_ref(AVFrame *frame,
  77. const AVFilterBufferRef *picref);
  78. /**
  79. * Fill an AVFrame with information stored in ref.
  80. *
  81. * @param frame an already allocated AVFrame
  82. * @param ref a video or audio buffer reference
  83. * @return 0 in case of success, a negative AVERROR code in case of
  84. * failure
  85. * @deprecated Use avfilter_copy_buf_props() instead.
  86. */
  87. attribute_deprecated
  88. int avfilter_fill_frame_from_buffer_ref(AVFrame *frame,
  89. const AVFilterBufferRef *ref);
  90. #endif
  91. #endif /* AVFILTER_AVCODEC_H */