I like to listen to music while programming so i've created a mediaplayer plugin for codeblocks.
It's made after my mediaplayer project https://sourceforge.net/projects/fafnir/ (https://sourceforge.net/projects/fafnir/) with less features.
It can play *.mp3 and *.ogg files. It can load, create and save playlists and some more stuff...
I uploaded the .cbplugin for Windows linked with the latest SVN to
http://sourceforge.net/project/showfiles.php?group_id=258661&package_id=323616 (http://sourceforge.net/project/showfiles.php?group_id=258661&package_id=323616)
The source code is aviable at http://fafnir.svn.sourceforge.net/viewvc/fafnir/Plugin/ (http://fafnir.svn.sourceforge.net/viewvc/fafnir/Plugin/) !
Please read the HowToUse.txt and report any impression/bug/suggestion/question
in this post or at the project page in the forum
https://sourceforge.net/forum/forum.php?forum_id=957228 (https://sourceforge.net/forum/forum.php?forum_id=957228)
PS: Sorry for my bad english!
Greets GeO
cool :)
Quote from: GeO on May 22, 2009, 04:24:19 PM
The source code is aviable at http://fafnir.svn.sourceforge.net/viewvc/fafnir/Plugin/ (http://fafnir.svn.sourceforge.net/viewvc/fafnir/Plugin/) !
Really nice one! :-)
Just a couple of comments:
- I had to link against
libtag.dll and not
libtag.dll.a like setup in the project settings (
libtag.dll.a is not present).
- I had to move "
#include <wx/dcbuffer.h>" in "
SGauge.cpp"
outside the
WX_PRECOMP #ifdef to compile correctly (with wxMSW 2.8.10)
just wanted to try it out.
But it seems it was build with an older sdk ??
However you mentioned build against latest CB svn ...
Quote from: killerbot on May 25, 2009, 12:47:17 PM
But it seems it was build with an older sdk ??
I built it myself - so I don't know. I never trust 3rd party binaries. ;-)
Martin,
Could you attach your windows binary of the dll ?
Or PM it to me ?
Cheers,
Lieven
Quote from: killerbot on May 25, 2009, 01:15:17 PM
Or PM it to me ?
I would but I have a different SDK, too so you would end up in the same trouble. Should I anyways?!
let's try 8)
Quote from: MortenMacFly on May 25, 2009, 07:40:19 AM
Really nice one! :-)
Just a couple of comments:
- I had to link against libtag.dll and not libtag.dll.a like setup in the project settings (libtag.dll.a is not present).
- I had to move "#include <wx/dcbuffer.h>" in "SGauge.cpp" outside the WX_PRECOMP #ifdef to compile correctly (with wxMSW 2.8.10)
Fixed in SVN.
Quote from: killerbot on May 25, 2009, 12:47:17 PM
But it seems it was build with an older sdk ??
In file manifest.xml the SDK version is:
SdkVersion major="1" minor="11" release="12"
I use svn build rev 5604 of Code::Blocks!!
Greets GeO
I tryed to build plugin but got following message:
g++.exe -shared -Wl,--dll -LD:\bin\dev\libs\CB_SDK\devel -LD:\bin\dev\libs\wxWidgets-2.8.7\lib\gcc_dll .objs\GMPlayList.o .objs\GMPlaylistFrm.o .objs\SGauge.o .objs\cbMP.o .objs\wxAudiere.o .objs\GMOctoCtrl.o -o cbMP.dll -Wl,--enable-auto-image-base -Wl,--export-all-symbols -Wl,--add-stdcall-alias -Wl,--enable-auto-import -lcodeblocks -lwxmsw28u MSW_spez\TagLib\libtag.dll MSW_spez\Audiere\audiere.lib
Cannot export audiere_NULL_THUNK_DATA: symbol not found
collect2: ld returned 1 exit status
Do you know why it appears and how to correct it? :?
For me this comand works (using wxWidgets-2.8.10, Codeblocks SVN 5604 and MinGW 4.3.3-tdm)!
g++.exe -shared -Wl,--dll -LC:\Programme\CodeBlocks\src\devel -LC:\Programme\wxWidgets-2.8.10\lib\gcc_dll
.objs\GMPlayList.o .objs\GMPlaylistFrm.o .objs\SGauge.o .objs\cbMP.o .objs\wxAudiere.o .objs\GMOctoCtrl.o
-o cbMP.dll -Wl,--enable-auto-image-base -Wl,--export-all-symbols -Wl,--add-stdcall-alias -Wl,--enable-auto-import
-lcodeblocks -lwxmsw28u MSW_spez\TagLib\libtag.dll MSW_spez\Audiere\audiere.lib
Ok! I made it. Reason of problem was a mingw 3.4.5 that is not clever enough :lol:
But I have another problem: C::B not loaded - it crushes while loading.
This is the codeblocks.RPT contents:
-------------------
Error occured on Monday, June 1, 2009 at 10:27:31.
D:\bin\dev\c++\CodeBlocks\codeblocks.exe caused an Access Violation at location 66f5db58 in module D:\bin\dev\c++\CodeBlocks\share\codeblocks\plugins\cbMP.dll Reading from location 00000000.
Registers:
eax=00000000 ebx=00000000 ecx=00000000 edx=0281a6f8 esi=0022f6ec edi=6d265954
eip=66f5db58 esp=0022f280 ebp=0022f288 iopl=0 nv up ei pl nz ac pe nc
cs=001b ss=0023 ds=0023 es=0023 fs=003b gs=0000 efl=00210212
Call stack:
66F5DB58 D:\bin\dev\c++\CodeBlocks\share\codeblocks\plugins\cbMP.dll:66F5DB58
Maybe it's a bug? Or the matter is in the C::B version - 5602 (under Win XP).
Don't know what to do. :?
Have you copied the audiere.dll and libtag.dll to the Code::Blocks Installpath?
Else you could try to change the OUTPUT_HELP at cbMP.cpp line 52 from wxMEDIABACKEND_AUDIERE to wxMEDIABACKEND_WMP10.
Have you tried to install the binary cbMP.cbplugin? Do you get the same crash?
GeO
any one run this on linux ?
i compile it successfully but it says me that the sdk version is different :(
i attach my project file
my system is Ubuntu 9.04
wx from apt.wxwidgets.org
taglib form ubuntu
audiere from ubuntu
and 2 changes in the code
at GMPlayList.cpp
around lines 230 and 261 i change .c_str() to .char_str()
[attachment deleted by admin]
Quote from: PsYhLo on June 01, 2009, 01:00:39 PM
i compile it successfully but it says me that the sdk version is different :(
I tried it too, the problem is not the sdk version, but the dynamic libraries (libtag.so and audiere.so).
look at he Code::Blocks Logpane::
/home/[user]/.codeblocks/share/codeblocks/plugins/cbMP.so: not loaded (missing symbols?)
In Windows you just have to put this libraries to your Code::Blocks install. But in Linux (Ubuntu) i don't know
where to put it (i copied them in every folder that has something to do with Code::Blocks but i had no success :?)!!
GeO
Quote from: GeO on June 01, 2009, 05:26:03 PM
Quote from: PsYhLo on June 01, 2009, 01:00:39 PM
i compile it successfully but it says me that the sdk version is different :(
I tried it too, the problem is not the sdk version, but the dynamic libraries (libtag.so and audiere.so).
look at he Code::Blocks Logpane::
/home/[user]/.codeblocks/share/codeblocks/plugins/cbMP.so: not loaded (missing symbols?)
In Windows you just have to put this libraries to your Code::Blocks install. But in Linux (Ubuntu) i don't know
where to put it (i copied them in every folder that has something to do with Code::Blocks but i had no success :?)!!
GeO
It happens, because the medi-library of wxWidgets will not be loaded if you use default
wx-config parameters.
I attach a patch, that makes the plugin compilable and installable on linux (debian 64-bit).
But I'm not able to play any files. I can load a file (mp3 or ogg), but if I want to play it (double-click in the playlist) the following MessageBox pops up:
Error: Couldn't open file!
Debuginfo: OpenSampleSource()I also did not find a way to remove the file or add another one.
[attachment deleted by admin]
@jens codeblocks crash when i try your way
@ jens thx alot you fixed my problems with the libraries
Now cbMP works on Ubuntu (and on every OS with wxGTK support)!
I have updated the SVN repository (look at page 1)!
I created two build target Windows/Linux and i uploaded the libcbMP.cbplugin binary linked to the C::B svn rev 5616(from jens' repo) to http://sourceforge.net/project/showfiles.php?group_id=258661&package_id=323616 (http://sourceforge.net/project/showfiles.php?group_id=258661&package_id=323616)
Greets GeO