Skip to content

Commit

Permalink
fix encoding issues
Browse files Browse the repository at this point in the history
  • Loading branch information
louis030195 committed Sep 3, 2024
1 parent 25e1bb5 commit fcf3612
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions screenpipe-audio/src/pcm_decode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,20 @@ pub fn pcm_decode<P: AsRef<std::path::Path>>(path: P) -> anyhow::Result<(Vec<f32
// Get the instantiated format reader.
let mut format = probed.format;

// Debug log the format information
debug!(
"Detected format: {:?}",
format.metadata().current().unwrap()
);

// Debug log all available tracks
for (idx, track) in format.tracks().iter().enumerate() {
debug!(
"Track {}: Codec: {:?}, Codec params: {:?}",
idx, track.codec_params.codec, track.codec_params
);
}

// Find the first audio track with a known (decodeable) codec.
let track = format
.tracks()
Expand Down

0 comments on commit fcf3612

Please sign in to comment.