avi, mpeg, wmv, mov encoder

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
มีใครพอทราบโปรแกรมที่สามารถแปลงไฟล์วีดีโอประเภทต่าง ๆ เช่น avi, mpeg, mpg, mov เป็น wmv ได้มั่งครับ ขอบคุณครับ
รูปภาพของ taz
taz
Rating 10
Posts: 1154
Joined: 02-12-2002
avi, mpeg, wmv, mov encoder

wmv มันเป็น codecของ win ไม่รู้มีคนทำ โปรแกรมแปลงไว้หรือเปล่าแต่พวกโปรแกรมแปลง format อื่นมีเยอะเหมือนกันครับแนะนำ2 ตัว
ffmpeg (TLE มีให้ apt)
กับ
vcdgear http://www.vcdgear.com/download.html
vcdgear มีทั้งบน win และ linux ลองความสามารถหลายอย่างแล้ว linux ใช้งานได้เร็วกว่า win มาก format ที่แปลงได้ของ vcdgear
[code:1:06b89a9e60]
Options:
-cue2raw -cif2mpg -mpg2bin -bin2mpg
-cue2dat -mpg2mpg -cif2bin -toc2mpg
-cue2mpg -nrg2mpg -nrg2bin -mpg2toc
-raw2dat -mpg2dat -sfd2mpg
-raw2mpg -dat2mpg
[/code:1:06b89a9e60]

--

=Read The Fxxx Manual _| ̄|○

Don't Learn to HACK - Hack to LEARN

ถ้าไม่รู้ว่า RTFM คืออะไรให้ไปอ่าน ถามอย่างไรจึงจะได้คำตอบ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

ขอบคุณมากครับ ลองดูแล้วแต่แย่จังที่ใช้ไม่เป็น พอทราบแหล่งหรือหนังสืออ่านแนะนำวิธีใช้ไม๊ครับ
ffmpeg ผมได้ลงแล้วโดยใช้ synaptic ขอบคุณครับ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

สิืบเนื่องจากคราวที่แล้ว ผมก็ยังไม่มีความสามารถมากพอที่จะแปลง avi เป็น mpg ได้อยู่ดี ไม่ว่าจะใช้ ดาวน์โหลด ffmpeg มาลง หรือดาวน์โหลด vcdgear มาที่เครื่องแล้วก็ตามแต่ดันไม่สามารถติดตั้งได้ครับ
มีใครพอทราบวิธีใช้ ffmpeg หรือวิธีการติดตั้งและใช้งาน vcdgear ไม็ครับ แนะนำเป็นหนังสือให้อ่านก็ได้ครับ ขอบคุณครับ

รูปภาพของ audy
audy
Rating 1
Posts: 9
Joined: 28-04-2003
avi, mpeg, wmv, mov encoder

กรณีใช้โปรแกรม vcdgear บนลินุกซ์ เมื่อดาวน์โหลดมาแล้วก็ทำการขยายไฟล์
$tar -zxvf vcdgear176-040415_linux.tar.gz
เมื่อแตกไฟล์แล้วจะได้เป็นไดเรกทอรี vcdgear ก็เข้าไปไดเรกทอรี่นี้
$cd vcdgear
วิธีเรียกใช้งานโปรแกรมก็ทำได้ด้วยการเรียกสคริปต์ แล้วตามด้วยออปชันดังนี้
Options:
-cue2raw -cif2mpg -mpg2bin -bin2mpg
-cue2dat -mpg2mpg -cif2bin -toc2mpg
-cue2mpg -nrg2mpg -nrg2bin -mpg2toc
-raw2dat -mpg2dat -sfd2mpg
-raw2mpg -dat2mpg

ตัวอย่าง:
$./vcdgear -cue2mpg thisvideo.cue videostreams.mpg
$./vcdgear -dat2mpg thisvideo.dat videostreams.mpg

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

ขอบคุณครับ ถามต่ออีกนิด ถ้าเกิดต้องการแปลง avi เป็น mpg ละครับ ต้องใช้ options อะไร
vcdgear ไม่มีกราฟิกโหมดเหรอครับ

รูปภาพของ taz
taz
Rating 10
Posts: 1154
Joined: 02-12-2002
avi, mpeg, wmv, mov encoder

avi mpg คงต้องใช้ ffmpeg วิธี:ใช้ผมก้อใช้ไม่ค่อยเป็นส่วนมากก้อ จะใช้ทีก้อ search google ที ก้อลอง search ตัวอย่างการใช้งานใน google ดูแล้วกัน
vcdgear ไม่มี gui บน linux แต่มี gui บน win ครับ
vcdgear ยังง่ายกว่า ffmpeg เยอะครับ ถ้าดูที่ option แล้ว ถ้า vcdgear ยังถามหา gui ผมว่า ffmpeg คงมีปัญหามากสำครับการใช้งานเพราะตัวนี้ผมยังไ่มเห็น gui ของมัน(หรือมีคนทำไว้แล้วก้อไม่รู้เพราะผมก้อไม่ค่อยได้ใช้เท่าไร)

แต่ถ้าจะพูดถึง โปรแกรม แปลง file หนังแล้ว ของ opensource ดีดีก้อมี Virtual Dub
http://virtualdub.sourceforge.net/
ซึ่ง มีแต่ version window ผมลองไปหาอ่านแล้วคนพัฒนาเค้า เขียนบน Linux ไม่เป็นเลยไม่ทำ version linux ออกมาแล้วก็เขียนอ้างอิงสถาปัตยกรรมหลายอย่างของ Win (code ลึกในระดับ asm)แต่ขอบอกว่า โปรแกรมนี้ดีจริงๆครับลองใช้ดูถ้ามีเครื่อง win ลองนะครับ

--

=Read The Fxxx Manual _| ̄|○

Don't Learn to HACK - Hack to LEARN

ถ้าไม่รู้ว่า RTFM คืออะไรให้ไปอ่าน ถามอย่างไรจึงจะได้คำตอบ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

อือ ฟังแล้วถอดใจ สงสัยต้องลองไปทำในวินโดว์เหมือนเดิม ขอบคุณครับ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

บังเอิญเจอครับ จะลองใช้ดู http://www.designersoft.co.uk/avi_mpeg.html

Linux - How to convert AVI-MPEG/VCD
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

Links to changing a MPEG file into a VCD format and burning.

* VCD
* Burn the VCD

CBR AVI-MPEG

* Transcode (RPM-FIND results)

To convert the avi file into a mpeg file for a PAL 352x288 screen, there is different settings either use the 'man' or goto the Transcode website for viewing the conversion in more detail. The command line that I use is

transcode -i<AVI FILM> -V -y mpeg -F v,1 -E 44100 -b 224 -fps 25 -o <OUTPUTFILENAME>

This generates two files, *.m1v (the video segment) and *.mpa (the audio segment).
The options in the above command line are

* -b Audio bitrate Kbit's
* -E Audio sampling rate (Hz)
* -F codec
* -i input file
* -V use internal video codec (faster but some import modules do not support this)
* -y video, audio export modules.
* -fps Frames per second, 25 is for PAL, 29.97 for NTSC

Joining the OUTPUTFILENAME's together

To join these two segments together

tcmplex -o <OUTPUT.MPG> -i <OUTPUTFILENAME.M1V> -p <OUTPUTFILENAME.MPA> -m v

This will create a MPEG file ready to be either watched or converted again into the VCD format and then burned.

VBR AVI-MPEG

The programs to download/use are obtained from these links

* FFMpeg (RPM-FIND results)

If the AVI file is in MS MPeg4 v3(DIVX3)

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 MPlayer website. To convert to the required file structure use the commands below.
mencoder -ovc lavc -lavcopts vcodec=mpeg4:vhq -oac copy INPUTFILE.AVI -o OUTPUT.AVI

The options produce a mpeg4 version of the input file using the lavc video converter. Also with the option 'vhq', it produces a very high quality output file.
Convert AVI-MPEG

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
ffmpeg -vcd -i INPUT.FILE -b 1150 -s 352x288 -vcodec mpeg1video -f mpegvideo OUTPUT.FILE

The options enable an VCD Mpeg type file output(-vcd) with a bitrate of 1150 (-b) and an output screen size of 352x288 (-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.
Note: 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.
PAL Divx 3 avi file to NTSC vcd

Thanks to Marc for this

ffmpeg -i FILE.AVI -b 1150 -r 29.97 -s 352x240 -aspect 16:9 -vcodec mpeg1video -f mpegvideo FILE-NTSC.mpeg
If MPEG file is bigger than 700MB

If the MPeg file is over the maximum size of the cd, then I use the program mencoder from MPlayer. With the options as below
mencoder -oac copy -ovc copy INPUT.FILE -o OUTPUT.FILE -endpos 670mb

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. I usally subtract about 10 frames just to make sure.
mencoder -oac copy -ovc copy INPUT.FILE -o OUTPUT2.FILE -ss VALUE

Both of the files, INPUT & OUTPUT are mpeg files

This will create a MPEG file ready to be either watched or converted again into the VCD format and then burned.

Hope that helps, and this also servers as a reminder to me :)

If you wish to email me at designersoft.co.uk click here
Last modified: 17/07/2005.

รูปภาพของ จักรนันท์
จักรนันท์
Rating 7
Posts: 551
Joined: 10-12-2004
avi, mpeg, wmv, mov encoder

ffmpeg ยังไม่มี GUI ออกมาดอกครับ เขาเขียนขึ้นมาเพื่อเป็น Command line application และเป็น Libaray เฉยๆ
เพื่อให้คนอื่นเอาไปเขียนเป็น GUI Application มาเรียกใช้งานได้ครับ
ffmpeg มีทั้ง Version ใน DOS และ Linux ครับ
ปกติ ผมจะใช้ mplayer จัดการครับ เพราะ mplayer ก็ไปใช้ ffmpeg engine ได้ และยังใช้ Engine อื่นได้อีกหลายตัวเลย
mplayer mี่ผมกล่าวถึง ไม่ใช่ตัว gmplayer ที่เป็น GUI นะครับ
gmplayer คือตัว GUI ที่เรียก mplayer ทำงานอยู่ข้างหลังครับ แต่คนเขียนเดียวกัน
ก็เหมือนกรณี ffmpeg แหละครับ เพียงแต่ ffmpeg นั่น คนเขียนเขาไม่มีโครงการจะเขียน GUI Applcation มาครอบอีกที
เขาตั้งใจแค่เขียนเป็น Engine ให้คนอื่นมาเอาไปใช้ฟรีๆ เฉยๆ ครับ
ffmpeg มีความสามารถสูงที่สุดเท่าที่ผมเจอบน Linux ครับ

ทีนี้.... การเรียกใช้ ffmpeg เองโดยตรงนั้น ปัญหามันอยู่ที่ว่า
ผู้ใช้ต้องเข้าใจดีเรื่อง Format file ทั้งหลาย และเข้า Structure ทั้งหมด
รวมถึงเข้าใจ Algorythm ของการ Animation ต่างๆ เป็นอย่างดีด้วย
เพราะ ffmpeg จะไม่มีค่า default ใดๆ เลย
ต้องมี Parameter ส่งผ่านเป็นจำนวนมากมาย
จึงทำให้ใช้งานยากมาก สำหรับผู้ที่ไม่เข้าใจดีครับ

เช่น... -codec อย่างเงี้ย...
หมายถึง เราต้องกำหนดว่าจะใช้ codec อะไรในการเข้ารหัสเพื่อให้ได้ไฟล์เป้าหมาย
codec คือ Coder - Decoder library ครับ
หรือ CBR, VBR และอื่นๆ อีก นั่นคือ Parameter กำหนดทั้งนั้น
เราจึงต้องรู้เป้าหมายด้วย เช่นว่า...
ถ้าจะทำเป็น VCD เราก็ต้องรู้ว่าไฟล์ Format mี่จะเขียน VCD ต้องเป็น mpg
และมี fps = 25 คือ 25 Frame ต่อวินาที
ในบ้านเราเป็นแบบ PAL ก็คือ Non-Interlace
ถ้า NTSC ก็ Interlace
และมี Resolution เท่ากับ 352 X 288 ในกรณีที่เป็น PAL
และ 352x288 สำหรับ NTSC

และยังมี.... โอย.... ผมสาธยายไม่ไหวเลยครับ
ผมเองจำได้ไม่หมด แต่จะจำได้เฉพาะ Format ที่ใช้บ่อยๆ
ซึ่งผมใช้บ่อย 3 ตัวคือ mpeg สำหรับ VCD, SVCD และ DVD
เนื่องจากเวลาถ่าย VDO อะไรมา ก็จะมาทำเป็น VCD, SVCD หรือ DVD เสมอๆ
จึงทำให้จำค่างๆ ของ 3 ตัวนี้ได้หมด (อ้อ... เฉพาะ PAL เท่านั้นนะ NTSC ก็จำได้นิดหน่อย เพราะโทรทัศน์บ้านเราเป็น PAL)

ดังนั้น กรณี Format อื่นอย่าง wmv ผมจึงไม่ทราบ ยังไม่เคยค้นคว้าหาเลยว่า wmv มันเป็นอย่างไรบ้าง
แต่ ffmpeg ทำได้แน่นอน

แล้วที่ผมมาเล่าให้อ่านนี่ คืออะไรกันหรือ?...

ผมมาบอกเพื่อเป็น Guide line ให้เข้าใจว่า ffmpeg คืออะไร
และคุณต้องหา Know how อะไรเพิ่มเติมบ้าง เพื่อจะมาป้อนให้ ffmpeg เพื่อให้ได้ผลอย่างที่ต้องการไงครับ

อีก Trick หนึ่งคือ ลองใช้ mplayer ดูครับ ง่ายกว่า
ผมมี Codec สำหรับ mplayer ไว้เพียบ หรือจะไป D/L เองก็ได้ที่...

http://www.mplayerhq.hu/homepage/design7/dload.html

จะได้ Codec เพียบมากมาย ซึ่งทำให้ mplayer คุณรู้จัก File format มากขึ้น
ส่งผลไปถึง Mozilla และ Firefox จะสามารถเล่นไฟล์บน Internet ได้มากขึ้นด้วยครับ
เพราะ gmplayer จะได้กุศลไปด้วย ซึ่ง gmplayer มัน Plug-in กับ Mozilla/Firefox อยู่แล้ว

ทีนี้... mplayer เนี่ย ง่ายขึ้นก็จริง... แต่ไม่มากนักดอกครับ
ก็ยังต้องใช้ Knowledge base ไม่แพ้ ffmpeg เลย
แต่ก็ยังต้องการ Parameter พอสมควร (อย่างน้อยก็ 4-5 ตัวล่ะ)
เพียงแต่ บางค่ามันจะ fix ให้เลย (คือมี default ให้) ไม่ต้องส่งผ่านก็ได้
ผลงานที่ได้จึงอยู่ในระดับดี เพราะค่าอื่นๆ ที่ Default ให้จะเป็นระดับดี
ถ้าจะให้ดีที่สุก ก็ต้องกำหนดเองหมดเหมือนกัน
เพราะยังไงมันก็ต้องไป Execute ให้ codec จัดการให้อยู่ดีครับ

วันนี้ขอโม้แค่นี้ก่อนแล้วกันนะครับ
ดึกแล้ว... บายล่ะครับ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

ตอนนี้ผมกำลังพยายามติดตั้งตัว mplayer โดยใช้ synaptic ครับ ไม่ทราบว่าวิธีการเรียกใช้ ffmpegเพื่อแปลง
ไฟล์ต้องทำยังไงเหรอครับ

ปล. นึกว่าต้องกลับไปใช้ winavi ในวินโดว์อย่างเดิมแล้วซิ

รูปภาพของ yongyoot
yongyoot
Rating 2
Posts: 25
Joined: 26-07-2005
avi, mpeg, wmv, mov encoder

ในที่สุดก็เจอที่ต้องการครับ
เผื่อเพื่อน ๆ พี่ ๆ จะมีปัญหาเดียวกัน http://encode2mpeg.sourceforge.net/encode2mpeg.html

โชคดีครับ

รูปภาพของ taz
taz
Rating 10
Posts: 1154
Joined: 02-12-2002
avi, mpeg, wmv, mov encoder

ใช่อย่างคุณ จักรนันท์ พูดครับ การแปลง file vdo format ใน linux ผู้ใช้ต้องรู้ codec ของ file ที่เราจะเปลงก่อนไม่งั้นมันจะแปลงไม่ถูก ผมมีวิธีดูว่า fileนั้นใช้ code อะไรง่ายๆมาแนะครับ
ใช้ mplayer command line ในการหา สั่ง
mplayer vdo_file.xxx แล้วแต่ว่าจะหา file ไหนก้อสั่ง ไปเลยครับ
สั่งเสร็จกด ออกจาก โปรแกรมเลย(กด q) แล้ว ไล่ดู message report ที่ mplayer บอกจะมีบอก codec ให้ด้วยครับว่า file นั้นใช้ codec อะไร
ที่ห่วงตรงนี้คือห่วงว่า avi file ที่คุณได้มาก่อนแปลงมันจะเป็น divx แล้วมันจะไปใช้กะโปรแกรมที่แปลงพวก avi 1-2 ไม่ได้หนะครับ

--

=Read The Fxxx Manual _| ̄|○

Don't Learn to HACK - Hack to LEARN

ถ้าไม่รู้ว่า RTFM คืออะไรให้ไปอ่าน ถามอย่างไรจึงจะได้คำตอบ

รูปภาพของ wd
wd
Rating 2
Posts: 63
Joined: 04-02-2005
avi, mpeg, wmv, mov encoder

ผมใช้ kino ครับ ใช้ทั้ง capture, ตัดต่อ แล้วก็ export เป็น mpeg
หลังจากนั้นก็ส่งต่อให้ frontend ของ dvdauthor เขียนแผ่น
ไม่ต้องใช้ windows เลยครับ
(ขออภัย ตอบผิดคำถาม ไม่ทันอ่านให้ดีเสียก่อน)

Syndicate content