Solved

Conform picture to 8x12 format

Posted on 2011-03-09
1
243 Views
Last Modified: 2012-06-22
I've used some of the PHP image functions and have been quite impressed.  I was wondering if it could help me with this project.  I have .jpg files all of different sizes and proportions.  I need to print them all on 8x12 prints.  What I have been doing is using my calculator and enlarging the canvas and adding black bars where space needs to be filled, so that it fulfills the 8x12 ratio.

I can't help but think this could be done programatically using PHP.
0
Comment
Question by:hrolsons
1 Comment
 
LVL 34

Accepted Solution

by:
Beverley Portlock earned 500 total points
ID: 35087987
If you can work out the pixel size then you can use the image resize routine in the question below to ensure that your resized image fits within the pixel sizes for your image

http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/PHP/Q_24935011.html#25924977

Adding the borders would be a matter of calculationg two rectangles in the appropriate places and filling them with black (or white)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
This article discusses four methods for overlaying images in a container on a web page
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now