title: Resizing an Image using Imagemagick convert
body: <p>I have a YUV420 image of size 1280x720. I am trying to resize it to 720x576 using convert (Imagemagick) using below commandline options. But the generated output file doesnot seem to be a proper resized YUV420 image(I want the resized output also to be in YUV420 format):</p>
  
  <pre><code>convert -size 1280x720 -depth 8 -sampling-factor 2x2  test_1280x720_yuv420.yuv  -filter lanczos -resize 720x576 -depth 8 -sampling-factor 2x2  720x576_yuv420.yuv //Here the output file size is not what it should be of a 720x576 YUV420 file which is 720x576x1.5 bytes. 
  </code></pre>
  
  <p>Qiestion: What is the format of this output file then?</p>
  
  <p>Also tried  -sample option as, but same result. Incorrect sized output file. I even tried to display the generated resized file, but it sure is not a YUV420 file, as could not view it correctly at all. </p>
  
  <pre><code>convert -size 1280x720 -depth 8 -sampling-factor 2x2  test_1280x720_yuv420.yuv   -sample 720x576 -depth 8 -sampling-factor 2x2  720x576_yuv420.yuv
  </code></pre>
  
  <p>Question: Would convert be able to do what I am trying to get done? IF yes, what are the options?</p>
  
  <p>Question: Any other tool(freeware,shareware) which could help me resize YUV files(different formats YUV420, YUV444) to YUV format output files?</p>