<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12px"><div dir="ltr" id="yui_3_16_0_1_1443045196012_2739"><span id="yui_3_16_0_1_1443045196012_3259">Not an NCL problem, but you could try "convert -trim +repage".</span></div><div id="yui_3_16_0_1_1443045196012_3333" dir="ltr"><br><span id="yui_3_16_0_1_1443045196012_3259"></span></div><div id="yui_3_16_0_1_1443045196012_3328" dir="ltr"><span id="yui_3_16_0_1_1443045196012_3259">Good luck,</span></div><div id="yui_3_16_0_1_1443045196012_3332" dir="ltr"><span id="yui_3_16_0_1_1443045196012_3259">Dave.</span></div>  <br><div id="yui_3_16_0_1_1443045196012_2764" class="qtdSeparateBR"><br><br></div><div style="display: block;" id="yui_3_16_0_1_1443045196012_2761" class="yahoo_quoted"> <div id="yui_3_16_0_1_1443045196012_2760" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12px;"> <div id="yui_3_16_0_1_1443045196012_2759" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div id="yui_3_16_0_1_1443045196012_2765" dir="ltr"> <font id="yui_3_16_0_1_1443045196012_2766" face="Arial" size="2"> On Wednesday, September 23, 2015 11:25 PM, "ncl-talk-request@ucar.edu" &lt;ncl-talk-request@ucar.edu&gt; wrote:<br> </font> </div>  <br><br> <div id="yui_3_16_0_1_1443045196012_2758" class="y_msg_container">----------------------------------------------------------------------<br><br>Date: Wed, 23 Sep 2015 15:24:47 -0300<br>From: Sebastian Otarola-Bustos &lt;<a id="yui_3_16_0_1_1443045196012_2998" ymailto="mailto:Sebastian.F.Otarola-Bustos.1@nd.edu" href="mailto:Sebastian.F.Otarola-Bustos.1@nd.edu">Sebastian.F.Otarola-Bustos.1@nd.edu</a>&gt;<br>Subject: [ncl-talk] PNG trim error before doing animated Gif, all the<br>&nbsp;&nbsp;&nbsp; space outside the trimmed area now is black colored.<br>To: "<a id="yui_3_16_0_1_1443045196012_3374" ymailto="mailto:ncl-talk@ucar.edu" href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a>" &lt;<a id="yui_3_16_0_1_1443045196012_2776" ymailto="mailto:ncl-talk@ucar.edu" href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a>&gt;<br>Message-ID:<br>&nbsp;&nbsp;&nbsp; &lt;CAO9pyik1_R50FwZwhs=<a id="yui_3_16_0_1_1443045196012_2997" ymailto="mailto:VcywLhovGSLEnx5LGkm0LkMtX4E1X7w@mail.gmail.com" href="mailto:VcywLhovGSLEnx5LGkm0LkMtX4E1X7w@mail.gmail.com">VcywLhovGSLEnx5LGkm0LkMtX4E1X7w@mail.gmail.com</a>&gt;<br>Content-Type: text/plain; charset="utf-8"<br><br>Hi everybody,<br><br>I've been making animations without troubles converting .png to .gif using<br>the following commands: convert -trim &amp; convert -delay, so I'm cutting the<br>white space with trim and then doing the animation with -delay. The strange<br>thing is that if I see each .png file separately, it's cutted ok, as it<br>showns in Figure1, but after doing the animation with the cutted files, you<br>can see the trimmed area, but the difference between the cutted area and<br>the original size is all filled with black as you can see in Figure2. Here<br>you can see the main steps of my scripts:<br><br><br>&nbsp; *do n=0,ntimes-1,4*<br><br>*&nbsp; &nbsp; &nbsp; wks_type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; = "png"*<br>*&nbsp; &nbsp; &nbsp; <a ymailto="mailto:wks_type@wkWidth" href="mailto:wks_type@wkWidth">wks_type@wkWidth</a>&nbsp; &nbsp; = 1700*<br>*&nbsp; &nbsp; &nbsp; <a ymailto="mailto:wks_type@wkHeight" href="mailto:wks_type@wkHeight">wks_type@wkHeight</a>&nbsp;  = 1700*<br>*&nbsp; &nbsp; &nbsp; wks = gsn_open_wks("png","animate"+sprinti("%03i",n))&nbsp; &nbsp; ;<br>animate_000.png, animate_001.png, etc*<br>*&nbsp; &nbsp; &nbsp; print("Trabajando en el tiempo: " + times(n))*<br>*&nbsp; &nbsp; &nbsp; <a ymailto="mailto:mpres@gsnRightString" href="mailto:mpres@gsnRightString">mpres@gsnRightString</a>&nbsp; = " Velocity(m/s):&nbsp; "+ times(n)*<br>*&nbsp; &nbsp; &nbsp; <a ymailto="mailto:mpres@gsnLeftString" href="mailto:mpres@gsnLeftString">mpres@gsnLeftString</a> = " "*<br><br>*&nbsp; &nbsp; &nbsp; mpid&nbsp;  = gsn_csm_map(wks,mpres)*<br>*&nbsp; &nbsp; &nbsp; V&nbsp; = gsn_csm_contour(wks,speed(n,:,:),spres)*<br>*&nbsp; &nbsp; &nbsp; wind = gsn_csm_vector(wks,u(n,:,:),v(n,:,:),Vres)*<br>*&nbsp; &nbsp; &nbsp; Heig&nbsp; &nbsp; =gsn_csm_contour(wks,ter(:,:),ter_res)*<br><br>*&nbsp; &nbsp; &nbsp; overlay(mpid,V)*<br>*&nbsp; &nbsp; &nbsp; overlay(mpid,Heig)*<br>*&nbsp; &nbsp; &nbsp; overlay(mpid,wind)*<br>*&nbsp; &nbsp; &nbsp; maximize_output(wks,True)*<br>*&nbsp; &nbsp; &nbsp; delete(wks)*<br>*&nbsp; &nbsp; &nbsp; cmd="convert -trim animate"+sprinti("%03i",n)+".png<br>"+"animate"+sprinti("%03i",n)+".png"*<br>*&nbsp; &nbsp; &nbsp; system(cmd)*<br><br><br>*&nbsp; end doINS = "convert -delay 50 animate*.png velocity_3.gif" system(INS)*<br><br>I still cannot see the error, and any help would be really appreciated as<br>always,<br><br>All the best,<br>Thank you very much,<br>Sebasti?n.<br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: <a id="yui_3_16_0_1_1443045196012_2979" href="http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0001.html" target="_blank">http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0001.html </a><br>-------------- next part --------------<br>A non-text attachment was scrubbed...<br>Name: Figure_1.PNG<br>Type: image/png<br>Size: 124596 bytes<br>Desc: not available<br>Url : <a id="yui_3_16_0_1_1443045196012_2845" href="http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0002.png" target="_blank">http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0002.png</a><br>-------------- next part --------------<br>A non-text attachment was scrubbed...<br>Name: Figure_2.PNG<br>Type: image/png<br>Size: 109313 bytes<br>Desc: not available<br>Url : <a id="yui_3_16_0_1_1443045196012_2980" href="http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0003.png" target="_blank">http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150923/544fdb0d/attachment-0003.png </a><br><br>------------------------------<br></div>  </div> </div>  </div></div></body></html>