mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-26 01:02:33 +00:00
avcodec/nvenc: Add 'nvenc_h264' as an alternative name for 'nvenc'
This allows us to offer the same codec name that libav uses. We don't have a special way to do aliases, so it's all a bit more verbose than you'd want but such is life. Signed-off-by: Philip Langdale <philipl@overt.org>
This commit is contained in:
parent
e79c40fe72
commit
7e4661174a
1
configure
vendored
1
configure
vendored
@ -2485,6 +2485,7 @@ libutvideo_decoder_deps="libutvideo"
|
|||||||
libutvideo_encoder_deps="libutvideo"
|
libutvideo_encoder_deps="libutvideo"
|
||||||
libzvbi_teletext_decoder_deps="libzvbi"
|
libzvbi_teletext_decoder_deps="libzvbi"
|
||||||
nvenc_encoder_deps="nvenc"
|
nvenc_encoder_deps="nvenc"
|
||||||
|
nvenc_h264_encoder_deps="nvenc"
|
||||||
nvenc_hevc_encoder_deps="nvenc"
|
nvenc_hevc_encoder_deps="nvenc"
|
||||||
|
|
||||||
# demuxers / muxers
|
# demuxers / muxers
|
||||||
|
@ -236,6 +236,7 @@ void avcodec_register_all(void)
|
|||||||
REGISTER_DECODER(MXPEG, mxpeg);
|
REGISTER_DECODER(MXPEG, mxpeg);
|
||||||
REGISTER_DECODER(NUV, nuv);
|
REGISTER_DECODER(NUV, nuv);
|
||||||
REGISTER_ENCODER(NVENC, nvenc);
|
REGISTER_ENCODER(NVENC, nvenc);
|
||||||
|
REGISTER_ENCODER(NVENC_H264, nvenc_h264);
|
||||||
REGISTER_ENCODER(NVENC_HEVC, nvenc_hevc);
|
REGISTER_ENCODER(NVENC_HEVC, nvenc_hevc);
|
||||||
REGISTER_DECODER(PAF_VIDEO, paf_video);
|
REGISTER_DECODER(PAF_VIDEO, paf_video);
|
||||||
REGISTER_ENCDEC (PAM, pam);
|
REGISTER_ENCDEC (PAM, pam);
|
||||||
|
@ -1427,6 +1427,31 @@ AVCodec ff_nvenc_encoder = {
|
|||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Add an alias for nvenc_h264 */
|
||||||
|
#if CONFIG_NVENC_H264_ENCODER
|
||||||
|
static const AVClass nvenc_h264_class = {
|
||||||
|
.class_name = "nvenc_h264",
|
||||||
|
.item_name = av_default_item_name,
|
||||||
|
.option = options,
|
||||||
|
.version = LIBAVUTIL_VERSION_INT,
|
||||||
|
};
|
||||||
|
|
||||||
|
AVCodec ff_nvenc_h264_encoder = {
|
||||||
|
.name = "nvenc_h264",
|
||||||
|
.long_name = NULL_IF_CONFIG_SMALL("Nvidia NVENC h264 encoder"),
|
||||||
|
.type = AVMEDIA_TYPE_VIDEO,
|
||||||
|
.id = AV_CODEC_ID_H264,
|
||||||
|
.priv_data_size = sizeof(NvencContext),
|
||||||
|
.init = nvenc_encode_init,
|
||||||
|
.encode2 = nvenc_encode_frame,
|
||||||
|
.close = nvenc_encode_close,
|
||||||
|
.capabilities = CODEC_CAP_DELAY,
|
||||||
|
.priv_class = &nvenc_h264_class,
|
||||||
|
.defaults = nvenc_defaults,
|
||||||
|
.pix_fmts = pix_fmts_nvenc,
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
#if CONFIG_NVENC_HEVC_ENCODER
|
#if CONFIG_NVENC_HEVC_ENCODER
|
||||||
static const AVClass nvenc_hevc_class = {
|
static const AVClass nvenc_hevc_class = {
|
||||||
.class_name = "nvenc_hevc",
|
.class_name = "nvenc_hevc",
|
||||||
|
Loading…
Reference in New Issue
Block a user