feat: add new image scaling modes#1699
Conversation
|
@ozcode2009 could you explain what the difference is? I thought the original aspect already did that... |
|
With the original scaling modes, the image is always top-left aligned. |
|
@ozcode2009 it's been a while since I've looked at these, but if memory serves me well, you just need to set MIXER ANCHOR to .5 .5 and the scaling will be center aligned. Could you try that? I don't have a box at hand at the moment. |
|
I feel like I remember changing the anchor like that works. Maybe it would be worth considering changing the default anchor (and potentially other properties) to be the middle, to make this simpler? I'm pretty sure it has annoyed me before when scaling things even manually. |
Same here. In more cases than not, it seems the expectation is that the anchor is at the center of the image. |
|
I guess default anchor points should be something to configure. Me working in the LED market scaling and positioning from top left is ideal, but ican understand this is different for other users. |
|
When I get some free time I'll write a new config option that will set a default mixer anchor point for scaled content if that satisfies everyone's interests. |
#1566 added support for new scaling modes, allowing for images' aspect ratios to be transformed in standard ways to get scaling modes like fit, fill, original, hfill, and vfill.
However, often with content that does not match the aspect ratio of the consumer, the image must be centered. This PR adds support for new scaling modes that are the same as the 5 added in #1566 but include a
_CENTEReg.FIT_CENTER, which both fits and centers the image.