I haven’t really used the Pixel Perfect camera component before, but it seems like it’s bugging out, unless this is intended behaviour. I am trying to learn the pixel perfect camera, to achieve the effect of:
On mobile, instead of having pillar / letter boxing, if the screen is a different size, then stretching the edges of the screen to fit. I assume that’s what the 2 squares are for - the dotted line being the critical main area, and the solid line being the extension? Unless I’m misunderstanding. In any case, my issue is below:
I have 2 monitors, which are different resolutions. One is HD, the other is 2560 x 1440. When the “Game” view window is on my larger screen, if I have the game window not maximized like the below screenshot, the green camera window looks like the above screenshot.
However, if I maximize the game window on my larger right screen, like this:
Then the main camera green square area looks like this:
The green square area gets smaller, throwing off where I placed all of my sprites. This seems like strange behaviour, which I assume is somehow related to the fact that my screens are both different resolutions.
For reference, the game view window is set to 16:9, which also gives an error:
Which doesn’t make sense to me on several levels:
- HD is also 16:9
- my games reference ration on the pixel perfect camera is 240 x 135, which is exactly 1/8 of HD
So either way you cut the cake, the pixels should be fine. The warning goes away if I set the camera aspect ratio to just HD. But if I do that, then I get this:
I don’t get the dotted lines anymore, and only a solid green line, which I am guessing will not expand out nicely like I want on different mobile screens and just stretch to fit. Maybe I am misunderstanding what this green camera outline is for and it doesn’t work how I think, and won’t do what I want, but either way, maximising or not maximising my game window seems like it should not affect anything.