chore: add more logging in /render to debug
This commit is contained in:
@@ -340,11 +340,22 @@ pub async fn handle(state: State, interaction: Interaction) {
|
|||||||
|
|
||||||
let after_start = datetime - start;
|
let after_start = datetime - start;
|
||||||
|
|
||||||
|
let progress_by_time = after_start / duration;
|
||||||
|
|
||||||
let origin = (after_start.whole_seconds() as u32 * sample_rate)
|
let origin = (after_start.whole_seconds() as u32 * sample_rate)
|
||||||
+ (after_start.subsec_microseconds() as u32 * sample_rate / 1_000_000);
|
+ (after_start.subsec_microseconds() as u32 * sample_rate / 1_000_000);
|
||||||
let origin = origin as usize;
|
let origin = origin as usize;
|
||||||
|
|
||||||
tracing::debug!(origin, total_samples);
|
let progress_by_sample = (origin as f64) / (total_samples as f64);
|
||||||
|
|
||||||
|
tracing::debug!(
|
||||||
|
progress_by_time,
|
||||||
|
progress_by_sample,
|
||||||
|
?after_start,
|
||||||
|
?duration,
|
||||||
|
origin,
|
||||||
|
total_samples
|
||||||
|
);
|
||||||
|
|
||||||
for (i, sample) in samples.into_iter().enumerate() {
|
for (i, sample) in samples.into_iter().enumerate() {
|
||||||
if let Some(composite_sample) = composite.get_mut(origin + i) {
|
if let Some(composite_sample) = composite.get_mut(origin + i) {
|
||||||
|
|||||||
Reference in New Issue
Block a user