1. Is there a way to convert lossless files only and transfer mp3 over? My files are either FLAC or MP3.
SyncRules=FLAC*0*MP3_160
SyncRules=*0*copy
Read on to understand the two lines.
2. I don't seem to get how the convertFormat sections works and how to set it up for FLAC to MP3.
Example:
SyncRules=$if($greater($strstr(%KNI_SYNC%,'Wecker'),0),'T')*0*Vorbis_q2
SyncRules=IT*0*copy
SyncRules=MOD*0*copy
SyncRules=669*0*copy
SyncRules=XM*0*copy
SyncRules=*<115*copy
SyncRules=*>115*Vorbis_q2
Important:
Syncrules are processed from top to buttom.
The first matching for the processed item will decide what ConvertFormats is used.
The example above reads as follows:
$if($greater($strs ... shows that very complex things are possible. Just ignore for the moment. :-)
Files from media lib with extensions IT, MOD, 669 or XM will just be copied.
All other files than theese will be copied if bitrate is < 115kbit.
Rest of files (with more than 115 kbit bitrate) will be converted to Vorbis codec with profile "Vorbis_q2" (see below).
profile Vorbis_q2
ConvertFormats=Vorbis_q2*OGG*-vn -c:a libvorbis -ac 2 -ab 96k*96*_q2
The stars (*) are used as delimiters. The meaning of the arguments are descibed in the Wiki.
Most of this stuff is related to ffmpeg, that does the conversion.
It's not easy to get it all setup but thats the price you pay for the flexibility you get.
Here some more examples for ConvertFormats:
ConvertFormats=MP3_128*MP3*-vn -ac 2 -ab 128k*128
ConvertFormats=MP3_160*MP3*-vn -ac 2 -ab 160k*160
ConvertFormats=MP3_192*MP3*-vn -ac 2 -ab 192k*192
ConvertFormats=MP3_256*MP3*-vn -ac 2 -ab 256k*256
ConvertFormats=Vorbis_q4*OGG*-vn -c:a libvorbis -ac 2 -ab 128k*128*_q4
ConvertFormats=Vorbis_q5*OGG*-vn -c:a libvorbis -ac 2 -ab 150k*150*_q5
ConvertFormats=OPUS_96*-vn -c:a libopus -ac 2 -ab 96k*96
ConvertFormats=OPUS_128*OGG*-vn -c:a libopus -ac 2 -ab 128k*128
ConvertFormats=AAC_HE_80*AAC*-vn -c:a libvo_aacenc -profile:a aac_he_v2 -ac 2 -ab 80k*80
Currently, the file that appears in the folder is:
filename_q2.OGGFLAG
Theese FLAG-files are just placeholders for the conversion and disappear when sync is finished.
They are used to judge if an item in a playlist must be copied to PLSyncBaseDir.
So if an item is already in MLSyncBaseDir synced it will not get copied to PLSyncBaseDir. Instead the playlist will just link the item to the existing file.
3. Is there a way to embed the folder.jpg that resides in the folder where the file is? I know this can be done with metaflac.exe --ti "pathto/folder.jpg"
Not with FoobarSync directly but you are on the right way. If you embed the album cover into the FLAC-files and tell FoobarSync to just copy, it will contain your cover as no modifications to copied files are made. If an embedded album cover will survive conversion from one format to another is a question of the converter used: ffmpeg.
Could you do me a favour and tell me what version or Foobar you are running?
I'd like to update my wiki that it runs with newer versions and add the path-issue with comserver2.
Thanks