| Code-Review | +1 |
let duration_ms: f64 = match fh.duration {Why don't we just do `duration_ms = fh.duration.unwrap_or(0.0)`?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Why don't we just do `duration_ms = fh.duration.unwrap_or(0.0)`?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Should update the commit message about the `FrameDurationAtIndex` fix?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
4 is the latest approved patch-set.
The change was submitted with unreviewed changes in the following files:
```
The name of the file: third_party/rust/jxl/v0_2/wrapper/lib.rs
Insertions: 1, Deletions: 6.
@@ -283,13 +283,8 @@
fn extract_frame_header(&self) -> Option<JxlRsFrameHeader> {
let fh = self.decoder.frame_header()?;
- let duration_ms: f64 = match fh.duration {
- Some(d) if d.is_finite() && d >= 0.0 => d,
- _ => 0.0,
- };
-
Some(JxlRsFrameHeader {
- duration_ms,
+ duration_ms: fh.duration.unwrap_or(0.0),
name_length: fh.name.len() as u32,
})
}
```
Fix JXL animation drift by preserving frame duration precision
Frame durations were being truncated from f64 to u32 in the Rust FFI
wrapper, causing animations to slowly drift out of sync when looping.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |