DS9 backend: reading an audio cd + Patch
Tanguy Krotoff
tkrotoff at gmail.com
Mon Dec 1 17:05:49 CET 2008
On Mon, Dec 1, 2008 at 10:30 AM, Thierry Bastian
<thierry.bastian at trolltech.com> wrote:
> Hi,
> I was talking about cdaudio.diff.
> The other one doesn't fully make sense to me since you have everything you
> need in the mediacontroller title interface. Or did I miss something?
True, my mistake, I was more thinking under Windows about the
D:/Track05.cda thing since in my mind MediaController was done more
for DVDs and VCDs.
So I guess the right way to deal with D:/Track05.cda under Windows would be:
//Drag&drop "D:/Track05.cda", parse it and get all the needed infos
MediaObject * mediaObject = new...
MediaController * mediaController = new...
mediaController->setCurrentTitle(5); //In the case of an audio cd,
title is in fact a track, let's go for track number 5
mediaObject->setCurrentSource(MediaSource(Phonon::Cd, "D:/"));
mediaObject->play();
For the MPlayer backend, it will simply run "mplayer.exe cdda://5
-cdrom-device = "D:/""
For the cdaudio.diff I can commit it with my KDE account tkrotoff if
you agree, it will be my first commit on KDE svn \o/
Also I have noticed 2 other things inside the DS9 CMakeLists.txt:
- find_package(OPENGL... should be written find_package(OpenGL...
I guess it works under Windows/VC++ since Windows is not case
sensitive. It might give some troubles if somebody wants to compile it
using Cygwin.
- The ConfigureChecks.cmake is not the "clean" way to detect
DirectShow, a more "CMake" approach would be to create a
FindDirectX.cmake
+ ConfigureChecks.cmake assumes that $ENV{DXSDK_DIR} is defined which
is not always the case. My Visual Studio 2008/DirectX SDK clean setup
(not the Express Edition) does not define DXSDK_DIR.
I have created a FindDirectX.cmake here:
http://code.google.com/p/phonon-vlc-mplayer/source/browse/trunk/cmake/modules/FindDirectX.cmake?r=498
which is far from being perfect and over complex (I have almost no
DirectX knowledge). (There is more FindDirectX.cmake on Google)
By creating a FindDirectX.cmake, it can be integrated into CMake, used
and improved by other CMake users.
I know that Trolltech/Nokia is not a fan of CMake :) but still if you
agree, I can provide you a patch
--
Tanguy Krotoff <tkrotoff at gmail.com>
+33 6 68 42 70 24
More information about the Phonon-backends
mailing list