Click here for more information. Build the ffmpeg Development Environment on Ubuntu10.04 and compile and run it. For details, refer to: Installing Yasm, x.264, Lame, libvpx in sequence; and 2. Installing ffm by referring to (2 ).
Click here for more information. Build the ffmpeg development environment and compile and run it on Ubuntu10.04. For details, refer:
- Http://www.linuxidc.com/Linux/2013-04/83108.htm
- Http://www.linuxidc.com/Linux/2013-04/83109.htm
1. Install Yasm, x.264, Lame, and libvpx in sequence with reference to (1;
2. See (2) install ffmpeg, libavcodec-dev, libswscale-dev, libx264-dev;
3. Modify/usr/include/libavutil/common. h by referring to (2) and add the following content.
# Ifndef UINT64_C
# Define UINT64_C (value) _ CONCAT (value, ULL)
# Endif
4. Modify shower. cpp in the sunkwei source code file to block the original four lines of code, and then add a line of code as follows:
Int got; // modify it from here
// Block the AVPacket pkt of the Bank;
// Block the row pkt. data = buf;
// Block the row pkt. size = rc;
// Block the int ret = avcodec_decode_video2 (dec, frame, & got, & pkt );
Int ret = avcodec_decode_video (dec, frame, & got, buf, rc );
// Modify it to this row, and the code below does not move
If (ret> 0 & got ){
The reason for the modification is that the ffmpeg version is different. The Library version I installed with apt-get install libavcodec-dev is lower than that used by the source code author. In my library, avccodec_decode_video2 is not used, and only avccodec_decode_video.
After the modification is complete, go to the source code directory and make it. The compilation result is displayed successfully. Run the command to check the effect.
For more information about Ubuntu, see Ubuntu special page http://www.linuxidc.com/topicnews.aspx? Tid = 2