Le lun. 11 mars 2019 à 10:04, Carl Eugen Hoyos <[email protected]> a écrit :
> 2019-03-11 4:14 GMT+01:00, NDJORE BORIS <[email protected]>: > > > I just enabled vaapi in my configure options but It doesn't > > work. I have the error : vaapi hardware is needed. > > Is this error message unclear? > > Carl Eugen > _______________________________________________ > This is excactly the output error : > > [h264_vaapi @ 0x8712c0] A hardware frames reference is required to > associate the encoding device. > Cannot open video encoder for stream #0 > > In my code I use these lines to choose the encoder : > > if (dec_ctx->codec_type == AVMEDIA_TYPE_VIDEO || dec_ctx->codec_type == > AVMEDIA_TYPE_AUDIO) > { > encoder = avcodec_find_encoder(dec_ctx->codec_id); > if(!encoder) > { > av_log(NULL, AV_LOG_FATAL, "Necessary > encoder not found\n"); > return AVERROR_INVALIDDATA; > } > enc_ctx = avcodec_alloc_context3(encoder); > if(!enc_ctx) > { > av_log(NULL, AV_LOG_FATAL, "Failed to > allocate the encoder context\n"); > return AVERROR(ENOMEM); > } > > For others videos formats, all is right. But the above error happens when > the video is a h264 format. >
_______________________________________________ Libav-user mailing list [email protected] https://ffmpeg.org/mailman/listinfo/libav-user To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
