Hello Guest

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - pagu

Pages: [1]
1
Support / Re: multiplatform - simpler solution?
« on: July 24, 2013, 01:46:47 pm »
Ah, what about this one?

Quote
P.S. Is there a way to get the actual size of the camera? Camera.mainCamera.pixelHeight and Camera.mainCamera.pixelRect.yMax on the device returned 768 but moving an object to the upper corner of the screen shows that the value on the border of the screen is about 600. I need to know the actual borders of the camera so that I could spawn and destroy GameObjects when they are outside of the camera.

2
Support / Re: multiplatform - simpler solution?
« on: July 24, 2013, 10:08:35 am »
Ah... I see. Thanks!

3
Support / Re: multiplatform - simpler solution?
« on: July 24, 2013, 08:18:11 am »
I'm experimenting with all the options for handling different screen sizes, resolutions and aspect ratios for mobile (Android & iOS).

My scene is setup with resolution of 800x480 (landscape) using td2dCamera. I've added a resolution override with height = 768 and width = -1 with Autoscale = Pixel Perfect fit. I'm testing how the game will look on many of the Android devices out there. As expected, everything is smaller on the screen and bigger part of the scene is visible - this is what I've expected as the resolution of the device is almost double the scene resolution (800x480 vs 1280x768). After that I've added another spritesheet which is twice bigger than the first one and set it as x2 platform. The original one is x1. I've also set the current configuration to be x2. Launching the test on the Android device showed the sprites from the new spritesheet, however the physical size of the gameObject on the screen remained the same.

This is not pixel perfect. I've expected that setting the tk2dSystem.CurrentPlatform = "2x" and Autoscale = Pixel Perfect fit will result in twice bigger objects on the screen being pixel perfect. What actually happens is that the sprite is downscaled so that the physical dimension remains the same. Is this a bug or this is the expected behaviour?

P.S. Is there a way to get the actual size of the camera? Camera.mainCamera.pixelHeight and Camera.mainCamera.pixelRect.yMax on the device returned 768 but moving an object to the upper corner of the screen shows that the value on the border of the screen is about 600. I need to know the actual borders of the camera so that I could spawn and destroy GameObjects when they are outside of the camera.

Thank you!

Pages: [1]