Don't delete video node factories owned by the plugin loader.
Make the fallback factories members instead of creating on the heap so there's no need to delete members of the m_videoNodeFactories some of which may be shared with other current and future video outputs. Change-Id: I3d2e32e52479b12ff64e31a2ed527336d94a191b Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com> Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
This commit is contained in:
committed by
Qt by Nokia
parent
ba43d50b31
commit
655408bced
@@ -183,8 +183,8 @@ QDeclarativeVideoOutput::QDeclarativeVideoOutput(QQuickItem *parent) :
|
||||
}
|
||||
|
||||
// Append existing node factories as fallback if we have no plugins
|
||||
m_videoNodeFactories.append(new QSGVideoNodeFactory_I420);
|
||||
m_videoNodeFactories.append(new QSGVideoNodeFactory_RGB);
|
||||
m_videoNodeFactories.append(&m_i420Factory);
|
||||
m_videoNodeFactories.append(&m_rgbFactory);
|
||||
}
|
||||
|
||||
QDeclarativeVideoOutput::~QDeclarativeVideoOutput()
|
||||
@@ -197,7 +197,6 @@ QDeclarativeVideoOutput::~QDeclarativeVideoOutput()
|
||||
m_source.clear();
|
||||
_q_updateMediaObject();
|
||||
delete m_surface;
|
||||
qDeleteAll(m_videoNodeFactories);
|
||||
}
|
||||
|
||||
/*!
|
||||
|
||||
Reference in New Issue
Block a user