FreeRDP
dsp_ffmpeg.c File Reference
#include <freerdp/config.h>
#include <freerdp/log.h>
#include <libavcodec/avcodec.h>
#include <libavutil/avutil.h>
#include <libavutil/opt.h>
#include "dsp.h"
#include "dsp_ffmpeg.h"

Macros

#define TAG   FREERDP_TAG("dsp.ffmpeg")
 

Functions

static BOOL ffmpeg_codec_is_filtered (enum AVCodecID id, BOOL encoder)
 
static enum AVCodecID ffmpeg_get_avcodec (const AUDIO_FORMAT *format)
 
static int ffmpeg_sample_format (const AUDIO_FORMAT *format)
 
static void ffmpeg_close_context (FREERDP_DSP_CONTEXT *context)
 
static BOOL ffmpeg_open_context (FREERDP_DSP_CONTEXT *context)
 
static BOOL ffmpeg_resample_frame (AVAudioResampleContext *context, AVFrame *in, AVFrame *out)
 
static BOOL ffmpeg_encode_frame (AVCodecContext *context, AVFrame *in, AVPacket *packet, wStream *out)
 
static BOOL ffmpeg_fill_frame (AVFrame *frame, const AUDIO_FORMAT *inputFormat, const BYTE *data, size_t size)
 
static BOOL ffmpeg_decode (AVCodecContext *dec_ctx, AVPacket *pkt, AVFrame *frame, AVAudioResampleContext *resampleContext, AVFrame *resampled, wStream *out)
 
BOOL freerdp_dsp_ffmpeg_supports_format (const AUDIO_FORMAT *format, BOOL encode)
 
FREERDP_DSP_CONTEXT * freerdp_dsp_ffmpeg_context_new (BOOL encode)
 
void freerdp_dsp_ffmpeg_context_free (FREERDP_DSP_CONTEXT *context)
 
BOOL freerdp_dsp_ffmpeg_context_reset (FREERDP_DSP_CONTEXT *context, const AUDIO_FORMAT *targetFormat)
 
static BOOL freerdp_dsp_channel_mix (FREERDP_DSP_CONTEXT *context, const BYTE *src, size_t size, const AUDIO_FORMAT *srcFormat, const BYTE **data, size_t *length, AUDIO_FORMAT *dstFormat)
 
BOOL freerdp_dsp_ffmpeg_encode (FREERDP_DSP_CONTEXT *context, const AUDIO_FORMAT *format, const BYTE *data, size_t length, wStream *out)
 
BOOL freerdp_dsp_ffmpeg_decode (FREERDP_DSP_CONTEXT *context, const AUDIO_FORMAT *srcFormat, const BYTE *data, size_t length, wStream *out)
 

Macro Definition Documentation

◆ TAG

#define TAG   FREERDP_TAG("dsp.ffmpeg")

FreeRDP: A Remote Desktop Protocol Implementation Digital Sound Processing - FFMPEG backend

Copyright 2018 Armin Novak armin.nosp@m..nov.nosp@m.ak@th.nosp@m.inca.nosp@m.st.co.nosp@m.m Copyright 2018 Thincast Technologies GmbH

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Function Documentation

◆ ffmpeg_close_context()

static void ffmpeg_close_context ( FREERDP_DSP_CONTEXT *  context)
static
Here is the caller graph for this function:

◆ ffmpeg_codec_is_filtered()

static BOOL ffmpeg_codec_is_filtered ( enum AVCodecID  id,
BOOL  encoder 
)
static
Here is the caller graph for this function:

◆ ffmpeg_decode()

static BOOL ffmpeg_decode ( AVCodecContext *  dec_ctx,
AVPacket *  pkt,
AVFrame *  frame,
AVAudioResampleContext *  resampleContext,
AVFrame *  resampled,
wStream out 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ffmpeg_encode_frame()

static BOOL ffmpeg_encode_frame ( AVCodecContext *  context,
AVFrame *  in,
AVPacket *  packet,
wStream out 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ffmpeg_fill_frame()

static BOOL ffmpeg_fill_frame ( AVFrame *  frame,
const AUDIO_FORMAT inputFormat,
const BYTE data,
size_t  size 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ffmpeg_get_avcodec()

static enum AVCodecID ffmpeg_get_avcodec ( const AUDIO_FORMAT format)
static
Here is the caller graph for this function:

◆ ffmpeg_open_context()

static BOOL ffmpeg_open_context ( FREERDP_DSP_CONTEXT *  context)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ffmpeg_resample_frame()

static BOOL ffmpeg_resample_frame ( AVAudioResampleContext *  context,
AVFrame *  in,
AVFrame *  out 
)
static
Here is the caller graph for this function:

◆ ffmpeg_sample_format()

static int ffmpeg_sample_format ( const AUDIO_FORMAT format)
static
Here is the caller graph for this function:

◆ freerdp_dsp_channel_mix()

static BOOL freerdp_dsp_channel_mix ( FREERDP_DSP_CONTEXT *  context,
const BYTE src,
size_t  size,
const AUDIO_FORMAT srcFormat,
const BYTE **  data,
size_t *  length,
AUDIO_FORMAT dstFormat 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_context_free()

void freerdp_dsp_ffmpeg_context_free ( FREERDP_DSP_CONTEXT *  context)

FreeRDP: A Remote Desktop Protocol Implementation Digital Sound Processing - FFMPEG backend

Copyright 2018 Armin Novak armin.nosp@m..nov.nosp@m.ak@th.nosp@m.inca.nosp@m.st.co.nosp@m.m Copyright 2018 Thincast Technologies GmbH

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_context_new()

FREERDP_DSP_CONTEXT* freerdp_dsp_ffmpeg_context_new ( BOOL  encode)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_context_reset()

BOOL freerdp_dsp_ffmpeg_context_reset ( FREERDP_DSP_CONTEXT *  context,
const AUDIO_FORMAT targetFormat 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_decode()

BOOL freerdp_dsp_ffmpeg_decode ( FREERDP_DSP_CONTEXT *  context,
const AUDIO_FORMAT srcFormat,
const BYTE data,
size_t  length,
wStream out 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_encode()

BOOL freerdp_dsp_ffmpeg_encode ( FREERDP_DSP_CONTEXT *  context,
const AUDIO_FORMAT format,
const BYTE data,
size_t  length,
wStream out 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ freerdp_dsp_ffmpeg_supports_format()

BOOL freerdp_dsp_ffmpeg_supports_format ( const AUDIO_FORMAT format,
BOOL  encode 
)
Here is the call graph for this function:
Here is the caller graph for this function: