Hello Guest

Author Topic: Keeping sprites looking great at various Camera Zooms  (Read 4301 times)

rxmarcus

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 24
    • View Profile
Keeping sprites looking great at various Camera Zooms
« on: March 24, 2014, 10:29:30 pm »
Our game is 4 player on the same screen.  Because of this our 2dtk camera is frequently zooming in close on the action when players are close together and zooming out pretty far when players are spread far apart.  We have created our player sprites at a large enough resolution that they look good when the camera is zoomed in close, but when the camera is zoomed out far (0.25 zoom factor), the players look very blurry/blocky.  I'm not super experienced with 2dtk yet so I'm wondering if it has any features that would allow our player sprites to look clean and crisp at any zoom factor that the camera is currently set to.

Thanks for your time.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Keeping sprites looking great at various Camera Zooms
« Reply #1 on: March 25, 2014, 10:34:27 am »
There is no way to do that unless you're using vectors or some complicated scaling schemes that will only work for certain kinds of artwork, or a super expensive cubic upscale shader.

Graphics hardware upscales using either linear or point filtering, resulting in blurry or blocky images respectively. Any alternatives will have to be implemented explicitly.

rxmarcus

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 24
    • View Profile
Re: Keeping sprites looking great at various Camera Zooms
« Reply #2 on: March 25, 2014, 05:27:43 pm »
Does 2dtk support swapping out images on the fly during runtime?  If you could do this, could you have multiple resolutions of an image and swap out the image during runtime depending on the zoomFactor of the camera?  I wonder if this would even make a difference?

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Keeping sprites looking great at various Camera Zooms
« Reply #3 on: March 26, 2014, 10:44:20 am »
It could potentially make a difference, but will mean a substantial amount of work and memory for high res images - you could have started with higher resolution images and will get similar results with mipmaps. 2D Toolkit doesn't support swapping out images on the fly.