Search Ctrl K
Home / Tools
THE FEUTEX TOOLKIT

Pixel Art Integer Camera Scale

Find integer upscaling and letterbox borders for pixel-art games.

Gaming workspace● Runs in your browser
01 Your input
02 Your result
View or copy raw result data
FormulaScale = Math.floor(Math.min(screen_width/base_width,screen_height/base_height)); Border y = (screen_height-base_height*Math.floor(Math.min(screen_width/base_width,screen_height/base_height)))/2

Made for real tasks

  • Find integer upscaling and letterbox borders for pixel-art games.
  • Compare two scenarios by changing the inputs and rerunning the tool.
Explore step-by-step workflows →

Worked example

Inputs

Base width
320 px
Base height
180 px
Screen width
1920 px
Screen height
1200 px

Expected results

Scale
6 ×
Border y
60 px

Load the example in the workspace to reproduce these results. Display rounding does not change the underlying calculation.

How to use this tool

  1. Enter base width, base height, screen width, screen height.
  2. Use consistent units shown beside each input. Run the calculation and review the assumptions below.

Try this example

{
  "base_width": 320,
  "base_height": 180,
  "screen_width": 1920,
  "screen_height": 1200
}

Accuracy and scope

Uses the largest whole-number scale that fits both dimensions; centered borders can be half a pixel. No noninteger downscaling, device pixel ratio or engine rendering configuration.

Is my data uploaded?

This tool runs locally in your browser. Input and output are not sent to a processing server. Copy or download your result before leaving the page.