Fair point, cropping should not modify the pixels. But at some point you would want to remove the pixels outside the selected region, or copy the pixels inside the region to the destination frame. I dont’t see either of these things happening in filter_frame() Am I looking in the wrong place? ________________________________________ From: [email protected] <[email protected]> on behalf of Carl Eugen Hoyos <[email protected]> Sent: 31 January 2015 22:59 To: [email protected] Subject: Re: [Libav-user] How is cropping and scaling implemented
Kristensen, Odd-Arild <okristensen@...> writes: > If filter_frame() does perform cropping, how does > > frame->data[0] += s->y * frame->linesize[0]; > > frame->data[0] += s->x * s->max_step[0]; > > in any way change the pixels of the video? I would say that cropping is not supposed to change the pixels (of a video). > Scaling on the other hand seem to be done by > sws_scale() if I am not mistaken. This is correct. > But the wording in the documentation confuses me. > Does it change/convert the pixel format of the > video, or does it actually scale the video/frame > to a different resolution? Both. Carl Eugen _______________________________________________ Libav-user mailing list [email protected] http://ffmpeg.org/mailman/listinfo/libav-user _______________________________________________ Libav-user mailing list [email protected] http://ffmpeg.org/mailman/listinfo/libav-user
