]> git.nihav.org Git - nihav.git/commitdiff
nihav_core/formats: add channels iterator for NAChannelMap
authorKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 28 Jan 2026 17:54:25 +0000 (18:54 +0100)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 28 Jan 2026 17:54:25 +0000 (18:54 +0100)
nihav-core/src/formats.rs

index 4d6b906cce864df84760518fc21184e8d1cfec9b..722bd186dd750ee26271cbe29476172fd143b4d1 100644 (file)
@@ -305,6 +305,8 @@ impl NAChannelMap {
         }
         cm
     }
+    /// Returns an iterator over channels.
+    pub fn iter(&self) -> std::slice::Iter<'_, NAChannelType> { self.ids.iter() }
 }
 
 impl fmt::Display for NAChannelMap {