[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: ThumbCreator
From:       Bosselut Cyril <bosselut () b1project ! com>
Date:       2004-03-29 21:20:21
Message-ID: 200403292319.05459 () B1ProjectMailServer
[Download RAW message or body]

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

i've modified my Makefile.am so now the lib is in /usr/lib/kde3 but i get the 
same error
i've attached my files, so i you see something ;)

Le lundi 29 Mars 2004 20:58, Kevin Krammer a écrit :
> On Tuesday 30 March 2004 00:48, Bosselut Cyril wrote:
> > it's not that :(
> > my kdedir is /usr
> > libmp3thumbnail.la and libmp3thumbnail.so are in /usr/lib
>
> Shouldn't that be /usr/lib/kde3, the "modules" directory?
>
> Maybe you can track down here it fails loading by using a small test
> application that uses KTrader to query for the servicetype and then trys to
> get the symbol.
>
> Cheers,
> Kevin

- -- 
Certaines zones de peche commencent a etre
tellement polluees par les hydrocarbures
qu'on y peche des turbots diesels.
	-- P. Geluck
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAaK7p9J4lbJfupC0RAodeAJ9gwSQ2s85BJ4oUT54uQWyFTeZNgwCgjMsZ
LW1AEeXb14F5oGTKtoIpmA4=
=VZab
-----END PGP SIGNATURE-----

["mp3thumbcreator.cpp" (text/x-c++src)]

/***************************************************************************
 *   Copyright (C) 2004 by Cyril Bosselut                                  *
 *   bosselut@b1project.com                                                *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 *   This program is distributed in the hope that it will be useful,       *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 *   GNU General Public License for more details.                          *
 *                                                                         *
 *   You should have received a copy of the GNU General Public License     *
 *   along with this program; if not, write to the                         *
 *   Free Software Foundation, Inc.,                                       *
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
 ***************************************************************************/
#include "mp3thumbcreator.h"
#include "../tags.h"
#include <qimage.h>
#include <kdebug.h>

MP3ThumbCreator::MP3ThumbCreator() : ThumbCreator()
{
}


MP3ThumbCreator::~MP3ThumbCreator() {
}

bool MP3ThumbCreator::create(const QString &path, int width, int height, QImage &img)
{
	Tags *tags = new Tags(path);
	kdDebug("ThumbCreator") << path << endl;
	if(tags->isMP3()){
		tags->ReadId3();
		if(tags->haveCover){
			img = (tags->cover).smoothScale(height, width, QImage::ScaleMin);
			return true;
		}
		else{
			return false;
		}
	}
	else{
		return false;
	}

}


["mp3thumbcreator.h" (text/x-chdr)]

/***************************************************************************
 *   Copyright (C) 2004 by Cyril Bosselut                                  *
 *   bosselut@b1project.com                                                *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 *   This program is distributed in the hope that it will be useful,       *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 *   GNU General Public License for more details.                          *
 *                                                                         *
 *   You should have received a copy of the GNU General Public License     *
 *   along with this program; if not, write to the                         *
 *   Free Software Foundation, Inc.,                                       *
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
 ***************************************************************************/
#ifndef MP3THUMBCREATOR_H
#define MP3THUMBCREATOR_H

#include <kio/thumbcreator.h>


class MP3ThumbCreator : public ThumbCreator
{
public:
    MP3ThumbCreator();
    ~MP3ThumbCreator();
    virtual bool create(const QString &path, int width, int height, QImage &img);
    virtual Flags flags() const
    {
        return BlendIcon; // try BlendIcon as an alternative
    }
};

#endif

["mp3thumbnail.cpp" (text/x-c++src)]

/***************************************************************************
 *   Copyright (C) 2004 by Cyril Bosselut                                  *
 *   bosselut@b1project.com                                                *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 *   This program is distributed in the hope that it will be useful,       *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 *   GNU General Public License for more details.                          *
 *                                                                         *
 *   You should have received a copy of the GNU General Public License     *
 *   along with this program; if not, write to the                         *
 *   Free Software Foundation, Inc.,                                       *
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
 ***************************************************************************/
#include "mp3thumbcreator.h"

extern "C"
 {
   ThumbCreator *new_creator()
   {
     return new MP3ThumbCreator();
   }
 };

["Makefile.am" (text/x-makefile)]

INCLUDES = -I$(top_srcdir)/src $(all_includes)
METASOURCES = AUTO

noinst_HEADERS =  mp3thumbcreator.h tags.h

kde_module_LTLIBRARIES =  libmp3thumbnail.la
libmp3thumbnail_la_SOURCES =  mp3thumbnail.cpp mp3thumbcreator.cpp tags.cpp
libmp3thumbnail_la_LIBADD = $(LIB_KIO)
libmp3thumbnail_la_LDFLAGS = -module $(all_libraries) $(KDE_PLUGIN) $(KDE_RPATH)

kde_servicesdir = $(kde_datadir)/services
kde_services_DATA =  mp3thumbnail.desktop


>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic