[vlc-devel] [PATCH] Vovoid VSXu audio visualization integration
Jonatan Wallmander
jonatan at vovoid.com
Mon Mar 12 22:45:16 CET 2012
Added visualization plugin using Vovoid VSXu - real time graphics
modular programming language
http://www.vsxu.com
Since VSXu isn't packaged into any binary Linux distributions yet, to
build it you need to build it yourself (for windows also obviously).
For simplicity - use VSXu's build scripts:
https://github.com/vovoid/vsxu-build
(put this in ~/vsxu/build )
And the actual source code of VSXu (use master branch):
https://github.com/vovoid/vsxu
(put into ~/vsxu/vsxu )
Then go:
cd ~/vsxu/build
cd linux64 (or linux32)
./prepare (if you actually want to install, use ./prepare_usr)
cd build
make -j4
make install
export LD_LIBRARY_PATH=/home/$USER/vsxu/build/linux64/install/lib/
export PKG_CONFIG_PATH=/home/$USER/vsxu/build/linux64/install/lib/pkgconfig
(there are also build scripts/examples for win32/win64 for compilation
with mingw-w64)
Then VLC should find it and compile happily.
Some general comments about the implementation/integration:
To accomplish this, I wrote a cyclic buffer class for interim storage of
audio fragments as I found out that the Project M implementation (which
I forked) receives audio 0.3-0.4 seconds out of sync (ahead of time;
may vary for you), using PTS values sent via block_t.i_pts.
Synchronization really makes or breaks a music visual. If you want to
test audio sync with visuals, use this file:
https://github.com/vovoid/vsxu/blob/master/tests/audio/latency_test.mp3
(series of 880Hz beeps)
If there's a better (VLC) way to do this, I should do/use that instead.
The code is also doing some tricks to keep VSXu getting at least 60
Hz/FPS (512 sample blocks) of audio data so that the visualization is as
exact and dynamic as possible (the concept is: vsxu must have new audio
data every frame, VLC doesn't call its audio filter callback that often).
If and before incorporating this into any vlc package of any kind we
need to go through which visual effects (design-wise) are suitable, this
is out of scope for this commit. This patch thus just adds the code, so
take it for what it is. Feel free to botanize among the visuals
currently in the
vsxu repository, some are quite large and slow to load so those have to
be axed and shipped separately (perhaps as downloadable from our site)
for instance.
/jaw
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Added-support-for-audio-visualization-Vovoid-VSXu.patch
Type: text/x-diff
Size: 21756 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20120312/735062f6/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Cleaned-out-some-debug-printfs.patch
Type: text/x-diff
Size: 4373 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20120312/735062f6/attachment-0001.patch>
More information about the vlc-devel
mailing list