Mp4v2 porting and brief introduction of MP4 video recording library under embedded Linux

Source: Internet
Author: User
Tags locale

*************************************************************************************************************** ************
Easywave Time: 2014.10.31

Category: Linux application-mp4 video recording library mp4v2 transplant experience and brief introduction statement: Reprint. Please keep the link

Note: If there is an error, please correct me.

These are the journal articles I studied ...

*************************************************************************************************************** ************

A: Mp4v2 Library simple Introduction

Mp4v2 's predecessor was a feature library in the Mpeg4ip Open source project, but today MPEG4IP is no longer updated. But Mp4v2 is still in the update, and independent out. MP4V2 is primarily an open source library that is recorded as a MP4 file. For example, see the following:


MPEG4IP provides an end-to-end system for the transmission of audio and video streams. Support for different encoding formats including mpeg4/h.261/mpeg2/h.263 MP3/AAC/AMR. Today's Google-related code.google.com can't be opened, so it's only good to offer the following. For example, see the following: Https://launchpad.net/ubuntu/+source/mp4v2



II: Compilation of MP4V2

To compile mp4v2 under Linux, we first need to configure which options, we can see through the Configure. Run./configure--help will be able to. For example, see the following:

/work/prj/mp4v2/mp4v2-2.0.0$./configure--help ' Configure ' configures Mp4v2 2.0.0 to adapt to many kinds of systems. Usage:./configure [OPTION] ... [Var=value] ...  To assign environment variables (e.g., CC, CFLAGS ...), specify them asvar=value. See below for descriptions of some of the useful variables. Defaults for the options is specified in brackets. Configuration:-H,--help display this Help and exit--help=short display options specific to th Is package--help=recursive display the short help of all the included Packages-v,--version display V Ersion information and Exit-q,--quiet,--silent do not print ' checking ... ' Messages--cache-file=file cache Te St results in FILE [disabled]-C,--config-cache alias for '--cache-file=config.cache '-N,--no-create do n OT Create output files--srcdir=dir find the sources in dir [Configure DIR or ' ... '] Installation directories:--prefix=prefix Install Architecture-independent files in PREFIX [/usr/local]--exec-prefix=eprefix install Architecture-de pendent files in Eprefix [prefix]by default, ' make install ' would install all the files in '/usr/lo  Cal/bin ', '/usr/local/lib ' etc. You can Specifyan installation prefix other than '/usr/local ' using '--prefix ', for instance '--prefix= $HOME '. For better control, use the options below.           Fine tuning of the installation directories:--bindir=dir user executables [Eprefix/bin]--sbindir=dir System admin Executables [Eprefix/sbin]--libexecdir=dir program executables [eprefix/libexec]--sysconfdir=d IR read-only single-machine data [prefix/etc]--sharedstatedir=dir modifiable architecture-independent data [PR Efix/com]--localstatedir=dir modifiable single-machine data [Prefix/var]--libdir=dir object code Librar ies [eprefix/lib]--includedir=dir C header files [prefix/include]--oldincLudedir=dir C header files for NON-GCC [/usr/include]--datarootdir=dir read-only arch.-independent data root [  Prefix/share]--datadir=dir read-only architecture-independent data [Datarootdir]--infodir=dir Info            Documentation [DATAROOTDIR/INFO]--localedir=dir locale-dependent data [Datarootdir/locale]--mandir=DIR Man documentation [Datarootdir/man]--docdir=dir documentation root [datarootdir/doc/mp4v2]--htmldir=di R HTML documentation [DOCDIR]--dvidir=dir DVI documentation [DOCDIR]--pdfdir=dir PDF D            ocumentation [Docdir]--psdir=dir PS documentation [Docdir]program names:--program-prefix=prefix Prepend PREFIX to Installed program names--program-suffix=suffix append suffix to Installed program names-  -program-transform-name=program run SED program on installed program Namessystem types:--build=build Configure for Building on BUILD [guesSED]--host=host cross-compile to build programs to run on host [build]optional Features:--disable-option-checkin G Ignore unrecognized--enable/--with options--disable-feature do not include FEATURE (same as--enable-feature=n o)--enable-feature[=arg] include FEATURE [arg=yes]--disable-debug disable debugging compilation--disable-op Timize Disable optimizing compilation--disable-fvisibility disable use of-fvisibility--disable-gch D isable GCC precompiled-headers--disable-largefile Disable LFS (large file support)--disable-util disable Build of command-line utilities--enable-bi=arch Enable-march for Bi-arch compilation--enable-ub[=archs] En Able-arch Arch for Universal-binaries (OSX only)--enable-cygwin-win32 when building with Cygwin Use-mwin32--enable -mingw-threads when building with MinGW use-mthreads--disable-dependency-tracking speeds up one-time build--enable- Dependency-tracking do Not reject slow dependency extractors--enable-shared[=pkgs] Build shared libraries [Default=yes]--enable-static[=pkg S] Build static libraries [Default=yes]--enable-fast-install[=pkgs] optimize for fast Installa tion [Default=yes]--disable-libtool-lock avoid locking (might break parallel builds) Optional Packages:--with-package[              =ARG] Use package [Arg=yes]--without-package does not use the package (same as--with-package=no)--with-pic Try to use only Pic/non-pic objects [Default=use both]--with-gnu-ld assume the    C compiler uses GNU LD [default=no]some influential environment Variables:cxx C + + compiler command Cxxflags C + + compiler flags LDFLAGS linker flags, e.g.-l<lib dir> if you had libraries in a nonstandard D Irectory <lib dir> LIBS libraries to pass to the linker, e.g.-l<library> cppflags (Objective) C/ + + preprocessor flags, E. G.-i<include dir> If you had headers in a nonstandard directory <include dir> CC c c  Ompiler command CFLAGS C compiler flags CPP C preprocessor cxxcpp C + + preprocessoruse these variables To override the choices made by ' configure ' or to Helpit to find libraries and programs with nonstandard names/locations. Report bugs to <[email protected]>.
There are too many options to choose from. I have provided a build.sh script, please follow the inside of the configuration to do just fine. Just need to note is:--disable-optimize, assuming--enable-optimize after. Mp4v2 compiled out of the library will be much less, otherwise mp4v2 library will be larger, the detailed trade-offs to see oneself to think, here do not pull this. The build.sh script file looks like the following:


Just execute the./build.sh script will be self-initiated to compile and install, after the successful compilation, will be generated in the _install folder, such as the following folder. For example, see the following:


See if there are mp4v2 libraries under the Lib folder, such as the following:


To know how to use this library, you can take a look at the application code under the Util folder, such as the following:


Specific applications need to see their own, it may be used in a practical project. There is no specific description of how to use it here.


Mp4v2 porting and brief introduction of MP4 video recording library under embedded Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.