}
KThumb::~KThumb() {
- if (audioThumbProducer.isRunning()) audioThumbProducer.exit();
+ if (audioThumbProducer.isRunning()) {
+ slotAudioThumbOver();
+ audioThumbProducer.stop_me = true;
+ audioThumbProducer.wait(300);
+ }
}
void KThumb::setProducer(Mlt::Producer *producer) {
m_dar = producer->profile()->dar();
}
+void KThumb::clearProducer() {
+ m_producer = NULL;
+}
+
bool KThumb::hasProducer() const {
return m_producer != NULL;
}
-void KThumb::updateClipUrl(KUrl url) {
+void KThumb::updateThumbUrl(const QString &hash) {
+ m_thumbFile = m_clipManager->projectFolder() + "/thumbs/" + hash + ".thumb";
+}
+
+void KThumb::updateClipUrl(KUrl url, const QString &hash) {
m_url = url;
if (m_producer) {
char *tmp = Render::decodedString(url.path());
m_producer->set("resource", tmp);
delete[] tmp;
}
+ m_thumbFile = m_clipManager->projectFolder() + "/thumbs/" + hash + ".thumb";
}
//static