File: big-endian.patch

package info (click to toggle)
rust-glycin-utils 4.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 304 kB
  • sloc: makefile: 4
file content (12 lines) | stat: -rw-r--r-- 632 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
Origin: https://gitlab.gnome.org/GNOME/glycin/-/issues/158
--- a/src/editing/change_memory_format.rs
+++ b/src/editing/change_memory_format.rs
@@ -95,7 +95,7 @@ pub fn change_memory_format(
                 let k0 = x * target_pixel_n_bytes;
 
                 for i in 0..target_n_channels as usize {
-                    new_row[k0 + i] = (u16::from_ne_bytes([
+                    new_row[k0 + i] = (u16::from_le_bytes([
                         src_data[i0 + source_target_index_map[i] * source_channel_size],
                         src_data[i0 + source_target_index_map[i] * source_channel_size + 1],
                     ])