Keyword - Building

Entries feed - Comments feed

Saturday, May 23 2009

Want to include vlc in your Qt application?

Qt and VLC

Well, we have a very easy howto for you: libVLC in Qt .

This will output the video inside the widget that you want using QWidget::winId() method.

This has been tested on Linux and Windows, using libVLC 0.9.9.

Need

If you can't build your application easily, remember to install libvlc-dev or to use the SDK for windows from the .zip files of the releases!

Participate

Don't hesitate to complete this!

Thursday, April 30 2009

VLC and IDE

I receive many questions about using an IDE to build VLC.

Usually, the answer is VIM. But I will try to introduce something else today.

Needs

Yeah, VIM is TEH awesome, but sometimes we would like more. But usually, more is slow, incomplete and boring...

Would you want an editor with:

  • VIM syntax and command,
  • Completion that is faster than the one from Eclipse
  • Git inclusion
  • Doesn't eat all your RAM
  • Debuggueur and step-by-step+breakpoints integration like MSVC?

I guess so!

Believe it or not, there is a solution: QtCreator from Nokia/QtSoftware that I have tested to work with VLC.

Even if you don't think this will be useful for you, at least read in diagonale the following post.

Installation

  • Take QtCreator 1.1 (don't take older versions, they won't fit for VLC, or the VIM part will suck...)
   `apt-get install qtcreator` in Debian/Sid
  • Take Qt4.5.1 (I mean it, Qt 4.5.0 is buggy!)

Setup

General Setup

  • Run QtCreator and launch Tools->options
    • Activate FakeVim and set ShiftWidth to 4
    • Text Editor->Behaviour, set Tab size at 4
    • Text Editor->Display, enable Text Wrapping and display right margin, and if you like Alexis' vim, Visualize whitespace
    • Text Editor, change the colour schemes to match you old editor ;)
  • Save options.

VLC Setup

For the example, I assume that you build your vlc in a "build" subdir of the source (as xtophe usually gives advice)

 * File->New
   Select 'Import of Makefile-based Project'
   -
   Project Name 'VLC'
   Location '/home/you/vlc' and Choose, Next
   -
   Let it process... It should take around 1minute
   Finish.
  • EXIT QtCreator... I MEAN it.

Setup Indexation

QtCreator will have done VLC.includes VLC.creator, VLC.files and a VLC.config in your vlc/ folder.

Overwrite the VLC.includes and the VLC.files with the one you can find:

Doing this will gain you some time. Those could be auto-generated one day, I guess...

Setup Build

Relaunch QtCreator

  • Select Projects (on the left) and select VLC on the list
  • Build Settings,
    • Change Build directory to /home/you/vlc/build, using browse
  • Run Settings,
    • Add a custom Executable with the blue '+'
    • Name it VLC, browse to /home/you/vlc/build/vlc for Executable
    • Put -Iqt in Arguments
  • Click on Edit on the left. You should see VLC with most useful files.

Build VLC and launch it.

  • In the Menu, Build and Build All, you should see the Compilation output on the bottom (or by clicking on the left build progressbar)
  • In the same menu, Build and Run it, and VLC will launch directly, outputting everything in the Application output.

Cool. But that was just a minimum...

Using it like VIM: Good!

Open modules/codec/avcodec/audio.c from the file browser and see... You are using VIM commands to control. You have Visual, Edit and all usual VIM modes!

  • Completion is triggered with Ctrl+Space and will give you a list. If there is no ambiguition, it is filled.
  • . and -> triggers the list of the members of the struct or the class by default.
  • After function completions, it will give the type of the arguments.
  • F2 will give you access to the function definition where your mouse is.

Debugging it: awesome!

  • You can put breakpoints in the margins near the line numbers. (Like in modules/gui/qt4/main_interface.cpp:100 and 108)
  • Now re run it using debug running.

It will stop at your breakpoint and you will have the function call lists (and line numbers) but also pointers values (like p_intf, and this in main_interface.cpp) http://people.videolan.org/~jb/QtCreator/VLC_Qt_Creator.png

You can, of course Step In, Step Into and Step Out, resume or stop the code

More coolness:

Locate

Use the locate search box to find quick declarations: 'm vlc_object_act' will help you to go quickly to the method declaration, etc...

Git

Use the Git menu to checkout from within QtCreator.

Nota Bene

The indexing shouldn't be too long, but could be a bit longer the first time you launch the project!

Have fun!

Tuesday, March 3 2009

Howto build VLC 1.0.0-git in Ubuntu in less than 5 commands.

Since building VLC is easier and easier now, I am compelled to improve my HOWTOS. Here is one for Ubuntu, that can easily adapt to Debian.

This is not a complete and detailed post, but just a summary. If you need more details, take the Build on Intrepid HOWTO.

Get all you need

sudo apt-get build-dep vlc && sudo apt-get install libtool build-essential automake1.10 git-core

Get the source

git clone git://git.videolan.org/vlc.git

Go

cd vlc && ./bootstrap

mkdir build && cd build && ../configure --disable-nls --enable-qt4

make

Done.

Wednesday, November 26 2008

Build VLC media player under Ubuntu Intrepid

This post is an update of the popular howto for Build VLC with feisty and Build VLC with hardy.

Those articles are always popular on my blog, so here is an update.

Continue reading...

Monday, February 4 2008

VLC: misc and builds

Just some miscellaneous news about VLC and build systems:

  • Tree Cleaning: we decided to clean the tree of all the not really necessaries folder that are around now. See the wiki.
  • There is some experiments to build VLC using CMake inside the main tree. Checkout the latest VLC to test it.
  • Windows nightly builds are back after the big changes in the building and in the config.h changes.
  • New contribs with updated 3rd party libraries are done for windows.
  • Windows CE and Symbian port are advancing... Not yet released, and ETA is really unknown.
  • Roadmap are changing, more about that soon.

Friday, December 14 2007

Configure-step in VLC building.

Idea

VLC can be built with a classical process: ./bootstrap; ./configure --options; make

However, since VLC is very modular, not everyone wants the same modules built so the configure line can be very long.

Therefore, I'll try to explain a bit the main configure options and give a few examples.

Configure

./configure

General and Developers options

--prefix=/usr \
--host= \
--build= \

--enable-debug | --enable-release # Choose the mode you want

--enable-optimizations            # Optimisations are good idea
--enable-sse --enable-mmx         # for releases

--enable-optimize-memory          # Smaller memory for less perf

--enable-cprof --enable-gprof     # Profiling
--enable-fast-install             # Libtool

--enable-testsuite                # If you want the tests to be built

--enable-static                   # Static libraries
--enable-shared                   # Shared libraries
--with-words                      # Endianess

Main VLC options

--enable-vlm                      # VLC Manager
--enable-visual                   # Visualisations
--enable-update-check             # Check the updates?
--enable-sout                     # Streaming Server
--enable-snapshot                 # Create VIdeo Snapshots
--enable-lua                      # Script VLC

--enable-freetype --enable-fribidi # No Need to disable this
--enable-nls --enable-libxml2      # or that.

Codecs

--enable-a52 [--with-a52-fixed]   # AC-3
--enable-dirac
--enable-faad                     # MPEG-4 Audio
--enable-fluidsynth               # Midi
--enable-mpc                      # Musepack Audio
--enable-real                     # Real Audio
--enable-loader                   # DirectMediaObject support for WMV
--enable-theora
--enable-twolame                  # MPGA Encoding
--enable-tremor
--enable-x264                     # H.264 Encoding
--enable-vorbis
--enable-speex
--enable-tarkin
--enable-zvbi | --enable-telx     # Teletext support
--enable-dca                      # DTS
--enable-flac
--enable-ffmpeg                   # lots of codecs
[--with-ffmpeg-a52 --with-ffmpeg-mp3lame --with-ffmpeg-zlib --with-ffmpeg-amrnb --with-ffmpeg-amrwb --with-ffmpeg-faac --with-ffmpeg-theora --with-ffmpeg-vorbis ]
--enable-libmpeg2
--enable-mad                      # Mpga decoding

--enable-png
--enable-svg
--enable-sdl-image

Video Outputs

--enable-xvideo                     # Linux
--enable-xinerama
--enable-x11
--enable-glx
--enable-directfb

--enable-wingdi                     # Win32
--enable-directx

--enable-opengl                     # All
--enable-sdl
--enable-caca
--enable-aa

Audio outputs

--enable-alsa                       # Unix
--enable-arts
--enable-esd
--enable-jack
--enable-portaudio
--enable-hd1000a
--enable-oss

--enable-waveout                    # Windows

Access

--enable-screen                     # Desktop record

--enable-bda                        # DVB for windows
--enable-dshow                      # DirectShow device

--enable-v4l                        # video 4 linux
--enable-v4l2                       # video 4 linux 2
--enable-dvb                        # DVB for Linux
--enable-pvr                        # PVR/IVTV
--enable-dv                         # DV support

--enable-gnutls                     # Encrypted streams
--enable-gnomevfs                   # Gnome VFS-
--enable-smb                        # Samba/Windows shares
--enable-cdda | --enable-cddax      # CD Audio
--enable-dvdnav                     # DVD video
--enable-vcd | --enable-vcdx        # VCD
--enable-dc1394                     # 1394 support
--enable-hal
--enable-live555 --enable-realrtsp  # RTSP

--enable-bonjour --enable-cyberlink # Various Service discoveries
--enable-upnp                       #

demux

--enable-mkv                        # Matroska
--enable-mod                        # ModPlug (instruments)
--enable-ogg                        # Ogg
--enable-gme                        # GME videogames

interface

--enable-qnx                        # QNX platform
--enable-qt4                        # Default interface in Qt4
--enable-qte                        # QTE/Opie interface
--enable-skins2                     # skins2
--enable-wxwidgets                  # Old default interface in wxWidgets
--enable-xosd                       # OSD interface
--enable-ncurses                    # Ncurses interface
--enable-fbosd                      # FrameBuffer interface
--enable-pda                        # Small gtk interface
--enable-httpd                      # HTTP daemon and interface

--enable-mozilla                    # Mozilla integration
--enable-activex                    # IE and ActiveX integration
--enable-dbus                       # D-Bus control
--enable-dbus-control
--enable-lirc                       # InfraRed Remotes
--enable-java-bindings
--enable-python-bindings

Visualisations

--enable-galaktos --enable-goom

Metadata support

--enable-id3tag                     # metadata using id3tag
--enable-taglib                     # metadata using taglib
--enable-musicbrainz                # Musicbrainz
--enable-libcddb                    # CDDB/FreeDB integration
--enable-libcdio                    # CD-Text

- page 1 of 2