Skip to content

Commit

Permalink
actually compile depending on target_os [ci-build]
Browse files Browse the repository at this point in the history
  • Loading branch information
prixt committed Feb 17, 2020
1 parent 17e4589 commit 0110062
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
13 changes: 7 additions & 6 deletions src/sound/sound_channel/loop_player.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,12 +151,13 @@ impl LoopPlayer {
}
).convert_samples::<f32>();
// TODO: make Spatial work in here!!
// let source = Spatial::new(
// source,
// [_balance, 1.0, 0.0],
// [-1.0, 0.0, 0.0],
// [1.0, 0.0, 0.0],
// );
#[cfg(not(target_os="windows"))]
let source = Spatial::new(
source,
[_balance, 1.0, 0.0],
[-1.0, 0.0, 0.0],
[1.0, 0.0, 0.0],
);
self.in_queue.fetch_add(1, Ordering::SeqCst);
let source = source::Done::new(source, self.in_queue.clone());
self.sleep_until_end = Some(self.queue_tx.append_with_signal(source));
Expand Down
13 changes: 7 additions & 6 deletions src/sound/sound_channel/oneshot_player.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,13 @@ impl OneshotPlayer {
}
).convert_samples::<f32>();
// TODO: make Spatial work in here!!
// let source = Spatial::new(
// source,
// [_balance, 1.0, 0.0],
// [-1.0, 0.0, 0.0],
// [1.0, 0.0, 0.0],
// );
#[cfg(not(target_os="windows"))]
let source = Spatial::new(
source,
[_balance, 1.0, 0.0],
[-1.0, 0.0, 0.0],
[1.0, 0.0, 0.0],
);
let source = source::Done::new(source, control_b.count.clone());
play_raw(device, source);
self.controls.push(control);
Expand Down

0 comments on commit 0110062

Please sign in to comment.