Thank you for your answser!<br><br>I'm going to try libavfilter. I saw it seems to provide a filter algorithm, so i guess libavfilter can replace libswscale? So what is the benefits to use libswcale instead of libavfilter?<br>

<br><br><div class="gmail_quote">On Wed, Feb 13, 2013 at 6:35 PM, Paul B Mahol <span dir="ltr"><<a href="mailto:onemda@gmail.com" target="_blank">onemda@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="HOEnZb"><div class="h5">On 2/13/13, Eric Beuque <<a href="mailto:eric.beuque@gmail.com">eric.beuque@gmail.com</a>> wrote:<br>
> Hi,<br>
><br>
> I'm using avcodec and swcale to to display a MPJEG stream in a Qt<br>
> application.<br>
><br>
> avcodec decode image as YUV image and swscale rescale it in a RGB32 image<br>
> to fit in the windows.<br>
><br>
> I would like to provide a zoom feature, i so i am wondering if any way<br>
> exists with swscale to rescale only the selected region. For example, I got<br>
> an original YUV image as 1280x800 pixels, the destination widget is 640x480<br>
> pixels, but i want only to display the region [0,0] to [320,240].<br>
><br>
> Is swscale able to to that? I have some difficulties to understand all<br>
> variables in the documentation.<br>
<br>
</div></div>No, swscale is not supposed to do that.<br>
<br>
libavfilter have filters that do cropping, pading and etc...<br>
Also its not hard to do it manually.<br>
<br>
> Thank for your help<br>
><br>
_______________________________________________<br>
Libav-user mailing list<br>
<a href="mailto:Libav-user@ffmpeg.org">Libav-user@ffmpeg.org</a><br>
<a href="http://ffmpeg.org/mailman/listinfo/libav-user" target="_blank">http://ffmpeg.org/mailman/listinfo/libav-user</a><br>
</blockquote></div><br>