summaryrefslogtreecommitdiffstats
path: root/wgpu
diff options
context:
space:
mode:
Diffstat (limited to 'wgpu')
-rw-r--r--wgpu/src/backend.rs8
-rw-r--r--wgpu/src/layer.rs6
2 files changed, 7 insertions, 7 deletions
diff --git a/wgpu/src/backend.rs b/wgpu/src/backend.rs
index 25134d68..e86e52c4 100644
--- a/wgpu/src/backend.rs
+++ b/wgpu/src/backend.rs
@@ -147,8 +147,8 @@ impl Backend {
}
if !layer.meshes.is_empty() {
- let scaled = transformation
- * Transformation::scale(scale_factor, scale_factor);
+ let scaled =
+ transformation * Transformation::scale(scale_factor);
self.triangle_pipeline.prepare(
device,
@@ -161,8 +161,8 @@ impl Backend {
#[cfg(any(feature = "image", feature = "svg"))]
{
if !layer.images.is_empty() {
- let scaled = transformation
- * Transformation::scale(scale_factor, scale_factor);
+ let scaled =
+ transformation * Transformation::scale(scale_factor);
self.image_pipeline.prepare(
device,
diff --git a/wgpu/src/layer.rs b/wgpu/src/layer.rs
index 82e8ba02..4a2e72df 100644
--- a/wgpu/src/layer.rs
+++ b/wgpu/src/layer.rs
@@ -133,7 +133,7 @@ impl<'a> Layer<'a> {
position: *position * transformation,
color: *color,
clip_bounds: *clip_bounds * transformation,
- scale: transformation.scale_y(),
+ scale: transformation.scale_factor(),
});
}
Primitive::Editor {
@@ -149,7 +149,7 @@ impl<'a> Layer<'a> {
position: *position * transformation,
color: *color,
clip_bounds: *clip_bounds * transformation,
- scale: transformation.scale_y(),
+ scale: transformation.scale_factor(),
});
}
Primitive::Text {
@@ -169,7 +169,7 @@ impl<'a> Layer<'a> {
layer.text.push(Text::Cached(text::Cached {
content,
bounds: *bounds * transformation,
- size: *size * transformation.scale_y(),
+ size: *size * transformation.scale_factor(),
line_height: *line_height,
color: *color,
font: *font,