filter-utils: Check main filter nodes in a more robust way
This patch makes the check more robust when detecting main filter nodes. This is because some filters might append '/Internal' to their main node media class. The direction check has also been improved to work with Video filters.
This commit is contained in:
@@ -306,14 +306,13 @@ local function rescanFilters (om, metadata_om)
|
||||
|
||||
-- Only handle the main filter nodes
|
||||
filter.media_class = n.properties ["media.class"]
|
||||
if filter.media_class ~= "Audio/Sink" and
|
||||
filter.media_class ~= "Audio/Source" and
|
||||
filter.media_class ~= "Video/Source" then
|
||||
if string.find (filter.media_class, "Stream") then
|
||||
goto skip_linkable
|
||||
end
|
||||
|
||||
-- Filter direction
|
||||
if filter.media_class == "Audio/Sink" then
|
||||
if string.find (filter.media_class, "Audio/Sink") or
|
||||
string.find (filter.media_class, "Video/Sink") then
|
||||
filter.direction = "input"
|
||||
else
|
||||
filter.direction = "output"
|
||||
|
Reference in New Issue
Block a user