FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
libndi_newtek_enc.c File Reference
#include "libavformat/avformat.h"
#include "libavformat/internal.h"
#include "libavutil/opt.h"
#include "libavutil/imgutils.h"
#include "libndi_newtek_common.h"

Go to the source code of this file.

Data Structures

struct  NDIContext
 

Macros

#define OFFSET(x)   offsetof(struct NDIContext, x)
 

Functions

static int ndi_write_trailer (AVFormatContext *avctx)
 
static int ndi_write_video_packet (AVFormatContext *avctx, AVStream *st, AVPacket *pkt)
 
static int ndi_write_audio_packet (AVFormatContext *avctx, AVStream *st, AVPacket *pkt)
 
static int ndi_write_packet (AVFormatContext *avctx, AVPacket *pkt)
 
static int ndi_setup_audio (AVFormatContext *avctx, AVStream *st)
 
static int ndi_setup_video (AVFormatContext *avctx, AVStream *st)
 
static int ndi_write_header (AVFormatContext *avctx)
 

Variables

static const AVOption options []
 
static const AVClass libndi_newtek_muxer_class
 
AVOutputFormat ff_libndi_newtek_muxer
 

Macro Definition Documentation

#define OFFSET (   x)    offsetof(struct NDIContext, x)

Definition at line 271 of file libndi_newtek_enc.c.

Function Documentation

static int ndi_write_trailer ( AVFormatContext avctx)
static

Definition at line 42 of file libndi_newtek_enc.c.

static int ndi_write_video_packet ( AVFormatContext avctx,
AVStream st,
AVPacket pkt 
)
static

Definition at line 57 of file libndi_newtek_enc.c.

Referenced by ndi_write_packet().

static int ndi_write_audio_packet ( AVFormatContext avctx,
AVStream st,
AVPacket pkt 
)
static

Definition at line 104 of file libndi_newtek_enc.c.

Referenced by ndi_write_packet().

static int ndi_write_packet ( AVFormatContext avctx,
AVPacket pkt 
)
static

Definition at line 120 of file libndi_newtek_enc.c.

static int ndi_setup_audio ( AVFormatContext avctx,
AVStream st 
)
static

Definition at line 132 of file libndi_newtek_enc.c.

Referenced by ndi_write_header().

static int ndi_setup_video ( AVFormatContext avctx,
AVStream st 
)
static

Definition at line 155 of file libndi_newtek_enc.c.

Referenced by ndi_write_header().

static int ndi_write_header ( AVFormatContext avctx)
static

Definition at line 231 of file libndi_newtek_enc.c.

Variable Documentation

const AVOption options[]
static
Initial value:
= {
{ "reference_level", "The audio reference level in dB" , OFFSET(reference_level), AV_OPT_TYPE_INT, { .i64 = 0 }, -20, 20, AV_OPT_FLAG_ENCODING_PARAM | AV_OPT_FLAG_AUDIO_PARAM},
{ "clock_video", "These specify whether video 'clock' themselves" , OFFSET(clock_video), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, AV_OPT_FLAG_ENCODING_PARAM | AV_OPT_FLAG_VIDEO_PARAM },
{ "clock_audio", "These specify whether audio 'clock' themselves" , OFFSET(clock_audio), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, AV_OPT_FLAG_ENCODING_PARAM | AV_OPT_FLAG_AUDIO_PARAM },
{ NULL },
}
#define NULL
Definition: coverity.c:32
#define AV_OPT_FLAG_AUDIO_PARAM
Definition: opt.h:281
#define AV_OPT_FLAG_ENCODING_PARAM
a generic parameter which can be set by the user for muxing or encoding
Definition: opt.h:276
#define AV_OPT_FLAG_VIDEO_PARAM
Definition: opt.h:282
#define OFFSET(x)

Definition at line 272 of file libndi_newtek_enc.c.

const AVClass libndi_newtek_muxer_class
static
Initial value:
= {
.class_name = "NDI muxer",
.item_name = av_default_item_name,
.option = options,
}
#define LIBAVUTIL_VERSION_INT
Definition: version.h:86
av_default_item_name
static const AVOption options[]

Definition at line 279 of file libndi_newtek_enc.c.

AVOutputFormat ff_libndi_newtek_muxer
Initial value:
= {
.name = "libndi_newtek",
.long_name = NULL_IF_CONFIG_SMALL("Network Device Interface (NDI) output using NewTek library"),
.audio_codec = AV_CODEC_ID_PCM_S16LE,
.subtitle_codec = AV_CODEC_ID_NONE,
.flags = AVFMT_NOFILE,
.priv_class = &libndi_newtek_muxer_class,
.priv_data_size = sizeof(struct NDIContext),
.write_packet = ndi_write_packet,
.write_trailer = ndi_write_trailer,
}
static int ndi_write_header(AVFormatContext *avctx)
static int ndi_write_packet(AVFormatContext *avctx, AVPacket *pkt)
static int ndi_write_trailer(AVFormatContext *avctx)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:179
Passthrough codec, AVFrames wrapped in AVPacket.
Definition: avcodec.h:695
#define AVFMT_NOFILE
Demuxer will use avio_open, no opened file should be provided by the caller.
Definition: avformat.h:478
static const AVClass libndi_newtek_muxer_class
static void write_header(FFV1Context *f)
Definition: ffv1enc.c:337

Definition at line 287 of file libndi_newtek_enc.c.