mirror of
https://code.gri.mw/GUI/grim.git
synced 2026-07-20 05:38:55 +00:00
camera: fix image crop
This commit is contained in:
@@ -78,7 +78,7 @@ impl CameraContent {
|
||||
ui.vertical_centered(|ui| {
|
||||
egui::Image::from_texture(sized_image)
|
||||
// Setup to make image cropped at center of square.
|
||||
.uv(Rect::from([Pos2::new(0.125, 0.0), Pos2::new(1.125, 1.0)]))
|
||||
.uv(Rect::from([Pos2::new(0.25, 0.0), Pos2::new(1.0, 1.0)]))
|
||||
.max_height(ui.available_width())
|
||||
.maintain_aspect_ratio(false)
|
||||
.shrink_to_fit()
|
||||
|
||||
Reference in New Issue
Block a user