Log cleanup
This commit is contained in:
2 files changed
+8
-8
No files matched your search
@@ -516,7 +516,7 @@ impl StreamData {
|
||||
match data {
|
||||
BcMedia::Iframe(BcMediaIframe{data, microseconds, ..}) => {
|
||||
prev_ts = Duration::from_micros(microseconds as u64);
|
||||
log::debug!("IFrame: {prev_ts:?}");
|
||||
// log::debug!("IFrame: {prev_ts:?}");
|
||||
let d = StampedData{
|
||||
keyframe: true,
|
||||
data: Arc::new(data),
|
||||
@@ -536,7 +536,7 @@ impl StreamData {
|
||||
},
|
||||
BcMedia::Pframe(BcMediaPframe{data, microseconds,..}) if recieved_iframe => {
|
||||
prev_ts = Duration::from_micros(microseconds as u64);
|
||||
log::debug!("PFrame: {prev_ts:?}");
|
||||
// log::debug!("PFrame: {prev_ts:?}");
|
||||
// log::debug!("data: {data:02X?}");
|
||||
let d = StampedData{
|
||||
keyframe: false,
|
||||
@@ -554,7 +554,7 @@ impl StreamData {
|
||||
log::trace!("Sent Vid Frame");
|
||||
}
|
||||
BcMedia::Aac(BcMediaAac{data, ..}) | BcMedia::Adpcm(BcMediaAdpcm{data,..}) if recieved_iframe => {
|
||||
log::debug!("Audio: {prev_ts:?}");
|
||||
// log::debug!("Audio: {prev_ts:?}");
|
||||
let d = StampedData{
|
||||
keyframe: aud_keyframe,
|
||||
data: Arc::new(data),
|
||||
|
||||
+5
-5
@@ -486,11 +486,11 @@ fn hold_stream<E, T: Stream<Item = Result<StampedData, E>> + Unpin>(
|
||||
if let Ok(frame) = frame {
|
||||
if frame.keyframe {
|
||||
// Release
|
||||
log::debug!("Yielding: {}", held_frames.len());
|
||||
// log::debug!("Yielding: {}", held_frames.len());
|
||||
for held_frame in held_frames.drain(..) {
|
||||
yield Ok(held_frame);
|
||||
}
|
||||
log::debug!("Yielded");
|
||||
// log::debug!("Yielded");
|
||||
yield Ok(frame);
|
||||
} else {
|
||||
// Hold
|
||||
@@ -522,7 +522,7 @@ fn frametime_stream<E, T: Stream<Item = Result<StampedData, E>> + Unpin>(
|
||||
}
|
||||
|
||||
let delta_ts = std::cmp::min(curr_ts - prev_ts, MIN_FPS_DELTA);
|
||||
log::debug!("curr_ts: {curr_ts:?}, {prev_ts:?} delta_ts: {delta_ts:?}");
|
||||
// log::debug!("curr_ts: {curr_ts:?}, {prev_ts:?} delta_ts: {delta_ts:?}");
|
||||
|
||||
sleep_until(last_release + delta_ts).await;
|
||||
last_release = Instant::now();
|
||||
@@ -545,7 +545,7 @@ fn repeat_keyframe<E, T: Stream<Item = Result<StampedData, E>> + Unpin>(
|
||||
while let Some(frame) = stream.next().await {
|
||||
if let Ok(frame) = frame {
|
||||
if frame.keyframe {
|
||||
log::debug!("Key Frame");
|
||||
// log::debug!("Key Frame");
|
||||
let repeater = frame.clone();
|
||||
yield Ok(frame);
|
||||
|
||||
@@ -555,7 +555,7 @@ fn repeat_keyframe<E, T: Stream<Item = Result<StampedData, E>> + Unpin>(
|
||||
v = stream.next() => {
|
||||
if let Some(frame) = v {
|
||||
if let Ok(frame) = frame {
|
||||
log::debug!("Key Frame: Resume");
|
||||
// log::debug!("Key Frame: Resume");
|
||||
yield Ok(frame);
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user