Thanks for your prompt reply, however I still have some troubles in removing mp4 cover art;<div><br></div><div>I programmatically added 70 1600X1200 jpg files to a small mp4 clip, the file size increased from 0.09 to 35 MB after saving.</div>
<div>I tried to remove the covers like this:</div><div><br></div><div><div> MP4::File f(strName, false );</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">        </span>MP4::Tag *mp4Tag = f.tag();</div>
<div><span class="Apple-tab-span" style="white-space:pre">        </span>if ( mp4Tag && !mp4Tag->isEmpty() )</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>{</div><div><span class="Apple-tab-span" style="white-space:pre">                </span>MP4::ItemListMap map = mp4Tag->itemListMap();</div>
<div><span class="Apple-tab-span" style="white-space:pre">                </span>MP4::ItemListMap::Iterator it = map.begin();</div><div><span class="Apple-tab-span" style="white-space:pre">                </span>for ( ; it != map.end(); ++it )</div>
<div><span class="Apple-tab-span" style="white-space:pre">                        </span>mp4Tag->RemoveItme( (*it).first );</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">                </span>if ( !f.save() )</div><div><span class="Apple-tab-span" style="white-space:pre">                </span> printf( ("Fail to save") );</div>
<div><span class="Apple-tab-span" style="white-space:pre">        </span>}</div></div><div><br></div><div>The code did remove the mpeg4 tag as well as the covers, but the file size is still 35MB. I think the covers have been invalidated but their binary data were still stored in the file. </div>
<div><br></div><div>I am not sure it was the fault of the above code or it was caused by a bug of Taglib.<br><br><div class="gmail_quote">2010/9/6 Lukáš Lalinský <span dir="ltr"><<a href="mailto:lalinsky@gmail.com">lalinsky@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="im">On Sun, Sep 5, 2010 at 6:25 PM, Anthony Liu <<a href="mailto:quadamage@gmail.com">quadamage@gmail.com</a>> wrote:<br>
> Hi to all, I tried to remove pictures of a flac file like this:<br>
> FLAC::File f( "I:\\test.flac", true );<br>
> f.removePictures();<br>
> if ( !f.save() ) printf( "Fail to save!") );<br>
><br>
> The save function seemed to be called successfully, but the pictures were<br>
> still existing.<br>
> Any suggestions regarding this?<br>
<br>
</div>Embedding images in FLAC pictures is not supported in any released<br>
version of TagLib. The code which is currently in SVN is limited to<br>
read-only operations. It will work in versoin 1.7, but currently<br>
neither adding nor removing pictures is implemented.<br>
<div><div></div><div class="h5"><br>
Lukas<br>
_______________________________________________<br>
taglib-devel mailing list<br>
<a href="mailto:taglib-devel@kde.org">taglib-devel@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/taglib-devel" target="_blank">https://mail.kde.org/mailman/listinfo/taglib-devel</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Best Regards<br>
</div>