Commit bde75995 authored by Till Theato's avatar Till Theato Committed by Vincent PINON

Remove old "on screen display" code.

parent 45d1317d
......@@ -155,7 +155,6 @@ Render::~Render()
void Render::closeMlt()
{
//delete m_osdTimer;
m_requestList.clear();
m_infoThread.waitForFinished();
delete m_showFrameEvent;
......@@ -1317,7 +1316,6 @@ int Render::setSceneList(QString playlist, int position)
if (m_mltProducer) {
m_mltProducer->set_speed(0);
//if (KdenliveSettings::osdtimecode() && m_osdInfo) m_mltProducer->detach(*m_osdInfo);
/*Mlt::Service service(m_mltProducer->parent().get_service());
service.lock();
......@@ -1374,27 +1372,6 @@ int Render::setSceneList(QString playlist, int position)
m_mltProducer->set("meta.volume", (double)volume / 100);
m_mltProducer->optimise();
/*if (KdenliveSettings::osdtimecode()) {
// Attach filter for on screen display of timecode
delete m_osdInfo;
QString attr = "attr_check";
mlt_filter filter = mlt_factory_filter( "data_feed", (char*) attr.ascii() );
mlt_properties_set_int( MLT_FILTER_PROPERTIES( filter ), "_loader", 1 );
mlt_producer_attach( m_mltProducer->get_producer(), filter );
mlt_filter_close( filter );
m_osdInfo = new Mlt::Filter("data_show");
m_osdInfo->set("resource", m_osdProfile.toUtf8().constData());
mlt_properties properties = MLT_PRODUCER_PROPERTIES(m_mltProducer->get_producer());
mlt_properties_set_int( properties, "meta.attr.timecode", 1);
mlt_properties_set( properties, "meta.attr.timecode.markup", "#timecode#");
m_osdInfo->set("dynamic", "1");
if (m_mltProducer->attach(*m_osdInfo) == 1) kDebug()<<"////// error attaching filter";
} else {
m_osdInfo->set("dynamic", "0");
}*/
m_fps = m_mltProducer->get_fps();
if (position != 0) {
// Seek to correct place after opening project.
......@@ -1547,31 +1524,6 @@ void Render::slotSetVolume(int volume)
{
if (!m_mltConsumer || !m_mltProducer) return;
m_mltProducer->set("meta.volume", (double)volume / 100.0);
//return;
/*osdTimer->stop();
m_mltConsumer->set("refresh", 0);
// Attach filter for on screen display of timecode
mlt_properties properties = MLT_PRODUCER_PROPERTIES(m_mltProducer->get_producer());
mlt_properties_set_double( properties, "meta.volume", volume );
mlt_properties_set_int( properties, "meta.attr.osdvolume", 1);
mlt_properties_set( properties, "meta.attr.osdvolume.markup", i18n("Volume: ") + QString::number(volume * 100));
if (!KdenliveSettings::osdtimecode()) {
m_mltProducer->detach(*m_osdInfo);
mlt_properties_set_int( properties, "meta.attr.timecode", 0);
if (m_mltProducer->attach(*m_osdInfo) == 1) kDebug()<<"////// error attaching filter";
}*/
//refresh();
//m_osdTimer->setSingleShot(2500);
}
void Render::slotOsdTimeout()
{
mlt_properties properties = MLT_PRODUCER_PROPERTIES(m_mltProducer->get_producer());
mlt_properties_set_int(properties, "meta.attr.osdvolume", 0);
mlt_properties_set(properties, "meta.attr.osdvolume.markup", NULL);
//if (!KdenliveSettings::osdtimecode()) m_mltProducer->detach(*m_osdInfo);
refresh();
}
void Render::start()
......
......@@ -385,7 +385,6 @@ private:
Mlt::Producer *m_blackClip;
QString m_activeProfile;
QTimer *m_osdTimer;
QTimer m_refreshTimer;
QMutex m_mutex;
QMutex m_infoMutex;
......@@ -428,7 +427,6 @@ private slots:
/** @brief Refreshes the monitor display. */
void refresh();
void slotOsdTimeout();
/** @brief Process the clip info requests (in a separate thread). */
void processFileProperties();
/** @brief A clip with multiple video streams was found, ask what to do. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment