Installation ============ Add to your Gemfile: gem 'pixel' Usage ===== 50.pixels.high.calculate([100, 200]) => [50, 100] image_tag @image.url, size: 50.pixels.high.calculate(@image.dimensions).reverse.join('x')
Project
pixel
Quickly calculate the new dimensions of a resized image by giving it the original dimensions, and how many pixels wide or tall you need your new image to be
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
Development
Dependencies
Development
>= 0
Project Readme