You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My main inspiration is image-rs/image#2259, where the current image pixel types use an internal array like: struct Rgb<T>([T;3]) and also implement Index<usize> and IndexMutso if thergb` crates types also implemented those traits then the migration process would be easier.
On the other hand, using the field access (.r, .g, .b) seems much more readable to me so perhaps we shouldn't implement Index<usize> and instead refactor the image crate to field access when doing the migration.
The text was updated successfully, but these errors were encountered:
My main inspiration is image-rs/image#2259, where the current
image
pixel types use an internal array like:struct Rgb<T>([T;3])
and also implementIndex<usize>
and IndexMutso if the
rgb` crates types also implemented those traits then the migration process would be easier.On the other hand, using the field access (
.r
,.g
,.b
) seems much more readable to me so perhaps we shouldn't implementIndex<usize>
and instead refactor theimage
crate to field access when doing the migration.The text was updated successfully, but these errors were encountered: