World of Might and Magic  0.2.0
Open reimplementation of Might and Magic 6 7 8 game engine
Buffer sink API
+ Граф связей класса Buffer sink API:

Группы

 Buffer sink accessors
 Get the properties of the stream.
 

Файлы

файл  buffersink.h
 

Классы

struct  AVBufferSinkParams
 
struct  AVABufferSinkParams
 

Определения типов

typedef struct AVBufferSinkParams AVBufferSinkParams
 
typedef struct AVABufferSinkParams AVABufferSinkParams
 

Функции

int av_buffersink_get_frame_flags (AVFilterContext *ctx, AVFrame *frame, int flags)
 
AVBufferSinkParamsav_buffersink_params_alloc (void)
 
AVABufferSinkParamsav_abuffersink_params_alloc (void)
 
void av_buffersink_set_frame_size (AVFilterContext *ctx, unsigned frame_size)
 
int av_buffersink_get_frame (AVFilterContext *ctx, AVFrame *frame)
 
int av_buffersink_get_samples (AVFilterContext *ctx, AVFrame *frame, int nb_samples)
 

Подробное описание

Типы

◆ AVBufferSinkParams

◆ AVABufferSinkParams

Функции

◆ av_buffersink_get_frame_flags()

int av_buffersink_get_frame_flags ( AVFilterContext ctx,
AVFrame frame,
int  flags 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavfilter/buffersink.h>

Get a frame with filtered data from sink and put it in frame.

Аргументы
ctxpointer to a buffersink or abuffersink filter context.
framepointer to an allocated frame that will be filled with data. The data must be freed using av_frame_unref() / av_frame_free()
flagsa combination of AV_BUFFERSINK_FLAG_* flags
Возвращает
>= 0 in for success, a negative AVERROR code for failure.

◆ av_buffersink_params_alloc()

◆ av_abuffersink_params_alloc()

◆ av_buffersink_set_frame_size()

void av_buffersink_set_frame_size ( AVFilterContext ctx,
unsigned  frame_size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavfilter/buffersink.h>

Set the frame size for an audio buffer sink.

All calls to av_buffersink_get_buffer_ref will return a buffer with exactly the specified number of samples, or AVERROR(EAGAIN) if there is not enough. The last buffer at EOF will be padded with 0.

◆ av_buffersink_get_frame()

int av_buffersink_get_frame ( AVFilterContext ctx,
AVFrame frame 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavfilter/buffersink.h>

Get a frame with filtered data from sink and put it in frame.

Аргументы
ctxpointer to a context of a buffersink or abuffersink AVFilter.
framepointer to an allocated frame that will be filled with data. The data must be freed using av_frame_unref() / av_frame_free()
Возвращает
  • >= 0 if a frame was successfully returned.
  • AVERROR(EAGAIN) if no frames are available at this point; more input frames must be added to the filtergraph to get more output.
  • AVERROR_EOF if there will be no more output frames on this sink.
  • A different negative AVERROR code in other failure cases.

◆ av_buffersink_get_samples()

int av_buffersink_get_samples ( AVFilterContext ctx,
AVFrame frame,
int  nb_samples 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavfilter/buffersink.h>

Same as av_buffersink_get_frame(), but with the ability to specify the number of samples read. This function is less efficient than av_buffersink_get_frame(), because it copies the data around.

Аргументы
ctxpointer to a context of the abuffersink AVFilter.
framepointer to an allocated frame that will be filled with data. The data must be freed using av_frame_unref() / av_frame_free() frame will contain exactly nb_samples audio samples, except at the end of stream, when it can contain less than nb_samples.
Возвращает
The return codes have the same meaning as for av_buffersink_get_frame().
Предупреждения
do not mix this function with av_buffersink_get_frame(). Use only one or the other with a single sink, not both.