{"id":312,"date":"2009-07-29T13:31:21","date_gmt":"2009-07-29T12:31:21","guid":{"rendered":"http:\/\/www.codingfriends.com\/?p=312"},"modified":"2009-07-29T13:31:33","modified_gmt":"2009-07-29T12:31:33","slug":"how-to-convert-avi-mpeg-to-vcd","status":"publish","type":"post","link":"https:\/\/www.codingfriends.com\/index.php\/2009\/07\/29\/how-to-convert-avi-mpeg-to-vcd\/","title":{"rendered":"How to convert AVI-MPEG to VCD"},"content":{"rendered":"<p>This shall serve as a reminder for myself and may help others.  There is different versions of audio conversion, CBR (Constant Bit Rate) and VBR (Variable Bit Rate), it seems that many DVD players perfer the CBR.  Below is both versions with links to the relevant programs and example command lines.<\/p>\n<ul>\n<li><a href=\"#CBR\" title=\"Constant Bit Rate\">CBR<\/a><\/li>\n<li><a href=\"#VBR\" title=\"Variable Bit Rate\">VBR<\/a><\/li>\n<\/ul>\n<p><a name=\"CBR\">CBR AVI-MPEG<\/a><\/p>\n<ul>\n<li><a href=\"http:\/\/www.theorie.physik.uni-goettingen.de\/~ostreich\/transcode\/\" title=\"Transcode source\" target=\"_blank\">Transcode<\/a> (RPM-FIND <a href=\"http:\/\/rpmfind.net\/linux\/rpm2html\/search.php?query=transcode\" title=\"rpmfind transcode\" target=\"_blank\">results<\/a>)<\/li>\n<\/ul>\n<p>To convert the avi file into a mpeg file for a PAL 352&#215;288 screen, there is different settings either use the &#8216;man&#8217; or goto the <a href=\"http:\/\/www.theorie.physik.uni-goettingen.de\/~ostreich\/transcode\/\" title=\"Transcode source\" target=\"_blank\">Transcode<\/a> website for viewing the conversion in more detail.  The command line that I use is <\/p>\n<pre class=\"consoleoutput\">\r\ntranscode -i&lt;AVI FILM&gt; -V -y mpeg -F v,1 -E 44100 -b 224 -fps 25 -o &lt;OUTPUTFILENAME&gt;\r\n<\/pre>\n<p>This generates two files, *.m1v (the video segment) and *.mpa (the audio segment).<\/p>\n<p>The options in the above command line are<\/p>\n<ul>\n<li>-b    Audio bitrate Kbit&#8217;s<\/li>\n<li>-E    Audio sampling rate (Hz)<\/li>\n<li>-F    codec<\/li>\n<li>-i     input file<\/li>\n<li>-V    use internal video codec (faster but some import modules do not support this)<\/li>\n<li>-y    video, audio export modules.<\/li>\n<li>-fps  Frames per second, 25 is for PAL, 29.97 for NTSC<\/li>\n<\/ul>\n<p>Joining the OUTPUTFILENAME&#8217;s together<\/p>\n<p>To join these two segments together <\/p>\n<pre class=\"consoleoutput\">\r\ntcmplex -o &lt;OUTPUT.MPG&gt; -i &lt;OUTPUTFILENAME.M1V&gt; -p &lt;OUTPUTFILENAME.MPA&gt; -m v\r\n<\/pre>\n<p>This will create a MPEG file ready to be either watched or converted again into the <a href=\"vcd.html#VCD\" title=\"Link to VCD conversion below\">VCD<\/a> format and then <a href=\"vcd.html#Burning\" title=\"Link to burned details below\">burned<\/a>.<\/p>\n<p><a name=\"VBR\">VBR AVI-MPEG<\/a><\/p>\n<p>The programs to download\/use are obtained from these links<\/p>\n<ul>\n<li><a href=\"http:\/\/ffmpeg.sourceforge.net\/\" title=\"ffmpeg sourceforge\" target=\"_blank\">FFMpeg<\/a> (RPM-FIND <a href=\"http:\/\/rpmfind.net\/linux\/rpm2html\/search.php?query=ffmpeg\" title=\"rpmfind ffmpeg\" target=\"_blank\">results<\/a>)<\/li>\n<\/ul>\n<p>If the AVI file is in MS MPeg4 v3(DIVX3)<\/p>\n<p>If the INPUT file is in a MS MPeg4 v3 (DIVX3) then you have to convert the file into a DIVX format for FFMPeg to do its stuff. To convert to the required file you will need the mencoder program from <a href=\"http:\/\/www.mplayerhq.hu\/homepage\" title=\"Mplayer\" target=\"_blank\">MPlayer<\/a> website.  To convert to the required file structure use the commands below.<\/p>\n<pre class=\"consoleoutput\">\r\nmencoder -ovc lavc -lavcopts vcodec=mpeg4:vhq -oac copy INPUTFILE.AVI -o OUTPUT.AVI\r\n<\/pre>\n<p>The options produce a mpeg4 version of the input file using the lavc video converter. Also with the option &#8216;vhq&#8217;, it produces a very high quality output file.<\/p>\n<p>Convert AVI-MPEG<\/p>\n<p>To convert AVI to MPEG use the ffmpeg program, with the commands as below.  The INPUT.FILE is in AVI format and the OUTPUT.FILE is an MPEG format<\/p>\n<pre class=\"consoleoutput\">\r\nffmpeg -vcd -i INPUT.FILE -b 1150 -s 352x288 -vcodec mpeg1video -f mpegvideo OUTPUT.FILE\r\n<\/pre>\n<p>With advice, the ffmpeg build version 4753 (form cvs) the parameters are:- <\/p>\n<pre class=\"consoleoutput\">\r\nffmpeg -target vcd -i INPUT.FILE -b 1150 -s 352x288 -vcodec mpeg1video -f mpegvideo OUTPUT.FIL\r\n<\/pre>\n<p>The options enable an VCD Mpeg type file output(-vcd) with a bitrate of 1150 (-b) and an output screen size of 352&#215;288 (-s). The codecs to convert to are mpeg1video (-vcodec) so that it is able to be converted to an vcd image with the vcdimager program.<br \/>\nNote: This is still a MPEG file and not a vcd file, you have to use vcdimager below to create a vcd file to burn to disk.<\/p>\n<p>PAL Divx 3 avi file to NTSC vcd<\/p>\n<p>Thanks to Marc for this<\/p>\n<pre class=\"consoleoutput\">\r\nffmpeg -i FILE.AVI -b 1150 -r 29.97 -s 352x240 -aspect 16:9 -vcodec mpeg1video -f mpegvideo FILE-NTSC.mpeg\r\n<\/pre>\n<p>If MPEG file is bigger than 700MB<\/p>\n<p>If the MPeg file is over the maximum size of the cd, then I use the program mencoder from <a href=\"http:\/\/www.mplayerhq.hu\/homepage\" target=\"_blank\">MPlayer<\/a>.  With the options as below<\/p>\n<pre class=\"consoleoutput\">\r\nmencoder -oac copy -ovc copy INPUT.FILE -o OUTPUT.FILE -endpos 670mb\r\n<\/pre>\n<p>At the end of the copy it should say the frame that the mencoder finished on for the first file. Place that value in the line below (in the VALUE) to create the second value.<br \/>\nI usally subtract about 10 frames just to make sure.<\/p>\n<pre class=\"consoleoutput\">\r\nmencoder -oac copy -ovc copy INPUT.FILE -o OUTPUT2.FILE -ss VALUE\r\n<\/pre>\n<p>Both of the files, INPUT &#038; OUTPUT are mpeg files<\/p>\n<p>This will create a MPEG file ready to be either watched or converted again into the VCD format and then burned.<\/p>\n<p>Hope that helps, and this also servers as a reminder to me \ud83d\ude42<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This shall serve as a reminder for myself and may help others. There is different versions of audio conversion, CBR (Constant Bit Rate) and VBR (Variable Bit Rate), it seems that many DVD players perfer the CBR. Below is both versions with links to the relevant programs and example command lines. CBR VBR CBR AVI-MPEG &hellip; <a href=\"https:\/\/www.codingfriends.com\/index.php\/2009\/07\/29\/how-to-convert-avi-mpeg-to-vcd\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">How to convert AVI-MPEG to VCD<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[32],"tags":[34,33,398,35],"class_list":["post-312","post","type-post","status-publish","format-standard","hentry","category-video","tag-avi","tag-dvd","tag-linux","tag-vcd"],"_links":{"self":[{"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/posts\/312","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/comments?post=312"}],"version-history":[{"count":2,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/posts\/312\/revisions"}],"predecessor-version":[{"id":314,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/posts\/312\/revisions\/314"}],"wp:attachment":[{"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/media?parent=312"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/categories?post=312"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.codingfriends.com\/index.php\/wp-json\/wp\/v2\/tags?post=312"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}