mirror of
https://github.com/librempeg/librempeg
synced 2024-11-22 09:02:20 +00:00
lavc/videotoolbox: drop HEVC cropping from start_frame rather than end_frame
HEVCContext.output_frame will be removed in following commits. Reported-By: Max Bykov Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
ad36e000f7
commit
2768532223
@ -1053,6 +1053,14 @@ static int videotoolbox_hevc_start_frame(AVCodecContext *avctx,
|
||||
const uint8_t *buffer,
|
||||
uint32_t size)
|
||||
{
|
||||
HEVCContext *h = avctx->priv_data;
|
||||
AVFrame *frame = h->cur_frame->f;
|
||||
|
||||
frame->crop_right = 0;
|
||||
frame->crop_left = 0;
|
||||
frame->crop_top = 0;
|
||||
frame->crop_bottom = 0;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1079,11 +1087,6 @@ static int videotoolbox_hevc_end_frame(AVCodecContext *avctx)
|
||||
VTContext *vtctx = avctx->internal->hwaccel_priv_data;
|
||||
int ret;
|
||||
|
||||
h->output_frame->crop_right = 0;
|
||||
h->output_frame->crop_left = 0;
|
||||
h->output_frame->crop_top = 0;
|
||||
h->output_frame->crop_bottom = 0;
|
||||
|
||||
ret = ff_videotoolbox_common_end_frame(avctx, frame);
|
||||
vtctx->bitstream_size = 0;
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user