November 22, 2017, 01:03:29 AM

Author Topic: zoomEven scale method  (Read 137 times)

mikale

  • Newbie
  • *
  • Posts: 12
    • View Profile
zoomEven scale method
« on: September 29, 2017, 05:45:00 AM »
Hi all,

I'm having a hard time figuring this out, I really wish there was an official tutorial for developing for multiple screen sizes but this is what I want to do.
I want to use the zoomEven scale method for my game, taken from Corona SDK's documentation:
 


The letterbox method is outdated and no longer accepted by Apple. The second method works for me when I code in Corona because I use fairly hi res assets and I'm not too picky about a slight bit of upscaling or downscaling.
I just need to be able to add something to my startup code so I can develop my game for one screen size, and it will scale it up or down, and center it accordingly (in portrait or landscape).

Any help would be very appreciated! :) Thanks!

bendmorris

  • Global Moderator
  • Jr. Member
  • *****
  • Posts: 85
    • View Profile
Re: zoomEven scale method
« Reply #1 on: October 17, 2017, 09:34:59 AM »
It sounds like what you want is haxepunk.screen.UniformScaleMode, with the first argument set to UniformScaleType.ZoomIn. If you take a look at the examples, there's a "screenscale" project which shows the different variations of scaling methods we support.

AndrewBradd

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: zoomEven scale method
« Reply #2 on: October 24, 2017, 10:07:50 PM »
Great I will try to see how to return to what it is.