equal
deleted
inserted
replaced
56 } |
56 } |
57 |
57 |
58 BackendNode::~BackendNode() |
58 BackendNode::~BackendNode() |
59 { |
59 { |
60 //this will remove the filter from the graph |
60 //this will remove the filter from the graph |
61 mediaObjectDestroyed(); |
61 FILTER_INFO info; |
|
62 for(int i = 0; i < FILTER_COUNT; ++i) { |
|
63 const Filter &filter = m_filters[i]; |
|
64 if (!filter) |
|
65 continue; |
|
66 filter->QueryFilterInfo(&info); |
|
67 if (info.pGraph) { |
|
68 HRESULT hr = info.pGraph->RemoveFilter(filter); |
|
69 |
|
70 if (hr == VFW_E_NOT_STOPPED && m_mediaObject) { |
|
71 m_mediaObject->ensureStopped(); |
|
72 |
|
73 hr = info.pGraph->RemoveFilter(filter); |
|
74 } |
|
75 Q_ASSERT(SUCCEEDED(hr)); |
|
76 info.pGraph->Release(); |
|
77 } |
|
78 } |
62 } |
79 } |
63 |
80 |
64 void BackendNode::setMediaObject(MediaObject *mo) |
81 void BackendNode::setMediaObject(MediaObject *mo) |
65 { |
82 { |
66 if (m_mediaObject) { |
83 if (m_mediaObject) { |