📄 readme
字号:
July 29, 2002 - Dave MackieMP4LIVE =======MP4LIVE is a Linux audio/video capture utility that can capture and encode audio and video in real-time. The results can be written to either an .mp4file, transmitted onto the network via either unicast or multicast, or both simultaneously! The audio is encoded with MP3 or AAC, and the video with MPEG-4 Simple Profile.Please use the MPEG4IP SourceForge site to report problems, suggest enhancements, ask questions, etc. The URL is http://www.sourceforge.net/projects/mpeg4ipChanges in Version 0.9.8========================Major syncronization changes.Changes in Version 0.9.7========================Split out encoder specific information from the base architecture(rtp transmitter, file recorder). This enables easy addition of codecs.Reworked configuration variables.Changes in Version 0.9.5========================Once again, fixes for A/V sync and adapting to encoding speed.Added UI to easily load and save configuration filesSDP now reflects media bandwidthExperimental file sources is removed.Hardware Requirements=====================Pentium III class machine of at least 500 MHz (Pentium IV class machine at 2 GHz is very nice.)Note systems vary quite a bit in their video capture abilities. For instance,I have a name brand 750 MHz PIII that drops frames when pushed to CIF sizesat greater than 15 fps, but I have a no-name clone with a 800 MHz PIII that can encode CIF @ 24 fps no problem.RAM is not typically an issue. I develop on machines with 128 MB, but I believe much smaller configurations would work fine. The real issue is CPU speed.A sound card with an OSS compatible driver and capture ability.A video device with a video4linux (v4l) compatible driver and memory mapped capture ability.Known to work are: Video capture cards based on the Brooktree 8x8 chip with an analog A/V source - VCR, DVD, Camcorder, Settop box, Tivo, etc. Typically a video capture card will support composite video inputs. Some will also have S-Video input. Others will also have a TV Tuner input. Logitech Quickcam Express WebcamNote on multi-processor machines (SMP): mp4live is multithreaded at a coarselevel. Specifically the video encoder, audio encoder, file recorder, networktransmitter, and user interface each have their own thread. Unfortunately forowners of multiprocessor machines, the video encoder thread dominates the computational requirements so one CPU will be very busy, and the others willbe lightly to moderately loaded. For those looking for a project, a multi-threaded video encoder would certainly provide an interesting challenge.Software Requirements=====================Linux with a 2.4 or later kernel (My development was done on RedHat 7.X)Drivers for sound and video devices bttv 0.7 or later video capture driver (Included with RedHat 7.1 and later) qce webcam driverWARNINGS!=========Please see the MPEG4IP README regarding legal issues, and the list of open source packages that are redistributed with this code.This is a LINUX program! Do not even think about trying to get this to run on Windows! Even moving it to other UNIX systems would require some re-programming since the sound and video capture interfaces are Linux specific.By far the easiest route is to use a Linux distribution that already has a2.4 kernel, the bttv driver, and the associated i2c module built into it.I've hacked kernels before, and I'm not sure I could sucessfully follow the instructions in the bttv driver as to how to configure a kernel so that it would work. Caveat emptor!I've had many headaches with sound cards under Linux. Before you start using mp4live, please make sure you're able to playback and record with your sound card!You should definitely increase the number of capture buffers for the bttv driver. This reduces the chance of dropping video frames due to transientdelays in the system. By default bttv uses 2 buffers. You can increase this by editting /etc/modules.conf and adding the line "add options bttv gbuffers=32"at the end of the file. The value 32 is my recommendation but you can experiment with other values if you are so inclined.Tips====I suggest you disable any fancy, computationally intensive screensavers when using mp4live to capture long programs. Along the same lines, don'trun any programs that make large resource demands (CPU, bus, disk, network)while mp4live is running.If you're capturing large video image sizes, then you may be able to boostthe encoded video frame rate by disabling video preview. In general, onceyou've got the system working, disabling preview is a good idea.The AAC audio encoder is noticeably slower than the MP3 audio encoder so you will see lower video frame rates and greater sensitivity to CPU load if you are using AAC.Linux supports the POSIX soft real-time extensions and mp4live will attemptto use these to give it priority over non-real time processes. Typicallythese calls can only be made by processes with root privileges, so you maywant to run mp4live as root for this reason.If you have the latest version of OSS, you have a chance of detectingaudio overruns. That, in combination with the latest version andworking on a fast machine will give fairly good lip syncronization up toabout the hour mark running 90% of the CPU.Building and Installing=======================See the MPEG4IP README for general notes about the build environment. Assuming you've already done a build at the top level of mpeg4ip, andyou're on a Linux system then mp4live should be built and waiting for youin this directory. If you've done a top level 'make install', the mp4livewill be installed into '/usr/local/bin'. Of course, you can also issue 'make' and 'make install' from this directory as well.Using mp4live=============Typically, there is no need for command line options to mp4live. You canjust type 'mp4live' and you'll be up and running.If you change an mp4live configuration setting, then that change will be saved in your home directory in ~/.mp4live_rc. This file is read when mp4live is started, and the configuration settings adjusted accordingly.The default settings for mp4live are to record 1 minute of audio and videoto an mp4 file, ./capture.mp4 The first time you use the program, it'sa good idea to just hit the Start button, and see what happens. If allgoes well, 1 minute later you have a playable/streamable mp4 file. If youdon't get this, then it's time to review this README, and it that doesn'thelp, then fire off a message on the MPEG4IP SourceForge discussion group.Assuming things are working you can now use the Settings buttons to adjustthings like the video size and frame rate, the audio sampling rate, the encoded bitrates, etc. The UI is hopefully self-explanatory. If not, let usknow what's confusing and we'll look at fixing that. (I'm a big believer thatif you need to read a document to use a UI, then the UI is broken and shouldbe fixed. Of course, as I've re-learned many times, what is obvious and naturalto me, isn't always to other people.)If you're capturing video that uses "widescreen" or "letterbox" format, it's a big win to change the "Aspect Ratio" in the Video Settings. This will cause the video to be automatically cropped so you don't waste precious CPU time encoding the empty black bars at the top and bottom of the screen. The capture cards will always try to capture frame rates based on whatthe setting of the video card is (either NTSC or PAL).The default is to assume that the video driver is going to capture closeto the correct frame rate of 29.97 for NTSC, 25 for PAL. If you don't think that this is working quite right, try the "videoTimestampCache=0"to the .mp4live_rc before you start. (This may be the case with usb
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -