FFmpeg
Macros | Functions | Variables
nvenc_hevc.c File Reference
#include "libavutil/internal.h"
#include "avcodec.h"
#include "internal.h"
#include "nvenc.h"

Go to the source code of this file.

Macros

#define OFFSET(x)   offsetof(NvencContext, x)
 
#define VE   AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM
 

Functions

static av_cold int nvenc_old_init (AVCodecContext *avctx)
 

Variables

static const AVOption options []
 
static const AVCodecDefault defaults []
 
static const AVClass nvenc_hevc_class
 
AVCodec ff_nvenc_hevc_encoder
 
static const AVClass hevc_nvenc_class
 
AVCodec ff_hevc_nvenc_encoder
 

Macro Definition Documentation

◆ OFFSET

#define OFFSET (   x)    offsetof(NvencContext, x)

Definition at line 26 of file nvenc_hevc.c.

◆ VE

Definition at line 27 of file nvenc_hevc.c.

Function Documentation

◆ nvenc_old_init()

static av_cold int nvenc_old_init ( AVCodecContext avctx)
static

Definition at line 184 of file nvenc_hevc.c.

Variable Documentation

◆ options

const AVOption options[]
static

Definition at line 28 of file nvenc_hevc.c.

◆ defaults

const AVCodecDefault defaults[]
static
Initial value:
= {
{ "b", "2M" },
{ "qmin", "-1" },
{ "qmax", "-1" },
{ "qdiff", "-1" },
{ "qblur", "-1" },
{ "qcomp", "-1" },
{ "g", "250" },
{ "bf", "-1" },
{ "refs", "0" },
{ NULL },
}

Definition at line 169 of file nvenc_hevc.c.

◆ nvenc_hevc_class

const AVClass nvenc_hevc_class
static
Initial value:
= {
.class_name = "nvenc_hevc",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 190 of file nvenc_hevc.c.

◆ ff_nvenc_hevc_encoder

AVCodec ff_nvenc_hevc_encoder
Initial value:
= {
.name = "nvenc_hevc",
.long_name = NULL_IF_CONFIG_SMALL("NVIDIA NVENC hevc encoder"),
.init = nvenc_old_init,
.receive_packet = ff_nvenc_receive_packet,
.priv_data_size = sizeof(NvencContext),
.priv_class = &nvenc_hevc_class,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
.wrapper_name = "nvenc",
.hw_configs = ff_nvenc_hw_configs,
}

Definition at line 197 of file nvenc_hevc.c.

◆ hevc_nvenc_class

const AVClass hevc_nvenc_class
static
Initial value:
= {
.class_name = "hevc_nvenc",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 219 of file nvenc_hevc.c.

◆ ff_hevc_nvenc_encoder

AVCodec ff_hevc_nvenc_encoder
Initial value:
= {
.name = "hevc_nvenc",
.long_name = NULL_IF_CONFIG_SMALL("NVIDIA NVENC hevc encoder"),
.receive_packet = ff_nvenc_receive_packet,
.priv_data_size = sizeof(NvencContext),
.priv_class = &hevc_nvenc_class,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
.wrapper_name = "nvenc",
.hw_configs = ff_nvenc_hw_configs,
}

Definition at line 226 of file nvenc_hevc.c.

hevc_nvenc_class
static const AVClass hevc_nvenc_class
Definition: nvenc_hevc.c:219
AV_CODEC_CAP_HARDWARE
#define AV_CODEC_CAP_HARDWARE
Codec is backed by a hardware implementation.
Definition: codec.h:157
NvencContext
Definition: nvenc.h:146
ff_nvenc_pix_fmts
enum AVPixelFormat ff_nvenc_pix_fmts[]
Definition: nvenc.c:46
ff_nvenc_encode_flush
av_cold void ff_nvenc_encode_flush(AVCodecContext *avctx)
Definition: nvenc.c:2349
nvenc_hevc_class
static const AVClass nvenc_hevc_class
Definition: nvenc_hevc.c:190
AV_CODEC_CAP_ENCODER_FLUSH
#define AV_CODEC_CAP_ENCODER_FLUSH
This encoder can be flushed using avcodec_flush_buffers().
Definition: codec.h:178
ff_nvenc_encode_init
av_cold int ff_nvenc_encode_init(AVCodecContext *avctx)
Definition: nvenc.c:1633
pix_fmts
static enum AVPixelFormat pix_fmts[]
Definition: libkvazaar.c:309
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
NULL
#define NULL
Definition: coverity.c:32
defaults
static const AVCodecDefault defaults[]
Definition: nvenc_hevc.c:169
ff_nvenc_encode_close
av_cold int ff_nvenc_encode_close(AVCodecContext *avctx)
Definition: nvenc.c:1556
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:235
AV_CODEC_CAP_DR1
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
Definition: codec.h:52
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:117
ff_nvenc_hw_configs
const AVCodecHWConfigInternal *const ff_nvenc_hw_configs[]
Definition: nvenc.c:62
ff_nvenc_receive_packet
int ff_nvenc_receive_packet(AVCodecContext *avctx, AVPacket *pkt)
Definition: nvenc.c:2298
nvenc_old_init
static av_cold int nvenc_old_init(AVCodecContext *avctx)
Definition: nvenc_hevc.c:184
FF_CODEC_CAP_INIT_CLEANUP
#define FF_CODEC_CAP_INIT_CLEANUP
The codec allows calling the close function for deallocation even if the init function returned a fai...
Definition: internal.h:49
AV_CODEC_ID_HEVC
@ AV_CODEC_ID_HEVC
Definition: codec_id.h:223
AV_CODEC_CAP_DELAY
#define AV_CODEC_CAP_DELAY
Encoder or decoder requires flushing with NULL input at the end in order to give the complete and cor...
Definition: codec.h:77
AVMEDIA_TYPE_VIDEO
@ AVMEDIA_TYPE_VIDEO
Definition: avutil.h:201
options
static const AVOption options[]
Definition: nvenc_hevc.c:28