Skip to content

Commit

Permalink
fix crash trying to add GPU filter to Output
Browse files Browse the repository at this point in the history
This fix simply prevents offering the GPU filters for the Output track.
  • Loading branch information
ddennedy committed Jul 27, 2023
1 parent 796a45e commit df40a4d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/models/metadatamodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
*/

#include "metadatamodel.h"
#include "controllers/filtercontroller.h"
#include "mainwindow.h"
#include "qmltypes/qmlmetadata.h"
#include "settings.h"
#include <Logger.h>
Expand Down Expand Up @@ -162,6 +164,9 @@ bool MetadataModel::isVisible(int row) const
if (meta->filterMask & m_filterMask) {
return false;
}
if (Settings.playerGPU() && meta->needsGPU() && MAIN.filterController()->isOutputTrackSelected()) {
return false;
}
if (m_search.isEmpty()) {
switch (m_filter) {
case FavoritesFilter:
Expand Down

0 comments on commit df40a4d

Please sign in to comment.