diff options
author | Hanspeter Portner <dev@open-music-kontrollers.ch> | 2019-04-07 10:14:21 +0200 |
---|---|---|
committer | Hanspeter Portner <dev@open-music-kontrollers.ch> | 2019-04-07 10:14:21 +0200 |
commit | ac9820a2f69963e70eb41a7c1cf23431b4282fc9 (patch) | |
tree | 0ef3250b695b7dbef3fa9e4451b1fec3f91cad27 | |
parent | 0e9d3a7a003da574ecb94e684e04eff727d21fbc (diff) | |
download | monitors.lv2-ac9820a2f69963e70eb41a7c1cf23431b4282fc9.tar.xz |
Squashed 'canvas.lv2/' changes from d5e603a..8bfdb96
8bfdb96 fix fitting in to bounding box.
git-subtree-dir: canvas.lv2
git-subtree-split: 8bfdb96bf4c95f68ca6c6de97eb0e59d33e58de4
-rw-r--r-- | canvas.lv2/idisp.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/canvas.lv2/idisp.h b/canvas.lv2/idisp.h index afe7371..099ab2c 100644 --- a/canvas.lv2/idisp.h +++ b/canvas.lv2/idisp.h @@ -44,7 +44,7 @@ _lv2_canvas_idisp_surf_init(LV2_Canvas_Idisp *idisp, int w, int h) LV2_Inline_Display_Image_Surface *surf = &idisp->image_surface; surf->width = w; - surf->height = w > h ? h : w; // try to use 1:1 ratio + surf->height = h; surf->stride = cairo_format_stride_for_width(CAIRO_FORMAT_ARGB32, surf->width); surf->data = realloc(surf->data, surf->stride * surf->height); if(!surf->data) @@ -113,7 +113,7 @@ lv2_canvas_idisp_surf_configure(LV2_Canvas_Idisp *idisp, W = w; H = w / aspect_ratio; } - else // aspect_ratio == 0.f + else // aspect_ratio == 1.f { W = w; H = h; |